[Bug 767512] jpeg2000parse: support j2c and jp2 file formats

GStreamer (GNOME Bugzilla) bugzilla at gnome.org
Fri Jun 17 10:01:57 UTC 2016


https://bugzilla.gnome.org/show_bug.cgi?id=767512

Sebastian Dröge (slomo) <slomo at coaxion.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
 Attachment #329827|none                        |needs-work
             status|                            |

--- Comment #33 from Sebastian Dröge (slomo) <slomo at coaxion.net> ---
Review of attachment 329827:
 --> (https://bugzilla.gnome.org/review?bug=767512&attachment=329827)

Thanks :)

::: gst/videoparsers/gstjpeg2000parse.c
@@ +246,3 @@
+      GST_ELEMENT_ERROR (jpeg2000parse, STREAM, DECODE, NULL,
+          ("Missing contiguous code stream box for j2c stream"));
+      ret = GST_FLOW_NOT_NEGOTIATED;

GST_FLOW_ERROR (the data is broken, it's not that we can't handle this specific
one)

@@ +264,3 @@
+        GST_ELEMENT_ERROR (jpeg2000parse, STREAM, DECODE, NULL,
+            ("Corrupt contiguous code stream box for j2c stream"));
+        ret = GST_FLOW_NOT_NEGOTIATED;

and here

@@ +271,3 @@
+        GST_ELEMENT_ERROR (jpeg2000parse, STREAM, DECODE, NULL,
+            ("Missing contiguous code stream box size for j2c stream"));
+        ret = GST_FLOW_NOT_NEGOTIATED;

here

@@ +292,3 @@
+      /* J2C has 8 bytes preceding J2K magic */
+      if (jpeg2000parse->codec_format == GST_JPEG2000_PARSE_J2C)
+        *skipsize -= GST_JPEG2000_PARSE_SIZE_OF_J2C_PREFIX_BYTES;

Probably want to assert that magic_offset >= J2C_PREFIX_BYTES

@@ +529,1 @@
     gst_caps_unref (current_caps);

Why do we still get the current caps here? You could just parse it all in
set_caps() and be done with it :)

-- 
You are receiving this mail because:
You are the QA Contact for the bug.
You are the assignee for the bug.


More information about the gstreamer-bugs mailing list