CAMSurface

Syntax

#include <cafe/camera/camera.h>

//enumerates pixel formats for target decode surface 
typedef enum _CAMERA_PIXEL_FORMAT
{
    CAMERA_NV12 = 0

} CAMERA_PIXEL_FORMAT;

//enumerates tiling modes for target decode surface 
typedef enum _CAMERA_TILE_MODE
{
    CAMERA_LINEAR = 0

} CAMERA_TILE_MODE;

typedef struct _CAMSurface
{
    int  imageSize;    
    void *imagePtr;    
    int  height;       
    int  width;        
    int  pitch;        
    int  alignment;    
    CAMERA_TILE_MODE     tileMode;   
    CAMERA_PIXEL_FORMAT  pixelFormat;  
} CAMSurface;

Elements

imageSize Size of the image in bytes.
imagePtr Pointer to the image.
height Height of the image in pixels.
width Width of the image in pixels.
pitch Pitch of the image in bytes.
alignment Alignment in bytes of the starting address of the image.
tileMode Tiling mode of the image.
pixelFormat Pixel format of the image.

Description

The CAMSurface structure stores information about the decode target surface that is listed in the table above.

NV12 is currently the only supported surface format. FOURCC.org (http://www.fourcc.org) describes the format as:

"YUV 4:2:0 image with a plane of 8-bit Y samples followed by an interleaved U/V plane containing 8-bit 2x2 subsampled color difference samples."

The camera library imposes the following additional restrictions.

See Also

CAMSubmitTargetSurface

Revision History

2014/06/24 Reworked external link.
2013/05/08 Automated cleanup pass.
2011/10/24 Initial version.


CONFIDENTIAL