get mouse navigation events on application level ?
adrian at tortenboxer.de
adrian at tortenboxer.de
Wed Aug 14 07:41:43 PDT 2013
Hello,
In my application the stream from a live camera (appsrc) is displayed in a GTK drawarea (autovideosink+gst_video_overlay_set_window_handle). I would like to be able to interactively draw rectangular selections on the video. For the drawing I can use a cairooverlay element, but it is not clear to me how to subscribe to mouse navigation events.
That is, using GTK (motion-notify-events of the drawing_area etc.) I can get the widget-relative pointer coordinates, but then I have to calculate the frame-relative coordinates myself (which might be inaccurate, considering I force the aspect ratio so that the video overlay is possibly much smaller than the drawing area widget itself). I can see how the navigationtest element does the job, looking at its source code, but I am under the impression that I would have to implement a gstreamer element in order to subscribe to these upstream propagating events. Am I wrong ? In any case the application developer manual does not explain how to connect to these events. Is there another element which exposes the "mouse-move" etc. events ?
I would welcome any pointer in the right direction, even just one or two keywords to look for. I am discovering the gstreamer framework simultaneously with glib, gobject, gtk+, ..., so I'm struggling a bit...
TIA
Adrian
More information about the gstreamer-devel
mailing list