Mercurial > libavcodec.hg
comparison parser.c @ 3989:eddcc352c0dc libavcodec
doxy
| author | michael |
|---|---|
| date | Wed, 11 Oct 2006 10:29:00 +0000 |
| parents | c8c591fe26f8 |
| children | 04ff8026d9c0 |
comparison
equal
deleted
inserted
replaced
| 3988:3041b7b5476c | 3989:eddcc352c0dc |
|---|---|
| 69 } | 69 } |
| 70 s->fetch_timestamp=1; | 70 s->fetch_timestamp=1; |
| 71 return s; | 71 return s; |
| 72 } | 72 } |
| 73 | 73 |
| 74 /* NOTE: buf_size == 0 is used to signal EOF so that the last frame | 74 /** |
| 75 can be returned if necessary */ | 75 * |
| 76 * @param buf input | |
| 77 * @param buf_size input length, to signal EOF, this should be 0 (so that the last frame can be output) | |
| 78 * @param pts input presentation timestamp | |
| 79 * @param dts input decoding timestamp | |
| 80 * @param poutbuf will contain a pointer to the first byte of the output frame | |
| 81 * @param poutbuf_size will contain the length of the output frame | |
| 82 * @return the number of bytes of the input bitstream used | |
| 83 * | |
| 84 * Example: | |
| 85 * @code | |
| 86 * while(in_len){ | |
| 87 * len = av_parser_parse(myparser, AVCodecContext, &data, &size, | |
| 88 * in_data, in_len, | |
| 89 * pts, dts); | |
| 90 * in_data += len; | |
| 91 * in_len -= len; | |
| 92 * | |
| 93 * decode_frame(data, size); | |
| 94 * } | |
| 95 * @endcode | |
| 96 */ | |
| 76 int av_parser_parse(AVCodecParserContext *s, | 97 int av_parser_parse(AVCodecParserContext *s, |
| 77 AVCodecContext *avctx, | 98 AVCodecContext *avctx, |
| 78 uint8_t **poutbuf, int *poutbuf_size, | 99 uint8_t **poutbuf, int *poutbuf_size, |
| 79 const uint8_t *buf, int buf_size, | 100 const uint8_t *buf, int buf_size, |
| 80 int64_t pts, int64_t dts) | 101 int64_t pts, int64_t dts) |
