We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c03f15a commit 80d7832Copy full SHA for 80d7832
src/capturer/mod.rs
@@ -20,6 +20,7 @@ pub enum Resolution {
20
_1440p,
21
_2160p,
22
_4320p,
23
+ Custom {width: u32},
24
25
#[default]
26
Captured,
@@ -34,6 +35,9 @@ impl Resolution {
34
35
Resolution::_1440p => [2560, (2560_f32 / aspect_ratio).floor() as u32],
36
Resolution::_2160p => [3840, (3840_f32 / aspect_ratio).floor() as u32],
37
Resolution::_4320p => [7680, (7680_f32 / aspect_ratio).floor() as u32],
38
+ Resolution::Custom { width } => {
39
+ [width, (width / aspect_ratio).floor() as u32]
40
+ }
41
Resolution::Captured => {
42
panic!(".value should not be called when Resolution type is Captured")
43
}
0 commit comments