[Live-devel] How to create a custom sink that streams to both the network and a local file

Hoang Bui Vu buivuhoang15 at gmail.com
Thu Dec 8 02:33:56 PST 2011


I'm currently doing a live camera streaming project that needs a history
function. I've done some search and come to the solution of creating a
custom sink that is the combination of MPEG4ESVideoRTPSink and FileSink,
which will stream to both a local file and the network.
What I've done is creating a new class called RTPFileSink which is the
merged version of the two classes. I modified the constructor and the
createNew function to take parameters from both classes. However, the
resulting class seems to be in conflict, as the server continuously tries
to read from the source and fails. The output looks like this:

Beginning to read from file...
...done reading from file
Beginning to read from file...
...done reading from file
Beginning to read from file...
...done reading from file
Beginning to read from file...
...done reading from file
Beginning to read from file...
...done reading from file

and it goes on forever. My guess is that the code i merge is containing two
different source readers and streamers, thus they deny each other to read
the source.

I am still very new to this framework, any help is much appreciated.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.live555.com/pipermail/live-devel/attachments/20111208/42217d6d/attachment.html>


More information about the live-devel mailing list