summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
b026b1a)
Interrupt glk_schannel_create() and print warnings if GStreamer functions
fail
g_free(pipeline_name);
/* Create GStreamer elements to put in the pipeline */
g_free(pipeline_name);
/* Create GStreamer elements to put in the pipeline */
- s->source = gst_element_factory_make("fakesrc", NULL);
+ s->source = gst_element_factory_make("filesrc", NULL);
s->filter = gst_element_factory_make("identity", NULL);
s->filter = gst_element_factory_make("identity", NULL);
- s->sink = gst_element_factory_make("fakesink", NULL);
+ s->sink = gst_element_factory_make("autoaudiosink", NULL);
+ if(!s->source || !s->filter || !s->sink) {
+ WARNING("Could not create one or more GStreamer elements");
+ goto fail;
+ }
+
gst_bin_add_many(GST_BIN(s->pipeline), s->source, s->filter, s->sink, NULL);
gst_bin_add_many(GST_BIN(s->pipeline), s->source, s->filter, s->sink, NULL);
- if(!gst_element_link_many(s->source, s->filter, s->sink, NULL))
+ if(!gst_element_link_many(s->source, s->filter, s->sink, NULL)) {
+ WARNING("Could not link GStreamer elements");
glui32
glk_schannel_play(schanid_t chan, glui32 snd)
{
glui32
glk_schannel_play(schanid_t chan, glui32 snd)
{
- VALID_SCHANNEL(chan, return 0);
- return 0;
+ return glk_schannel_play_ext(chan, snd, 1, 0);