Basically as the title says, I’m just wondering if anyone has managed to get a QEMU-KVM virtual machine to display in the native 3:2 (2256x1504) resolution. I’ve had a bit of trouble getting this going with my windows 11 guest (Fedora 39 host), but I’ve seen that someone has potentially managed to achieve this on a Linux guest. Any pointers are welcome, cheers!
Have you installed the appropriate Virt-IO driver? Otherwise you will be limited by the MS Generic graphic driver.
I also had to disable scaling on the host (set to 100%) and to set the video model of the virtual machine to ‘QXL’. Otherwise the viewer window size would not be reported properly to the guest video driver.
I managed to get it working just by installing the Virt-IO drivers for windows 11. @Viandant this managed to work for me without changing any scaling on the host. I was also able to use Virt-IO instead of QXL which allows me to enable 3D acceleration which is pretty great. For reference, I am using Wayland but im not sure if this makes a difference.
I did add the following resolution line to the Virt-IO video section of the XML:
<video>
<model type="virtio" heads="1" primary="yes">
<acceleration accel3d="yes"/>
<resolution x="2256" y="1504"/>
</model>
<address type="pci" domain="0x0000" bus="0x00" slot="0x01" function="0x0"/>
</video>
Delighted to hear this has been resolved. Marking as such.
Thank you, @Aiden_Contini. I tried your config snippet. But on my system I still cannot use 2256x1504 with VirtIO and scaling. As I’m on Debian sid, I think the Virt-IO drivers are not as compatible with Debian as they are with Fedora.
But I’m glad it works for you.
I don’t think @Aiden_Contini installed the Virt-IO drivers for his distro, but rather the ones for windows in his guest.
I also installed the Virt-IO drivers for windows. Because the resolutions that are offered in the Windows display setting depend on the scaling factor set on the Linux host, I think there must already be something wrong on the Linux side.
I’ve now done some tests with Fedora 39 live with the same results as on Debian. With fractional scaling and Virt-IO the resolution 2256×1504 from the config file is ignored. Instead some standard resolutions plus one or two weird ones can be set on Windows. With virt-viewer running full screen I can choose 3006×2004. But then Windows crashes.
With scaling factor 1, the resolution corresponding to the window size of virt-viewer before logging in shows up in the display resolution menu on the guest. But the resolution cannot be adapted when the window size is changed later.
Quite contrary to QXL, where the windows display resolution is always automatically adjusted to the current size of the viewer window.
So I’ll stick with QXL.