All Classes Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
Loading...
Searching...
No Matches
CameraFrame Struct Reference

Public Attributes

uint64_t timestamp { 0 }
 Frame timestamp at end of exposure in nanoseconds.
 
uint64_t exposureTime { 0 }
 Exposure duration in nanoseconds.
 
uint8_t * buffer { nullptr }
 Pointer to first byte of the pixel buffer.
 
uint32_t bufferSize { 0 }
 Size of the pixel buffer in bytes.
 
uint32_t index { 0 }
 Frame index, ascending number.
 
uint32_t width { 0 }
 Frame width.
 
uint32_t height { 0 }
 Frame height.
 
uint32_t stride { 0 }
 Stride value indicating how many bytes are used per row.
 
PixelFormat format { PixelFormat::YUYV }
 Frame format.
 
CameraIntrinsics intrinsics
 Camera intrinsics used to capture the frame.
 

Detailed Description

Data structure describing a camera frame.

Member Data Documentation

◆ timestamp

uint64_t timestamp { 0 }

Frame timestamp at end of exposure in nanoseconds.

Note
The time base varies between the platforms. On Android CLOCK_MONOTONIC is used, the current timestamp can be obtained with clock_gettime().

◆ stride

uint32_t stride { 0 }

Stride value indicating how many bytes are used per row.

Note
If the frame is tightly packed this should equal to width * bytes per pixel. For NV12 and NV21 images, this should be the stride of the Y plane in bytes and the stride of the UV plane must be identical. For YUV420p and YV12 images, this should be the stride of the Y plane in bytes. The stride of the U and V planes must be exactly half of that.