<html>
  <head>
    <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
  </head>
  <body bgcolor="#FFFFFF" text="#000000">
    <div class="moz-cite-prefix">On 08/19/2015 05:35 PM, James Felix
      Black wrote:<br>
    </div>
    <blockquote
cite="mid:1440016550.2798814.360669409.11243BF2@webmail.messagingengine.com"
      type="cite">
      <title></title>
      <div>I ran at DEBUG 2 and didn't get much interesting info., but I
        also just wrote something to read the raw RGBA frame sample data
        and now I can point OpenCV at that. <br>
      </div>
    </blockquote>
    Well, it would be nice to debug your case as well to understand what
    was wrong as it seems like it should work. Can you please get a
    GST_DEBUG=6 and attach to a bug in bugzilla.gnome.org under
    GStreamer?<br>
    <br>
    Thanks!<br>
    <blockquote
cite="mid:1440016550.2798814.360669409.11243BF2@webmail.messagingengine.com"
      type="cite">
      <div> </div>
      <div>Cheers.</div>
      <div> </div>
      <div> </div>
      <div>On Wed, Aug 19, 2015, at 16:19, Thiago Santos wrote:<br>
      </div>
      <blockquote type="cite">
        <div>On 08/19/2015 03:46 PM, James Felix Black wrote:<br>
        </div>
        <blockquote type="cite"
cite="mid:1440010011.2772906.360579729.60567105@webmail.messagingengine.com">
          <div>On Wed, Aug 19, 2015, at 13:52, Thiago Santos wrote:<br>
          </div>
          <blockquote type="cite">
            <div>On 08/19/2015 02:42 PM, James Felix Black wrote:<br>
            </div>
            <blockquote
cite="mid:1440006164.2756501.360488729.41C9CF17@webmail.messagingengine.com"
              type="cite">
              <div>Linux ARM (nVidia Jetson TK1), gstreamer-1.5.2, Qt
                5.5, qt-streamer 1.2.0<br>
              </div>
              <div> </div>
              <div>I have a simple X11 application that I'm working,
                based for now on the qt-gstreamer demo code [1] that
                plays a video to the screen, and snapshots "interesting"
                frames to disk. I'm using Qt and the qt-gstreamer
                package, and I am able to access sample data directly
                off the pipeline (using the "sample" property at a given
                time), and write the raw video to disk as such:<br>
              </div>
              <div> </div>
              <div>
                <div>  QGlib::Value val =
                  pipeline->property("sample");<br>
                </div>
                <div>  GstSample * v = (GstSample
                  *)g_value_get_boxed(val);<br>
                </div>
                <div> </div>
                <div>  // write the contents of v's memory buffer to
                  disk ....<br>
                </div>
                <div> </div>
                <div>What I get is a raw file of 4bytes * 1920 * 1080.
                  That's cool! But what I want to do is:<br>
                </div>
                <div> </div>
                <div>  GstCaps * jpegCaps =
                  gst_caps_new_simple("image/jpeg", "width", G_TYPE_INT,
                  640, NULL);<br>
                </div>
                <div>  GError * err;<br>
                </div>
                <div>  GstSample * jpeg = gst_video_convert_sample(v,
                  jpegCaps, 100, &err);<br>
                </div>
                <div> </div>
                <div>... and then write the contents of *that* sample to
                  disk, instead. However, if I do that conversion, jpeg
                  is null and the error is:<br>
                </div>
                <div> </div>
                <div>"Cannot find any image encoder for caps image/jpeg"<br>
                </div>
                <div> </div>
                <div>OK, that seems fair. But my pipeline (again see the
                  example code at [1]) is constructed as such:<br>
                </div>
                <div> </div>
                <div>        m_pipeline =
QGst::ElementFactory::make("playbin").dynamicCast<QGst::Pipeline>();<br>
                </div>
                <div> </div>
                <div>My question then becomes: how should I approach
                  this problem? Should I modify the pipeline? I see that
                  there's a "convert-sample" signal on playbin;  is that
                  what I should be using?<br>
                </div>
                <div> </div>
                <div>Any light anyone can shed would be most welcome.<br>
                </div>
              </div>
            </blockquote>
            <div> </div>
            <div>Do you have jpegenc (or any other jpeg encoder) in your
              system? gst-inspect-1.0 jpegenc should show it. Or
              gst-inspect-1.0 |grep jpeg.<br>
            </div>
            <div> </div>
          </blockquote>
          <div> </div>
          <div>I was missing jpegenc; thanks. Having installed it, I now
            get an "Internal data flow error". <br>
          </div>
          <p><span>default convertframe.c:325:gst_video_convert_sample:</span><span>
              Could not convert video frame: Internal data flow error.</span><br>
          </p>
          <div>This is using a one-second timeout on the frame
            conversion (GST_SECOND). Hmmm. Any pointers here?<br>
          </div>
        </blockquote>
        <div>I'd recommend using GST_DEBUG to get some log and check
          what exactly was the error.<br>
        </div>
        <div> </div>
        <div> </div>
        <blockquote type="cite"
cite="mid:1440010011.2772906.360579729.60567105@webmail.messagingengine.com">
          <div> </div>
          <div> </div>
          <pre>_______________________________________________
gstreamer-devel mailing list
<a moz-do-not-send="true" href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.freedesktop.org</a> <a moz-do-not-send="true" href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a>
</pre>
        </blockquote>
        <div> </div>
        <div> </div>
        <pre>-- 
Thiago Sousa Santos
Senior Multimedia Engineer, Open Source Group
Samsung Research America - Silicon Valley
</pre>
        <div><u>_______________________________________________</u><br>
        </div>
        <div>gstreamer-devel mailing list<br>
        </div>
        <div><a moz-do-not-send="true"
            href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.freedesktop.org</a><br>
        </div>
        <div><a moz-do-not-send="true"
            href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a><br>
        </div>
      </blockquote>
      <div> </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
      <pre wrap="">_______________________________________________
gstreamer-devel mailing list
<a class="moz-txt-link-abbreviated" href="mailto:gstreamer-devel@lists.freedesktop.org">gstreamer-devel@lists.freedesktop.org</a>
<a class="moz-txt-link-freetext" href="http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel">http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel</a>
</pre>
    </blockquote>
    <br>
    <br>
    <pre class="moz-signature" cols="72">-- 
Thiago Sousa Santos
Senior Multimedia Engineer, Open Source Group
Samsung Research America - Silicon Valley</pre>
  </body>
</html>