[gst-devel] XOverlay / desired size

Benjamin Otte in7y118 at public.uni-hamburg.de
Fri Jan 2 11:40:02 CET 2004


Any objections to the following patch?
It implements an (optional) desired size for the XOverlay interface, so
there's a possibility to figure out how big a the video is currently.
I'm at a loss for what to return in size_request in a GtkWidget embedding
this.

Full patch is attached seperately.

Benjamin


#> cvs diff -u xoverlay.h
Index: xoverlay.h
===================================================================
RCS file:
/home/cvs/gstreamer/gst-plugins/gst-libs/gst/xoverlay/xoverlay.h,v
retrieving revision 1.5
diff -u -r1.5 xoverlay.h
--- xoverlay.h  9 Dec 2003 10:02:08 -0000       1.5
+++ xoverlay.h  2 Jan 2004 19:34:48 -0000
@@ -50,10 +50,17 @@
   /* virtual functions */
   void (* set_xwindow_id) (GstXOverlay *overlay,
                           XID          xwindow_id);
+  /* optional virtual functions */
+  void (* get_desired_size) (GstXOverlay *overlay,
+                            guint *width,
+                            guint *height);

   /* signals */
   void (*have_xwindow_id) (GstXOverlay *overlay,
                            XID          xwindow_id);
+  void (* desired_size)          (GstXOverlay *overlay,
+                          guint width,
+                          guint height);

   gpointer _gst_reserved[GST_PADDING];
 } GstXOverlayClass;
@@ -62,9 +69,11 @@

 /* virtual class function wrappers */
 void gst_x_overlay_set_xwindow_id (GstXOverlay *overlay, XID xwindow_id);
+void gst_x_overlay_get_desired_size (GstXOverlay *overlay, guint *width,
guint *height);

 /* public methods to fire signals */
 void gst_x_overlay_got_xwindow_id (GstXOverlay *overlay, XID xwindow_id);
+void gst_x_overlay_got_desired_size (GstXOverlay *overlay, guint width,
guint height);

 G_END_DECLS


-------------- next part --------------
A non-text attachment was scrubbed...
Name: xoverlay.diff.gz
Type: application/x-gunzip
Size: 1545 bytes
Desc: complete diff
URL: <http://lists.freedesktop.org/archives/gstreamer-devel/attachments/20040102/602e4063/attachment.bin>


More information about the gstreamer-devel mailing list