Hi, I am trying to use the openjpeg J2K encode and decode from plugins bad. _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
On Mo, 2016-05-09 at 22:43 -0400, Aaron Boxer wrote:
> Hi, > > I am trying to use the openjpeg J2K encode and decode from plugins bad. > > But, when I try to run my pipeline, gst complains that there is no openjpegenc. > > Is there something special I need to do to use OpenJPEG ? > > I have the 2.1 release. Can you check the config.log to see why/how the configure checks for openjpeg are failing? I'm using 1.5.2 here as provided by Debian, but a year ago or so I made the plugin also work with some 2.0 version (however the API changed in a way that made it less efficient for GStreamer to use). -- Sebastian Dröge, Centricular Ltd · http://www.centricular.com _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel signature.asc (968 bytes) Download Attachment |
In reply to this post by boxerab@gmail.com
On Tue, May 10, 2016 at 8:13 AM, Aaron Boxer <[hidden email]> wrote:
> I am trying to use the openjpeg J2K encode and decode from plugins bad. > > But, when I try to run my pipeline, gst complains that there is no > openjpegenc. > > Is there something special I need to do to use OpenJPEG ? > > I have the 2.1 release. > I was looking at this yesterday, and 2.1 broke API/ABI with 2.0, so the plugin doesn't build against 2.1. Your options are to either build against openjpeg 1.5 (most distros still ship it) or port the plugin to 2.1: https://bugzilla.gnome.org/show_bug.cgi?id=766213 -- ~Nirbheek Chauhan _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
On Tue, May 10, 2016 at 3:07 PM, Nirbheek Chauhan
<[hidden email]> wrote: > On Tue, May 10, 2016 at 8:13 AM, Aaron Boxer <[hidden email]> wrote: >> I am trying to use the openjpeg J2K encode and decode from plugins bad. >> >> But, when I try to run my pipeline, gst complains that there is no >> openjpegenc. >> >> Is there something special I need to do to use OpenJPEG ? >> >> I have the 2.1 release. >> > Your options are to either build against openjpeg 1.5 (most distros > still ship it) or port the plugin to 2.1: > https://bugzilla.gnome.org/show_bug.cgi?id=766213 > There is now a patch on that bug that ports the plugin to 2.1. It would be great if you could test it and tell us if it works for you as well. -- ~Nirbheek Chauhan _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
Thanks, Sebastian and Nirbheek. I will test this out. What is the simplest way of doing the following:On Tue, May 10, 2016 at 6:56 AM, Nirbheek Chauhan <[hidden email]> wrote: On Tue, May 10, 2016 at 3:07 PM, Nirbheek Chauhan _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
On Tue, May 10, 2016 at 4:51 PM, Aaron Boxer <[hidden email]> wrote:
> Thanks, Sebastian and Nirbheek. I will test this out. > What is the simplest way of doing the following: > > 1) passing a single TIFF image to gstreamer, and have it output a J2K > encoded image > 2) passing a single J2K image to gstreamer, and have it output a TIF image > (or PNG for example) > For TIFF, gstreamer has: One encoder: avenc_tiff (wrapper around libav) Two decoders: avdec_tiff (wrapper around libav) and gdkpixbuf (if you build gdk-pixbuf with the tiff pixbuf loader). For JPEG2000, the best encoder/decoder is openjpeg. For converting a file from tiff to jp2k, something like this should work: multifilesrc location=test.tiff num-buffers=1 caps=image/jp2 ! avdec_tiff ! videoconvert ! openjpegenc ! 'image/jp2' ! filesink location=test.jp2 Note that you need to specify which format you want for JPEG2000: 'image/jp2' or 'image/x-jpc', etc. For converting jp2k to tiff, this should work: multifilesrc location=test.jp2 num-buffers=1 caps=image/jp2 ! openjpegdec ! videoconvert ! avenc_tiff ! filesink location=test.tiff The reason why you need multifilesrc is because it allows you to specify the caps of the data which is needed by decoders that do not implement parsers (such as openjpegdec, avdec_tiff, etc). If you used something like pngdec you could use filesrc directly and the decoder would figure out the caps. -- ~Nirbheek Chauhan _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
On Tue, May 10, 2016 at 8:36 AM, Nirbheek Chauhan <[hidden email]> wrote: On Tue, May 10, 2016 at 4:51 PM, Aaron Boxer <[hidden email]> wrote: Awesome, thanks for the detailed instructions. Aaron
_______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
In reply to this post by Sebastian Dröge-3
On Tue, May 10, 2016 at 2:20 AM, Sebastian Dröge <[hidden email]> wrote: On Mo, 2016-05-09 at 22:43 -0400, Aaron Boxer wrote: Sebastian, can you please elaborate on how the API change made it less efficient? I contribute to the project, so if you can advise on improving the API, I can try to get this implemented. Thanks, Aaron
_______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
On Di, 2016-05-10 at 13:19 -0400, Aaron Boxer wrote:
> > Sebastian, can you please elaborate on how the API change made it > less efficient? > I contribute to the project, so if you can advise on improving the > API, I can try to get this implemented. I can't remember details unfortunately, but it somehow related to the new file-style API with read/write functions. And after the porting, the encoder/decoder were both considerably slower, but I didn't look closer back then. Sorry for not having a more useful answer, I would have to look in more detail again. -- Sebastian Dröge, Centricular Ltd · http://www.centricular.com _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel signature.asc (968 bytes) Download Attachment |
On Wed, May 11, 2016 at 2:06 AM, Sebastian Dröge <[hidden email]> wrote: On Di, 2016-05-10 at 13:19 -0400, Aaron Boxer wrote: Thanks. I will look into this when I have time.
_______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
On Mi, 2016-05-11 at 13:55 -0400, Aaron Boxer wrote:
> > > On Wed, May 11, 2016 at 2:06 AM, Sebastian Dröge wrote: > > On Di, 2016-05-10 at 13:19 -0400, Aaron Boxer wrote: > > > > > > Sebastian, can you please elaborate on how the API change made it > > > less efficient? > > > I contribute to the project, so if you can advise on improving the > > > API, I can try to get this implemented. > > > > I can't remember details unfortunately, but it somehow related to the > > new file-style API with read/write functions. And after the porting, > > the encoder/decoder were both considerably slower, but I didn't look > > closer back then. > > > > Sorry for not having a more useful answer, I would have to look in more > > detail again. > Thanks. I will look into this when I have time. Ideally openjpeg would directly work on our input data without copying, and we could pass its output data directly onwards without copying. But that was also not the case before IIRC. -- Sebastian Dröge, Centricular Ltd · http://www.centricular.com _______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel signature.asc (968 bytes) Download Attachment |
On Thu, May 12, 2016 at 1:27 AM, Sebastian Dröge <[hidden email]> wrote: On Mi, 2016-05-11 at 13:55 -0400, Aaron Boxer wrote: Yes, I think I know how to improve this. This will be my next focus once I master the kung-fu of gstreamer patches :)
_______________________________________________ gstreamer-devel mailing list [hidden email] https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
Free forum by Nabble | Edit this page |