mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 04:01:08 +00:00
camerabin: remove custom renegotiate event
In 1.0 there is a core reconfigure event, camerabin doesn't need its custom renegotiate event anymore
This commit is contained in:
parent
b030923eb5
commit
b5ba142b06
2 changed files with 1 additions and 29 deletions
|
@ -71,11 +71,3 @@ caps negotiation. Camerabin2 puts capsfilters downstream from each of the
|
|||
camera source pads. The camera source can simply get_caps on the peer of
|
||||
each of its pads to know what are the allowed caps for that pad.
|
||||
|
||||
|
||||
-- Renegotiation --
|
||||
Easy renegotiation isn't supported on gstreamer yet (there is some ongoing work
|
||||
currently). Camerabin2 will use a custom 'renegotiate' event, no fields to
|
||||
indicate that a certain pad should renegotiate its caps.
|
||||
|
||||
Upon receiving this event, a pad should get_caps on its peer and do the caps
|
||||
negotiation again. It is likely that a new format was requested.
|
||||
|
|
|
@ -347,13 +347,6 @@ gst_camera_bin_change_state (GstElement * element, GstStateChange trans);
|
|||
|
||||
/* Camerabin functions */
|
||||
|
||||
static GstEvent *
|
||||
gst_camera_bin_new_event_renegotiate (void)
|
||||
{
|
||||
return gst_event_new_custom (GST_EVENT_CUSTOM_BOTH,
|
||||
gst_structure_new_empty ("renegotiate"));
|
||||
}
|
||||
|
||||
static GstEvent *
|
||||
gst_camera_bin_new_event_file_location (const gchar * location)
|
||||
{
|
||||
|
@ -2094,13 +2087,8 @@ gst_camera_bin_set_property (GObject * object, guint prop_id,
|
|||
GST_WARNING_OBJECT (camera, "Image capsfilter missing");
|
||||
}
|
||||
|
||||
/* set the capsfilter caps and notify the src to renegotiate */
|
||||
if (pad) {
|
||||
GST_DEBUG_OBJECT (camera, "Pushing renegotiate on %s",
|
||||
GST_PAD_NAME (pad));
|
||||
gst_pad_send_event (pad, gst_camera_bin_new_event_renegotiate ());
|
||||
if (pad)
|
||||
gst_object_unref (pad);
|
||||
}
|
||||
}
|
||||
break;
|
||||
case PROP_VIDEO_CAPTURE_CAPS:{
|
||||
|
@ -2115,7 +2103,6 @@ gst_camera_bin_set_property (GObject * object, guint prop_id,
|
|||
"Setting video capture caps to %" GST_PTR_FORMAT,
|
||||
gst_value_get_caps (value));
|
||||
|
||||
/* set the capsfilter caps and notify the src to renegotiate */
|
||||
if (G_LIKELY (camera->videobin_capsfilter)) {
|
||||
g_object_set (camera->videobin_capsfilter, "caps",
|
||||
gst_value_get_caps (value), NULL);
|
||||
|
@ -2124,9 +2111,6 @@ gst_camera_bin_set_property (GObject * object, guint prop_id,
|
|||
}
|
||||
|
||||
if (pad) {
|
||||
GST_DEBUG_OBJECT (camera, "Pushing renegotiate on %s",
|
||||
GST_PAD_NAME (pad));
|
||||
gst_pad_send_event (pad, gst_camera_bin_new_event_renegotiate ());
|
||||
gst_object_unref (pad);
|
||||
}
|
||||
}
|
||||
|
@ -2143,7 +2127,6 @@ gst_camera_bin_set_property (GObject * object, guint prop_id,
|
|||
"Setting viewfinder capture caps to %" GST_PTR_FORMAT,
|
||||
gst_value_get_caps (value));
|
||||
|
||||
/* set the capsfilter caps and notify the src to renegotiate */
|
||||
if (G_LIKELY (camera->viewfinderbin_capsfilter)) {
|
||||
g_object_set (camera->viewfinderbin_capsfilter, "caps",
|
||||
gst_value_get_caps (value), NULL);
|
||||
|
@ -2152,9 +2135,6 @@ gst_camera_bin_set_property (GObject * object, guint prop_id,
|
|||
}
|
||||
|
||||
if (pad) {
|
||||
GST_DEBUG_OBJECT (camera, "Pushing renegotiate on %s",
|
||||
GST_PAD_NAME (pad));
|
||||
gst_pad_send_event (pad, gst_camera_bin_new_event_renegotiate ());
|
||||
gst_object_unref (pad);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue