[cheese] Initial switch from theora/ogg to vp8/webm



commit b326fe35de561935213509d9bdce1a04756d77cb
Author: Oleksij Rempel (Alexey Fisher) <bug-track fisher-privat net>
Date:   Thu Dec 22 15:53:27 2011 +0100

    Initial switch from theora/ogg to vp8/webm
    
    It is time to go webm :)
    
    Fixes bug 564957 and 666718.
    
    Signed-off-by: Oleksij Rempel (Alexey Fisher) <bug-track fisher-privat net>

 TODO                        |    1 -
 libcheese/cheese-camera.c   |   13 +++++--------
 libcheese/cheese-fileutil.h |    2 +-
 3 files changed, 6 insertions(+), 10 deletions(-)
---
diff --git a/TODO b/TODO
index 610bd5d..f3385a3 100644
--- a/TODO
+++ b/TODO
@@ -4,7 +4,6 @@ TODO
   changing effects, loading webcam, starting recording video
 * Drop MX table layout
   * Add a 1px white border around previews
-* Improve video recording, see bug #564957
 * Upload videos to Youtube, bug #522210
 * Use a GStreamer pipeline to encode images, bug #628226
   * Save EXIF data to photos, bug #583650
diff --git a/libcheese/cheese-camera.c b/libcheese/cheese-camera.c
index 42d22c8..0eb058c 100644
--- a/libcheese/cheese-camera.c
+++ b/libcheese/cheese-camera.c
@@ -470,23 +470,20 @@ cheese_camera_set_video_recording (CheeseCamera *camera, GError **error)
   GstElement          *video_enc;
   GstElement          *mux;
 
-  if ((video_enc = gst_element_factory_make ("theoraenc", "theoraenc")) == NULL)
+  if ((video_enc = gst_element_factory_make ("vp8enc", "vp8enc")) == NULL)
   {
-    cheese_camera_set_error_element_not_found (error, "theoraenc");
+    cheese_camera_set_error_element_not_found (error, "vp8enc");
     return;
   }
   g_object_set (priv->camerabin, "video-encoder", video_enc, NULL);
-  g_object_set (G_OBJECT (video_enc), "speed-level", 2, NULL);
+  g_object_set (G_OBJECT (video_enc), "speed", 2, NULL);
 
-  if ((mux = gst_element_factory_make ("oggmux", "oggmux")) == NULL)
+  if ((mux = gst_element_factory_make ("webmmux", "webmmux")) == NULL)
   {
-    cheese_camera_set_error_element_not_found (error, "oggmux");
+    cheese_camera_set_error_element_not_found (error, "webmmux");
     return;
   }
   g_object_set (priv->camerabin, "video-muxer", mux, NULL);
-  g_object_set (G_OBJECT (mux),
-                "max-delay", (guint64) 10000000,
-                "max-page-delay", (guint64) 10000000, NULL);
 }
 
 /*
diff --git a/libcheese/cheese-fileutil.h b/libcheese/cheese-fileutil.h
index 21b9eec..a470427 100644
--- a/libcheese/cheese-fileutil.h
+++ b/libcheese/cheese-fileutil.h
@@ -36,7 +36,7 @@
  *
  * The filename suffix for videos saved by Cheese.
  */
-#define CHEESE_VIDEO_NAME_SUFFIX ".ogv"
+#define CHEESE_VIDEO_NAME_SUFFIX ".webm"
 
 G_BEGIN_DECLS
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]