[gst-devel] How to set window ID on Mac OSX
andreas at neokast.com
Thu Jun 26 00:16:07 CEST 2008
I am trying to get an application to run on a Max OSX 10.5.2. I have
downloaded and built the latest tar balls and everything seems to be running
fine when I use gst-launch.
>From within my app, which also runs on Windows, I am doing the following to
set the id of the window I want the video to be rendered on:
- get_bus_set_sync_handler to setup my callback
- The callback function looks as follows:
gpointer * data)
// ignore anything but 'prepare-xwindow-id' element messages
if (GST_MESSAGE_TYPE (message) != GST_MESSAGE_ELEMENT)
if (!gst_structure_has_name (message->structure, "prepare-xwindow-id"))
DefaultVideoRenderer* renderer = (DefaultVideoRenderer*)data;
if (renderer->m_windowHandle.GetHandle() != 0)
MEDIA_LOG_INFO("Attaching window handle: ", renderer->m_windowHandle
gst_x_overlay_set_xwindow_id (GST_X_OVERLAY (GST_MESSAGE_SRC (
MEDIA_LOG_INFO("Cannot attach window handle because it is null");
This code seems to be working fine on Windows but not on the Mac. I have
found that it never gets to the "GetHandle" line, which leads me to believe
that the XOverlay interface does not exist on the Mac.
The video does play back just fine in its own window by the way.
I am using the "autovideosink" for video in my pipeline.
So the question is: How would one go about setting the render window on a
Mac? Since I am also working on a Linux version I would also be interested
in a solution for that platform.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the gstreamer-devel