mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-31 03:29:50 +00:00
libs: remove deprecated code
This commit is contained in:
parent
ab2c5a489c
commit
d1c3840eba
5 changed files with 0 additions and 542 deletions
|
@ -38,10 +38,6 @@ gst_dp_crc
|
|||
gst_dp_header_payload_length
|
||||
gst_dp_header_payload_type
|
||||
|
||||
gst_dp_header_from_buffer
|
||||
gst_dp_packet_from_caps
|
||||
gst_dp_packet_from_event
|
||||
|
||||
gst_dp_buffer_from_header
|
||||
gst_dp_caps_from_packet
|
||||
gst_dp_event_from_packet
|
||||
|
@ -75,12 +71,6 @@ gst_controller_set_control_source
|
|||
gst_controller_get
|
||||
gst_controller_get_value_arrays
|
||||
gst_controller_get_value_array
|
||||
gst_controller_set
|
||||
gst_controller_set_from_list
|
||||
gst_controller_unset
|
||||
gst_controller_unset_all
|
||||
gst_controller_get_all
|
||||
gst_controller_set_interpolation_mode
|
||||
<SUBSECTION Standard>
|
||||
GstControllerClass
|
||||
GstControllerPrivate
|
||||
|
|
|
@ -97,21 +97,6 @@ struct _GstControllerPrivate
|
|||
};
|
||||
|
||||
/* helper */
|
||||
#ifndef GST_REMOVE_DEPRECATED
|
||||
static void
|
||||
gst_controlled_property_add_interpolation_control_source (GstControlledProperty
|
||||
* self)
|
||||
{
|
||||
GstControlSource *csource =
|
||||
GST_CONTROL_SOURCE (gst_interpolation_control_source_new ());
|
||||
|
||||
GST_INFO
|
||||
("Adding a GstInterpolationControlSource because of backward compatibility");
|
||||
g_return_if_fail (!self->csource);
|
||||
gst_control_source_bind (GST_CONTROL_SOURCE (csource), self->pspec);
|
||||
self->csource = csource;
|
||||
}
|
||||
#endif
|
||||
|
||||
/*
|
||||
* gst_controlled_property_new:
|
||||
|
@ -972,318 +957,3 @@ gst_controller_get_type (void)
|
|||
}
|
||||
return type;
|
||||
}
|
||||
|
||||
/* FIXME: backward compatibility functions */
|
||||
|
||||
/*
|
||||
* gst_controlled_property_set_interpolation_mode:
|
||||
* @self: the controlled property object to change
|
||||
* @mode: the new interpolation mode
|
||||
*
|
||||
* Sets the given Interpolation mode for the controlled property and activates
|
||||
* the respective interpolation hooks.
|
||||
*
|
||||
* Deprecated: Use #GstControlSource, for example #GstInterpolationControlSource
|
||||
* directly.
|
||||
*
|
||||
* Returns: %TRUE for success
|
||||
*/
|
||||
#ifndef GST_REMOVE_DEPRECATED
|
||||
static gboolean
|
||||
gst_controlled_property_set_interpolation_mode (GstControlledProperty * self,
|
||||
GstInterpolateMode mode)
|
||||
{
|
||||
GstInterpolationControlSource *icsource;
|
||||
|
||||
/* FIXME: backward compat, add GstInterpolationControlSource */
|
||||
if (!self->csource)
|
||||
gst_controlled_property_add_interpolation_control_source (self);
|
||||
|
||||
g_return_val_if_fail (GST_IS_INTERPOLATION_CONTROL_SOURCE (self->csource),
|
||||
FALSE);
|
||||
|
||||
icsource = GST_INTERPOLATION_CONTROL_SOURCE (self->csource);
|
||||
|
||||
return gst_interpolation_control_source_set_interpolation_mode (icsource,
|
||||
mode);
|
||||
}
|
||||
#endif
|
||||
|
||||
/**
|
||||
* gst_controller_set:
|
||||
* @self: the controller object which handles the properties
|
||||
* @property_name: the name of the property to set
|
||||
* @timestamp: the time the control-change is schedules for
|
||||
* @value: the control-value
|
||||
*
|
||||
* Set the value of given controller-handled property at a certain time.
|
||||
*
|
||||
* Deprecated: Use #GstControlSource, for example #GstInterpolationControlSource
|
||||
* directly.
|
||||
*
|
||||
* Returns: FALSE if the values couldn't be set (ex : properties not handled by controller), TRUE otherwise
|
||||
*/
|
||||
#ifndef GST_REMOVE_DEPRECATED
|
||||
#ifdef GST_DISABLE_DEPRECATED
|
||||
gboolean
|
||||
gst_controller_set (GstController * self, const gchar * property_name,
|
||||
GstClockTime timestamp, GValue * value);
|
||||
#endif
|
||||
gboolean
|
||||
gst_controller_set (GstController * self, const gchar * property_name,
|
||||
GstClockTime timestamp, GValue * value)
|
||||
{
|
||||
gboolean res = FALSE;
|
||||
GstControlledProperty *prop;
|
||||
|
||||
g_return_val_if_fail (GST_IS_CONTROLLER (self), FALSE);
|
||||
g_return_val_if_fail (property_name, FALSE);
|
||||
|
||||
g_mutex_lock (self->lock);
|
||||
if ((prop = gst_controller_find_controlled_property (self, property_name))) {
|
||||
/* FIXME: backward compat, add GstInterpolationControlSource */
|
||||
if (!prop->csource)
|
||||
gst_controlled_property_add_interpolation_control_source (prop);
|
||||
|
||||
if (!GST_IS_INTERPOLATION_CONTROL_SOURCE (prop->csource))
|
||||
goto out;
|
||||
res =
|
||||
gst_interpolation_control_source_set (GST_INTERPOLATION_CONTROL_SOURCE
|
||||
(prop->csource), timestamp, value);
|
||||
}
|
||||
|
||||
out:
|
||||
g_mutex_unlock (self->lock);
|
||||
|
||||
return res;
|
||||
}
|
||||
#endif
|
||||
|
||||
/**
|
||||
* gst_controller_set_from_list:
|
||||
* @self: the controller object which handles the properties
|
||||
* @property_name: the name of the property to set
|
||||
* @timedvalues: a list with #GstTimedValue items
|
||||
*
|
||||
* Sets multiple timed values at once.
|
||||
*
|
||||
* Deprecated: Use #GstControlSource, for example #GstInterpolationControlSource
|
||||
* directly.
|
||||
*
|
||||
* Returns: %FALSE if the values couldn't be set (ex : properties not handled by controller), %TRUE otherwise
|
||||
*/
|
||||
#ifndef GST_REMOVE_DEPRECATED
|
||||
#ifdef GST_DISABLE_DEPRECATED
|
||||
gboolean
|
||||
gst_controller_set_from_list (GstController * self, const gchar * property_name,
|
||||
GSList * timedvalues);
|
||||
#endif
|
||||
gboolean
|
||||
gst_controller_set_from_list (GstController * self, const gchar * property_name,
|
||||
GSList * timedvalues)
|
||||
{
|
||||
gboolean res = FALSE;
|
||||
GstControlledProperty *prop;
|
||||
|
||||
g_return_val_if_fail (GST_IS_CONTROLLER (self), FALSE);
|
||||
g_return_val_if_fail (property_name, FALSE);
|
||||
|
||||
g_mutex_lock (self->lock);
|
||||
if ((prop = gst_controller_find_controlled_property (self, property_name))) {
|
||||
/* FIXME: backward compat, add GstInterpolationControlSource */
|
||||
if (!prop->csource)
|
||||
gst_controlled_property_add_interpolation_control_source (prop);
|
||||
|
||||
if (!GST_IS_INTERPOLATION_CONTROL_SOURCE (prop->csource))
|
||||
goto out;
|
||||
|
||||
res =
|
||||
gst_interpolation_control_source_set_from_list
|
||||
(GST_INTERPOLATION_CONTROL_SOURCE (prop->csource), timedvalues);
|
||||
}
|
||||
|
||||
out:
|
||||
g_mutex_unlock (self->lock);
|
||||
|
||||
return res;
|
||||
}
|
||||
#endif
|
||||
|
||||
/**
|
||||
* gst_controller_unset:
|
||||
* @self: the controller object which handles the properties
|
||||
* @property_name: the name of the property to unset
|
||||
* @timestamp: the time the control-change should be removed from
|
||||
*
|
||||
* Used to remove the value of given controller-handled property at a certain
|
||||
* time.
|
||||
*
|
||||
* Deprecated: Use #GstControlSource, for example #GstInterpolationControlSource
|
||||
* directly.
|
||||
*
|
||||
* Returns: %FALSE if the values couldn't be unset (ex : properties not handled by controller), %TRUE otherwise
|
||||
*/
|
||||
#ifndef GST_REMOVE_DEPRECATED
|
||||
#ifdef GST_DISABLE_DEPRECATED
|
||||
gboolean
|
||||
gst_controller_unset (GstController * self, const gchar * property_name,
|
||||
GstClockTime timestamp);
|
||||
#endif
|
||||
gboolean
|
||||
gst_controller_unset (GstController * self, const gchar * property_name,
|
||||
GstClockTime timestamp)
|
||||
{
|
||||
gboolean res = FALSE;
|
||||
GstControlledProperty *prop;
|
||||
|
||||
g_return_val_if_fail (GST_IS_CONTROLLER (self), FALSE);
|
||||
g_return_val_if_fail (property_name, FALSE);
|
||||
g_return_val_if_fail (GST_CLOCK_TIME_IS_VALID (timestamp), FALSE);
|
||||
|
||||
g_mutex_lock (self->lock);
|
||||
if ((prop = gst_controller_find_controlled_property (self, property_name))) {
|
||||
if (!prop->csource || !GST_IS_INTERPOLATION_CONTROL_SOURCE (prop->csource))
|
||||
goto out;
|
||||
|
||||
res =
|
||||
gst_interpolation_control_source_unset (GST_INTERPOLATION_CONTROL_SOURCE
|
||||
(prop->csource), timestamp);
|
||||
}
|
||||
|
||||
out:
|
||||
g_mutex_unlock (self->lock);
|
||||
|
||||
return res;
|
||||
}
|
||||
#endif
|
||||
|
||||
/**
|
||||
* gst_controller_unset_all:
|
||||
* @self: the controller object which handles the properties
|
||||
* @property_name: the name of the property to unset
|
||||
*
|
||||
* Used to remove all time-stamped values of given controller-handled property
|
||||
*
|
||||
* Deprecated: Use #GstControlSource, for example #GstInterpolationControlSource
|
||||
* directly.
|
||||
*
|
||||
* Returns: %FALSE if the values couldn't be unset (ex : properties not handled
|
||||
* by controller), %TRUE otherwise
|
||||
* Since: 0.10.5
|
||||
*/
|
||||
#ifndef GST_REMOVE_DEPRECATED
|
||||
#ifdef GST_DISABLE_DEPRECATED
|
||||
gboolean gst_controller_unset_all (GstController * self,
|
||||
const gchar * property_name);
|
||||
#endif
|
||||
gboolean
|
||||
gst_controller_unset_all (GstController * self, const gchar * property_name)
|
||||
{
|
||||
GstControlledProperty *prop;
|
||||
|
||||
g_return_val_if_fail (GST_IS_CONTROLLER (self), FALSE);
|
||||
g_return_val_if_fail (property_name, FALSE);
|
||||
|
||||
g_mutex_lock (self->lock);
|
||||
if ((prop = gst_controller_find_controlled_property (self, property_name))) {
|
||||
if (!prop->csource || !GST_IS_INTERPOLATION_CONTROL_SOURCE (prop->csource))
|
||||
goto out;
|
||||
|
||||
gst_interpolation_control_source_unset_all (GST_INTERPOLATION_CONTROL_SOURCE
|
||||
(prop->csource));
|
||||
}
|
||||
|
||||
out:
|
||||
g_mutex_unlock (self->lock);
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
#endif
|
||||
|
||||
/**
|
||||
* gst_controller_get_all:
|
||||
* @self: the controller to get the list from
|
||||
* @property_name: the name of the property to get the list for
|
||||
*
|
||||
* Returns a read-only copy of the list of #GstTimedValue for the given property.
|
||||
* Free the list after done with it.
|
||||
*
|
||||
* <note><para>This doesn't modify the controlled GObject property!</para></note>
|
||||
*
|
||||
* Deprecated: Use #GstControlSource, for example #GstInterpolationControlSource
|
||||
* directly.
|
||||
*
|
||||
* Returns: a copy of the list, or %NULL if the property isn't handled by the controller
|
||||
*/
|
||||
#ifndef GST_REMOVE_DEPRECATED
|
||||
#ifdef GST_DISABLE_DEPRECATED
|
||||
const GList *gst_controller_get_all (GstController * self,
|
||||
const gchar * property_name);
|
||||
#endif
|
||||
const GList *
|
||||
gst_controller_get_all (GstController * self, const gchar * property_name)
|
||||
{
|
||||
const GList *res = NULL;
|
||||
GstControlledProperty *prop;
|
||||
|
||||
g_return_val_if_fail (GST_IS_CONTROLLER (self), NULL);
|
||||
g_return_val_if_fail (property_name, NULL);
|
||||
|
||||
g_mutex_lock (self->lock);
|
||||
if ((prop = gst_controller_find_controlled_property (self, property_name))) {
|
||||
if (!prop->csource || !GST_IS_INTERPOLATION_CONTROL_SOURCE (prop->csource))
|
||||
goto out;
|
||||
|
||||
res =
|
||||
gst_interpolation_control_source_get_all
|
||||
(GST_INTERPOLATION_CONTROL_SOURCE (prop->csource));
|
||||
}
|
||||
|
||||
out:
|
||||
g_mutex_unlock (self->lock);
|
||||
|
||||
return res;
|
||||
}
|
||||
#endif
|
||||
|
||||
/**
|
||||
* gst_controller_set_interpolation_mode:
|
||||
* @self: the controller object
|
||||
* @property_name: the name of the property for which to change the interpolation
|
||||
* @mode: interpolation mode
|
||||
*
|
||||
* Sets the given interpolation mode on the given property.
|
||||
*
|
||||
* <note><para>User interpolation is not yet available and quadratic interpolation
|
||||
* is deprecated and maps to cubic interpolation.</para></note>
|
||||
*
|
||||
* Deprecated: Use #GstControlSource, for example #GstInterpolationControlSource
|
||||
* directly.
|
||||
*
|
||||
* Returns: %TRUE if the property is handled by the controller, %FALSE otherwise
|
||||
*/
|
||||
#ifndef GST_REMOVE_DEPRECATED
|
||||
#ifdef GST_DISABLE_DEPRECATED
|
||||
gboolean
|
||||
gst_controller_set_interpolation_mode (GstController * self,
|
||||
const gchar * property_name, GstInterpolateMode mode);
|
||||
#endif
|
||||
gboolean
|
||||
gst_controller_set_interpolation_mode (GstController * self,
|
||||
const gchar * property_name, GstInterpolateMode mode)
|
||||
{
|
||||
gboolean res = FALSE;
|
||||
GstControlledProperty *prop;
|
||||
|
||||
g_return_val_if_fail (GST_IS_CONTROLLER (self), FALSE);
|
||||
g_return_val_if_fail (property_name, FALSE);
|
||||
|
||||
g_mutex_lock (self->lock);
|
||||
if ((prop = gst_controller_find_controlled_property (self, property_name))) {
|
||||
res = gst_controlled_property_set_interpolation_mode (prop, mode);
|
||||
}
|
||||
g_mutex_unlock (self->lock);
|
||||
|
||||
return res;
|
||||
}
|
||||
#endif
|
||||
|
|
|
@ -132,24 +132,6 @@ void gst_object_set_control_rate (GObject * object, GstClockTime control_rate);
|
|||
gboolean gst_controller_init (int * argc, char ***argv);
|
||||
|
||||
|
||||
/* FIXME: deprecated functions */
|
||||
#ifndef GST_DISABLE_DEPRECATED
|
||||
gboolean gst_controller_set (GstController * self, const gchar * property_name,
|
||||
GstClockTime timestamp, GValue * value);
|
||||
gboolean gst_controller_set_from_list (GstController * self,
|
||||
const gchar * property_name, GSList * timedvalues);
|
||||
|
||||
gboolean gst_controller_unset (GstController * self, const gchar * property_name,
|
||||
GstClockTime timestamp);
|
||||
gboolean gst_controller_unset_all (GstController * self, const gchar * property_name);
|
||||
|
||||
const GList *gst_controller_get_all (GstController * self,
|
||||
const gchar * property_name);
|
||||
|
||||
gboolean gst_controller_set_interpolation_mode (GstController * self,
|
||||
const gchar * property_name, GstInterpolateMode mode);
|
||||
#endif /* GST_DISABLE_DEPRECATED */
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* __GST_CONTROLLER_H__ */
|
||||
|
|
|
@ -365,34 +365,6 @@ gst_dp_header_payload_type (const guint8 * header)
|
|||
|
||||
/*** PACKETIZER FUNCTIONS ***/
|
||||
|
||||
/**
|
||||
* gst_dp_header_from_buffer:
|
||||
* @buffer: a #GstBuffer to create a header for
|
||||
* @flags: the #GstDPHeaderFlag to create the header with
|
||||
* @length: a guint pointer to store the header length in
|
||||
* @header: a guint8 * pointer to store a newly allocated header byte array in
|
||||
*
|
||||
* Creates a GDP header from the given buffer.
|
||||
*
|
||||
* Deprecated: use a #GstDPPacketizer
|
||||
*
|
||||
* Returns: %TRUE if the header was successfully created.
|
||||
*/
|
||||
#ifndef GST_REMOVE_DEPRECATED
|
||||
#ifdef GST_DISABLE_DEPRECATED
|
||||
gboolean
|
||||
gst_dp_header_from_buffer (const GstBuffer * buffer, GstDPHeaderFlag flags,
|
||||
guint * length, guint8 ** header);
|
||||
#endif
|
||||
gboolean
|
||||
gst_dp_header_from_buffer (const GstBuffer * buffer, GstDPHeaderFlag flags,
|
||||
guint * length, guint8 ** header)
|
||||
{
|
||||
return gst_dp_header_from_buffer_any (buffer, flags, length, header,
|
||||
GST_DP_VERSION_0_2);
|
||||
}
|
||||
#endif
|
||||
|
||||
static gboolean
|
||||
gst_dp_header_from_buffer_1_0 (const GstBuffer * buffer, GstDPHeaderFlag flags,
|
||||
guint * length, guint8 ** header)
|
||||
|
@ -401,35 +373,6 @@ gst_dp_header_from_buffer_1_0 (const GstBuffer * buffer, GstDPHeaderFlag flags,
|
|||
GST_DP_VERSION_1_0);
|
||||
}
|
||||
|
||||
/**
|
||||
* gst_dp_packet_from_caps:
|
||||
* @caps: a #GstCaps to create a packet for
|
||||
* @flags: the #GstDPHeaderFlag to create the header with
|
||||
* @length: a guint pointer to store the header length in
|
||||
* @header: a guint8 pointer to store a newly allocated header byte array in
|
||||
* @payload: a guint8 pointer to store a newly allocated payload byte array in
|
||||
*
|
||||
* Creates a GDP packet from the given caps.
|
||||
*
|
||||
* Deprecated: use a #GstDPPacketizer
|
||||
*
|
||||
* Returns: %TRUE if the packet was successfully created.
|
||||
*/
|
||||
#ifndef GST_REMOVE_DEPRECATED
|
||||
#ifdef GST_DISABLE_DEPRECATED
|
||||
gboolean
|
||||
gst_dp_packet_from_caps (const GstCaps * caps, GstDPHeaderFlag flags,
|
||||
guint * length, guint8 ** header, guint8 ** payload);
|
||||
#endif
|
||||
gboolean
|
||||
gst_dp_packet_from_caps (const GstCaps * caps, GstDPHeaderFlag flags,
|
||||
guint * length, guint8 ** header, guint8 ** payload)
|
||||
{
|
||||
return gst_dp_packet_from_caps_any (caps, flags, length, header, payload,
|
||||
GST_DP_VERSION_0_2);
|
||||
}
|
||||
#endif
|
||||
|
||||
static gboolean
|
||||
gst_dp_packet_from_caps_1_0 (const GstCaps * caps, GstDPHeaderFlag flags,
|
||||
guint * length, guint8 ** header, guint8 ** payload)
|
||||
|
@ -438,105 +381,6 @@ gst_dp_packet_from_caps_1_0 (const GstCaps * caps, GstDPHeaderFlag flags,
|
|||
GST_DP_VERSION_1_0);
|
||||
}
|
||||
|
||||
/**
|
||||
* gst_dp_packet_from_event:
|
||||
* @event: a #GstEvent to create a packet for
|
||||
* @flags: the #GstDPHeaderFlag to create the header with
|
||||
* @length: a guint pointer to store the header length in
|
||||
* @header: a guint8 pointer to store a newly allocated header byte array in
|
||||
* @payload: a guint8 pointer to store a newly allocated payload byte array in
|
||||
*
|
||||
* Creates a GDP packet from the given event.
|
||||
*
|
||||
* Deprecated: use a #GstDPPacketizer
|
||||
*
|
||||
* Returns: %TRUE if the packet was successfully created.
|
||||
*/
|
||||
#ifndef GST_REMOVE_DEPRECATED
|
||||
#ifdef GST_DISABLE_DEPRECATED
|
||||
gboolean
|
||||
gst_dp_packet_from_event (const GstEvent * event, GstDPHeaderFlag flags,
|
||||
guint * length, guint8 ** header, guint8 ** payload);
|
||||
#endif
|
||||
gboolean
|
||||
gst_dp_packet_from_event (const GstEvent * event, GstDPHeaderFlag flags,
|
||||
guint * length, guint8 ** header, guint8 ** payload)
|
||||
{
|
||||
guint8 *h;
|
||||
guint pl_length; /* length of payload */
|
||||
|
||||
g_return_val_if_fail (GST_IS_EVENT (event), FALSE);
|
||||
g_return_val_if_fail (length, FALSE);
|
||||
g_return_val_if_fail (header, FALSE);
|
||||
g_return_val_if_fail (payload, FALSE);
|
||||
|
||||
/* first construct payload, since we need the length */
|
||||
switch (GST_EVENT_TYPE (event)) {
|
||||
case GST_EVENT_UNKNOWN:
|
||||
GST_WARNING ("Unknown event, ignoring");
|
||||
return FALSE;
|
||||
case GST_EVENT_EOS:
|
||||
case GST_EVENT_FLUSH_START:
|
||||
case GST_EVENT_FLUSH_STOP:
|
||||
case GST_EVENT_NEWSEGMENT:
|
||||
pl_length = 0;
|
||||
*payload = NULL;
|
||||
break;
|
||||
case GST_EVENT_SEEK:
|
||||
{
|
||||
gdouble rate;
|
||||
GstFormat format;
|
||||
GstSeekFlags flags;
|
||||
GstSeekType cur_type, stop_type;
|
||||
gint64 cur, stop;
|
||||
|
||||
gst_event_parse_seek ((GstEvent *) event, &rate, &format, &flags,
|
||||
&cur_type, &cur, &stop_type, &stop);
|
||||
|
||||
pl_length = 4 + 4 + 4 + 8 + 4 + 8;
|
||||
*payload = g_malloc0 (pl_length);
|
||||
/* FIXME write rate */
|
||||
GST_WRITE_UINT32_BE (*payload, (guint32) format);
|
||||
GST_WRITE_UINT32_BE (*payload + 4, (guint32) flags);
|
||||
GST_WRITE_UINT32_BE (*payload + 8, (guint32) cur_type);
|
||||
GST_WRITE_UINT64_BE (*payload + 12, (guint64) cur);
|
||||
GST_WRITE_UINT32_BE (*payload + 20, (guint32) stop_type);
|
||||
GST_WRITE_UINT64_BE (*payload + 24, (guint64) stop);
|
||||
break;
|
||||
}
|
||||
case GST_EVENT_QOS:
|
||||
case GST_EVENT_NAVIGATION:
|
||||
case GST_EVENT_TAG:
|
||||
GST_WARNING ("Unhandled event type %d, ignoring", GST_EVENT_TYPE (event));
|
||||
return FALSE;
|
||||
default:
|
||||
GST_WARNING ("Unknown event type %d, ignoring", GST_EVENT_TYPE (event));
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
/* now we can create and fill the header */
|
||||
h = g_malloc0 (GST_DP_HEADER_LENGTH);
|
||||
*length = GST_DP_HEADER_LENGTH;
|
||||
|
||||
/* version, flags, type */
|
||||
GST_DP_INIT_HEADER (h, GST_DP_VERSION_0_2, flags,
|
||||
GST_DP_PAYLOAD_EVENT_NONE + GST_EVENT_TYPE (event));
|
||||
|
||||
/* length */
|
||||
GST_WRITE_UINT32_BE (h + 6, (guint32) pl_length);
|
||||
/* timestamp */
|
||||
GST_WRITE_UINT64_BE (h + 10, GST_EVENT_TIMESTAMP (event));
|
||||
|
||||
GST_DP_SET_CRC (h, flags, *payload, pl_length);
|
||||
|
||||
GST_LOG ("created header from event:");
|
||||
gst_dp_dump_byte_array (h, GST_DP_HEADER_LENGTH);
|
||||
|
||||
*header = h;
|
||||
return TRUE;
|
||||
}
|
||||
#endif
|
||||
|
||||
static gboolean
|
||||
gst_dp_packet_from_event_1_0 (const GstEvent * event, GstDPHeaderFlag flags,
|
||||
guint * length, guint8 ** header, guint8 ** payload)
|
||||
|
@ -888,13 +732,6 @@ gst_dp_packetizer_new (GstDPVersion version)
|
|||
ret->version = version;
|
||||
|
||||
switch (version) {
|
||||
#ifndef GST_REMOVE_DEPRECATED
|
||||
case GST_DP_VERSION_0_2:
|
||||
ret->header_from_buffer = gst_dp_header_from_buffer;
|
||||
ret->packet_from_caps = gst_dp_packet_from_caps;
|
||||
ret->packet_from_event = gst_dp_packet_from_event;
|
||||
break;
|
||||
#endif
|
||||
case GST_DP_VERSION_1_0:
|
||||
ret->header_from_buffer = gst_dp_header_from_buffer_1_0;
|
||||
ret->packet_from_caps = gst_dp_packet_from_caps_1_0;
|
||||
|
|
|
@ -139,27 +139,6 @@ guint32 gst_dp_header_payload_length (const guint8 * header);
|
|||
GstDPPayloadType
|
||||
gst_dp_header_payload_type (const guint8 * header);
|
||||
|
||||
/* converting from GstBuffer/GstEvent/GstCaps */
|
||||
#ifndef GST_DISABLE_DEPRECATED
|
||||
gboolean gst_dp_header_from_buffer (const GstBuffer * buffer,
|
||||
GstDPHeaderFlag flags,
|
||||
guint * length,
|
||||
guint8 ** header);
|
||||
#endif
|
||||
#ifndef GST_DISABLE_DEPRECATED
|
||||
gboolean gst_dp_packet_from_caps (const GstCaps * caps,
|
||||
GstDPHeaderFlag flags,
|
||||
guint * length,
|
||||
guint8 ** header,
|
||||
guint8 ** payload);
|
||||
#endif
|
||||
#ifndef GST_DISABLE_DEPRECATED
|
||||
gboolean gst_dp_packet_from_event (const GstEvent * event,
|
||||
GstDPHeaderFlag flags,
|
||||
guint * length,
|
||||
guint8 ** header,
|
||||
guint8 ** payload);
|
||||
#endif
|
||||
/* converting to GstBuffer/GstEvent/GstCaps */
|
||||
GstBuffer * gst_dp_buffer_from_header (guint header_length,
|
||||
const guint8 * header);
|
||||
|
|
Loading…
Reference in a new issue