summaryrefslogtreecommitdiff
path: root/gst/rawparse/gstrawbaseparse.c
diff options
context:
space:
mode:
Diffstat (limited to 'gst/rawparse/gstrawbaseparse.c')
-rw-r--r--gst/rawparse/gstrawbaseparse.c31
1 files changed, 0 insertions, 31 deletions
diff --git a/gst/rawparse/gstrawbaseparse.c b/gst/rawparse/gstrawbaseparse.c
index 5fb8e73c8..f5bb202e6 100644
--- a/gst/rawparse/gstrawbaseparse.c
+++ b/gst/rawparse/gstrawbaseparse.c
@@ -109,29 +109,24 @@
#include <string.h>
#include "gstrawbaseparse.h"
-
GST_DEBUG_CATEGORY_STATIC (raw_base_parse_debug);
#define GST_CAT_DEFAULT raw_base_parse_debug
-
enum
{
PROP_0,
PROP_USE_SINK_CAPS
};
-
#define DEFAULT_USE_SINK_CAPS FALSE
#define INITIAL_PARSER_CONFIG \
((DEFAULT_USE_SINK_CAPS) ? GST_RAW_BASE_PARSE_CONFIG_SINKCAPS : \
GST_RAW_BASE_PARSE_CONFIG_PROPERTIES)
-
#define gst_raw_base_parse_parent_class parent_class
G_DEFINE_ABSTRACT_TYPE (GstRawBaseParse, gst_raw_base_parse,
GST_TYPE_BASE_PARSE);
-
static void gst_raw_base_parse_finalize (GObject * object);
static void gst_raw_base_parse_set_property (GObject * object, guint prop_id,
GValue const *value, GParamSpec * pspec);
@@ -152,8 +147,6 @@ static gboolean gst_raw_base_parse_is_using_sink_caps (GstRawBaseParse *
static gboolean gst_raw_base_parse_is_gstformat_supported (GstRawBaseParse *
raw_base_parse, GstFormat format);
-
-
static void
gst_raw_base_parse_class_init (GstRawBaseParseClass * klass)
{
@@ -196,7 +189,6 @@ gst_raw_base_parse_class_init (GstRawBaseParseClass * klass)
);
}
-
static void
gst_raw_base_parse_init (GstRawBaseParse * raw_base_parse)
{
@@ -204,7 +196,6 @@ gst_raw_base_parse_init (GstRawBaseParse * raw_base_parse)
g_mutex_init (&(raw_base_parse->config_mutex));
}
-
static void
gst_raw_base_parse_finalize (GObject * object)
{
@@ -215,7 +206,6 @@ gst_raw_base_parse_finalize (GObject * object)
G_OBJECT_CLASS (parent_class)->finalize (object);
}
-
static void
gst_raw_base_parse_set_property (GObject * object, guint prop_id,
GValue const *value, GParamSpec * pspec)
@@ -291,7 +281,6 @@ gst_raw_base_parse_set_property (GObject * object, guint prop_id,
}
}
-
static void
gst_raw_base_parse_get_property (GObject * object, guint prop_id,
GValue * value, GParamSpec * pspec)
@@ -312,7 +301,6 @@ gst_raw_base_parse_get_property (GObject * object, guint prop_id,
}
}
-
static gboolean
gst_raw_base_parse_start (GstBaseParse * parse)
{
@@ -338,7 +326,6 @@ gst_raw_base_parse_start (GstBaseParse * parse)
return TRUE;
}
-
static gboolean
gst_raw_base_parse_stop (GstBaseParse * parse)
{
@@ -351,7 +338,6 @@ gst_raw_base_parse_stop (GstBaseParse * parse)
return TRUE;
}
-
static gboolean
gst_raw_base_parse_set_sink_caps (GstBaseParse * parse, GstCaps * caps)
{
@@ -363,7 +349,6 @@ gst_raw_base_parse_set_sink_caps (GstBaseParse * parse, GstCaps * caps)
g_assert (klass->get_caps_from_config);
g_assert (klass->get_config_frame_size);
-
GST_RAW_BASE_PARSE_CONFIG_MUTEX_LOCK (raw_base_parse);
GST_DEBUG_OBJECT (parse, "getting config from new sink caps");
@@ -488,18 +473,15 @@ gst_raw_base_parse_handle_frame (GstBaseParse * parse,
g_assert (klass->get_config_frame_size);
g_assert (klass->get_units_per_second);
-
/* We never skip any bytes this way. Instead, subclass takes care
* of skipping any overhead (necessary, since the way it needs to
* be skipped is completely subclass specific). */
*skipsize = 0;
-
/* The operations below access the current config. Protect
* against race conditions by using the object lock. */
GST_RAW_BASE_PARSE_CONFIG_MUTEX_LOCK (raw_base_parse);
-
/* If the source pad caps haven't been set yet, or need to be
* set again, do so now, BEFORE any buffers are pushed out */
if (G_UNLIKELY (!raw_base_parse->src_caps_set)) {
@@ -544,7 +526,6 @@ gst_raw_base_parse_handle_frame (GstBaseParse * parse,
klass->get_config_frame_size (raw_base_parse,
GST_RAW_BASE_PARSE_CONFIG_CURRENT);
-
in_size = gst_buffer_get_size (frame->buffer);
/* gst_base_parse_set_min_frame_size() is called when the current
@@ -636,7 +617,6 @@ gst_raw_base_parse_handle_frame (GstBaseParse * parse,
* operations, so the lock can be released */
GST_RAW_BASE_PARSE_CONFIG_MUTEX_UNLOCK (raw_base_parse);
-
/* If any new caps have to be pushed downstrean, do so
* *before* the frame is finished */
if (G_UNLIKELY (new_caps_event != NULL)) {
@@ -650,7 +630,6 @@ gst_raw_base_parse_handle_frame (GstBaseParse * parse,
return flow_ret;
-
config_not_ready:
GST_RAW_BASE_PARSE_CONFIG_MUTEX_UNLOCK (raw_base_parse);
GST_ELEMENT_ERROR (parse, STREAM, FORMAT,
@@ -676,7 +655,6 @@ error_end:
return flow_ret;
}
-
static gboolean
gst_raw_base_parse_convert (GstBaseParse * parse, GstFormat src_format,
gint64 src_value, GstFormat dest_format, gint64 * dest_value)
@@ -689,12 +667,10 @@ gst_raw_base_parse_convert (GstBaseParse * parse, GstFormat src_format,
g_assert (klass->is_config_ready);
g_assert (klass->get_units_per_second);
-
/* The operations below access the current config. Protect
* against race conditions by using the object lock. */
GST_RAW_BASE_PARSE_CONFIG_MUTEX_LOCK (raw_base_parse);
-
if (!klass->is_config_ready (raw_base_parse,
GST_RAW_BASE_PARSE_CONFIG_CURRENT)) {
if (gst_raw_base_parse_is_using_sink_caps (raw_base_parse)) {
@@ -746,7 +722,6 @@ gst_raw_base_parse_convert (GstBaseParse * parse, GstFormat src_format,
GST_RAW_BASE_PARSE_CONFIG_MUTEX_UNLOCK (raw_base_parse);
return ret;
-
config_not_ready:
GST_RAW_BASE_PARSE_CONFIG_MUTEX_UNLOCK (raw_base_parse);
GST_ELEMENT_ERROR (parse, STREAM, FORMAT,
@@ -755,7 +730,6 @@ config_not_ready:
return FALSE;
}
-
static gboolean
gst_raw_base_parse_is_using_sink_caps (GstRawBaseParse * raw_base_parse)
{
@@ -766,7 +740,6 @@ gst_raw_base_parse_is_using_sink_caps (GstRawBaseParse * raw_base_parse)
GST_RAW_BASE_PARSE_CONFIG_SINKCAPS;
}
-
static gboolean
gst_raw_base_parse_is_gstformat_supported (GstRawBaseParse * raw_base_parse,
GstFormat format)
@@ -777,10 +750,6 @@ gst_raw_base_parse_is_gstformat_supported (GstRawBaseParse * raw_base_parse,
return klass->is_unit_format_supported (raw_base_parse, format);
}
-
-
-
-
/**
* gst_raw_base_parse_invalidate_src_caps:
* @raw_base_parse: a #GstRawBaseParse instance