controller: port to new interpolation-mode api
authorStefan Sauer <ensonic@users.sf.net>
Mon, 19 Dec 2011 22:41:25 +0000 (23:41 +0100)
committerStefan Sauer <ensonic@users.sf.net>
Mon, 19 Dec 2011 22:41:25 +0000 (23:41 +0100)
tests/check/elements/volume.c
tests/icles/audio-trickplay.c

index 77996d6..aac28ab 100644 (file)
@@ -1723,8 +1723,7 @@ GST_START_TEST (test_controller_usability)
 
   /* this shouldn't crash, whether this mode is implemented or not */
   csource = gst_interpolation_control_source_new ();
-  gst_interpolation_control_source_set_interpolation_mode (csource,
-      GST_INTERPOLATE_CUBIC);
+  g_object_set (csource, "mode", GST_INTERPOLATION_MODE_CUBIC, NULL);
   gst_controller_set_control_source (c, "volume", GST_CONTROL_SOURCE (csource));
 
   g_value_init (&value, G_TYPE_DOUBLE);
@@ -1765,8 +1764,7 @@ GST_START_TEST (test_controller_processing)
   fail_unless (GST_IS_CONTROLLER (c));
 
   csource = gst_interpolation_control_source_new ();
-  gst_interpolation_control_source_set_interpolation_mode (csource,
-      GST_INTERPOLATE_CUBIC);
+  g_object_set (csource, "mode", GST_INTERPOLATION_MODE_CUBIC, NULL);
   gst_controller_set_control_source (c, "volume", GST_CONTROL_SOURCE (csource));
   g_object_unref (csource);
 
index 133fe3d..9626cf2 100644 (file)
@@ -134,10 +134,8 @@ main (gint argc, gchar ** argv)
 
   /* Set interpolation mode */
 
-  gst_interpolation_control_source_set_interpolation_mode (csource1,
-      GST_INTERPOLATE_LINEAR);
-  gst_interpolation_control_source_set_interpolation_mode (csource2,
-      GST_INTERPOLATE_LINEAR);
+  g_object_set (csource1, "mode", GST_INTERPOLATION_MODE_LINEAR, NULL);
+  g_object_set (csource2, "mode", GST_INTERPOLATION_MODE_LINEAR, NULL);
 
   /* set control values */
   g_value_init (&vol, G_TYPE_DOUBLE);