summaryrefslogtreecommitdiff
path: root/ext/mpeg2enc
diff options
context:
space:
mode:
authorJan Schmidt <thaytan@mad.scientist.com>2005-09-05 17:20:29 +0000
committerJan Schmidt <thaytan@mad.scientist.com>2005-09-05 17:20:29 +0000
commit012dfb8b33969b582f9132ac9f95402b3098ff43 (patch)
treeacff4df23e44c9d15abab2b9877c3f72032da286 /ext/mpeg2enc
parent390621f8de27467709897c92e5fec4605d96be75 (diff)
downloadgstreamer-plugins-bad-012dfb8b33969b582f9132ac9f95402b3098ff43.tar.gz
Fix up all the state change functions.
Original commit message from CVS: Fix up all the state change functions.
Diffstat (limited to 'ext/mpeg2enc')
-rw-r--r--ext/mpeg2enc/gstmpeg2enc.cc18
1 files changed, 9 insertions, 9 deletions
diff --git a/ext/mpeg2enc/gstmpeg2enc.cc b/ext/mpeg2enc/gstmpeg2enc.cc
index 264eec2ec..d53c28f49 100644
--- a/ext/mpeg2enc/gstmpeg2enc.cc
+++ b/ext/mpeg2enc/gstmpeg2enc.cc
@@ -33,8 +33,7 @@ static void
add_fps (GstCaps * caps)
{
GstStructure *structure = gst_caps_get_structure (caps, 0);
- GValue list = { 0 }, fps =
- {
+ GValue list = { 0 }, fps = {
0};
gdouble fpss[] = { 24.0 / 1.001, 24.0, 25.0,
30.0 / 1.001, 30.0, 50.0,
@@ -105,7 +104,8 @@ static void gst_mpeg2enc_loop (GstElement * element);
static GstPadLinkReturn
gst_mpeg2enc_sink_link (GstPad * pad, const GstCaps * caps);
-static GstElementStateReturn gst_mpeg2enc_change_state (GstElement * element);
+static GstStateChangeReturn gst_mpeg2enc_change_state (GstElement * element,
+ GstStateChange transition);
static void gst_mpeg2enc_get_property (GObject * object,
guint prop_id, GValue * value, GParamSpec * pspec);
@@ -295,13 +295,13 @@ gst_mpeg2enc_set_property (GObject * object,
GST_MPEG2ENC (object)->options->setProperty (prop_id, value);
}
-static GstElementStateReturn
-gst_mpeg2enc_change_state (GstElement * element)
+static GstStateChangeReturn
+gst_mpeg2enc_change_state (GstElement * element, GstStateChange transition)
{
GstMpeg2enc *enc = GST_MPEG2ENC (element);
- switch (GST_STATE_TRANSITION (element)) {
- case GST_STATE_PAUSED_TO_READY:
+ switch (transition) {
+ case GST_STATE_CHANGE_PAUSED_TO_READY:
delete enc->encoder;
enc->encoder = NULL;
break;
@@ -310,9 +310,9 @@ gst_mpeg2enc_change_state (GstElement * element)
}
if (parent_class->change_state)
- return parent_class->change_state (element);
+ return parent_class->change_state (element, transition);
- return GST_STATE_SUCCESS;
+ return GST_STATE_CHANGE_SUCCESS;
}
static gboolean