President New Member Jan 6, 2023 #1 How can we fit video into mobile screen same as a tiktok.. need responsive ui 9:16. how can we do it in player Last edited: Jan 6, 2023
How can we fit video into mobile screen same as a tiktok.. need responsive ui 9:16. how can we do it in player
Max Administrator Staff member Jan 7, 2023 #2 Good day. You can set appropriate aspect ratio with constraints while publishing Code: session.createStream({name:"stream1", display: localVideo, constraints:{audio:true, video:{width:360,height:640}}}).publish(); and playback if needed (in this case, transcoding will be enabled on server) Code: session.createStream({name:"stream1", display: remoteVideo, constraints:{audio:true, video:{width:360,height:640}}}).play();
Good day. You can set appropriate aspect ratio with constraints while publishing Code: session.createStream({name:"stream1", display: localVideo, constraints:{audio:true, video:{width:360,height:640}}}).publish(); and playback if needed (in this case, transcoding will be enabled on server) Code: session.createStream({name:"stream1", display: remoteVideo, constraints:{audio:true, video:{width:360,height:640}}}).play();