1 person found this helpful
camera.setMode() and camera.setQuality() control the size, frame rate, and bandwidth used for encoding video from your camera. the third parameter to setMode is the framerate.
Thank you mike,
Could camera class use in Stratus ? I thought it just work with FMS.
If so, will i am able to use rigiding and stable fps with the exception of bandwidth ?
And also, if so i expect to support h.264 on Struts early.
you can use your camera and microphone when connected to Stratus. however, you can only publish your camera/microphone for direct connections (new NetStream(nc, NetStream.DIRECT_CONNECTIONS)), and subscribers must use the direct connect API to get the stream from you (new NetStream(nc, <your-peer-id>)). in this mode, your video/audio stream never goes to the server, but travels directly from you (the publisher) to the subscribers. that's the *only* mode that Stratus supports.
because your stream may be received by multiple peers, you must choose a bandwidth (and other encoding parameters) that is likely to fit through the path(s) between the publisher and subscriber(s). if the encoding parameters you've chosen exceed the bandwidth between publisher and subscriber, eventually frames will be dropped. also in bandwidth exhaustion situations, because audio is higher priority than video, you may see audio and video go out of sync at the publisher.
if you set a fixed frame rate and a bandwidth cap, then the encoder will vary the quality to fit within the parameters you've fixed.