Thanks for your detailed response. I have taken a closer look at the source code for osxvideosink and found that it supports an "embed" property (which is FALSE by default).<br><br>I can tell that when TRUE it will emit a message called "have-ns-view", where it passes a GstGLView object to the callback. This object is an NSView (part of the Apple Cocoa framework). I have learned that I am supposed to attach that to a NSWindow.<br>
<br>Unfortunately I am pretty new to programming on the Mac. Thus far I have been using OS abstraction libraries such as Qt to avoid dealing with different windowing systems. Qt gives me back a window handle, which turns out to be integer but I have no idea how to retrieve a NSWindow object from that.<br>
<br>So if anyone has done this before on the Mac (with or without Qt) I would greatly appreciate your input.<br><br>Thanks,<br><br>Andreas<br><br><div class="gmail_quote">On Wed, Jun 25, 2008 at 5:26 PM, Michael Smith <<a href="mailto:msmith@xiph.org" target="_blank">msmith@xiph.org</a>> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div>On Wed, Jun 25, 2008 at 3:16 PM, Andreas Schuler <<a href="mailto:andreas@neokast.com" target="_blank">andreas@neokast.com</a>> wrote:<br>
> Hi all,<br>
><br>
> I am trying to get an application to run on a Max OSX <a href="http://10.5.2." target="_blank">10.5.2.</a> I have<br>
> downloaded and built the latest tar balls and everything seems to be running<br>
> fine when I use gst-launch.<br>
><br>
> >From within my app, which also runs on Windows, I am doing the following to<br>
> set the id of the window I want the video to be rendered on:<br>
><br>
> - get_bus_set_sync_handler to setup my callback<br>
> - The callback function looks as follows:<br>
<br>
</div>That looks good for Win32 and linux. On linux the 'window handle' will<br>
need to be the XID for the window, but that's just a matter of<br>
different platform-specific types, not a big problem.<br>
<br>
On OSX, you're presumably using osxvideosink (well, you say you're<br>
using autovideosink, but that'll be selecting osxvideosink<br>
internally).<br>
<br>
osxvideosink doesn't implement GstXOverlay, so you can't do this with<br>
it. Because of this it won't ever even emit the prepare-xwindow-id<br>
signal, which is what you're seeing.<br>
<br>
osxvideosink has some other interface to set this up, but I don't know<br>
the details of how it works. You may find looking at the output of<br>
"gst-inspect-0.10 osxvideosink" to be helpful - it'll tell you what<br>
signals exist, etc.<br>
<br>
If possible, it would be best to make osxvideosink implement the<br>
GstXOverlay interface - that would let people use more common code<br>
across different platforms. Looking into whether that's possible is on<br>
my TODO list, but pretty far down right now - I probably won't get to<br>
it for a month or two. If you manage to do that sooner, that'd be<br>
great - patches would be very welcome.<br>
<br>
Mike<br>
</blockquote></div>