mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-23 18:21:04 +00:00
gst/playback/gstplaybin.c: first try autovideosink, then xvimagesink, then error out
Original commit message from CVS: * gst/playback/gstplaybin.c: (gen_video_element): first try autovideosink, then xvimagesink, then error out * po/POTFILES.in: add translatable file * po/af.po: * po/az.po: * po/cs.po: * po/en_GB.po: * po/hu.po: * po/it.po: * po/nb.po: * po/nl.po: * po/or.po: * po/sq.po: * po/sr.po: * po/sv.po: * po/uk.po: * po/vi.po: update translations
This commit is contained in:
parent
f2ce71697b
commit
2d8a59b262
4 changed files with 50 additions and 12 deletions
22
ChangeLog
22
ChangeLog
|
@ -1,3 +1,25 @@
|
||||||
|
2005-10-28 Thomas Vander Stichele <thomas at apestaart dot org>
|
||||||
|
|
||||||
|
* gst/playback/gstplaybin.c: (gen_video_element):
|
||||||
|
first try autovideosink, then xvimagesink, then error out
|
||||||
|
* po/POTFILES.in:
|
||||||
|
add translatable file
|
||||||
|
* po/af.po:
|
||||||
|
* po/az.po:
|
||||||
|
* po/cs.po:
|
||||||
|
* po/en_GB.po:
|
||||||
|
* po/hu.po:
|
||||||
|
* po/it.po:
|
||||||
|
* po/nb.po:
|
||||||
|
* po/nl.po:
|
||||||
|
* po/or.po:
|
||||||
|
* po/sq.po:
|
||||||
|
* po/sr.po:
|
||||||
|
* po/sv.po:
|
||||||
|
* po/uk.po:
|
||||||
|
* po/vi.po:
|
||||||
|
update translations
|
||||||
|
|
||||||
2005-10-27 Philippe Khalaf <burger at speedy dot org>
|
2005-10-27 Philippe Khalaf <burger at speedy dot org>
|
||||||
|
|
||||||
* gst-libs/gst/rtp/gstbasedepayload.c:
|
* gst-libs/gst/rtp/gstbasedepayload.c:
|
||||||
|
|
|
@ -2,18 +2,20 @@
|
||||||
gstcolorbalance
|
gstcolorbalance
|
||||||
|
|
||||||
<!-- ##### SECTION Short_Description ##### -->
|
<!-- ##### SECTION Short_Description ##### -->
|
||||||
interface for elements that provide color balance operations
|
|
||||||
|
|
||||||
<!-- ##### SECTION Long_Description ##### -->
|
<!-- ##### SECTION Long_Description ##### -->
|
||||||
<para>
|
<para>
|
||||||
|
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### SECTION See_Also ##### -->
|
<!-- ##### SECTION See_Also ##### -->
|
||||||
<para>
|
<para>
|
||||||
|
|
||||||
</para>
|
</para>
|
||||||
|
|
||||||
|
|
||||||
<!-- ##### SECTION Stability_Level ##### -->
|
<!-- ##### SECTION Stability_Level ##### -->
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -24,6 +24,8 @@
|
||||||
#include <string.h>
|
#include <string.h>
|
||||||
#include <gst/gst.h>
|
#include <gst/gst.h>
|
||||||
|
|
||||||
|
#include <gst/gst-i18n-plugin.h>
|
||||||
|
|
||||||
#include "gstplaybasebin.h"
|
#include "gstplaybasebin.h"
|
||||||
|
|
||||||
GST_DEBUG_CATEGORY_STATIC (gst_play_bin_debug);
|
GST_DEBUG_CATEGORY_STATIC (gst_play_bin_debug);
|
||||||
|
@ -373,6 +375,8 @@ handoff (GstElement * identity, GstBuffer * frame, gpointer data)
|
||||||
* +----------|--------------------------------------------------+
|
* +----------|--------------------------------------------------+
|
||||||
* handoff
|
* handoff
|
||||||
*/
|
*/
|
||||||
|
/* FIXME: this might return NULL if no videosink was found, handle
|
||||||
|
* this in callers */
|
||||||
static GstElement *
|
static GstElement *
|
||||||
gen_video_element (GstPlayBin * play_bin)
|
gen_video_element (GstPlayBin * play_bin)
|
||||||
{
|
{
|
||||||
|
@ -390,23 +394,32 @@ gen_video_element (GstPlayBin * play_bin)
|
||||||
return element;
|
return element;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (play_bin->video_sink) {
|
||||||
|
sink = play_bin->video_sink;
|
||||||
|
} else {
|
||||||
|
sink = gst_element_factory_make ("autovideosink", "videosink");
|
||||||
|
if (sink == NULL) {
|
||||||
|
sink = gst_element_factory_make ("xvimagesink", "videosink");
|
||||||
|
}
|
||||||
|
/* FIXME: this warrants adding a CORE error category for missing
|
||||||
|
* elements/plugins */
|
||||||
|
if (sink == NULL) {
|
||||||
|
GST_ELEMENT_ERROR (play_bin, CORE, FAILED,
|
||||||
|
(_("Both autovideosink and xvimagesink elements are missing.")),
|
||||||
|
(NULL));
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
gst_object_ref (sink);
|
||||||
|
g_hash_table_insert (play_bin->cache, "video_sink", sink);
|
||||||
|
|
||||||
|
|
||||||
element = gst_bin_new ("vbin");
|
element = gst_bin_new ("vbin");
|
||||||
identity = gst_element_factory_make ("identity", "id");
|
identity = gst_element_factory_make ("identity", "id");
|
||||||
g_object_set (identity, "silent", TRUE, NULL);
|
g_object_set (identity, "silent", TRUE, NULL);
|
||||||
g_signal_connect (identity, "handoff", G_CALLBACK (handoff), play_bin);
|
g_signal_connect (identity, "handoff", G_CALLBACK (handoff), play_bin);
|
||||||
conv = gst_element_factory_make ("ffmpegcolorspace", "vconv");
|
conv = gst_element_factory_make ("ffmpegcolorspace", "vconv");
|
||||||
scale = gst_element_factory_make ("videoscale", "vscale");
|
scale = gst_element_factory_make ("videoscale", "vscale");
|
||||||
if (play_bin->video_sink) {
|
|
||||||
sink = play_bin->video_sink;
|
|
||||||
} else {
|
|
||||||
sink = gst_element_factory_make ("xvimagesink", "videosink");
|
|
||||||
if (sink == NULL) {
|
|
||||||
g_warning ("could not create autovideosink element");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
gst_object_ref (sink);
|
|
||||||
g_hash_table_insert (play_bin->cache, "video_sink", sink);
|
|
||||||
|
|
||||||
gst_bin_add (GST_BIN (element), identity);
|
gst_bin_add (GST_BIN (element), identity);
|
||||||
gst_bin_add (GST_BIN (element), conv);
|
gst_bin_add (GST_BIN (element), conv);
|
||||||
gst_bin_add (GST_BIN (element), scale);
|
gst_bin_add (GST_BIN (element), scale);
|
||||||
|
|
|
@ -4,3 +4,4 @@ ext/gnomevfs/gstgnomevfssrc.c
|
||||||
ext/gnomevfs/gstgnomevfssink.c
|
ext/gnomevfs/gstgnomevfssink.c
|
||||||
ext/ogg/gstoggdemux.c
|
ext/ogg/gstoggdemux.c
|
||||||
gst/playback/gstplaybasebin.c
|
gst/playback/gstplaybasebin.c
|
||||||
|
gst/playback/gstplaybin.c
|
||||||
|
|
Loading…
Reference in a new issue