Hi all,<br><br>I'm trying to modify the openRTSP test app in order to have it output quicktime files in one minute long chunks instead of in one big mov file. I've looked a lot at QuickTimeFileSink.cpp and PlayCommon.cpp but have run into some snags. <br>
Some things I have tried:<br><br>Since the start-of-file and end-of-file markers written into the quicktime file are linked with sink construction and destruction, the first thing I did was to set up a delayed task that, when invoked, closes the quicktime sink medium and attempt to recreate it. However, this didn't work as intended, as there is likely a whole lot of stuff still "attached" to the filter chain that was set up originally. I don't think live555 liked it when I ripped out the sink and tried to recreate it on the fly. The code looked something like this:<br>
<br><br><span style="font-family: courier new,monospace;">closeMediaSinks();</span><br style="font-family: courier new,monospace;"><br style="font-family: courier new,monospace;"><span style="font-family: courier new,monospace;"> qtOut = QuickTimeFileSink::createNew(*env, *session, quickTimeFileName.c_str(),</span><br style="font-family: courier new,monospace;">
<span style="font-family: courier new,monospace;"> fileSinkBufferSize,</span><br style="font-family: courier new,monospace;"><span style="font-family: courier new,monospace;"> movieWidth, movieHeight,</span><br style="font-family: courier new,monospace;">
<span style="font-family: courier new,monospace;"> movieFPS,</span><br style="font-family: courier new,monospace;"><span style="font-family: courier new,monospace;" dir="ltr" id=":1cs">
packetLossCompensate,<br>
syncStreams,<br>
generateHintTracks,<br>
generateMP4Format);<br> if (qtOut == NULL) <br> {<br> *env
<< "Failed to create </span><span style="font-family: courier new,monospace;" dir="ltr" id=":1cs">QuickTime file sink for stdout: " <<
env->getResultMsg();<br> shutdown();<br> }<br><br>
qtOut->startPlaying(sessionAfterPlaying, NULL);</span><br><br><br>Another approach I took was to simply run openRTSP back-to-back in one minute intervals. However, this left about a 10 second gap in which I didn't have video coverage.<br>
<br>The next thing I'd like to try is to close the quicktime movie with and reopen another one directly within the quicktime sink class itself, thereby avoiding the filter chain issues I had when destroying the sink entirely. <br>
<br>Just wanted to get your take on what the best approach to doing this is.<br><br>Thanks,<br>Josh<br><br>