Skip to content

Commit 76973a3

Browse files
authored
fix: use getSettings() to get actual dimensions for mobile (#560)
1 parent 9fad8c6 commit 76973a3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

lib/src/participant/local.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -178,8 +178,8 @@ class LocalParticipant extends Participant<LocalTrackPublication> {
178178
// use constraints passed to getUserMedia by default
179179
VideoDimensions dimensions = track.currentOptions.params.dimensions;
180180

181-
if (kIsWeb) {
182-
// getSettings() is only implemented for Web
181+
if (kIsWeb || lkPlatformIsMobile()) {
182+
// getSettings() is only implemented for Web & Mobile
183183
try {
184184
// try to use getSettings for more accurate resolution
185185
final settings = track.mediaStreamTrack.getSettings();

0 commit comments

Comments
 (0)