Skip to content

[3.0] direct3d11: fix leak when using NVIDIA Super Resolution

Steve Lhomme requested to merge robUx4/vlc:nvidia-leak-scale/4 into 3.0.x

The NVIDIA driver leaks massively when the Destination Rectangle is not exactly the size of the texture we write into.

To mitigate that we need to crop the source into the target exactly, but not at the screen size as currently done. And then place that in the fullscreen.

This is done on 3.0 first as it's blocking the 3.0.19 release. Also the way the window size is handled on 4.0 should make it a bit easier.

There's also less back and forth when the size changes, as soon as we know we ask the upscaler the size of the texture it's going to use to place it.

The positioning of the SPU is wonky in this special mode, but it's better than a leak... Ultimately this mode should go away when NVIDIA fixes the leak. It's better to let the VideoProcessor do the cropping.

fixes #28095 (closed)

Merge request reports