Linking xvimagesink to a gtk window.

Nathanael D. Noblet nathanael at
Tue Aug 23 11:43:57 PDT 2011

On 08/23/2011 11:14 AM, akaChella wrote:
> Hi all,
> I have created a window using gtk and linked the xvimagesink to that window.
> Able to play the Video but i am facing problem when i am trying to hide that
> widget.
> 1. I have constructed the pipeline to play the video.
> 2. During construction i have created the container window and a video
> window (drawing area) but did not show it. Used, gtk_widget_hide(window);
> 3. I wanted the window widget to be shown only when the play command is
> issued i.e, only when the pipeline is set to GST_PLAYING.
> 4. When the bus handler receives the EOS (End of Stream), i gave
> gtk_widget_hide(window); But the black window is displayed. It is not
> hidden.
> Is there anything i am missing.
> Note: I have not used gtk_main() function. I have just called the
> gtk_init(NULL,NULL); and then created a window.

I would suggest you call gtk_main() and build a 'properly' functioning 
gtk app. gtk_main deals with the event loop, which is somewhat necessary 
unless you have your own event loop which is likely just complicating 
things. Considering this is your first app I'd suggest sticking with the 

> Requirement: Want to create the window everytime i get a play command and
> want to hide / destroy that window when received a stop command or it
> reaches EOS.
> Need your help. I am new to gstreamer as well as gtk :(
> Thanks in advance.
> --
> View this message in context:
> Sent from the GStreamer-devel mailing list archive at
> _______________________________________________
> gstreamer-devel mailing list
> gstreamer-devel at

More information about the gstreamer-devel mailing list