| 21 | #include "parser.h" |
| 22 | |
| 23 | static int parse(AVCodecParserContext *s, |
| 24 | AVCodecContext *avctx, |
| 25 | const uint8_t **poutbuf, int *poutbuf_size, |
| 26 | const uint8_t *buf, int buf_size) |
| 27 | { |
| 28 | if(avctx->codec_id == CODEC_ID_THEORA) |
| 29 | s->pict_type= (buf[0]&0x40) ? FF_P_TYPE : FF_I_TYPE; |
| 30 | else |
| 31 | s->pict_type= (buf[0]&0x80) ? FF_P_TYPE : FF_I_TYPE; |
| 32 | |
| 33 | *poutbuf = buf; |
| 34 | *poutbuf_size = buf_size; |
| 35 | return buf_size; |
| 36 | } |
| 37 | |
| 38 | AVCodecParser vp3_parser = { |
| 39 | { CODEC_ID_THEORA, CODEC_ID_VP3, |
no outgoing calls
no test coverage detected