<div dir="ltr">Thanks for the quick reply!<div><br></div><div>Yes, I'm still developing an RTSP server. Below is my pipeline.<br><br>H264 Baseline 4.0 source (I and P frames only) -> ffmpeg (2.5) mpegts muxer -> custom FramedSource (based on DeviceSource) getting 1316 (188 * 7) byte output chunks from the mpegts muxer and writing all *chunks* for each H264 frame to `fTo`, setting fPresentationTime (via gettimeofday) for each H264 frame, not chunk. I'm not quite sure how to set `fDurationNanoseconds`. I tried to set it to each chunk and I get the same behavior as outline in the previous email. </div><div><br></div><div>To give a bit of background on my sources, the H264 encoder is commercial but not widely used, ffmpeg (libavformat) is muxing h264 data directly into an mpegts bytestream without modification. If I dump the h264 data directly to a file - it works. If I use `testH264VideoStreamer` with the h264 data - it works. If I also dump the mpegts data directly to a file - it works, BUT when using `testOnDemandRTSPServer` with said mpegts file, there is a large 4-5 second startup delay when a client connects on BOTH the client (openRTSP) and the server. I figured out that this was coming from MPEG2TransportStreamFramer. Since I use my own FramedSource instead of MPEP2TransportStreamFramer, I only see this now in `openRTSP`. I assume this is due to something being incorrect with my mpegts bitstream - I just haven't been able to figure it out yet. I can upload an mpegts file directly from my muxer if that'll be helpful. </div><div><br></div><div>(works == plays in all common players and shows no warnings/errors in the tools)</div><div><br></div><div>Thanks again Ross. I'm probably missing something simple. Advice is much appreciated.</div><div><br></div><div>-ac</div><div><br></div><div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Jun 4, 2015 at 10:29 AM, Ross Finlayson <span dir="ltr"><<a href="mailto:finlayson@live555.com" target="_blank">finlayson@live555.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex"><div style="word-wrap:break-word"><div><blockquote type="cite"><div>I have an MPEGTS muxer (ffmpeg) that spits out 1316 (188 * 7) byte chunks of valid data at a time. In my FramedSource subclass, I can write this to a file via fwrite and have a perfectly playable mpegts file. I've been sending data to `fTo` in 1316 byte chunks (as hinted in our previous conversation). The library gives no error or warning and it looks like the data is getting sent out correctly looking at IO rates in wireshark. My total rate is only about ~2Mbit/s, but `openRTSP` only writes it's output file at ~160Kbit/s.<br><br>I am curious of the proper "rate" to feed `fTo` for my MPEGTS FramedSource. I figured <= MTU sized data would be best, but it seems maybe something else. Ideas?</div></blockquote><br></div><div>Can you describe some more how your system is structured? (I assume, based on your previous message, that you’re still developing a RTSP server.)</div><div><br></div><div>In particular, does your “createNewStreamSource()” implementation (in your “OnDemandServerMediaSubsession” subclass) create only an instance of your “FramedSource” subclass, or does it also feed this to a “MPEG2TransportStreamFramer”? (If your “FramedSource” subclass is getting data from a live input source (e.g., from an encoder), rather than from a pre-recorded file, then you shouldn’t need to feed it to a “MPEG2TransportStreamFramer”; however, in that case it’s important that your “FramedSource” subclass set “fPresentationTime” and “fDurationInMicroseconds” correctly, so that the downstream object (a “SimpleRTPSink” in this case) will request data at the correct rate.)</div><span><font color="#888888"><br><br><div>
<span style="border-collapse:separate;color:rgb(0,0,0);font-family:Helvetica;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:-webkit-auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px"><span style="border-collapse:separate;color:rgb(0,0,0);font-family:Helvetica;font-style:normal;font-variant:normal;font-weight:normal;letter-spacing:normal;line-height:normal;text-align:-webkit-auto;text-indent:0px;text-transform:none;white-space:normal;word-spacing:0px">Ross Finlayson<br>Live Networks, Inc.<br><a href="http://www.live555.com/" target="_blank">http://www.live555.com/</a></span></span>
</div>
<br></font></span></div><br>_______________________________________________<br>
live-devel mailing list<br>
<a href="mailto:live-devel@lists.live555.com" target="_blank">live-devel@lists.live555.com</a><br>
<a href="http://lists.live555.com/mailman/listinfo/live-devel" target="_blank">http://lists.live555.com/mailman/listinfo/live-devel</a><br></blockquote></div>
</div></div></div>