summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorZaheer Abbas Merali <zaheerm@gentoo.org>2005-04-27 09:10:28 +0000
committerZaheer Abbas Merali <zaheerm@gentoo.org>2005-04-27 09:10:28 +0000
commit4ba40e3ead789efe468e787a0943f420c6337b93 (patch)
tree084e9901b6356b20c4979c9dab46a263c4ba69ae /media-libs/gst-plugins/files
parentStable on alpha + ia64, bug 90423. (diff)
downloadgentoo-2-4ba40e3ead789efe468e787a0943f420c6337b93.tar.gz
gentoo-2-4ba40e3ead789efe468e787a0943f420c6337b93.tar.bz2
gentoo-2-4ba40e3ead789efe468e787a0943f420c6337b93.zip
added patch so subtitle font selection is possible in totem 1.1.x
(Portage version: 2.0.51.19)
Diffstat (limited to 'media-libs/gst-plugins/files')
-rw-r--r--media-libs/gst-plugins/files/digest-gst-plugins-0.8.8-r21
-rw-r--r--media-libs/gst-plugins/files/gst-plugins-0.8.8-gstplaybin_subfont.patch116
2 files changed, 117 insertions, 0 deletions
diff --git a/media-libs/gst-plugins/files/digest-gst-plugins-0.8.8-r2 b/media-libs/gst-plugins/files/digest-gst-plugins-0.8.8-r2
new file mode 100644
index 000000000000..e862979669af
--- /dev/null
+++ b/media-libs/gst-plugins/files/digest-gst-plugins-0.8.8-r2
@@ -0,0 +1 @@
+MD5 4f6e7e730fa674ecd6ec713f937b8acb gst-plugins-0.8.8.tar.bz2 2214274
diff --git a/media-libs/gst-plugins/files/gst-plugins-0.8.8-gstplaybin_subfont.patch b/media-libs/gst-plugins/files/gst-plugins-0.8.8-gstplaybin_subfont.patch
new file mode 100644
index 000000000000..29d3ff0e8095
--- /dev/null
+++ b/media-libs/gst-plugins/files/gst-plugins-0.8.8-gstplaybin_subfont.patch
@@ -0,0 +1,116 @@
+===================================================================
+RCS file: /cvs/gstreamer/gst-plugins/gst/playback/gstplaybin.c,v
+retrieving revision 1.36.2.1
+retrieving revision 1.36.2.2
+diff -u -r1.36.2.1 -r1.36.2.2
+--- gstplaybin.c 2005/03/10 14:44:00 1.36.2.1
++++ gstplaybin.c 2005/04/01 15:44:20 1.36.2.2
+@@ -49,6 +49,7 @@
+ GstElement *video_sink;
+ GstElement *visualisation;
+ GstElement *volume_element;
++ GstElement *textoverlay_element;
+ gfloat volume;
+
+ /* these are the currently active sinks */
+@@ -65,6 +66,9 @@
+
+ /* boolean to see if we're currently switching groups */
+ gboolean group_switch;
++
++ /* font description */
++ gchar *font_desc;
+ };
+
+ struct _GstPlayBinClass
+@@ -80,7 +84,8 @@
+ ARG_VIDEO_SINK,
+ ARG_VIS_PLUGIN,
+ ARG_VOLUME,
+- ARG_FRAME
++ ARG_FRAME,
++ ARG_FONT_DESC
+ };
+
+ /* signals */
+@@ -182,13 +187,18 @@
+ g_param_spec_object ("vis-plugin", "Vis plugin",
+ "the visualization element to use (NULL = none)",
+ GST_TYPE_ELEMENT, G_PARAM_READWRITE));
+- g_object_class_install_property (G_OBJECT_CLASS (gobject_klass), ARG_VOLUME,
++ g_object_class_install_property (gobject_klass, ARG_VOLUME,
+ g_param_spec_double ("volume", "volume", "volume",
+ 0.0, VOLUME_MAX_DOUBLE, 1.0, G_PARAM_READWRITE));
+- g_object_class_install_property (G_OBJECT_CLASS (gobject_klass), ARG_FRAME,
++ g_object_class_install_property (gobject_klass, ARG_FRAME,
+ g_param_spec_boxed ("frame", "Frame",
+ "The last frame (NULL = no video available)",
+ GST_TYPE_BUFFER, G_PARAM_READABLE));
++ g_object_class_install_property (gobject_klass, ARG_FONT_DESC,
++ g_param_spec_string ("subtitle-font-desc",
++ "Subtitle font description",
++ "Pango font description of font "
++ "to be used for subtitle rendering", NULL, G_PARAM_WRITABLE));
+
+ gobject_klass->dispose = GST_DEBUG_FUNCPTR (gst_play_bin_dispose);
+
+@@ -216,10 +226,12 @@
+ play_bin->audio_sink = NULL;
+ play_bin->visualisation = NULL;
+ play_bin->volume_element = NULL;
++ play_bin->textoverlay_element = NULL;
+ play_bin->volume = 1.0;
+ play_bin->seekables = NULL;
+ play_bin->sinks = NULL;
+ play_bin->frame = NULL;
++ play_bin->font_desc = NULL;
+ play_bin->cache = g_hash_table_new_full (g_str_hash, g_str_equal,
+ NULL, (GDestroyNotify) gst_object_unref);
+ play_bin->group_switch = FALSE;
+@@ -253,7 +265,8 @@
+ gst_object_unref (GST_OBJECT (play_bin->visualisation));
+ play_bin->visualisation = NULL;
+ }
+-
++ g_free (play_bin->font_desc);
++ play_bin->font_desc = NULL;
+
+ if (G_OBJECT_CLASS (parent_class)->dispose) {
+ G_OBJECT_CLASS (parent_class)->dispose (object);
+@@ -314,6 +327,14 @@
+ play_bin->volume, NULL);
+ }
+ break;
++ case ARG_FONT_DESC:
++ g_free (play_bin->font_desc);
++ play_bin->font_desc = g_strdup (g_value_get_string (value));
++ if (play_bin->textoverlay_element) {
++ g_object_set (G_OBJECT (play_bin->textoverlay_element),
++ "font-desc", g_value_get_string (value), NULL);
++ }
++ break;
+ default:
+ G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
+ break;
+@@ -455,6 +476,11 @@
+ overlay = gst_element_factory_make ("textoverlay", "overlay");
+ g_object_set (G_OBJECT (overlay),
+ "halign", "center", "valign", "bottom", NULL);
++ play_bin->textoverlay_element = overlay;
++ if (play_bin->font_desc) {
++ g_object_set (G_OBJECT (play_bin->textoverlay_element),
++ "font-desc", play_bin->font_desc, NULL);
++ }
+ vbin = gen_video_element (play_bin);
+ if (!overlay) {
+ g_warning ("No overlay (pango) element, subtitles disabled");
+@@ -674,6 +700,9 @@
+ gst_buffer_unref (play_bin->frame);
+ play_bin->frame = NULL;
+ }
++
++ play_bin->textoverlay_element = NULL;
++ play_bin->volume_element = NULL;
+ }
+
+ /* loop over the streams and set up the pipeline to play this