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 710762 - qtdemux: fails reading some MOV files with problematic jpeg frames
qtdemux: fails reading some MOV files with problematic jpeg frames
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-good
1.2.0
Other All
: Normal normal
: 1.3.1
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on: 711094
Blocks:
 
 
Reported: 2013-10-23 22:18 UTC by Hervé ROMANO
Modified: 2014-01-11 19:48 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
jpegdec: Add data skipping on input (983 bytes, patch)
2013-10-29 01:09 UTC, Thiago Sousa Santos
committed Details | Review
jpegdec: let the base class decide when to return an error (881 bytes, patch)
2013-10-29 01:09 UTC, Thiago Sousa Santos
committed Details | Review
The previous patches cause a regression on jpegdec scenario of decoding (3.19 KB, patch)
2013-10-29 18:20 UTC, Thiago Sousa Santos
none Details | Review
jpegdec: make max-errors property effective (3.31 KB, patch)
2013-11-21 17:45 UTC, Thiago Sousa Santos
reviewed Details | Review

Description Hervé ROMANO 2013-10-23 22:18:41 UTC
With a lot of video files from my camera I get an error with totem and gst-play. Here is an example of the output of gst-play. Mplayer and VLC can read those files without errors.

gst-play-1.0 --gst-debug-level=2 P1060553.MOV 
Now playing /home/sauvegarde_fixe/HOME/archives/photos/2012/07 - juillet/P1060553.MOV
0:00:00.059538321  2982 0xb6602460 WARN                 qtdemux qtdemux_types.c:196:qtdemux_type_get: unknown QuickTime node type jpeg
0:00:00.059624022  2982 0xb6602460 WARN                 qtdemux qtdemux_types.c:196:qtdemux_type_get: unknown QuickTime node type twos
0:00:00.060139598  2982 0xb6602460 WARN                 qtdemux qtdemux.c:7939:qtdemux_parse_trak:<qtdemux0> unknown version 00000000
0:00:00.200676223  2982 0xb5b14290 WARN              bufferpool gstbufferpool.c:632:gst_buffer_pool_set_config:<xvimagebufferpool0> can't change config, we are active
0:00:00.200725757  2982 0xb5b14290 WARN              bufferpool gstbufferpool.c:632:gst_buffer_pool_set_config:<xvimagebufferpool0> can't change config, we are active
0:01:23.070390852  2982 0xb5b14290 WARN            videodecoder gstvideodecoder.c:3340:_gst_video_decoder_error:<jpegdec0> error: Failed to decode JPEG image
0:01:23.070815498  2982 0xb5b14290 WARN            videodecoder gstvideodecoder.c:3342:_gst_video_decoder_error:<jpegdec0> error: Decode error #70: Unsupported marker type 0xdf
0:01:23.071028249  2982 0xb6602460 WARN                 qtdemux qtdemux.c:4394:gst_qtdemux_loop:<qtdemux0> error: streaming stopped, reason error
ERROR GStreamer encountered a general stream error. for file:///home/sauvegarde_fixe/HOME/archives/photos/2012/07%20-%20juillet/P1060553.MOV
ERROR debug information: qtdemux.c(4394): gst_qtdemux_loop (): /GstPlayBin:playbin/GstURIDecodeBin:uridecodebin0/GstDecodeBin:decodebin0/GstQTDemux:qtdemux0:
streaming stopped, reason error
Reached end of play list.
Comment 1 Hervé ROMANO 2013-10-23 22:22:19 UTC
I forgot to tell :
- I had it with Ubuntu since version 12.10 (as I remember) with an older version of gstreamer, though I thought it was an ubuntu bug.
- but I have it with Archlinux too...
Comment 2 Thiago Sousa Santos 2013-10-23 22:59:19 UTC
Can you share a sample file that fails for debugging?
Comment 3 Hervé ROMANO 2013-10-28 13:46:17 UTC
I've made a small movie but it's 127Mb. Can I add it to the bug report or should I use some sharing service for that?

It's a 40s movie and crashes at 0:00:22.195850571. I don't have exactly the same report with that one "Decode error #53: JPEG datastream contains no image". There seems to be several bugs.

Thanks
Comment 4 Thiago Sousa Santos 2013-10-28 13:48:00 UTC
It should not be possible to attach a 127Mb file. Can you use some sharing service and post the link here, please?

If you happen to find more files with different issues, please post links for those here, too. (Or in separate bugs, if you think it is something different)

Thanks!
Comment 5 Hervé ROMANO 2013-10-28 18:47:17 UTC
Here is the link :

https://drive.google.com/file/d/0By9XS74bjJJuV1VCYnNjczJnbUE/edit?usp=sharing

It's my first use of this service, so tell me if it doesn't work.
Comment 6 Thiago Sousa Santos 2013-10-28 20:15:00 UTC
It seems that it is the same error. 

0:00:22.020533867 17075 0x7fb434006370 WARN            videodecoder gstvideodecoder.c:3340:_gst_video_decoder_error:<jpegdec0> error: Failed to decode JPEG image
0:00:22.020578221 17075 0x7fb434006370 WARN            videodecoder gstvideodecoder.c:3342:_gst_video_decoder_error:<jpegdec0> error: Decode error #53: JPEG datastream contains no image

How are you encoding this? When you refer to "my camera" is it a webcam or a 'standalone' digital camera? I'm assuming it is a camera by itself, just confirming.

Maybe the solution here is to make the jpeg decoder skip some error until a max error count is reached.
Comment 7 Thiago Sousa Santos 2013-10-29 01:09:49 UTC
Created attachment 258380 [details] [review]
jpegdec: Add data skipping on input

Add missing bytes skipping when bad input is received.
Comment 8 Thiago Sousa Santos 2013-10-29 01:09:58 UTC
Created attachment 258381 [details] [review]
jpegdec: let the base class decide when to return an error

The base videodecoder class has an error counting feature to tolerate
a few errors before posting an error message. So don't force the
error and let the base class decide when it should happen
Comment 9 Hervé ROMANO 2013-10-29 13:49:34 UTC
Yes, it's a standalone camera (Panasonic DMC TZ-7).
Comment 10 Thiago Sousa Santos 2013-10-29 18:20:16 UTC
Created attachment 258477 [details] [review]
The previous patches cause a regression on jpegdec scenario of decoding

a single 'bad frame', it would tolerate the error and exit successfully
instead of posting an error. This patch fixes it, but depends on bug
https://bugzilla.gnome.org/show_bug.cgi?id=711094

Also, it drops the max-errors 'automatic' mode, this might be considered a
break, but it wasn't being used anyway, so I didn't bother on keeping it.
Comment 11 Thiago Sousa Santos 2013-11-21 17:45:48 UTC
Created attachment 260476 [details] [review]
jpegdec: make max-errors property effective

The max-errors property was unused. This patch makes it set the max error
on the video decoder base class and use its implementation for handling
decoding errors.

As it was unused, this patch also removes the 0=automatic option from the
property as it isn't available in the base class
Comment 12 Sebastian Dröge (slomo) 2013-11-25 11:17:14 UTC
Comment on attachment 260476 [details] [review]
jpegdec: make max-errors property effective

This property should probably be just be deprecated and made a no-op
Comment 13 Thiago Sousa Santos 2013-11-25 14:13:40 UTC
commit be2f2f196abd510830a46db1191be50a0b654f76
commit 673b8ca1c1d3b2ef0499d6225415e173b37ab43e

First 2 patches committed, now updating the other one.
Comment 14 Thiago Sousa Santos 2013-11-25 15:05:57 UTC
6bb6a5cdf4039cb443bb487bc1b93a49ea5d390f pushed for deprecating the max-errors property.

Thanks for the reviews.
Comment 15 Hervé ROMANO 2014-01-11 17:45:28 UTC
Well, I have gst-plugins-good 1.2.2, and I still can't read the same file with gst-play. Here is the output :

gst-play-1.0 --gst-debug-level=2 P1100480.MOV 
Now playing /home/rv/T?l?chargements/P1100480.MOV
0:00:00.063522636  3263 0x7f918c0efc50 WARN                 qtdemux qtdemux_types.c:196:qtdemux_type_get: unknown QuickTime node type jpeg
0:00:00.063603108  3263 0x7f918c0efc50 WARN                 qtdemux qtdemux_types.c:196:qtdemux_type_get: unknown QuickTime node type twos
0:00:00.063744005  3263 0x7f918c0efc50 WARN                 qtdemux qtdemux.c:7975:qtdemux_parse_trak:<qtdemux0> unknown version 00000000
0:00:00.176476199  3263 0x7f91840062d0 WARN              bufferpool gstbufferpool.c:632:gst_buffer_pool_set_config:<xvimagebufferpool0> can't change config, we are active
0:00:00.176618697  3263 0x7f91840062d0 WARN              bufferpool gstbufferpool.c:632:gst_buffer_pool_set_config:<xvimagebufferpool0> can't change config, we are active
0:00:22.042271967  3263 0x7f91840062d0 WARN            videodecoder gstvideodecoder.c:3353:_gst_video_decoder_error:<jpegdec0> error: Failed to decode JPEG image
0:00:22.042325864  3263 0x7f91840062d0 WARN            videodecoder gstvideodecoder.c:3355:_gst_video_decoder_error:<jpegdec0> error: Decode error #53: JPEG datastream contains no image
0:00:22.042524727  3263 0x7f918c0efc50 WARN                 qtdemux qtdemux.c:4402:gst_qtdemux_loop:<qtdemux0> error: streaming stopped, reason error
ERROR GStreamer encountered a general stream error. for file:///home/rv/T%C3%A9l%C3%A9chargements/P1100480.MOV
ERROR debug information: qtdemux.c(4402): gst_qtdemux_loop (): /GstPlayBin:playbin/GstURIDecodeBin:uridecodebin0/GstDecodeBin:decodebin0/GstQTDemux:qtdemux0:
streaming stopped, reason error
Reached end of play list.
Comment 16 Tim-Philipp Müller 2014-01-11 19:48:47 UTC
These fixes are only available in git master, not in the 1.2 branch. They will be in the 1.3.x pre-releases and the 1.4.0 stable release when they come out.