comparison libmpdemux/aviheader.c @ 36341:63f19afc5a6f

avidemux: try reading ODML index if the default one is uselessly small. Fixes Bugzilla #2150.
author reimar
date Sat, 31 Aug 2013 06:49:56 +0000
parents 139f2b064ef9
children 33a385204875
comparison
equal deleted inserted replaced
36340:6198c908db85 36341:63f19afc5a6f
459 if(chunksize>0) stream_skip(demuxer->stream,chunksize); else 459 if(chunksize>0) stream_skip(demuxer->stream,chunksize); else
460 if((int)chunksize<0) mp_msg(MSGT_HEADER,MSGL_WARN,"chunksize=%u (id=%.4s)\n",chunksize,(char *) &id); 460 if((int)chunksize<0) mp_msg(MSGT_HEADER,MSGL_WARN,"chunksize=%u (id=%.4s)\n",chunksize,(char *) &id);
461 461
462 } 462 }
463 463
464 if (priv->suidx_size > 0 && priv->idx_size == 0) { 464 // Some files contain a dummy non-odml index.
465 // Ignore an index smaller than some arbitrary size.
466 // Some Canon cameras recording in MJPEG do this
467 // (encoder software identifier CanonMVI06).
468 if (priv->suidx_size > 0 && priv->idx_size < 4) {
465 /* 469 /*
466 * No NEWAVIINDEX, but we got an OpenDML index. 470 * No NEWAVIINDEX, but we got an OpenDML index.
467 */ 471 */
468 priv->isodml = 1; 472 priv->isodml = 1;
469 } 473 }