Merge branch 'master' into 0.11
authorWim Taymans <wim.taymans@collabora.co.uk>
Tue, 17 May 2011 14:13:59 +0000 (16:13 +0200)
committerWim Taymans <wim.taymans@collabora.co.uk>
Tue, 17 May 2011 14:13:59 +0000 (16:13 +0200)
1  2 
gst/rtsp/gstrtspsrc.c
sys/v4l2/gstv4l2object.c

@@@ -262,14 -265,57 +265,27 @@@ static gboolean gst_rtspsrc_push_event 
      gboolean source);
  
  /* commands we send to out loop to notify it of events */
- #define CMD_WAIT      0
- #define CMD_RECONNECT 1
- #define CMD_STOP      2
+ #define CMD_OPEN      0
+ #define CMD_PLAY      1
+ #define CMD_PAUSE     2
+ #define CMD_CLOSE     3
+ #define CMD_WAIT      4
+ #define CMD_RECONNECT 5
+ #define CMD_LOOP      6
+ #define GST_ELEMENT_PROGRESS(el, type, code, text)      \
+ G_STMT_START {                                          \
+   gchar *__txt = _gst_element_error_printf text;        \
+   gst_element_post_message (GST_ELEMENT_CAST (el),      \
+       gst_message_new_progress (GST_OBJECT_CAST (el),   \
+           GST_PROGRESS_TYPE_ ##type, code, __txt));     \
+   g_free (__txt);                                       \
+ } G_STMT_END
  
  /*static guint gst_rtspsrc_signals[LAST_SIGNAL] = { 0 }; */
 -
 -static void
 -_do_init (GType rtspsrc_type)
 -{
 -  static const GInterfaceInfo urihandler_info = {
 -    gst_rtspsrc_uri_handler_init,
 -    NULL,
 -    NULL
 -  };
 -
 -  GST_DEBUG_CATEGORY_INIT (rtspsrc_debug, "rtspsrc", 0, "RTSP src");
 -
 -  g_type_add_interface_static (rtspsrc_type, GST_TYPE_URI_HANDLER,
 -      &urihandler_info);
 -}
 -
 -GST_BOILERPLATE_FULL (GstRTSPSrc, gst_rtspsrc, GstBin, GST_TYPE_BIN, _do_init);
 -
 -static void
 -gst_rtspsrc_base_init (gpointer g_class)
 -{
 -  GstElementClass *element_class = GST_ELEMENT_CLASS (g_class);
 -
 -  gst_element_class_add_pad_template (element_class,
 -      gst_static_pad_template_get (&rtptemplate));
 -
 -  gst_element_class_set_details_simple (element_class, "RTSP packet receiver",
 -      "Source/Network",
 -      "Receive data over the network via RTSP (RFC 2326)",
 -      "Wim Taymans <wim@fluendo.com>, "
 -      "Thijs Vermeir <thijs.vermeir@barco.com>, "
 -      "Lutz Mueller <lutz@topfrose.de>");
 -}
 +#define gst_rtspsrc_parent_class parent_class
 +G_DEFINE_TYPE_WITH_CODE (GstRTSPSrc, gst_rtspsrc, GST_TYPE_BIN,
 +    G_IMPLEMENT_INTERFACE (GST_TYPE_URI_HANDLER, gst_rtspsrc_uri_handler_init));
  
  static void
  gst_rtspsrc_class_init (GstRTSPSrcClass * klass)
Simple merge