lundi 29 décembre 2014

Gstreamer does not play multiple streams at a time

I am working on an app which requires to play multiple RTSP streams at a time using Gstreamer , it is working fine with single stream , as i add second stream , first stream stops and second starts to play , after few sconds , it also stops and app crashes.


Here is screenshot of APP streams view APP screenview


and this screenshot when APP crashes


app crash screen


i have updates the Gstreamer.framework , searched and tried different solutions.but nothing worked


Here is my code sample for pipelining the streams



#import "VideoViewController.h"
#import "GStreamerBackend.h"
#import <UIKit/UIKit.h>

@interface VideoViewController () {
GStreamerBackend *gst_backend;
GStreamerBackend *gst_backend1;
int media_width; /* Width of the clip */
int media_height; /* height ofthe clip */
Boolean dragging_slider; /* Whether the time slider is being dragged or not */
Boolean is_local_media; /* Whether this clip is stored locally or is being streamed */
Boolean is_playing_desired; /* Whether the user asked to go to PLAYING */
}


in viewDidLoad:



url1= my first url
url2=my second URL


here I initialize my 2 stream.



gst_backend = [[GStreamerBackend alloc] init:self videoView:video_view];

gst_backend1 = [[GStreamerBackend alloc] init:self videoView:video_view1];


this delegate method is called :



-(void) gstreamerInitialized
{

dispatch_async(dispatch_get_main_queue(), ^{
firstInit=YES;
play_button.enabled = TRUE;
pause_button.enabled = TRUE;
message_label.text = @"Ready";
[gst_backend setUri:uri];
[gst_backend1 setUri:uri2];
//is_local_media = [uri hasPrefix:@"file://"];
//is_playing_desired = NO;

[gst_backend1 play];
[gst_backend play];
});

}


i think issue is in the search paths. enter image description here


enter image description here




Aucun commentaire:

Enregistrer un commentaire