The Vidyo client library makes a decision in regards to what resolution and frame rate is rendered by the local camera and sent to remote participants in a call. This decision is based on a number of factors including the device's CPU, available bandwidth, size of the view in the UI to render to, battery life, etc.

On mobile platforms (iOS/Android), battery life and temperature of the device are quite important factors in the decision making, for obvious reasons. In certain use cases, a developer may want to override the default behavior of the library and try to push the device harder to yield a greater resolution and frame rate. This can be done by implementing the following code. Note, that this example is for Android, but it would be the same logic on iOS. Also, please be aware that taking this action will drain the battery quicker than the default settings and the device is likely to heat up as well.

1. After construction of the Connector object, set the CPU tradeoff profile to high and register for local camera events:

mVidyoConnector = new Connector(mVideoFrame, Connector.ConnectorViewStyle.VIDYO_CONNECTORVIEWSTYLE_Default, 7, "info@VidyoClient info@VidyoConnector warning", "", 0);


if (!mVidyoConnector.registerLocalCameraEventListener(this)) {
    mLogger.Log("VidyoConnector RegisterLocalCameraEventListener failed");


2. Inherit and implement the Connector.IRegisterLocalCameraEventListener interface

public class MainActivity extends Activity implements
   IVideoFrameListener {


public void onLocalCameraAdded(LocalCamera localCamera) {}

public void onLocalCameraRemoved(LocalCamera localCamera) {}

public void onLocalCameraSelected(LocalCamera localCamera) {}

public void onLocalCameraStateUpdated(LocalCamera localCamera, Device.DeviceState deviceState) {}


3. In the onLocalCameraSelected callback, set the framerate and resolution tradeoff profiles to high. It is important to set both to high as these profiles are coupled in the library. 

public void onLocalCameraSelected(LocalCamera localCamera) {
if (localCamera != null) {


Was this article helpful?
2 out of 2 found this helpful


Please sign in to leave a comment.