[Live-devel] how to make latency as low as possible

Ross Finlayson finlayson at live555.com
Thu Jan 12 09:30:24 PST 2017


Your data source class (“FramedSource” subclass) looks mostly OK; however, I suspect that your problem is that you are not using the correct ‘framer’ class for your H.264 video ‘frames’ (in reality, H.264 NAL units).

Look at your implementation of the “createNewStreamSource()” virtual function (in your “OnDemandServerMediaSubsession” subclass).  Because your data source - from your encoder - is discrete H.264 NAL units (i.e., one at a time), rather than a byte stream, you must use feed your input source to a “H264VideoStreamDiscreteFramer”, *not* a “H264VideoStreamFramer”.

Note also that each ‘frame’ that come from your input source must be a single H.264 NAL unit, and MUST NOT be prepended by a 0x00 0x00 0x00 0x01 ‘start code’.


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




More information about the live-devel mailing list