Ticket #131 (closed enhancement: fixed)

Opened 2 years ago

Last modified 17 months ago

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

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

Change History

comment:1 Changed 2 years ago by cehoyos

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

Plays fine with mplayer -demuxer avi

Changed 2 years ago by cehoyos

comment:2 Changed 2 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 2 years ago by ami_stuff

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

comment:4 follow-up: ↓ 5 Changed 2 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 2 years ago by ami_stuff

Changed 2 years ago by ami_stuff

comment:5 in reply to: ↑ 4 Changed 2 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 21 months ago by cehoyos

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

comment:7 Changed 17 months ago by cehoyos

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