Opened 7 years ago

Closed 7 years ago

Last modified 7 years ago

#131 closed enhancement (fixed)

add support for (maybe broken) *.divx file

Reported by: ami_stuff Owned by:
Priority: normal Component: avformat
Version: git-master Keywords: avi
Cc: Blocked By:
Blocking: Reproduced by developer: yes
Analyzed by developer: no

Description

http://kakonacl.dip.jp/PlayerTry/TestMovies/Others/DivX6.11_MP3(Vidomi).divx

the file may be broken, but "Media Player Classic" and "VLC Player" can play it, so let it be playable with ffplay as well

C:\>ffmpeg -i C:\DivX6.11_MP3(Vidomi).divx
FFmpeg version git-N-29181-ga304071, Copyright (c) 2000-2011 the FFmpeg develope
rs
  built on Apr 18 2011 21:24:03 with gcc 4.5.2
  configuration: --enable-gpl --enable-version3 --enable-runtime-cpudetect --ena
ble-memalign-hack --enable-avisynth --enable-bzlib --enable-frei0r --enable-libo
pencore-amrnb --enable-libopencore-amrwb --enable-libfreetype --enable-libgsm --
enable-libmp3lame --enable-libopenjpeg --enable-librtmp --enable-libschroedinger
 --enable-libspeex --enable-libtheora --enable-libvorbis --enable-libvpx --enabl
e-libx264 --enable-libxavs --enable-libxvid --enable-zlib --cross-prefix=i686-w6
4-mingw32- --target-os=mingw32 --arch=x86_32 --extra-cflags=-I/home/kyle/softwar
e/ffmpeg/external-libraries/win32/include --extra-ldflags=-L/home/kyle/software/
ffmpeg/external-libraries/win32/lib --pkg-config=pkg-config
  libavutil    50. 40. 1 / 50. 40. 1
  libavcodec   52.120. 0 / 52.120. 0
  libavformat  52.108. 0 / 52.108. 0
  libavdevice  52.  4. 0 / 52.  4. 0
  libavfilter   1. 79. 0 /  1. 79. 0
  libswscale    0. 13. 0 /  0. 13. 0
[avi @ 01CEC000] scale/rate is 0/0 which is invalid. (This file has been generated by broken software.)
[avi @ 01CEC000] unknown stream type 73627573
C:\DivX6.11_MP3(Vidomi).divx: Operation not permitted

Attachments (3)

divx.avi (2.0 MB) - added by cehoyos 7 years ago.
JUMPSTAR.AVI (1.2 MB) - added by ami_stuff 7 years ago.
avidec.diff (607 bytes) - added by ami_stuff 7 years ago.

Change History (10)

comment:1 Changed 7 years ago by cehoyos

  • Component changed from undetermined to avformat
  • Reproduced by developer set
  • Status changed from new to open
  • Type changed from defect to enhancement
  • Version changed from unspecified to git-master

Plays fine with mplayer -demuxer avi

Changed 7 years ago by cehoyos

comment:2 Changed 7 years ago by reimar

Do you have any other info on the file? Patch below allows playback, but the subtitle format is not xsub it seems, any idea what it might be??
diff --git a/libavformat/avidec.c b/libavformat/avidec.c
index 9395dc2..af8b023 100644
--- a/libavformat/avidec.c
+++ b/libavformat/avidec.c
@@ -532,6 +532,8 @@ static int avi_read_header(AVFormatContext *s, AVFormatParameters *ap)

case MKTAG('a', 'u', 'd', 's'):

codec_type = AVMEDIA_TYPE_AUDIO;
break;

+ case MKTAG('s', 'u', 'b', 's'):
+ st->codec->codec_id = CODEC_ID_XSUB;

case MKTAG('t', 'x', 't', 's'):

codec_type = AVMEDIA_TYPE_SUBTITLE;
break;

@@ -656,7 +658,8 @@ static int avi_read_header(AVFormatContext *s, AVFormatParameters *ap)

break;

case AVMEDIA_TYPE_SUBTITLE:

st->codec->codec_type = AVMEDIA_TYPE_SUBTITLE;

  • st->request_probe= 1;

+ if (st->codec->codec_id == CODEC_ID_NONE)
+ st->request_probe= 1;

break;

default:

st->codec->codec_type = AVMEDIA_TYPE_DATA;

comment:3 Changed 7 years ago by ami_stuff

Sorry no info (just a random file found with Google).

comment:4 follow-up: Changed 7 years ago by ami_stuff

It is acceptable to just ignore the unknown stream? Here is another file which plays with mplayer/vlc/xing/mpc, but not with ffplay (ffmpeg).

Changed 7 years ago by ami_stuff

Changed 7 years ago by ami_stuff

comment:5 in reply to: ↑ 4 Changed 7 years ago by michael

Replying to ami_stuff:

It is acceptable to just ignore the unknown stream? Here is another file which plays with mplayer/vlc/xing/mpc, but not with ffplay (ffmpeg).

patch applied

comment:6 Changed 7 years ago by cehoyos

  • Resolution set to fixed
  • Status changed from open to closed

comment:7 Changed 7 years ago by cehoyos

  • Keywords avi added
Note: See TracTickets for help on using tickets.