Appsrc and Playbin

Sasha1987 topilski at mail.ru
Fri May 17 22:57:37 PDT 2013


I try to read mp4 file, mp4 file have audio and video streeam, i start read
buffers of this pipe with help appsink for audio and video. code next: 
sources_.video_sink_ = gst_element_factory_make ("appsink",
"video_appsink");
                    GstAppSinkCallbacks callbacks_v = {end_of_stream_video,
new_preroll_video,new_buffer_video,{NULL} };
                    gst_app_sink_set_callbacks
(GST_APP_SINK(sources_.video_sink_), &callbacks_v, this, NULL);
                    sources_.audio_sink_ = gst_element_factory_make
("appsink", "audio_appsink");
                    GstAppSinkCallbacks callbacks_a =  {end_of_stream_audio,
new_preroll_audio,new_buffer_audio,{NULL}  };
                    gst_app_sink_set_callbacks
(GST_APP_SINK(sources_.audio_sink_), &callbacks_a, this, NULL);
                    g_object_set (G_OBJECT (sources_.pipeline_), "uri",
QUrl::fromLocalFile(path).toString().toStdString().c_str(), NULL);
                    g_object_set (G_OBJECT (sources_.pipeline_),
"audio-sink", sources_.audio_sink_, NULL);
                    g_object_set (G_OBJECT (sources_.pipeline_),
"video-sink", sources_.video_sink_, NULL); 

then after this i try to send buffers to output pipe(playbin), but playbin
have only 1 appsrc and i may play video or audio, but not 2 stream at once.
How can i resolve this problem?



--
View this message in context: http://gstreamer-devel.966125.n4.nabble.com/Appsrc-and-Playbin-tp4659959p4659985.html
Sent from the GStreamer-devel mailing list archive at Nabble.com.


More information about the gstreamer-devel mailing list