You can customize the video capture by setting video constraints on a LocalVideoTrack. Setting constraints, lets you optimize the video track to network and device conditions. You can set size constraints, frame rate constraints or the aspect ratio constraints of your choice. Note that video constraints are used to resolve the capture format, but the actual video sent to Participant may be downscaled temporally or spatially in response to network and device conditions.
1const { connect, createLocalTracks } = require('twilio-video');23// Option 14createLocalTracks({5audio: true,6video: { width: 640 },7}).then(localTracks => {8return connect('$TOKEN', {9name: 'my-room-name',10tracks: localTracks,11});12}).then(room => {13console.log(`Connected to Room: ${room.name}`);14});1516// Option 217connect('$TOKEN', {18audio: true,19name: 'my-room-name',20video: { width: 640 },21}).then(room => {22console.log(`Connected to Room: ${room.name}`);23});