Using Communication Objects > NetStream object > NetStream.bufferTime |
![]() ![]() ![]() |
NetStream.bufferTime
For playback streams, the value returned by NetStream.bufferTime
specifies how much of the stream Flash Communication Server will buffer before the Flash Player starts playing it back. For example, if your recorded stream is 50 seconds long and your playback speed is twice as fast as your download speed, you might consider setting this value to 25 seconds. You will thus be able to play all of the stream without any stalls.
For publishing streams, this value specifies how long the outgoing queue can grow before the Flash Player considers dropping messages; to determine how much data is currently in the queue, use NetStream.bufferLength
. For a fast connection, the value returned by NetStream.bufferLength
will never approach the value of NetStream.bufferTime
, but on a slow connection it might.
Therefore, if you know your application is running over a slow connection and you want to minimize dropped messages or stalled playback, you might want to use NetStream.setBufferTime
to increase the value of NetStream.bufferTime
.
![]() ![]() ![]() |