<html>
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <div class="moz-cite-prefix">On 10/02/18 10:29, Hans Hony wrote:<br>
    </div>
    <blockquote type="cite"
cite="mid:CAG_0c72vpWAxD7_0x85+uD5vHuJJwZDxtLN84OwW0y0kAjOYog@mail.gmail.com">
      <div dir="ltr">Matt,<br>
        Thanks for the response.<br>
        <br>
        I'm not sure I follow.. I already have an instance of <font
          face="monospace, monospace">Glib.MainLoop</font> for the
        pipeline to run already.<br>
        <br>
        This is constructed on the main thread just after <font
          face="monospace, monospace">Gst.init(None)</font><font
          face="arial, helvetica, sans-serif"> is called.</font><br>
        But.. I am running <font face="monospace, monospace">GLib.MainLoop.run</font> in
        it's own thread - is this okay?<br>
        That Thread is started from the main application, just before
        the pipeline is started.<br>
      </div>
    </blockquote>
    <br>
    Unfortunately, no.  The CFRunLoop must be running on the main
    thread, otherwise this will not work.<br>
    <br>
    Cheers<br>
    -Matt<br>
    <br>
    <blockquote type="cite"
cite="mid:CAG_0c72vpWAxD7_0x85+uD5vHuJJwZDxtLN84OwW0y0kAjOYog@mail.gmail.com">
      <div dir="ltr">What I have tried so far:<br>
        <pre style="font-family:Menlo;font-size:9pt"><span style="background-color:rgb(255,255,255)"><font color="#000000"><span style="font-style:italic">import </span>gi
gi.require_version('GstGL', '1.0')
<span style="font-style:italic">from </span>gi.repository <span style="font-style:italic">import </span>GstGL</font></span></pre>
        <pre style="font-family:Menlo;font-size:9pt"><span style="background-color:rgb(255,255,255)"><font color="#000000">self._context = Gst.Context.new(GstGL.GL_DISPLAY_CONTEXT_TYPE, <span style="font-style:italic">True</span>)
self._gldisplay = GstGL.GLDisplay()
self._gldisplay.new()
self._glwindow = self._gldisplay.create_window()
self._glwindow.show()
self._glcontext = GstGL.GLContext.new(self._gldisplay)
GstGL.context_set_gl_display(self._context, self._gldisplay)
outputsink = gst_elem.make('glimagesink')
outputsink.set_context(self._context)
print('----- context: %s' % str(outputsink.get_property('context')))</font></span></pre>
        <span
style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">
          <div><span
style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"><br>
            </span></div>
          What I notice is that the constructed Element 'glimagesink'
          has a context property which returns 'None' after
          construction.</span><br
style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:small;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;text-decoration-style:initial;text-decoration-color:initial">
        <br>
        I can see that the python rocket bouncing.. so it's attempting
        to kick the display.. but no window.<br>
        <br>
        Do I need to override something with the
        GST_MESSAGE_NEED_CONTEXT, perhaps?<br>
        <br>
        I have attempted to connect this on the bus
        'message::need-context', but get no signal..<br>
        <br>
        <br>
        <div class="gmail_extra"><br>
          <div class="gmail_quote">On Thu, Feb 8, 2018 at 1:21 AM,
            Matthew Waters <span dir="ltr"><<a
                href="mailto:ystreet00@gmail.com" target="_blank"
                moz-do-not-send="true">ystreet00@gmail.com</a>></span>
            wrote:<br>
            <blockquote class="gmail_quote" style="margin:0 0 0
              .8ex;border-left:1px #ccc solid;padding-left:1ex">
              <div text="#000000" bgcolor="#FFFFFF">
                <div class="m_-4335131971921842420moz-cite-prefix">Mac
                  OS X is special in that a CFRunLoop is required to be
                  running on the main thread in order for glimagesink
                  (and other UI operations) to perform correctly.<br>
                  <br>
                  That either means you need to run one yourself, use a
                  toolkit that runs one or run a GMainLoop.<br>
                  <br>
                  Running your gst-launch-1.0 command with
                  GST_DEBUG=gl*:7 would give you more information about
                  what GStreamer is attempting to do, specifically
                  around <a
href="https://cgit.freedesktop.org/gstreamer/gst-plugins-base/tree/gst-libs/gst/gl/cocoa/gstgldisplay_cocoa.m#n105"
                    target="_blank" moz-do-not-send="true">https://cgit.freedesktop.org/<wbr>gstreamer/gst-plugins-base/<wbr>tree/gst-libs/gst/gl/cocoa/<wbr>gstgldisplay_cocoa.m#n105</a>.<span
                    class=""><br>
                    <br>
                    On 08/02/18 06:49, Hans Hony wrote:<br>
                  </span></div>
                <span class="">
                  <blockquote type="cite">
                    <div dir="ltr"><span
style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">I
                        have a question about launching a simple video
                        pipeline using 'glimagesink' with the python3
                        gi.repository.Gst.<wbr>ElementFactory..</span><br
style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">
                      <br
style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">
                      <span
style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">On
                        Mac OSX I can launch my pipeline with custom
                        plugin:</span><br
style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">
                      <span style="font-family:monospace,monospace">gst-launch-1.0
                        filesrc <avi> ! decodebin ! queue !
                        my_custom_plugin <props> ! autovideosink</span><br>
                      <br>
                      <div>The output a default window titled 'OpenGL
                        renderer'.. which I assume is <a
href="https://github.com/GStreamer/gst-plugins-bad/blob/1.12/gst-libs/gst/gl/cocoa/gstglwindow_cocoa.m#L466"
                          target="_blank" moz-do-not-send="true">gstglwindow_cocoa.m</a> from
                        gst-plugins-bad.. ?<br>
                        <font face="arial, helvetica, sans-serif"><br>
                          <span
style="color:rgb(34,34,34);font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:left;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">Likewise,
                            'glimagesink' will also open the 'OpenGL
                            renderer' window when used in a bash
                            gst-launch-1.0 command in the same way as
                            'autovideosink'. </span>Also I notice when I
                          launch the pipeline under bash, I can see:<br>
                        </font><br>
                        <span></span>
                        <p class="m_-4335131971921842420gmail-p1"
style="margin:0px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:12px;line-height:normal"><span
                            class="m_-4335131971921842420gmail-s1"
style="font-variant-ligatures:no-common-ligatures;background-color:rgb(255,255,255)"><font
                              face="monospace, monospace"
                              color="#000000">    Setting pipeline to
                              PAUSED ...</font></span></p>
                        <p class="m_-4335131971921842420gmail-p1"
style="margin:0px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:12px;line-height:normal"><span
                            class="m_-4335131971921842420gmail-s1"
style="font-variant-ligatures:no-common-ligatures;background-color:rgb(255,255,255)"><font
                              face="monospace, monospace"
                              color="#000000">    Pipeline is PREROLLING
                              ...</font></span></p>
                        <p class="m_-4335131971921842420gmail-p1"
style="margin:0px;font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:12px;line-height:normal"><span
                            class="m_-4335131971921842420gmail-s1"
style="font-variant-ligatures:no-common-ligatures;background-color:rgb(255,255,255)"><font
                              face="monospace, monospace"
                              color="#000000">    Got context from
                              element 'sink': gst.gl.GLDisplay=context,
                              gst.gl.GLDisplay=(<wbr>GstGLDisplay)"\(<wbr>GstGLDisplayCocoa\)\
                              gldisplaycocoa0";</font></span></p>
                        <br>
                        <br
style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">
                        <span
style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">However,
                          when I launch the pipeline for
                          gi.repository.Gst.<wbr>ElementFactory (in
                          python3) I have issues:</span><br
style="color:rgb(34,34,34);font-family:arial,sans-serif;font-size:12.8px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">
                        <div
style="font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;text-decoration-style:initial;text-decoration-color:initial">
                          <ol>
                            <li
style="font-size:12.8px;font-family:arial,sans-serif;background-color:rgb(255,255,255);color:rgb(34,34,34);margin-left:15px">It
                              fails horribly for
                              ElementFactory.make('autovideo<wbr>sink')
                              with <i>Illegal instruction: 4</i> when
                              NULL to READY is propagated.. so to fix
                              that I just didn't use 'autovideosink'..<br>
                              <br>
                            </li>
                            <li
style="font-size:12.8px;font-family:arial,sans-serif;background-color:rgb(255,255,255);color:rgb(34,34,34);font-style:normal;margin-left:15px">It
                              will propagate PLAY for
                              ElementFactory.make('glimagesi<wbr>nk')..
                              but nothing actually plays.. probably
                              because the chain isn't correct<br>
                              <br>
                            </li>
                            <li
style="font-size:12.8px;font-family:arial,sans-serif;background-color:rgb(255,255,255);color:rgb(34,34,34);font-style:normal;margin-left:15px">I
                              cannot figure out how to hook the
                              'sync_message' to an OSX window object
                              with glimagesink from python?!? I see
                              information in gst-inspect-1.0
                              glimagesink.. but I can't find any
                              examples to do this specifically.<br>
                              <br>
                            </li>
                            <li
                              style="font-size:12.8px;font-style:normal;margin-left:15px"><font
style="background-color:rgb(255,255,255)" color="#000000">Secondarily, I
                                see that I can use <font
                                  face="monospace, monospace">gi.repository.GstGL.GLDisplay(<wbr>).new()</font>
                                to create:<br>
                              </font>    <__gi__.GstGLDisplayCocoa
                              object at 0x10e05eb88 (GstGLDisplayCocoa
                              at 0x7fc7ba9439c0)><br>
                              .. which is seemingly what I want!<br>
                              <br>
                            </li>
                            <li
                              style="font-size:12.8px;font-style:normal;margin-left:15px">How
                              to do hook this object up to 'glimagesink'
                              ??<br>
                            </li>
                          </ol>
                        </div>
                      </div>
                    </div>
                  </blockquote>
                  <br>
                </span> You don't need to hook this up to GStreamer, it
                will create that automatically.<span class=""><br>
                  <br>
                  <blockquote type="cite">
                    <div dir="ltr">
                      <div>
                        <div
style="font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;text-decoration-style:initial;text-decoration-color:initial">
                          <ol>
                            <li
                              style="font-style:normal;margin-left:15px">Finally,
                              do I need to add:<br>
                              <font
                                style="background-color:rgb(255,255,255)"
                                color="#000000"><font
                                  style="font-size:12.8px"
                                  face="monospace, monospace"> 
                                  pipeline.get_bus()</font><span style="font-size:12px;font-family:monospace,monospace;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">.connect(</span><span class="m_-4335131971921842420gmail-pl-s" style="font-size:12px;font-family:monospace,monospace;box-sizing:border-box;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;text-decoration-style:initial;text-decoration-color:initial"><span class="m_-4335131971921842420gmail-pl-pds" style="box-sizing:border-box">'</span>sy<wbr>nc-message::element<span class="m_-4335131971921842420gmail-pl-pds" style="box-sizing:border-box">'</span></span><span style="font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"><font style="font-size:12px" face="monospace, monospace">, on_sync_message)
</font><font face="arial, helvetica, sans-serif">with a function on_sync_message(bus, msg) ?</font></span></font></li>
                          </ol>
                        </div>
                      </div>
                    </div>
                  </blockquote>
                  <br>
                </span> This shouldn't be needed.<span class=""><br>
                  <br>
                  <blockquote type="cite">
                    <div dir="ltr">
                      <div>
                        <div
style="font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px;text-decoration-style:initial;text-decoration-color:initial"><span style="font-family:arial,helvetica,sans-serif;white-space:pre-wrap;color:rgb(0,0,0)">From the Gtk examples I found there was a function which would update the GUI.. I assume that I would need to do this as well.. but the syntax is not clear immediately.
</span><br>
                          More specifically:<br>
                          <span class="m_-4335131971921842420gmail-pl-k" style="box-sizing:border-box;color:rgb(215,58,73);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">def</span><span style="color:rgb(36,41,46);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"> </span><span class="m_-4335131971921842420gmail-pl-en" style="box-sizing:border-box;color:rgb(111,66,193);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">on_sync_message</span><span style="color:rgb(36,41,46);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">(</span><span class="m_-4335131971921842420gmail-pl-smi" style="box-sizing:border-box;color:rgb(36,41,46);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">bus</span><span style="color:rgb(36,41,46);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">, </span><span class="m_-4335131971921842420gmail-pl-smi" style="box-sizing:border-box;color:rgb(36,41,46);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">msg</span><span style="color:rgb(36,41,46);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">):
</span><span style="color:rgb(36,41,46);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">    </span><span class="m_-4335131971921842420gmail-pl-k" style="box-sizing:border-box;color:rgb(215,58,73);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">if</span><span style="color:rgb(36,41,46);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"> msg.get_structure().get_name() </span><span class="m_-4335131971921842420gmail-pl-k" style="box-sizing:border-box;color:rgb(215,58,73);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">==</span><span style="color:rgb(36,41,46);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"> </span><span class="m_-4335131971921842420gmail-pl-s" style="box-sizing:border-box;color:rgb(3,47,98);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial"><span class="m_-4335131971921842420gmail-pl-pds" style="box-sizing:border-box;color:rgb(3,47,98)">'</span>prepare-window-handle<span class="m_-4335131971921842420gmail-pl-pds" style="box-sizing:border-box;color:rgb(3,47,98)">'</span></span><span style="color:rgb(36,41,46);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">:</span></div>
                        <div
style="font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;word-spacing:0px;text-decoration-style:initial;text-decoration-color:initial"><font
                            face="SFMono-Regular, Consolas, Liberation
                            Mono, Menlo, Courier, monospace"
                            color="#24292e"><span style="font-size:12px;white-space:pre-wrap"><span style="color:rgb(36,41,46);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">        sink </span><span class="m_-4335131971921842420gmail-pl-k" style="box-sizing:border-box;color:rgb(215,58,73);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">=</span><span style="color:rgb(36,41,46);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline"> msg.src</span></span></font></div>
                        <div
style="font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;word-spacing:0px;text-decoration-style:initial;text-decoration-color:initial"><font
                            face="SFMono-Regular, Consolas, Liberation
                            Mono, Menlo, Courier, monospace"
                            color="#24292e"><span style="font-size:12px;white-space:pre-wrap"><span style="color:rgb(36,41,46);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">        sink.set_window_handle(<<wbr>window_handle>)</span></span></font></div>
                        <div
style="font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;word-spacing:0px;text-decoration-style:initial;text-decoration-color:initial"><font
                            face="SFMono-Regular, Consolas, Liberation
                            Mono, Menlo, Courier, monospace"
                            color="#24292e"><span style="font-size:12px;white-space:pre-wrap"><span style="color:rgb(36,41,46);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">        sink.set_render_rectangle(</span><span class="m_-4335131971921842420gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,92,197);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">0</span><span style="color:rgb(36,41,46);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">, </span><span class="m_-4335131971921842420gmail-pl-c1" style="box-sizing:border-box;color:rgb(0,92,197);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial">0</span><span style="color:rgb(36,41,46);font-family:SFMono-Regular,Consolas,"Liberation Mono",Menlo,Courier,monospace;font-size:12px;font-style:normal;font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;white-space:pre-wrap;word-spacing:0px;background-color:rgb(255,255,255);text-decoration-style:initial;text-decoration-color:initial;float:none;display:inline">, <window.width>, <window.height>)</span></span></font><br>
                        </div>
                      </div>
                    </div>
                  </blockquote>
                  <br>
                </span> This is for embedding glimagesink's output
                inside another application.<span class=""><br>
                  <br>
                  <blockquote type="cite">
                    <div dir="ltr">
                      <div>
                        <div
style="font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;word-spacing:0px;text-decoration-style:initial;text-decoration-color:initial"><span
style="white-space:normal;font-size:12.8px;font-family:arial,sans-serif;background-color:rgb(255,255,255)">Overall,
                            I want to know:</span><br>
                          <ol
style="white-space:normal;font-size:12.8px;font-family:arial,sans-serif;background-color:rgb(255,255,255);color:rgb(34,34,34)">
                            <li>How is it that gst-launch-1.0 works so
                              well?<br>
                            </li>
                          </ol>
                        </div>
                      </div>
                    </div>
                  </blockquote>
                  <br>
                </span> Because, glimagesink is generally created and
                set to READY on the main thread. Otherwise, happy
                accident.<span class=""><br>
                  <br>
                  <blockquote type="cite">
                    <div dir="ltr">
                      <div>
                        <div
style="font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;word-spacing:0px;text-decoration-style:initial;text-decoration-color:initial">
                          <ol
style="white-space:normal;font-size:12.8px;font-family:arial,sans-serif;background-color:rgb(255,255,255);color:rgb(34,34,34)">
                            <li>How can I use that functionality in my
                              python3 gi code?<br>
                            </li>
                          </ol>
                        </div>
                      </div>
                    </div>
                  </blockquote>
                  <br>
                </span> Run a CFRunLoop/GMainLoop on the main thread.<span
                  class=""><br>
                  <br>
                  <blockquote type="cite">
                    <div dir="ltr">
                      <div>
                        <div
style="font-variant-ligatures:normal;font-variant-caps:normal;font-weight:400;letter-spacing:normal;text-align:start;text-indent:0px;text-transform:none;word-spacing:0px;text-decoration-style:initial;text-decoration-color:initial">
                          <ol
style="white-space:normal;font-size:12.8px;font-family:arial,sans-serif;background-color:rgb(255,255,255);color:rgb(34,34,34)">
                            <li>How can I add another element to trigger
                              that force-aspect-ratio window magic?</li>
                          </ol>
                        </div>
                      </div>
                    </div>
                  </blockquote>
                  <br>
                </span> I'm not sure what you mean by this.<br>
                <br>
                Cheers<br>
                -Matt<span class=""><br>
                  <br>
                  <blockquote type="cite">
                    <div dir="ltr">
                      <div>
                        <div>
                          <p class="m_-4335131971921842420gmail-p1"
style="margin:0px;font-style:normal;font-variant:normal;font-stretch:normal;font-size:12px;line-height:normal;font-family:Courier"><span
                              class="m_-4335131971921842420gmail-s1"
style="font-variant-ligatures:no-common-ligatures;background-color:rgb(255,255,255)"><font
                                color="#000000">$ brew list --versions |
                                grep gst</font></span></p>
                          <p class="m_-4335131971921842420gmail-p1"
style="margin:0px;font-style:normal;font-variant:normal;font-stretch:normal;font-size:12px;line-height:normal;font-family:Courier"><font
                              style="background-color:rgb(255,255,255)"
                              color="#000000"><span
                                class="m_-4335131971921842420gmail-s2"
                                style="font-variant-ligatures:no-common-ligatures">gst</span><span
                                class="m_-4335131971921842420gmail-s1"
                                style="font-variant-ligatures:no-common-ligatures">-plugins-bad
                                1.12.3</span></font></p>
                          <p class="m_-4335131971921842420gmail-p1"
style="margin:0px;font-style:normal;font-variant:normal;font-stretch:normal;font-size:12px;line-height:normal;font-family:Courier"><font
                              style="background-color:rgb(255,255,255)"
                              color="#000000"><span
                                class="m_-4335131971921842420gmail-s2"
                                style="font-variant-ligatures:no-common-ligatures">gst</span><span
                                class="m_-4335131971921842420gmail-s1"
                                style="font-variant-ligatures:no-common-ligatures">-plugins-base
                                1.12.3</span></font></p>
                          <p class="m_-4335131971921842420gmail-p1"
style="margin:0px;font-style:normal;font-variant:normal;font-stretch:normal;font-size:12px;line-height:normal;font-family:Courier"><font
                              style="background-color:rgb(255,255,255)"
                              color="#000000"><span
                                class="m_-4335131971921842420gmail-s2"
                                style="font-variant-ligatures:no-common-ligatures">gst</span><span
                                class="m_-4335131971921842420gmail-s1"
                                style="font-variant-ligatures:no-common-ligatures">-plugins-good
                                1.12.3</span></font></p>
                          <p class="m_-4335131971921842420gmail-p1"
style="margin:0px;font-style:normal;font-variant:normal;font-stretch:normal;font-size:12px;line-height:normal;font-family:Courier"><font
                              style="background-color:rgb(255,255,255)"
                              color="#000000"><span
                                class="m_-4335131971921842420gmail-s2"
                                style="font-variant-ligatures:no-common-ligatures">gst</span><span
                                class="m_-4335131971921842420gmail-s1"
                                style="font-variant-ligatures:no-common-ligatures">-plugins-ugly
                                1.12.3</span></font></p>
                          <p class="m_-4335131971921842420gmail-p1"
style="margin:0px;font-style:normal;font-variant:normal;font-stretch:normal;font-size:12px;line-height:normal;font-family:Courier"><font
                              style="background-color:rgb(255,255,255)"
                              color="#000000"><span
                                class="m_-4335131971921842420gmail-s2"
                                style="font-variant-ligatures:no-common-ligatures">gst</span><span
                                class="m_-4335131971921842420gmail-s1"
                                style="font-variant-ligatures:no-common-ligatures">-python
                                1.12.3</span></font></p>
                          <p class="m_-4335131971921842420gmail-p1"
style="margin:0px;font-style:normal;font-variant:normal;font-stretch:normal;font-size:12px;line-height:normal;font-family:Courier"><font
                              style="background-color:rgb(255,255,255)"
                              color="#000000"><span
                                class="m_-4335131971921842420gmail-s2"
                                style="font-variant-ligatures:no-common-ligatures">gst</span><span
                                class="m_-4335131971921842420gmail-s1"
                                style="font-variant-ligatures:no-common-ligatures">-rtsp-server
                                1.12.3</span></font></p>
                          <p class="m_-4335131971921842420gmail-p1"
style="margin:0px;font-style:normal;font-variant:normal;font-stretch:normal;font-size:12px;line-height:normal;font-family:Courier"><font
                              style="background-color:rgb(255,255,255)"
                              color="#000000"><span
                                class="m_-4335131971921842420gmail-s2"
                                style="font-variant-ligatures:no-common-ligatures">gst</span><span
                                class="m_-4335131971921842420gmail-s1"
                                style="font-variant-ligatures:no-common-ligatures">reamer
                                1.12.3</span></font></p>
                          <br>
                          Thanks,</div>
                        <div>Hans</div>
                      </div>
                    </div>
                  </blockquote>
                </span></div>
            </blockquote>
          </div>
        </div>
      </div>
    </blockquote>
  </body>
</html>