Use min for width/height to apply constraints (#35)
This commit is contained in:
@@ -228,8 +228,8 @@ class VideoParameters {
|
|||||||
// https://developer.mozilla.org/en-US/docs/Web/API/MediaDevices/getUserMedia
|
// https://developer.mozilla.org/en-US/docs/Web/API/MediaDevices/getUserMedia
|
||||||
//
|
//
|
||||||
Map<String, dynamic> toMediaConstraintsMap() => <String, dynamic>{
|
Map<String, dynamic> toMediaConstraintsMap() => <String, dynamic>{
|
||||||
'maxWidth': width,
|
'minWidth': width,
|
||||||
'maxHeight': height,
|
'minHeight': height,
|
||||||
'maxFrameRate': encoding.maxFramerate,
|
'maxFrameRate': encoding.maxFramerate,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user