GNOME Bugzilla – Bug 761637
qtmux: handle file with wrong color_table_id values
Last modified: 2016-04-14 17:42:44 UTC
Created attachment 320545 [details] [review] Patch to check if color table is actually present I got my hands on a file created by TPMGEnc that has color_table_id = 0, but no actual color table. While this violates the specification, there are obviously files like this out there and no other player chokes on them, so gstreamer should be able to handle them as well. Sample file http://s3.amazonaws.com/MatejK/Samples/invalid-color-table-id.mp4 Specification Color table ID A 16-bit integer that identifies which color table to use. If this field is set to –1, the default color table should be used for the specified depth. For all depths below 16 bits per pixel, this indicates a standard Macintosh color table for the specified depth. Depths of 16, 24, and 32 have no color table. If the color table ID is set to 0, a color table is contained within the sample description itself. The color table immediately follows the color table ID field in the sample description. See Color Table Atoms for a complete description of a color table. https://developer.apple.com/library/mac/documentation/QuickTime/QTFF/QTFFChap3/qtff3.html
Created attachment 320546 [details] [review] Patch to check if color table is actually present
Created attachment 320547 [details] [review] Patch to check if color table is actually present Fixes typo in comment
Created attachment 320548 [details] [review] Patch to check if color table is actually present Fixes even more typos.
Thanks, pushed (with minor reformatting, wrapped the long comment line and the if clause) commit f96c9eb6bc8e1cf0e6191e1acf525b19ca5000d4 Author: Matej Knopp <matej.knopp@gmail.com> Date: Sat Feb 6 14:39:05 2016 +0100 qtdemux: workaround for files with wrong color_table_id value Instead of erroring out, just use the default color table. https://bugzilla.gnome.org/show_bug.cgi?id=761637