mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-23 18:21:04 +00:00
Sprinkle some G_PARAM_DEPRECATED and #ifndef GST_REMOVE_DEPRECATED
This commit is contained in:
parent
da51a99403
commit
3956f5addc
5 changed files with 26 additions and 13 deletions
|
@ -151,12 +151,14 @@ gst_jpeg_dec_class_init (GstJpegDecClass * klass)
|
||||||
*
|
*
|
||||||
* Deprecated: 1.3.1: Property wasn't used internally
|
* Deprecated: 1.3.1: Property wasn't used internally
|
||||||
*/
|
*/
|
||||||
|
#ifndef GST_REMOVE_DEPRECATED
|
||||||
g_object_class_install_property (gobject_class, PROP_MAX_ERRORS,
|
g_object_class_install_property (gobject_class, PROP_MAX_ERRORS,
|
||||||
g_param_spec_int ("max-errors", "Maximum Consecutive Decoding Errors",
|
g_param_spec_int ("max-errors", "Maximum Consecutive Decoding Errors",
|
||||||
"(Deprecated) Error out after receiving N consecutive decoding errors"
|
"(Deprecated) Error out after receiving N consecutive decoding errors"
|
||||||
" (-1 = never fail, 0 = automatic, 1 = fail on first error)",
|
" (-1 = never fail, 0 = automatic, 1 = fail on first error)",
|
||||||
-1, G_MAXINT, JPEG_DEFAULT_MAX_ERRORS,
|
-1, G_MAXINT, JPEG_DEFAULT_MAX_ERRORS,
|
||||||
G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
|
G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS | G_PARAM_DEPRECATED));
|
||||||
|
#endif
|
||||||
|
|
||||||
gst_element_class_add_pad_template (element_class,
|
gst_element_class_add_pad_template (element_class,
|
||||||
gst_static_pad_template_get (&gst_jpeg_dec_src_pad_template));
|
gst_static_pad_template_get (&gst_jpeg_dec_src_pad_template));
|
||||||
|
@ -1302,10 +1304,11 @@ gst_jpeg_dec_set_property (GObject * object, guint prop_id,
|
||||||
case PROP_IDCT_METHOD:
|
case PROP_IDCT_METHOD:
|
||||||
dec->idct_method = g_value_get_enum (value);
|
dec->idct_method = g_value_get_enum (value);
|
||||||
break;
|
break;
|
||||||
|
#ifndef GST_REMOVE_DEPRECATED
|
||||||
case PROP_MAX_ERRORS:
|
case PROP_MAX_ERRORS:
|
||||||
g_atomic_int_set (&dec->max_errors, g_value_get_int (value));
|
g_atomic_int_set (&dec->max_errors, g_value_get_int (value));
|
||||||
break;
|
break;
|
||||||
|
#endif
|
||||||
default:
|
default:
|
||||||
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
|
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
|
||||||
break;
|
break;
|
||||||
|
@ -1324,10 +1327,11 @@ gst_jpeg_dec_get_property (GObject * object, guint prop_id, GValue * value,
|
||||||
case PROP_IDCT_METHOD:
|
case PROP_IDCT_METHOD:
|
||||||
g_value_set_enum (value, dec->idct_method);
|
g_value_set_enum (value, dec->idct_method);
|
||||||
break;
|
break;
|
||||||
|
#ifndef GST_REMOVE_DEPRECATED
|
||||||
case PROP_MAX_ERRORS:
|
case PROP_MAX_ERRORS:
|
||||||
g_value_set_int (value, g_atomic_int_get (&dec->max_errors));
|
g_value_set_int (value, g_atomic_int_get (&dec->max_errors));
|
||||||
break;
|
break;
|
||||||
|
#endif
|
||||||
default:
|
default:
|
||||||
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
|
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
|
||||||
break;
|
break;
|
||||||
|
|
|
@ -281,6 +281,7 @@ gst_qt_mux_class_init (GstQTMuxClass * klass)
|
||||||
{
|
{
|
||||||
GObjectClass *gobject_class;
|
GObjectClass *gobject_class;
|
||||||
GstElementClass *gstelement_class;
|
GstElementClass *gstelement_class;
|
||||||
|
GParamFlags streamable_flags;
|
||||||
const gchar *streamable_desc;
|
const gchar *streamable_desc;
|
||||||
gboolean streamable;
|
gboolean streamable;
|
||||||
#define STREAMABLE_DESC "If set to true, the output should be as if it is to "\
|
#define STREAMABLE_DESC "If set to true, the output should be as if it is to "\
|
||||||
|
@ -295,12 +296,14 @@ gst_qt_mux_class_init (GstQTMuxClass * klass)
|
||||||
gobject_class->get_property = gst_qt_mux_get_property;
|
gobject_class->get_property = gst_qt_mux_get_property;
|
||||||
gobject_class->set_property = gst_qt_mux_set_property;
|
gobject_class->set_property = gst_qt_mux_set_property;
|
||||||
|
|
||||||
|
streamable_flags = G_PARAM_READWRITE | G_PARAM_CONSTRUCT;
|
||||||
if (klass->format == GST_QT_MUX_FORMAT_ISML) {
|
if (klass->format == GST_QT_MUX_FORMAT_ISML) {
|
||||||
streamable_desc = STREAMABLE_DESC;
|
streamable_desc = STREAMABLE_DESC;
|
||||||
streamable = DEFAULT_STREAMABLE;
|
streamable = DEFAULT_STREAMABLE;
|
||||||
} else {
|
} else {
|
||||||
streamable_desc =
|
streamable_desc =
|
||||||
STREAMABLE_DESC " (DEPRECATED, only valid for fragmented MP4)";
|
STREAMABLE_DESC " (DEPRECATED, only valid for fragmented MP4)";
|
||||||
|
streamable_flags |= G_PARAM_DEPRECATED;
|
||||||
streamable = FALSE;
|
streamable = FALSE;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -323,7 +326,7 @@ gst_qt_mux_class_init (GstQTMuxClass * klass)
|
||||||
#ifndef GST_REMOVE_DEPRECATED
|
#ifndef GST_REMOVE_DEPRECATED
|
||||||
g_object_class_install_property (gobject_class, PROP_DTS_METHOD,
|
g_object_class_install_property (gobject_class, PROP_DTS_METHOD,
|
||||||
g_param_spec_enum ("dts-method", "dts-method",
|
g_param_spec_enum ("dts-method", "dts-method",
|
||||||
"(DEPRECATED) Method to determine DTS time",
|
"Method to determine DTS time (DEPRECATED)",
|
||||||
GST_TYPE_QT_MUX_DTS_METHOD, DEFAULT_DTS_METHOD,
|
GST_TYPE_QT_MUX_DTS_METHOD, DEFAULT_DTS_METHOD,
|
||||||
G_PARAM_DEPRECATED | G_PARAM_READWRITE | G_PARAM_CONSTRUCT |
|
G_PARAM_DEPRECATED | G_PARAM_READWRITE | G_PARAM_CONSTRUCT |
|
||||||
G_PARAM_STATIC_STRINGS));
|
G_PARAM_STATIC_STRINGS));
|
||||||
|
@ -354,8 +357,7 @@ gst_qt_mux_class_init (GstQTMuxClass * klass)
|
||||||
G_PARAM_READWRITE | G_PARAM_CONSTRUCT | G_PARAM_STATIC_STRINGS));
|
G_PARAM_READWRITE | G_PARAM_CONSTRUCT | G_PARAM_STATIC_STRINGS));
|
||||||
g_object_class_install_property (gobject_class, PROP_STREAMABLE,
|
g_object_class_install_property (gobject_class, PROP_STREAMABLE,
|
||||||
g_param_spec_boolean ("streamable", "Streamable", streamable_desc,
|
g_param_spec_boolean ("streamable", "Streamable", streamable_desc,
|
||||||
streamable,
|
streamable, streamable_flags | G_PARAM_STATIC_STRINGS));
|
||||||
G_PARAM_READWRITE | G_PARAM_CONSTRUCT | G_PARAM_STATIC_STRINGS));
|
|
||||||
|
|
||||||
gstelement_class->request_new_pad =
|
gstelement_class->request_new_pad =
|
||||||
GST_DEBUG_FUNCPTR (gst_qt_mux_request_new_pad);
|
GST_DEBUG_FUNCPTR (gst_qt_mux_request_new_pad);
|
||||||
|
|
|
@ -200,10 +200,13 @@ gst_level_class_init (GstLevelClass * klass)
|
||||||
*
|
*
|
||||||
* Deprecated: use the #GstLevel:post-messages property
|
* Deprecated: use the #GstLevel:post-messages property
|
||||||
*/
|
*/
|
||||||
|
#ifndef GST_REMOVE_DEPRECATED
|
||||||
g_object_class_install_property (gobject_class, PROP_MESSAGE,
|
g_object_class_install_property (gobject_class, PROP_MESSAGE,
|
||||||
g_param_spec_boolean ("message", "message",
|
g_param_spec_boolean ("message", "message",
|
||||||
"Post a 'level' message for each passed interval (deprecated)",
|
"Post a 'level' message for each passed interval "
|
||||||
TRUE, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
|
"(deprecated, use the post-messages property instead)", TRUE,
|
||||||
|
G_PARAM_READWRITE | G_PARAM_DEPRECATED | G_PARAM_STATIC_STRINGS));
|
||||||
|
#endif
|
||||||
g_object_class_install_property (gobject_class, PROP_INTERVAL,
|
g_object_class_install_property (gobject_class, PROP_INTERVAL,
|
||||||
g_param_spec_uint64 ("interval", "Interval",
|
g_param_spec_uint64 ("interval", "Interval",
|
||||||
"Interval of time between message posts (in nanoseconds)",
|
"Interval of time between message posts (in nanoseconds)",
|
||||||
|
|
|
@ -311,11 +311,13 @@ gst_multiudpsink_class_init (GstMultiUDPSinkClass * klass)
|
||||||
*
|
*
|
||||||
* Since: 1.0.2
|
* Since: 1.0.2
|
||||||
*/
|
*/
|
||||||
|
#ifndef GST_REMOVE_DEPRECATED
|
||||||
g_object_class_install_property (gobject_class, PROP_FORCE_IPV4,
|
g_object_class_install_property (gobject_class, PROP_FORCE_IPV4,
|
||||||
g_param_spec_boolean ("force-ipv4", "Force IPv4",
|
g_param_spec_boolean ("force-ipv4", "Force IPv4",
|
||||||
"Forcing the use of an IPv4 socket (DEPRECATED, has no effect anymore)",
|
"Forcing the use of an IPv4 socket (DEPRECATED, has no effect anymore)",
|
||||||
DEFAULT_FORCE_IPV4, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
|
DEFAULT_FORCE_IPV4,
|
||||||
|
G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS | G_PARAM_DEPRECATED));
|
||||||
|
#endif
|
||||||
g_object_class_install_property (G_OBJECT_CLASS (klass), PROP_QOS_DSCP,
|
g_object_class_install_property (G_OBJECT_CLASS (klass), PROP_QOS_DSCP,
|
||||||
g_param_spec_int ("qos-dscp", "QoS diff srv code point",
|
g_param_spec_int ("qos-dscp", "QoS diff srv code point",
|
||||||
"Quality of Service, differentiated services code point (-1 default)",
|
"Quality of Service, differentiated services code point (-1 default)",
|
||||||
|
|
|
@ -225,11 +225,13 @@ gst_udpsrc_class_init (GstUDPSrcClass * klass)
|
||||||
"The port to receive the packets from, 0=allocate", 0, G_MAXUINT16,
|
"The port to receive the packets from, 0=allocate", 0, G_MAXUINT16,
|
||||||
UDP_DEFAULT_PORT, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
|
UDP_DEFAULT_PORT, G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
|
||||||
/* FIXME 2.0: Remove multicast-group property */
|
/* FIXME 2.0: Remove multicast-group property */
|
||||||
|
#ifndef GST_REMOVE_DEPRECATED
|
||||||
g_object_class_install_property (gobject_class, PROP_MULTICAST_GROUP,
|
g_object_class_install_property (gobject_class, PROP_MULTICAST_GROUP,
|
||||||
g_param_spec_string ("multicast-group", "Multicast Group",
|
g_param_spec_string ("multicast-group", "Multicast Group",
|
||||||
"The Address of multicast group to join. DEPRECATED: "
|
"The Address of multicast group to join. (DEPRECATED: "
|
||||||
"Use address property instead", UDP_DEFAULT_MULTICAST_GROUP,
|
"Use address property instead)", UDP_DEFAULT_MULTICAST_GROUP,
|
||||||
G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS));
|
G_PARAM_READWRITE | G_PARAM_STATIC_STRINGS | G_PARAM_DEPRECATED));
|
||||||
|
#endif
|
||||||
g_object_class_install_property (gobject_class, PROP_MULTICAST_IFACE,
|
g_object_class_install_property (gobject_class, PROP_MULTICAST_IFACE,
|
||||||
g_param_spec_string ("multicast-iface", "Multicast Interface",
|
g_param_spec_string ("multicast-iface", "Multicast Interface",
|
||||||
"The network interface on which to join the multicast group",
|
"The network interface on which to join the multicast group",
|
||||||
|
|
Loading…
Reference in a new issue