Use min for width/height to apply constraints (#35)

This commit is contained in:
davidliu
2021-11-26 15:03:38 +09:00
committed by GitHub
parent 357213e7e4
commit c50e0269cf
+2 -2
View File
@@ -228,8 +228,8 @@ class VideoParameters {
// https://developer.mozilla.org/en-US/docs/Web/API/MediaDevices/getUserMedia
//
Map<String, dynamic> toMediaConstraintsMap() => <String, dynamic>{
'maxWidth': width,
'maxHeight': height,
'minWidth': width,
'minHeight': height,
'maxFrameRate': encoding.maxFramerate,
};
}