]> git.0d.be Git - empathy.git/commitdiff
Use framerate range instead of fix range
authorNicolas Dufresne <nicolas.dufresne@collabora.com>
Mon, 11 Jul 2011 23:45:46 +0000 (19:45 -0400)
committerSjoerd Simons <sjoerd.simons@collabora.co.uk>
Mon, 7 Nov 2011 20:07:19 +0000 (20:07 +0000)
Using framerate range reduce the chance that changing the framerate breaks
the pipline. We also always set an initial range to support src like
videotestsrc that does not allow changing framerate dynamically and would
default to a "as fast as possible" mode.

src/empathy-video-src.c

index 1e362547ad95db6b459162d33110555852ca6a6b..12d77d8f9775976b784730dc4dde93fcccccded5 100644 (file)
@@ -143,12 +143,10 @@ empathy_video_src_init (EmpathyGstVideoSrc *obj)
       g_message ("Couldn't add \"videomaxrate\" (gst-plugins-bad missing?)");
       element = element_back;
     }
-  else
-    {
-      gst_caps_set_simple (caps,
-        "framerate", GST_TYPE_FRACTION, 15, 1,
-        NULL);
-    }
+
+  gst_caps_set_simple (caps,
+      "framerate", GST_TYPE_FRACTION_RANGE, 1, 1, 30, 1,
+      NULL);
 
   str = gst_caps_to_string (caps);
   DEBUG ("Current video src caps are : %s", str);