mirror of
https://github.com/weyne85/rustdesk.git
synced 2025-10-29 17:00:05 +00:00
vram avoid always fallback to gdi (#8272)
Signed-off-by: 21pages <sunboeasy@gmail.com>
This commit is contained in:
@@ -528,6 +528,7 @@ fn run(vs: VideoService) -> ResultType<()> {
|
||||
#[cfg(all(windows, feature = "vram"))]
|
||||
if c.is_gdi() && encoder.input_texture() {
|
||||
log::info!("changed to gdi when using vram");
|
||||
VRamEncoder::set_fallback_gdi(display_idx, true);
|
||||
bail!("SWITCH");
|
||||
}
|
||||
check_privacy_mode_changed(&sp, c.privacy_mode_id)?;
|
||||
@@ -568,6 +569,10 @@ fn run(vs: VideoService) -> ResultType<()> {
|
||||
}
|
||||
#[cfg(windows)]
|
||||
{
|
||||
#[cfg(feature = "vram")]
|
||||
if try_gdi == 1 && !c.is_gdi() {
|
||||
VRamEncoder::set_fallback_gdi(display_idx, false);
|
||||
}
|
||||
try_gdi = 0;
|
||||
}
|
||||
Ok(())
|
||||
|
||||
Reference in New Issue
Block a user