[Live-devel] how to create custom sink ?

Ross Finlayson finlayson at live555.com
Fri Feb 5 23:26:09 PST 2010


>Hello,
>I have 2 UDP sockets receiving synchronized RTP audio ( AAC) and RTP
>video (H.264) streams  and i have to re- send that stream to RTSP
>client.
>Any idea how to connect RTSPServer to this source? It looks like I
>have to override "lookupServerMediaSession" ..

No, I don't think you need to modify (or subclass) the existing 
"RTSPServer" at all.  Instead you need only define new 
"ServerMediaSubsession" subclasses - one for your AAC audio source, 
and another for your H.264 video source.  Each subclass will create 
an appropriate "RTPSource" object ("MPEG4GenericRTPSource " for AAC 
audio; H264VideoRTPSource for H.264 video) for delivering its input 
data, and, of course, create appropriate "RTPSink" subclasses 
("MPEG4GenericRTPSink " for AAC audio; H264VideoRTPSink for H.264 
video) for its output.

Specifically, if you want to stream to your clients via multicast, 
you should define subclasses of "PassiveServerMediaSubsession"; if 
you want to stream to your clients via unicast, you should define 
subclasses of "OnDemandServerMediaSubsession".
-- 

Ross Finlayson
Live Networks, Inc.
http://www.live555.com/


More information about the live-devel mailing list