> I know that the testRelay program repeatedly reads from a UDP socket, and > retransmits each packet's payload to a new (multicast or unicast) address and > port. The data reading from the UDP socket contains audio and video data. Now > I want to relay the RTSP consists of an audio and a video subsession.The RTSP > sends audio and video data to the diffrent port,But the testRelay program can > read data only from one port.What can I to do to relay the audio and video > that coming from two ports.
It's easy. Simply model your application on the existing "testRelay" code, but duplicate the code that creates source and sink objects, and calls "startPlaying()". I.e., - Create another "groupsock" object: "inputGroupsock2" - From this, create another "FramedSource*": "source2" - Create another "groupsock" object: "outputGroupsock2" - From this, create another "MediaSink*": "sink2" - Then call sink2->startPlaying(*source2, NULL, NULL); This call can be before or after the original sink->startPlaying(*source, NULL, NULL); but both must occur before the call to env->taskScheduler().doEventLoop(); Ross Finlayson Live Networks, Inc. http://www.live555.com/
_______________________________________________ live-devel mailing list live-devel@lists.live555.com http://lists.live555.com/mailman/listinfo/live-devel