Set ForceCompositionPipeline to prevent tearing.
This commit is contained in:
parent
dcfca09d07
commit
f025288c8b
@ -106,7 +106,7 @@ impl Screen {
|
|||||||
None => return Err(CommandError::MissingMonitor(self.name.to_string())),
|
None => return Err(CommandError::MissingMonitor(self.name.to_string())),
|
||||||
};
|
};
|
||||||
|
|
||||||
Ok(format!("{connection}: {w}x{h} @{in_w}x{in_h} +{x}+{y} {{ViewPortIn={in_w}x{in_h}, ViewPortOut={w}x{h}+0+0, Rotation={rotation}}}",
|
Ok(format!("{connection}: {w}x{h} @{in_w}x{in_h} +{x}+{y} {{ForceCompositionPipeline=On, ViewPortIn={in_w}x{in_h}, ViewPortOut={w}x{h}+0+0, Rotation={rotation}}}",
|
||||||
connection=connection,
|
connection=connection,
|
||||||
w=width,
|
w=width,
|
||||||
h=height,
|
h=height,
|
||||||
@ -204,9 +204,9 @@ mod tests {
|
|||||||
"nvidia-settings",
|
"nvidia-settings",
|
||||||
"--assign",
|
"--assign",
|
||||||
"CurrentMetaMode=\
|
"CurrentMetaMode=\
|
||||||
DFP-5.8: 1920x1200 @1200x1920 +0+0 {ViewPortIn=1200x1920, ViewPortOut=1920x1200+0+0, Rotation=270}, \
|
DFP-5.8: 1920x1200 @1200x1920 +0+0 {ForceCompositionPipeline=On, ViewPortIn=1200x1920, ViewPortOut=1920x1200+0+0, Rotation=270}, \
|
||||||
DFP-0.1: 3440x1440 @3440x1440 +1200+0 {ViewPortIn=3440x1440, ViewPortOut=3440x1440+0+0, Rotation=0}, \
|
DFP-0.1: 3440x1440 @3440x1440 +1200+0 {ForceCompositionPipeline=On, ViewPortIn=3440x1440, ViewPortOut=3440x1440+0+0, Rotation=0}, \
|
||||||
DFP-0.8: 2560x1440 @2560x1440 +4640+0 {ViewPortIn=2560x1440, ViewPortOut=2560x1440+0+0, Rotation=0}"
|
DFP-0.8: 2560x1440 @2560x1440 +4640+0 {ForceCompositionPipeline=On, ViewPortIn=2560x1440, ViewPortOut=2560x1440+0+0, Rotation=0}"
|
||||||
|
|
||||||
]
|
]
|
||||||
);
|
);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user