After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 132341 - [avidemux] 'DIB ' => image upside-down
[avidemux] 'DIB ' => image upside-down
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins
git master
Other Linux
: Normal normal
: 0.8.8
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks: 138435
 
 
Reported: 2004-01-23 23:06 UTC by Christian Fredrik Kalager Schaller
Modified: 2005-01-29 15:47 UTC
See Also:
GNOME target: ---
GNOME version: 2.9/2.10


Attachments
Avi file that we fail to play (769.67 KB, application/octet-stream)
2004-01-23 23:26 UTC, Christian Fredrik Kalager Schaller
Details
Screenshot of video playing in mplayer (12.17 KB, image/png)
2004-10-29 13:58 UTC, Christian Fredrik Kalager Schaller
Details
Screenshot showing video playing in Totem with color distortion (38.35 KB, image/png)
2004-12-03 15:25 UTC, Christian Fredrik Kalager Schaller
Details

Description Christian Fredrik Kalager Schaller 2004-01-23 23:06:09 UTC
The attached avi does not play with GStreamer (and not with Xine either,
but mplayer plays it just fine)
Comment 1 Christian Fredrik Kalager Schaller 2004-01-23 23:26:04 UTC
Created attachment 23689 [details]
Avi file that we fail to play
Comment 2 Ronald Bultje 2004-01-24 23:51:20 UTC
What codec does mplayer use? Fourcc is 'DIB ', which is unknown to me.
Comment 3 Christian Fredrik Kalager Schaller 2004-01-25 01:55:35 UTC
Here is the mplayer output, hope it tells you something :)

Playing g10.avi.
AVI file format detected.
VIDEO:  []  120x120  8bpp  15.000 fps  1728.0 kbps (210.9 kbyte/s)
==========================================================================
Opening audio decoder: [pcm] Uncompressed PCM audio decoder
AUDIO: 22050 Hz, 1 ch, 16 bit (0x10), ratio: 44100->44100 (352.8 kbit)
Selected audio codec: [pcm] afm:pcm (Uncompressed PCM)
==========================================================================
vo: X11 running at 1024x768 with depth 24 and 32 bpp (":0.0" => local
display)
==========================================================================
Opening video decoder: [raw] RAW Uncompressed Video
VDec: vo config request - 120 x 120 (preferred csp: BGR 8-bit)
Could not find matching colorspace - retrying with -vf scale...
Opening video filter: [scale]
The selected video_out device is incompatible with this codec.
VDecoder init failed :(
Opening video decoder: [raw] RAW Uncompressed Video
VDec: vo config request - 120 x 120 (preferred csp: BGR 8-bit)
Could not find matching colorspace - retrying with -vf scale...
Opening video filter: [scale]
The selected video_out device is incompatible with this codec.
VDecoder init failed :(
Opening video decoder: [raw] RAW Uncompressed Video
VDec: vo config request - 120 x 120 (preferred csp: BGR 8-bit)
Could not find matching colorspace - retrying with -vf scale...
Opening video filter: [scale]
The selected video_out device is incompatible with this codec.
VDecoder init failed :(
Opening video decoder: [raw] RAW Uncompressed Video
VDec: vo config request - 120 x 120 (preferred csp: BGR 8-bit)
Could not find matching colorspace - retrying with -vf scale...
Opening video filter: [scale]
The selected video_out device is incompatible with this codec.
VDecoder init failed :(
Opening video decoder: [raw] RAW Uncompressed Video
VDec: vo config request - 120 x 120 (preferred csp: BGR 8-bit)
Could not find matching colorspace - retrying with -vf scale...
Opening video filter: [scale]
The selected video_out device is incompatible with this codec.
VDecoder init failed :(
Opening video decoder: [raw] RAW Uncompressed Video
VDec: vo config request - 120 x 120 (preferred csp: BGR 8-bit)
Could not find matching colorspace - retrying with -vf scale...
Opening video filter: [scale]
The selected video_out device is incompatible with this codec.
VDecoder init failed :(
Opening video decoder: [raw] RAW Uncompressed Video
VDec: vo config request - 120 x 120 (preferred csp: BGR 8-bit)
Could not find matching colorspace - retrying with -vf scale...
Opening video filter: [scale]
The selected video_out device is incompatible with this codec.
VDecoder init failed :(
Opening video decoder: [raw] RAW Uncompressed Video
VDec: vo config request - 120 x 120 (preferred csp: BGR 8-bit)
Could not find matching colorspace - retrying with -vf scale...
Opening video filter: [scale]
The selected video_out device is incompatible with this codec.
VDecoder init failed :(
Opening video decoder: [raw] RAW Uncompressed Video
VDec: vo config request - 120 x 120 (preferred csp: BGR 8-bit)
Could not find matching colorspace - retrying with -vf scale...
Opening video filter: [scale]
The selected video_out device is incompatible with this codec.
VDecoder init failed :(
Opening video decoder: [raw] RAW Uncompressed Video
VDec: vo config request - 120 x 120 (preferred csp: BGR 8-bit)
Could not find matching colorspace - retrying with -vf scale...
Opening video filter: [scale]
The selected video_out device is incompatible with this codec.
VDecoder init failed :(
Opening video decoder: [raw] RAW Uncompressed Video
VDec: vo config request - 120 x 120 (preferred csp: BGR 8-bit)
Could not find matching colorspace - retrying with -vf scale...
Opening video filter: [scale]
The selected video_out device is incompatible with this codec.
VDecoder init failed :(
Opening video decoder: [raw] RAW Uncompressed Video
VDec: vo config request - 120 x 120 (preferred csp: BGR 8-bit)
Could not find matching colorspace - retrying with -vf scale...
Opening video filter: [scale]
Opening video filter: [palette]
VDec: using BGR 8-bit as output csp (no 0)
Opening video filter: [flip]
Movie-Aspect is undefined - no prescaling applied.
SwScaler: reducing / aligning filtersize 1 -> 4
SwScaler: reducing / aligning filtersize 1 -> 4
SwScaler: reducing / aligning filtersize 1 -> 1
SwScaler: reducing / aligning filtersize 9 -> 8
 
SwScaler: BICUBIC scaler, from BGR 32-bit to Planar YV12 using MMX2
VO: [xv] 120x120 => 120x120 Planar YV12
Selected video codec: [rawbgr8flip] vfm:raw (RAW BGR8)
==========================================================================
Checking audio filter chain for 22050Hz/1ch/16bit -> 22050Hz/2ch/16bit...
AF_pre: af format: 2 bps, 1 ch, 22050 hz, little endian signed int
AF_pre: 22050Hz 1ch Signed 16-bit (Little-Endian)
AO: [oss] 22050Hz 2ch Signed 16-bit (Little-Endian) (2 bps)
Building audio filter chain for 22050Hz/1ch/16bit -> 22050Hz/2ch/16bit...
Starting playback...
A:   5.9 V:   5.9 A-V:  0.010 ct:  0.008   90/ 90   0%  3%  0.2% 0 0 
Comment 4 Ronald Bultje 2004-01-25 11:12:45 UTC
8-bit BGR (LE RGB) apparently?

I'll have a look, we don't handle this indeeed.
Comment 5 Christian Fredrik Kalager Schaller 2004-02-13 09:15:33 UTC
Ronald suggested getting this added to ffmpeg colorspace instead of 
us fixing it 'inhouse'
Comment 6 Ronald Bultje 2004-03-29 17:49:35 UTC
Well, the thing is that we need a way of converting from 8bpp RGB to whatever
the display wants (either 16/24bpp RGB or some YUV format), so that's easiest to
do by including it in the ffmpeg colorspace plugin. :).

It still needs to be added to the avidemux fourcc list then, though, it's not in
there either.
Comment 7 Ronald Bultje 2004-04-16 01:32:31 UTC
Interestingly, #138680 had palette handling as well, just like this file. I
added a hack to ffmpegdec to convert to RGBA32 from those. I might want to add
that hack over to ffmpegcolorspace and then this file would be supported as well.
Comment 8 Christian Fredrik Kalager Schaller 2004-09-29 18:22:28 UTC
Time to move the hack over and we can close this long standing playback bug
Ronald :)
Comment 9 Ronald Bultje 2004-09-30 12:03:13 UTC
I know, I have a long list of failing media files and this is one of them. I
can't do all at once...
Comment 10 Ronald Bultje 2004-10-02 14:20:21 UTC
Works with current CVS, but only with commandline and only if you use the
video_00 template of avidemux only. Playbin still fails, I'm currently unsure
why. The initial delay of the audio track might be too large. Once that's fixed,
it should work.
Comment 11 Ronald Bultje 2004-10-29 11:35:49 UTC
gst-launch filesrc location=~/Media/clips/file.avi ! avidemux .video_00 ! {
queue ! ffcolorspace ! ximagesink } avidemux0.audio_00 ! { queue ! audioconvert
! audioscale ! alsasink device=hw:0 }

plays it fine now. Once I've backported ffcolorspace into ffmpegcolorspace
(doing so now), playbin will play it. The image is completely screwed, however.
Can you attach a screenshot of how it looks in mplayer?
Comment 12 Christian Fredrik Kalager Schaller 2004-10-29 13:58:31 UTC
Created attachment 33205 [details]
Screenshot of video playing in mplayer
Comment 13 Christian Fredrik Kalager Schaller 2004-12-03 15:25:54 UTC
Created attachment 34455 [details]
Screenshot showing video playing in Totem with color distortion
Comment 14 Christian Fredrik Kalager Schaller 2004-12-03 15:26:50 UTC
Just attached a screenshot of Totem playing this video. It does not scale
correctly with ximagesink (as seen in shot) and colors are wrong and the image
is upsidedown for some reason.
Comment 15 Jan Schmidt 2004-12-15 11:39:08 UTC
The colour distortion looks like a bad palette lookup to me.
The upside-down bit, I'd be looking for stride information in the headers
somewhere that we're ignoring - for upside-down video, I'd expect a negative stride.
Comment 16 David Schleef 2004-12-15 18:32:26 UTC
Unlikely.  Some FOURCCs are just defined with data going from bottom to top.
Comment 17 Sebastien Cote 2004-12-31 17:25:37 UTC
From my experience, if height > 0 for uncompressed RGB streams (FOURCC
GST_RIFF_rgb, GST_RIFF_RGB and "DIB "), then the image is bottom up. A negative
height means the image is top-down.

See BITMAPINFOHEADER on MSDN for more information about that.
Comment 18 Ronald Bultje 2005-01-29 15:25:00 UTC
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/gdi/bitmaps_1rw2.asp

DIB is specifically bottom-up, unless the height is negative. It seems like
we'll have to add some code for this in avidemux...

Color distortion is fixed in CVS btw.
Comment 19 Ronald Bultje 2005-01-29 15:47:18 UTC
Invertion fixed too.