daala
0.0-281-ga767b96
Experimental Daala video codec API reference.
|
Modules | |
Configuration keys for the decoder ctl interface. | |
Decoder CTL settings. | |
Functions for decoding | |
You must link to | |
int | daala_decode_header_in (daala_info *info, daala_comment *dc, daala_setup_info **ds, const ogg_packet *op) |
Parses the header packets from an Ogg Daala stream. More... | |
daala_dec_ctx * | daala_decode_alloc (const daala_info *info, const daala_setup_info *setup) |
Allocates a decoder instance. More... | |
void | daala_setup_free (daala_setup_info *setup) |
Releases all storage used for the decoder setup information. More... | |
int | daala_decode_ctl (daala_dec_ctx *dec, int req, void *buf, size_t buf_sz) |
Decoder control function. More... | |
void | daala_decode_free (daala_dec_ctx *dec) |
Frees an allocated decoder instance. More... | |
int | daala_decode_packet_in (daala_dec_ctx *dec, od_img *img, const ogg_packet *op) |
Retrieves decoded video data frames. More... | |
int daala_decode_header_in | ( | daala_info * | info, |
daala_comment * | dc, | ||
daala_setup_info ** | ds, | ||
const ogg_packet * | op | ||
) |
Parses the header packets from an Ogg Daala stream.
To use this function:
info | The daala_info structure to fill in. This must have been previously initialized with daala_info_init(). The application may begin using the contents of this structure after the first header is decoded, though it must continue to be passed in unmodified on all subsequent calls. |
dc | The daala_comment structure to fill in. This must have been previously initialized with daala_comment_init(). The application may immediately begin using the contents of this structure after the second header is decoded, though it must continue to be passed in on all subsequent calls. |
ds | A pointer to a daala_setup_info pointer to fill in. The contents of this pointer must be initialized to NULL on the first call, and the returned value must continue to be passed in on all subsequent calls. |
op | The current header packet to process. |
0 | The first video data packet was encountered after all required header packets were parsed. The packet just passed to this call should be saved and fed to daaala_decode_packet_in() to begin decoding video data. |
OD_EFAULT | One of info, dc, or ds was NULL , or there was a memory allocation failure. |
OD_EBADHEADER | op was NULL , the packet was not the next header packet in the expected sequence, or the format fo the header data was invalid. |
OD_EVERSION | The packet data was a Daala header, but for a bitstream version not decodable with this version of libdaaladec . |
OD_ENOTFORMAT | The packet was not a Daala header. |
daala_dec_ctx* daala_decode_alloc | ( | const daala_info * | info, |
const daala_setup_info * | setup | ||
) |
Allocates a decoder instance.
info | A daala_info struct filled via daala_decode_header_in(). |
setup | A daala_setup_info handle returned via daala_decode_header_in(). |
NULL | If the decoding parameters were invalid. |
void daala_setup_free | ( | daala_setup_info * | setup | ) |
Releases all storage used for the decoder setup information.
This should be called after you no longer want to create any decoders for a stream whose headers you have parsed with daala_decode_header_in().
setup | The setup information to free. This can safely be NULL . |
int daala_decode_ctl | ( | daala_dec_ctx * | dec, |
int | req, | ||
void * | buf, | ||
size_t | buf_sz | ||
) |
Decoder control function.
This is used to provide advanced control of the decoding process.
dec | A daala_dec_ctx handle. |
req | The control code to process. See the list of available control codes for details. |
buf | The parameters for this control code. |
buf_sz | The size of the parameter buffer. |
void daala_decode_free | ( | daala_dec_ctx * | dec | ) |
Frees an allocated decoder instance.
dec | A daala_dec_ctx handle. |
int daala_decode_packet_in | ( | daala_dec_ctx * | dec, |
od_img * | img, | ||
const ogg_packet * | op | ||
) |
Retrieves decoded video data frames.
dec | A daala_dec_ctx handle. |
img | A buffer to receive the decoded image data. |
op | An incoming Ogg packet. |