* * Init smacker decoder * */
| 509 | * |
| 510 | */ |
| 511 | static av_cold int decode_init(AVCodecContext *avctx) |
| 512 | { |
| 513 | SmackVContext * const c = avctx->priv_data; |
| 514 | |
| 515 | c->avctx = avctx; |
| 516 | |
| 517 | avctx->pix_fmt = PIX_FMT_PAL8; |
| 518 | |
| 519 | |
| 520 | /* decode huffman trees from extradata */ |
| 521 | if(avctx->extradata_size < 16){ |
| 522 | av_log(avctx, AV_LOG_ERROR, "Extradata missing!\n"); |
| 523 | return -1; |
| 524 | } |
| 525 | |
| 526 | decode_header_trees(c); |
| 527 | |
| 528 | |
| 529 | return 0; |
| 530 | } |
| 531 | |
| 532 | |
| 533 |
nothing calls this directly
no test coverage detected