[Live-devel] Subclass for OnDemandServerMediaSubsession

vikas srivastava vikasjkmcs2005 at yahoo.co.in
Wed Mar 24 00:34:59 PDT 2010


Hi Ross,
          I am working on streaming from live source in H.264 format.I have studied you FAQ and i have made subclass H264VideoRtpServerMediaSubsession
from OnDemandServerMediaSubsession and redefined virtual function createNewStreamSource() , createNewRTPSink().

Inside createNewRTPSink virtual function , i have returned H264VideoRTPSink() sink
 
And inside createNewStreamSource() virtual function ,i have written code to access live source ,  i have created RTSPClient and then through describeURL() method provided my live source URL and then created MediaSession and ...... as openRTSP test , and finally returned framed source through
MediaSubsession rtspSource() method , code is following 
 FramedSource* framedSource=NULL;char*_progName = "SirisMediaPlayer"; char* url = "rtsp://10.69.170.23/axis-media/media.amp?videocodec=h264"; // Create our client object:RTSPClient *rtspClient = RTSPClient::createNew(envir(),1); 
MediaSession *mediaSession = MediaSession::createNew(envir(), sdpDescription);
MediaSubsessionIterator iter(*mediaSession);
MediaSubsession *mediaSubsession;
{char* sdpDescription = rtspClient->describeURL(url);while((mediaSubsession = iter.next()) != NULL) { if(!mediaSubsession->initiate()) // "Unable to create receiver for \"" << subsession->mediumName() << "/" << subsession->codecName() << "\" subsession: " << _env->getResultMsg() << "\n";} 
framedSource = mediaSubsession->rtpSource();
}
 
 
But as soon as i play VLC player , i gets error inside strlen.asm file as 
Unhandled exception at 0x7855b690 (msvcr90.dll) in openRTSP.exe: 0xC0000005: Access violation reading location 0x00000000.
Can you pls help me out where is the problem.if(mediaSubsession->rtpSource() != NULL)returnframedSource;
 
Thanks
Vikas Srivastava
 
________________________________
Your Mail works best with the New Yahoo Optimized IE8. Get it NOW!.


      Your Mail works best with the New Yahoo Optimized IE8. Get it NOW! http://downloads.yahoo.com/in/internetexplorer/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.live555.com/pipermail/live-devel/attachments/20100324/54afcf94/attachment.html>


More information about the live-devel mailing list