00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00030 #define BITSTREAM_READER_LE
00031 #include "avcodec.h"
00032 #include "get_bits.h"
00033 #include "dsputil.h"
00034 #include "ivi_dsp.h"
00035 #include "ivi_common.h"
00036 #include "indeo4data.h"
00037
00041 enum {
00042 FRAMETYPE_INTRA = 0,
00043 FRAMETYPE_INTRA1 = 1,
00044 FRAMETYPE_INTER = 2,
00045 FRAMETYPE_BIDIR = 3,
00046 FRAMETYPE_INTER_NOREF = 4,
00047 FRAMETYPE_NULL_FIRST = 5,
00048 FRAMETYPE_NULL_LAST = 6
00049 };
00050
00051 #define IVI4_PIC_SIZE_ESC 7
00052
00053
00054 static const struct {
00055 InvTransformPtr *inv_trans;
00056 DCTransformPtr *dc_trans;
00057 int is_2d_trans;
00058 } transforms[18] = {
00059 { ff_ivi_inverse_haar_8x8, ff_ivi_dc_haar_2d, 1 },
00060 { NULL, NULL, 0 },
00061 { NULL, NULL, 0 },
00062 { ff_ivi_put_pixels_8x8, ff_ivi_put_dc_pixel_8x8, 1 },
00063 { ff_ivi_inverse_slant_8x8, ff_ivi_dc_slant_2d, 1 },
00064 { ff_ivi_row_slant8, ff_ivi_dc_row_slant, 1 },
00065 { ff_ivi_col_slant8, ff_ivi_dc_col_slant, 1 },
00066 { NULL, NULL, 0 },
00067 { NULL, NULL, 0 },
00068 { NULL, NULL, 0 },
00069 { NULL, NULL, 0 },
00070 { ff_ivi_inverse_slant_4x4, ff_ivi_dc_slant_2d, 1 },
00071 { NULL, NULL, 0 },
00072 { NULL, NULL, 0 },
00073 { NULL, NULL, 0 },
00074 { NULL, NULL, 0 },
00075 { NULL, NULL, 0 },
00076 { NULL, NULL, 0 },
00077 };
00078
00089 static int decode_plane_subdivision(GetBitContext *gb)
00090 {
00091 int i;
00092
00093 switch (get_bits(gb, 2)) {
00094 case 3:
00095 return 1;
00096 case 2:
00097 for (i = 0; i < 4; i++)
00098 if (get_bits(gb, 2) != 3)
00099 return 0;
00100 return 4;
00101 default:
00102 return 0;
00103 }
00104 }
00105
00106 static inline int scale_tile_size(int def_size, int size_factor)
00107 {
00108 return size_factor == 15 ? def_size : (size_factor + 1) << 5;
00109 }
00110
00118 static int decode_pic_hdr(IVI45DecContext *ctx, AVCodecContext *avctx)
00119 {
00120 int pic_size_indx, i, p;
00121 IVIPicConfig pic_conf;
00122
00123 if (get_bits(&ctx->gb, 18) != 0x3FFF8) {
00124 av_log(avctx, AV_LOG_ERROR, "Invalid picture start code!\n");
00125 return AVERROR_INVALIDDATA;
00126 }
00127
00128 ctx->prev_frame_type = ctx->frame_type;
00129 ctx->frame_type = get_bits(&ctx->gb, 3);
00130 if (ctx->frame_type == 7) {
00131 av_log(avctx, AV_LOG_ERROR, "Invalid frame type: %d\n", ctx->frame_type);
00132 return AVERROR_INVALIDDATA;
00133 }
00134
00135 #if IVI4_STREAM_ANALYSER
00136 if (ctx->frame_type == FRAMETYPE_BIDIR)
00137 ctx->has_b_frames = 1;
00138 #endif
00139
00140 ctx->transp_status = get_bits1(&ctx->gb);
00141 #if IVI4_STREAM_ANALYSER
00142 if (ctx->transp_status) {
00143 ctx->has_transp = 1;
00144 }
00145 #endif
00146
00147
00148 if (get_bits1(&ctx->gb)) {
00149 av_log(avctx, AV_LOG_ERROR, "Sync bit is set!\n");
00150 return AVERROR_INVALIDDATA;
00151 }
00152
00153 ctx->data_size = get_bits1(&ctx->gb) ? get_bits(&ctx->gb, 24) : 0;
00154
00155
00156 if (ctx->frame_type >= FRAMETYPE_NULL_FIRST) {
00157 av_dlog(avctx, "Null frame encountered!\n");
00158 return 0;
00159 }
00160
00161
00162
00163
00164 if (get_bits1(&ctx->gb)) {
00165 skip_bits_long(&ctx->gb, 32);
00166 av_dlog(avctx, "Password-protected clip!\n");
00167 }
00168
00169 pic_size_indx = get_bits(&ctx->gb, 3);
00170 if (pic_size_indx == IVI4_PIC_SIZE_ESC) {
00171 pic_conf.pic_height = get_bits(&ctx->gb, 16);
00172 pic_conf.pic_width = get_bits(&ctx->gb, 16);
00173 } else {
00174 pic_conf.pic_height = ivi4_common_pic_sizes[pic_size_indx * 2 + 1];
00175 pic_conf.pic_width = ivi4_common_pic_sizes[pic_size_indx * 2 ];
00176 }
00177
00178
00179 if (get_bits1(&ctx->gb)) {
00180 pic_conf.tile_height = scale_tile_size(pic_conf.pic_height, get_bits(&ctx->gb, 4));
00181 pic_conf.tile_width = scale_tile_size(pic_conf.pic_width, get_bits(&ctx->gb, 4));
00182 #if IVI4_STREAM_ANALYSER
00183 ctx->uses_tiling = 1;
00184 #endif
00185 } else {
00186 pic_conf.tile_height = pic_conf.pic_height;
00187 pic_conf.tile_width = pic_conf.pic_width;
00188 }
00189
00190
00191 if (get_bits(&ctx->gb, 2)) {
00192 av_log(avctx, AV_LOG_ERROR, "Only YVU9 picture format is supported!\n");
00193 return AVERROR_INVALIDDATA;
00194 }
00195 pic_conf.chroma_height = (pic_conf.pic_height + 3) >> 2;
00196 pic_conf.chroma_width = (pic_conf.pic_width + 3) >> 2;
00197
00198
00199 pic_conf.luma_bands = decode_plane_subdivision(&ctx->gb);
00200 if (pic_conf.luma_bands)
00201 pic_conf.chroma_bands = decode_plane_subdivision(&ctx->gb);
00202 ctx->is_scalable = pic_conf.luma_bands != 1 || pic_conf.chroma_bands != 1;
00203 if (ctx->is_scalable && (pic_conf.luma_bands != 4 || pic_conf.chroma_bands != 1)) {
00204 av_log(avctx, AV_LOG_ERROR, "Scalability: unsupported subdivision! Luma bands: %d, chroma bands: %d\n",
00205 pic_conf.luma_bands, pic_conf.chroma_bands);
00206 return AVERROR_INVALIDDATA;
00207 }
00208
00209
00210 if (ivi_pic_config_cmp(&pic_conf, &ctx->pic_conf)) {
00211 if (ff_ivi_init_planes(ctx->planes, &pic_conf)) {
00212 av_log(avctx, AV_LOG_ERROR, "Couldn't reallocate color planes!\n");
00213 return AVERROR(ENOMEM);
00214 }
00215
00216 ctx->pic_conf = pic_conf;
00217
00218
00219 for (p = 0; p <= 2; p++) {
00220 for (i = 0; i < (!p ? pic_conf.luma_bands : pic_conf.chroma_bands); i++) {
00221 ctx->planes[p].bands[i].mb_size = !p ? (!ctx->is_scalable ? 16 : 8) : 4;
00222 ctx->planes[p].bands[i].blk_size = !p ? 8 : 4;
00223 }
00224 }
00225
00226 if (ff_ivi_init_tiles(ctx->planes, ctx->pic_conf.tile_width,
00227 ctx->pic_conf.tile_height)) {
00228 av_log(avctx, AV_LOG_ERROR,
00229 "Couldn't reallocate internal structures!\n");
00230 return AVERROR(ENOMEM);
00231 }
00232 }
00233
00234 ctx->frame_num = get_bits1(&ctx->gb) ? get_bits(&ctx->gb, 20) : 0;
00235
00236
00237 if (get_bits1(&ctx->gb))
00238 skip_bits(&ctx->gb, 8);
00239
00240
00241 if (ff_ivi_dec_huff_desc(&ctx->gb, get_bits1(&ctx->gb), IVI_MB_HUFF, &ctx->mb_vlc, avctx) ||
00242 ff_ivi_dec_huff_desc(&ctx->gb, get_bits1(&ctx->gb), IVI_BLK_HUFF, &ctx->blk_vlc, avctx))
00243 return AVERROR_INVALIDDATA;
00244
00245 ctx->rvmap_sel = get_bits1(&ctx->gb) ? get_bits(&ctx->gb, 3) : 8;
00246
00247 ctx->in_imf = get_bits1(&ctx->gb);
00248 ctx->in_q = get_bits1(&ctx->gb);
00249
00250 ctx->pic_glob_quant = get_bits(&ctx->gb, 5);
00251
00252
00253 ctx->unknown1 = get_bits1(&ctx->gb) ? get_bits(&ctx->gb, 3) : 0;
00254
00255 ctx->checksum = get_bits1(&ctx->gb) ? get_bits(&ctx->gb, 16) : 0;
00256
00257
00258 while (get_bits1(&ctx->gb)) {
00259 av_dlog(avctx, "Pic hdr extension encountered!\n");
00260 skip_bits(&ctx->gb, 8);
00261 }
00262
00263 if (get_bits1(&ctx->gb)) {
00264 av_log(avctx, AV_LOG_ERROR, "Bad blocks bits encountered!\n");
00265 }
00266
00267 align_get_bits(&ctx->gb);
00268
00269 return 0;
00270 }
00271
00272
00281 static int decode_band_hdr(IVI45DecContext *ctx, IVIBandDesc *band,
00282 AVCodecContext *avctx)
00283 {
00284 int plane, band_num, indx, transform_id, scan_indx;
00285 int i;
00286 int quant_mat;
00287
00288 plane = get_bits(&ctx->gb, 2);
00289 band_num = get_bits(&ctx->gb, 4);
00290 if (band->plane != plane || band->band_num != band_num) {
00291 av_log(avctx, AV_LOG_ERROR, "Invalid band header sequence!\n");
00292 return AVERROR_INVALIDDATA;
00293 }
00294
00295 band->is_empty = get_bits1(&ctx->gb);
00296 if (!band->is_empty) {
00297
00298
00299 if (get_bits1(&ctx->gb))
00300 skip_bits(&ctx->gb, 16);
00301
00302 band->is_halfpel = get_bits(&ctx->gb, 2);
00303 if (band->is_halfpel >= 2) {
00304 av_log(avctx, AV_LOG_ERROR, "Invalid/unsupported mv resolution: %d!\n",
00305 band->is_halfpel);
00306 return AVERROR_INVALIDDATA;
00307 }
00308 #if IVI4_STREAM_ANALYSER
00309 if (!band->is_halfpel)
00310 ctx->uses_fullpel = 1;
00311 #endif
00312
00313 band->checksum_present = get_bits1(&ctx->gb);
00314 if (band->checksum_present)
00315 band->checksum = get_bits(&ctx->gb, 16);
00316
00317 indx = get_bits(&ctx->gb, 2);
00318 if (indx == 3) {
00319 av_log(avctx, AV_LOG_ERROR, "Invalid block size!\n");
00320 return AVERROR_INVALIDDATA;
00321 }
00322 band->mb_size = 16 >> indx;
00323 band->blk_size = 8 >> (indx >> 1);
00324
00325 band->inherit_mv = get_bits1(&ctx->gb);
00326 band->inherit_qdelta = get_bits1(&ctx->gb);
00327
00328 band->glob_quant = get_bits(&ctx->gb, 5);
00329
00330 if (!get_bits1(&ctx->gb) || ctx->frame_type == FRAMETYPE_INTRA) {
00331 transform_id = get_bits(&ctx->gb, 5);
00332 if (transform_id >= FF_ARRAY_ELEMS(transforms) ||
00333 !transforms[transform_id].inv_trans) {
00334 av_log_ask_for_sample(avctx, "Unimplemented transform: %d!\n", transform_id);
00335 return AVERROR_PATCHWELCOME;
00336 }
00337 if ((transform_id >= 7 && transform_id <= 9) ||
00338 transform_id == 17) {
00339 av_log_ask_for_sample(avctx, "DCT transform not supported yet!\n");
00340 return AVERROR_PATCHWELCOME;
00341 }
00342
00343 if (transform_id < 10 && band->blk_size < 8) {
00344 av_log(avctx, AV_LOG_ERROR, "wrong transform size!\n");
00345 return AVERROR_INVALIDDATA;
00346 }
00347 #if IVI4_STREAM_ANALYSER
00348 if ((transform_id >= 0 && transform_id <= 2) || transform_id == 10)
00349 ctx->uses_haar = 1;
00350 #endif
00351
00352 band->inv_transform = transforms[transform_id].inv_trans;
00353 band->dc_transform = transforms[transform_id].dc_trans;
00354 band->is_2d_trans = transforms[transform_id].is_2d_trans;
00355 band->transform_size= (transform_id < 10) ? 8 : 4;
00356
00357 scan_indx = get_bits(&ctx->gb, 4);
00358 if ((scan_indx>4 && scan_indx<10) != (band->blk_size==4)) {
00359 av_log(avctx, AV_LOG_ERROR, "mismatching scan table!\n");
00360 return AVERROR_INVALIDDATA;
00361 }
00362 if (scan_indx == 15) {
00363 av_log(avctx, AV_LOG_ERROR, "Custom scan pattern encountered!\n");
00364 return AVERROR_INVALIDDATA;
00365 }
00366 band->scan = scan_index_to_tab[scan_indx];
00367
00368 quant_mat = get_bits(&ctx->gb, 5);
00369 if (quant_mat == 31) {
00370 av_log(avctx, AV_LOG_ERROR, "Custom quant matrix encountered!\n");
00371 return AVERROR_INVALIDDATA;
00372 }
00373 if (quant_mat > 21) {
00374 av_log(avctx, AV_LOG_ERROR, "Invalid quant matrix encountered!\n");
00375 return AVERROR_INVALIDDATA;
00376 }
00377 band->quant_mat = quant_mat;
00378 }
00379 if (quant_index_to_tab[band->quant_mat] > 4 && band->blk_size == 4) {
00380 av_log(avctx, AV_LOG_ERROR, "Invalid quant matrix for 4x4 block encountered!\n");
00381 band->quant_mat = 0;
00382 return AVERROR_INVALIDDATA;
00383 }
00384
00385 if (ff_ivi_dec_huff_desc(&ctx->gb, get_bits1(&ctx->gb), IVI_BLK_HUFF,
00386 &band->blk_vlc, avctx))
00387 return AVERROR_INVALIDDATA;
00388
00389
00390 band->rvmap_sel = get_bits1(&ctx->gb) ? get_bits(&ctx->gb, 3) : 8;
00391
00392
00393 band->num_corr = 0;
00394 if (get_bits1(&ctx->gb)) {
00395 band->num_corr = get_bits(&ctx->gb, 8);
00396 if (band->num_corr > 61) {
00397 av_log(avctx, AV_LOG_ERROR, "Too many corrections: %d\n",
00398 band->num_corr);
00399 return AVERROR_INVALIDDATA;
00400 }
00401
00402
00403 for (i = 0; i < band->num_corr * 2; i++)
00404 band->corr[i] = get_bits(&ctx->gb, 8);
00405 }
00406 }
00407
00408 if (band->blk_size == 8) {
00409 band->intra_base = &ivi4_quant_8x8_intra[quant_index_to_tab[band->quant_mat]][0];
00410 band->inter_base = &ivi4_quant_8x8_inter[quant_index_to_tab[band->quant_mat]][0];
00411 } else {
00412 band->intra_base = &ivi4_quant_4x4_intra[quant_index_to_tab[band->quant_mat]][0];
00413 band->inter_base = &ivi4_quant_4x4_inter[quant_index_to_tab[band->quant_mat]][0];
00414 }
00415
00416
00417 band->intra_scale = NULL;
00418 band->inter_scale = NULL;
00419
00420 align_get_bits(&ctx->gb);
00421
00422 if (!band->scan) {
00423 av_log(avctx, AV_LOG_ERROR, "band->scan not set\n");
00424 return AVERROR_INVALIDDATA;
00425 }
00426
00427 return 0;
00428 }
00429
00430
00441 static int decode_mb_info(IVI45DecContext *ctx, IVIBandDesc *band,
00442 IVITile *tile, AVCodecContext *avctx)
00443 {
00444 int x, y, mv_x, mv_y, mv_delta, offs, mb_offset, blks_per_mb,
00445 mv_scale, mb_type_bits, s;
00446 IVIMbInfo *mb, *ref_mb;
00447 int row_offset = band->mb_size * band->pitch;
00448
00449 mb = tile->mbs;
00450 ref_mb = tile->ref_mbs;
00451 offs = tile->ypos * band->pitch + tile->xpos;
00452
00453 blks_per_mb = band->mb_size != band->blk_size ? 4 : 1;
00454 mb_type_bits = ctx->frame_type == FRAMETYPE_BIDIR ? 2 : 1;
00455
00456
00457 mv_scale = (ctx->planes[0].bands[0].mb_size >> 3) - (band->mb_size >> 3);
00458 mv_x = mv_y = 0;
00459
00460 if (((tile->width + band->mb_size-1)/band->mb_size) * ((tile->height + band->mb_size-1)/band->mb_size) != tile->num_MBs) {
00461 av_log(avctx, AV_LOG_ERROR, "num_MBs mismatch %d %d %d %d\n", tile->width, tile->height, band->mb_size, tile->num_MBs);
00462 return -1;
00463 }
00464
00465 for (y = tile->ypos; y < tile->ypos + tile->height; y += band->mb_size) {
00466 mb_offset = offs;
00467
00468 for (x = tile->xpos; x < tile->xpos + tile->width; x += band->mb_size) {
00469 mb->xpos = x;
00470 mb->ypos = y;
00471 mb->buf_offs = mb_offset;
00472
00473 if (get_bits1(&ctx->gb)) {
00474 if (ctx->frame_type == FRAMETYPE_INTRA) {
00475 av_log(avctx, AV_LOG_ERROR, "Empty macroblock in an INTRA picture!\n");
00476 return AVERROR_INVALIDDATA;
00477 }
00478 mb->type = 1;
00479 mb->cbp = 0;
00480
00481 mb->q_delta = 0;
00482 if (!band->plane && !band->band_num && ctx->in_q) {
00483 mb->q_delta = get_vlc2(&ctx->gb, ctx->mb_vlc.tab->table,
00484 IVI_VLC_BITS, 1);
00485 mb->q_delta = IVI_TOSIGNED(mb->q_delta);
00486 }
00487
00488 mb->mv_x = mb->mv_y = 0;
00489 if (band->inherit_mv && ref_mb) {
00490
00491 if (mv_scale) {
00492 mb->mv_x = ivi_scale_mv(ref_mb->mv_x, mv_scale);
00493 mb->mv_y = ivi_scale_mv(ref_mb->mv_y, mv_scale);
00494 } else {
00495 mb->mv_x = ref_mb->mv_x;
00496 mb->mv_y = ref_mb->mv_y;
00497 }
00498 }
00499 } else {
00500 if (band->inherit_mv && ref_mb) {
00501 mb->type = ref_mb->type;
00502 } else if (ctx->frame_type == FRAMETYPE_INTRA ||
00503 ctx->frame_type == FRAMETYPE_INTRA1) {
00504 mb->type = 0;
00505 } else {
00506 mb->type = get_bits(&ctx->gb, mb_type_bits);
00507 }
00508
00509 mb->cbp = get_bits(&ctx->gb, blks_per_mb);
00510
00511 mb->q_delta = 0;
00512 if (band->inherit_qdelta) {
00513 if (ref_mb) mb->q_delta = ref_mb->q_delta;
00514 } else if (mb->cbp || (!band->plane && !band->band_num &&
00515 ctx->in_q)) {
00516 mb->q_delta = get_vlc2(&ctx->gb, ctx->mb_vlc.tab->table,
00517 IVI_VLC_BITS, 1);
00518 mb->q_delta = IVI_TOSIGNED(mb->q_delta);
00519 }
00520
00521 if (!mb->type) {
00522 mb->mv_x = mb->mv_y = 0;
00523 } else {
00524 if (band->inherit_mv && ref_mb) {
00525
00526 if (mv_scale) {
00527 mb->mv_x = ivi_scale_mv(ref_mb->mv_x, mv_scale);
00528 mb->mv_y = ivi_scale_mv(ref_mb->mv_y, mv_scale);
00529 } else {
00530 mb->mv_x = ref_mb->mv_x;
00531 mb->mv_y = ref_mb->mv_y;
00532 }
00533 } else {
00534
00535 mv_delta = get_vlc2(&ctx->gb, ctx->mb_vlc.tab->table,
00536 IVI_VLC_BITS, 1);
00537 mv_y += IVI_TOSIGNED(mv_delta);
00538 mv_delta = get_vlc2(&ctx->gb, ctx->mb_vlc.tab->table,
00539 IVI_VLC_BITS, 1);
00540 mv_x += IVI_TOSIGNED(mv_delta);
00541 mb->mv_x = mv_x;
00542 mb->mv_y = mv_y;
00543 }
00544 }
00545 }
00546
00547 s= band->is_halfpel;
00548 if (mb->type)
00549 if ( x + (mb->mv_x >>s) + (y+ (mb->mv_y >>s))*band->pitch < 0 ||
00550 x + ((mb->mv_x+s)>>s) + band->mb_size - 1
00551 + (y+band->mb_size - 1 +((mb->mv_y+s)>>s))*band->pitch > band->bufsize -1) {
00552 av_log(avctx, AV_LOG_ERROR, "motion vector %d %d outside reference\n", x*s + mb->mv_x, y*s + mb->mv_y);
00553 return AVERROR_INVALIDDATA;
00554 }
00555
00556 mb++;
00557 if (ref_mb)
00558 ref_mb++;
00559 mb_offset += band->mb_size;
00560 }
00561
00562 offs += row_offset;
00563 }
00564
00565 align_get_bits(&ctx->gb);
00566
00567 return 0;
00568 }
00569
00570
00576 static void switch_buffers(IVI45DecContext *ctx)
00577 {
00578 switch (ctx->prev_frame_type) {
00579 case FRAMETYPE_INTRA:
00580 case FRAMETYPE_INTRA1:
00581 case FRAMETYPE_INTER:
00582 ctx->buf_switch ^= 1;
00583 ctx->dst_buf = ctx->buf_switch;
00584 ctx->ref_buf = ctx->buf_switch ^ 1;
00585 break;
00586 case FRAMETYPE_INTER_NOREF:
00587 break;
00588 }
00589
00590 switch (ctx->frame_type) {
00591 case FRAMETYPE_INTRA:
00592 case FRAMETYPE_INTRA1:
00593 ctx->buf_switch = 0;
00594
00595 case FRAMETYPE_INTER:
00596 ctx->dst_buf = ctx->buf_switch;
00597 ctx->ref_buf = ctx->buf_switch ^ 1;
00598 break;
00599 case FRAMETYPE_INTER_NOREF:
00600 case FRAMETYPE_NULL_FIRST:
00601 case FRAMETYPE_NULL_LAST:
00602 break;
00603 }
00604 }
00605
00606
00607 static int is_nonnull_frame(IVI45DecContext *ctx)
00608 {
00609 return ctx->frame_type < FRAMETYPE_NULL_FIRST;
00610 }
00611
00612
00613 static av_cold int decode_init(AVCodecContext *avctx)
00614 {
00615 IVI45DecContext *ctx = avctx->priv_data;
00616
00617 ff_ivi_init_static_vlc();
00618
00619
00620 memcpy(ctx->rvmap_tabs, ff_ivi_rvmap_tabs, sizeof(ff_ivi_rvmap_tabs));
00621
00622
00623
00624 ctx->pic_conf.pic_width = 0;
00625 ctx->pic_conf.pic_height = 0;
00626
00627 avctx->pix_fmt = PIX_FMT_YUV410P;
00628
00629 ctx->decode_pic_hdr = decode_pic_hdr;
00630 ctx->decode_band_hdr = decode_band_hdr;
00631 ctx->decode_mb_info = decode_mb_info;
00632 ctx->switch_buffers = switch_buffers;
00633 ctx->is_nonnull_frame = is_nonnull_frame;
00634
00635 return 0;
00636 }
00637
00638
00639 AVCodec ff_indeo4_decoder = {
00640 .name = "indeo4",
00641 .type = AVMEDIA_TYPE_VIDEO,
00642 .id = AV_CODEC_ID_INDEO4,
00643 .priv_data_size = sizeof(IVI45DecContext),
00644 .init = decode_init,
00645 .close = ff_ivi_decode_close,
00646 .decode = ff_ivi_decode_frame,
00647 .long_name = NULL_IF_CONFIG_SMALL("Intel Indeo Video Interactive 4"),
00648 };