
#include <twl/tcl.h>
TCLResult TCL_EncodeAndWritePicture( TCLAccessor* pAccessor ,
const void* imageBuffer ,
u8* jpegBuffer ,
u32 jpegBufferSize ,
u8* workBuffer ,
u32 quality ,
u32 option ,
FSResult* pFSResult );
TCLResult TCL_EncodeAndWritePictureEx( TCLAccessor* pAccessor ,
const void* imageBuffer ,
u8* jpegBuffer ,
u32 jpegBufferSize ,
u8* workBuffer ,
u32 quality ,
u32 option ,
u8* makerNoteBuffer ,
u16 makerNoteBufferSize ,
FSResult* pFSResult );
pAccessor | Accessor |
imageBuffer | Source image buffer |
jpegBuffer | JPEG image buffer |
jpegBufferSize | Size of the JPEG image buffer |
workBuffer | JPEG encoding work buffer |
quality | JPEG encoding quality |
option | JPEG encoding option |
makerNoteBuffer | User maker note buffer |
makerNoteBufferSize | User maker note buffer size |
pFSResult | Processing result when an error has been generated by an FS function inside this function |
Encodes the source image data in JPEG and saves the data. Internally calls the SSP_StartJpegEncoder function.
It is necessary for the source image to have VGA dimensions.
The work buffer should allocate the size determined by the TCL_GetJpegEncoderBufferSize function.
After encoding succeeds, saves to the JPEG image's next save path and overwrites the management file.
If this function returns TCL_RESULT_ERROR_NO_NEXT_INDEX, the JPEG image cannot be saved because of a path restriction. Note that this error is also returned when TCL_CalcNumEnableToTakePictures is greater than 0.
The accessor must be initialized by the TCL_LoadTable or TCL_CreateTable function.
2008/12/05 Initial version.
CONFIDENTIAL