Opened 15 years ago
Closed 14 years ago
#4620 closed bug (fixed)
Some Xvid files don't play in MediaPlayer
Reported by: | leszek | Owned by: | dlmcpaul |
---|---|---|---|
Priority: | normal | Milestone: | R1 |
Component: | Audio & Video/Codecs | Version: | R1/alpha1 |
Keywords: | Cc: | ||
Blocked By: | Blocking: | ||
Platform: | All |
Description
Some xvid files (avi container with xvid as video codec and mp3 as audio codec) don't play in MediaPlayer. I figured out that files that show correct duration and bitrate when analyzed with ffmpeg -i play correct. Those ones which doesn't aren't even recognized as valid files and I get a error message that the right decoder is missing from the media player.
So I guess there is a problem with the ffmpeg decoder but I am not sure.
I also tested the ffmpeg build from ports.haiku-files.org and especially ffplay which plays all the xvid files nicely
Attachments (2)
Change History (16)
by , 15 years ago
Attachment: | test.flv.avi added |
---|
comment:1 by , 15 years ago
This may or may not be of use if fixing this, xvidcore-1.2.2 lib files build ok on Haiku: http://ports.haiku-files.org/wiki/media-libs/xvid/1.2.1/1
comment:2 by , 15 years ago
Hmm, that file is recognised as corrupt by G-Spot
Considering it's name .flv.avi are you certain it is an avi file?
I am unable to play it using various mediaplayers in windows.
comment:3 by , 15 years ago
It is an avi file.
Various mediaplayers in linux are playing it just fine. ffplay on Haiku also.
What bugs me is that this file was created with ffmpeg and so the ffmpegdecoder should play it. Perhaps the avi_reader needs a patch.
Btw. VLC in Haiku is playing the Video fine but audio does not work.
comment:4 by , 15 years ago
Ok I found out something new. The file I uploaded as an example was created with ffmpeg but gave out the error message : wrong buffer size . Its a known bug in ffmpeg together with libmp3lame 3.98 from howto-pages.org/ffmpeg:
The error message about the output buffer being too small is nothing important. It's merely a result of the way data is passed between ffmpeg and the external codec, LAME.
So the file plays fine on various linux mediaplayers except vlc which regardless of its platform plays only the video and gives out an error about a corrupt avi header. After searching through the web and of course my hd I found various of those files. Sadly I think there is no easy fix for this.
comment:5 by , 15 years ago
The test.flv.avi file is a little bit broken.
http://mediainfo.sourceforge.net/ does only give some basic information, thats not normal.
http://www.virtualdub.org/ raised some errors, about missing index and VBR audio.
comment:6 by , 15 years ago
The Question is should MediaPlayer support those kinds of files, just like the various MediaPlayers on Linux do, or should it complain about it ?
comment:7 by , 15 years ago
I think it is unlikely we will be able to handle files that do not conform to the known formats.
ffmpeg has lots of workarounds for broken files but we don't.
I have not looked too closely at the file yet, other than to see what my media utilities could tell me about it but so far it really looks broken. What the issue is yet I don't know and supporting it may be easy.
comment:8 by , 15 years ago
Owner: | changed from | to
---|
Ok the file uploaded has the following issues
- It is truncated
- The RIFF chunk has a 0 size
- A LIST chunk has a 0 size
I have made a change to the avi_reader to calculate the RIFF size if 0 as this can be done without error I have also put code in to calculate the LIST chunk size but that is just a guess on what it should be.
The above file now starts to play and then stops because of issue #1 I expect.
See hrev33261
comment:9 by , 15 years ago
Hmm... ok
I fixed now my ffmpeg and libmp3lame installation (and those of ZEVENOS) so that I will have valid files in the future. But I am still guessing that there are some distros and encoding apps that use the buggy libmp3lame and ffmpeg to encode their videos. (Didn't test the builds for haiku)
Another topic (maybe I should open up a new bug) OGV container format seems to be supported but only audio is playing.
Here's the file info (ffmpeg -i):
Input #0, ogg, from '/leszek/Videos/Screencasts/custom-usplash.ogv': Duration: 00:20:55.20, start: 0.000000, bitrate: 260 kb/s Stream #0.0: Invalid Codec type -1 Stream #0.1: Video: theora, yuv420p, 720x480, PAR 1:1 DAR 3:2, 15 tbr, 15 tbn, 15 tbc Stream #0.2: Audio: vorbis, 44100 Hz, 2 channels, s16, 80 kb/s Metadata ENCODER : ffmpeg2theora 0.21
Hope this helps for debugging. What is intersting is Stream #0.0 that is recognized as invalid. I am not sure but I heard something about skeleton' meta-data that is stored there.
The theora video decoder is still missing I suppose, so on normal ogg files (with video) only audio playback starts.
Another interesting file I found is here http://rapidshare.com/files/143692472/mtv.video.music.awards.2008.dsr.xvid.sample-sys.avi. It says xvid sample movie.
I analyzed it with ffmpeg -i again and thats what appears:
Input #0, avi, from '/media/disk/Videos/mtv.video.music.awards.2008.dsr.xvid.sample-sys.avi': Duration: 00:01:04.63, start: 0.000000, bitrate: 1213 kb/s Stream #0.0: Video: mpeg4, yuv420p, 512x384 [PAR 1:1 DAR 4:3], 29.97 tbr, 29.97 tbn, 29.97 tbc Stream #0.1: Audio: mp3, 48000 Hz, 2 channels, s16, 127 kb/s
So I guess its a mpeg4 codec not libxvid or xvid. Only audio is playing when opening that video.
comment:10 by , 15 years ago
Please raise a separate issue for OGG. I don't think we support video in OGG yet but I can have a look.
I will download the file and have a look, most likely the fourcc is not registered with our decoder.
comment:11 by , 15 years ago
Ok the mtv file contains a wierd fourcc of XviD instead of the correct fourcc XVID
I have registered the file with the ffmpeg decoder and it plays now.
I think our OGG reader does do video, hard to say from a quick look. Can you link to an example file?
by , 15 years ago
comment:12 by , 14 years ago
The two test files play fine in MediaPlayer in hrev38787, can this ticket be closed?
Example Video file that Media Player does not recognize