Skip to main content

Audio- / Video-Only

deprecated version

You're looking at the deprecated Webcaster Client API. If you're still on v5, learn more about features and changes here.

Follow this link If are ready to migrate to the new API version 6.

In addition to regular streaming, with the nanoStream Webcaster you can stream Audio-Only and Video-Only.

Audio-Only or Video-Only streaming is enabled by setting video or audio device to false in the configuration object passed to startPreview(config).

Audio-Only Streaming

audio-only streaming

To start Audio-Only streaming, we pass false to the video device configuration.

var videoDeviceConfig = {
device: false // setting a video device to "false" allows to stream Audio-Only
};

var audioDeviceConfig = {
device: 0 // we select the first available audio device
};

var config = {
videoDeviceConfig: videoDeviceConfig,
audioDeviceConfig: audioDeviceConfig,
elementId: videoElement
};

user.startPreview(config);

Video-Only Streaming

video-only streaming

To start Video-Only streaming, we pass false to the audio device configuration

var videoDeviceConfig = {
device: 0 // we select the first available video device
};

var audioDeviceConfig = {
device: false // setting an audio device to "false" allows to stream Video-Only
};

var config = {
videoDeviceConfig: videoDeviceConfig,
audioDeviceConfig: audioDeviceConfig,
elementId: videoElement
};

user.startPreview(config);