/pidgin/main: a441bf8b2eed: Merged in CMaiku/pidgin (pull reques...
Gary Kramlich
grim at reaperworld.com
Sat Jan 23 14:06:34 EST 2016
Changeset: a441bf8b2eed9d78dc2f6edf05fd2cfa4091cced
Author: Gary Kramlich <grim at reaperworld.com>
Date: 2016-01-23 12:45 -0600
Branch: default
URL: https://hg.pidgin.im/pidgin/main/rev/a441bf8b2eed
Description:
Merged in CMaiku/pidgin (pull request #15)
Fix voice and video default settings/functionality
diffstat:
libpurple/media/backend-fs2.c | 53 +++++-------------------------------------
pidgin/gtkprefs.c | 6 +++-
2 files changed, 11 insertions(+), 48 deletions(-)
diffs (108 lines):
diff --git a/libpurple/media/backend-fs2.c b/libpurple/media/backend-fs2.c
--- a/libpurple/media/backend-fs2.c
+++ b/libpurple/media/backend-fs2.c
@@ -1530,18 +1530,6 @@ init_conference(PurpleMediaBackendFs2 *s
return TRUE;
}
-static void
-gst_element_added_cb(FsElementAddedNotifier *self,
- GstBin *bin, GstElement *element, gpointer user_data)
-{
- /*
- * Hack to make H264 work with Gmail video.
- */
- if (!strncmp(GST_ELEMENT_NAME(element), "x264", 4)) {
- g_object_set(GST_OBJECT(element), "cabac", FALSE, NULL);
- }
-}
-
static gboolean
create_src(PurpleMediaBackendFs2 *self, const gchar *sess_id,
PurpleMediaSessionType type)
@@ -1660,9 +1648,8 @@ create_session(PurpleMediaBackendFs2 *se
PURPLE_MEDIA_BACKEND_FS2_GET_PRIVATE(self);
PurpleMediaBackendFs2Session *session;
GError *err = NULL;
- GList *codec_conf = NULL, *iter = NULL;
+ GList *codec_conf = NULL;
gchar *filename = NULL;
- gboolean is_nice = !strcmp(transmitter, "nice");
session = g_new0(PurpleMediaBackendFs2Session, 1);
@@ -1698,7 +1685,7 @@ create_session(PurpleMediaBackendFs2 *se
g_free(filename);
if (err != NULL) {
- if (err->code == 4)
+ if (err->code == G_KEY_FILE_ERROR_NOT_FOUND)
purple_debug_info("backend-fs2", "Couldn't read "
"fs-codec.conf: %s\n",
err->message);
@@ -1707,25 +1694,11 @@ create_session(PurpleMediaBackendFs2 *se
"fs-codec.conf: %s\n",
err->message);
g_error_free(err);
- }
-
- /*
- * Add SPEEX if the configuration file doesn't exist or
- * there isn't a speex entry.
- */
- for (iter = codec_conf; iter; iter = g_list_next(iter)) {
- FsCodec *codec = iter->data;
- if (!g_ascii_strcasecmp(codec->encoding_name, "speex"))
- break;
- }
-
- if (iter == NULL) {
- codec_conf = g_list_prepend(codec_conf,
- fs_codec_new(FS_CODEC_ID_ANY,
- "SPEEX", FS_MEDIA_TYPE_AUDIO, 8000));
- codec_conf = g_list_prepend(codec_conf,
- fs_codec_new(FS_CODEC_ID_ANY,
- "SPEEX", FS_MEDIA_TYPE_AUDIO, 16000));
+
+ purple_debug_info("backend-fs2",
+ "Loading default codec conf instead\n");
+ codec_conf = fs_utils_get_default_codec_preferences(
+ GST_ELEMENT(priv->conference));
}
fs_session_set_codec_preferences(session->session, codec_conf, NULL);
@@ -1740,18 +1713,6 @@ create_session(PurpleMediaBackendFs2 *se
g_object_set(G_OBJECT(session->session),
"no-rtcp-timeout", 0, NULL);
- /*
- * Hack to make x264 work with Gmail video.
- */
- if (is_nice && !strcmp(sess_id, "google-video")) {
- FsElementAddedNotifier *notifier =
- fs_element_added_notifier_new();
- g_signal_connect(G_OBJECT(notifier), "element-added",
- G_CALLBACK(gst_element_added_cb), NULL);
- fs_element_added_notifier_add(notifier,
- GST_BIN(priv->conference));
- }
-
session->id = g_strdup(sess_id);
session->backend = self;
session->type = type;
diff --git a/pidgin/gtkprefs.c b/pidgin/gtkprefs.c
--- a/pidgin/gtkprefs.c
+++ b/pidgin/gtkprefs.c
@@ -175,8 +175,10 @@ static const gchar *VIDEO_SINK_PLUGINS[]
"directdrawsink", "DirectDraw",
/* "gconfvideosink", "GConf", */
"glimagesink", "OpenGL",
- "ximagesink", "X Window System",
- "xvimagesink", "X Window System (Xv)",
+ /* Currently broken when embedding in a Gtk window
+ * "ximagesink", "X Window System",
+ * "xvimagesink", "X Window System (Xv)",
+ */
NULL
};
More information about the Commits
mailing list