[Live-devel] Avoid openning files when creating sdp format

Ross Finlayson finlayson at live555.com
Fri Jan 12 06:48:53 PST 2007


>I've noticed my file is being opened 2 to 3 times before actual
>streaming. After checking the code, the second open is for creating sdp
>format. Is there any ways that can avoid my files are being opened
>before actual streaming?

Not really.  However, if you're streaming from a live source, 
remember to set the "reuseFirstSource" parameter (to each 
"OnDemandServerMediaSubsession" subclass) to "True".  If you do that, 
you'll only read from the input stream once (no matter how many 
clients you get for it).  (The initial data that gets read in order 
to figure out the SDP description data will not get streamed.)
-- 

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


More information about the live-devel mailing list