Re: [Spice-devel] [PATCH xf86-video-qxl 1/2] Change default virtual size to 1920x1080
On 09/14/10 12:05, Alexander Larsson wrote: On Mon, 2010-09-13 at 22:14 +0200, Hans de Goede wrote: This change does come at the prize of using 5MB more memory, but that seems like a reasonable price to pay to give us parity wrt supported resolutions with the windows driver. Also this is a must have to allow the to be written Linux agent to change the guest resolution to match the client machines one when running in auto fullscreen mode. Does this really use 5 megs more memory? I don't think we ever use the framebuffer part of the qxl device for anything but the primary surface, so the 5 megs are unused right now. (unless i'm missing something.) This is correct (and this will not change as the memory needs to be reserved for vga mode too). cheers, Gerd ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/spice-devel
Re: [Spice-devel] [PATCH xf86-video-qxl 1/2] Change default virtual size to 1920x1080
On Mon, 2010-09-13 at 22:14 +0200, Hans de Goede wrote: > With the old default virtual size of 1024x768, using higher resolutions > is not possible without an xorg.conf. Since the default now a days is > to not have an xorg.conf, this is sort of unfortunate. > > This patch makes these higher resolutions available by making the > default virtual size 1920x1080, while keeping the default resolution > used when none is specified through xorg.conf at 1024x786, so that > the spice client window won't be way too large for smaller screens > by default. > > This change does come at the prize of using 5MB more memory, but that > seems like a reasonable price to pay to give us parity wrt supported > resolutions with the windows driver. Also this is a must have to allow > the to be written Linux agent to change the guest resolution to match > the client machines one when running in auto fullscreen mode. Does this really use 5 megs more memory? I don't think we ever use the framebuffer part of the qxl device for anything but the primary surface, so the 5 megs are unused right now. (unless i'm missing something.) -- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= Alexander LarssonRed Hat, Inc al...@redhat.comalexander.lars...@gmail.com He's a lounge-singing crooked sorceror who hangs with the wrong crowd. She's a sarcastic mutant schoolgirl from a different time and place. They fight crime! ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/spice-devel
[Spice-devel] [PATCH xf86-video-qxl 1/2] Change default virtual size to 1920x1080
With the old default virtual size of 1024x768, using higher resolutions is not possible without an xorg.conf. Since the default now a days is to not have an xorg.conf, this is sort of unfortunate. This patch makes these higher resolutions available by making the default virtual size 1920x1080, while keeping the default resolution used when none is specified through xorg.conf at 1024x786, so that the spice client window won't be way too large for smaller screens by default. This change does come at the prize of using 5MB more memory, but that seems like a reasonable price to pay to give us parity wrt supported resolutions with the windows driver. Also this is a must have to allow the to be written Linux agent to change the guest resolution to match the client machines one when running in auto fullscreen mode. In the long run we should add support for resizing the fb on the fly to match the resolution. --- src/qxl_driver.c | 12 ++-- 1 files changed, 10 insertions(+), 2 deletions(-) diff --git a/src/qxl_driver.c b/src/qxl_driver.c index fa79a3d..8492792 100644 --- a/src/qxl_driver.c +++ b/src/qxl_driver.c @@ -1332,8 +1332,8 @@ qxl_pre_init(ScrnInfoPtr pScrn, int flags) } if (pScrn->display->virtualX == 0 && pScrn->display->virtualY == 0) { - pScrn->display->virtualX = 1024; - pScrn->display->virtualY = 768; + pScrn->display->virtualX = 1920; + pScrn->display->virtualY = 1080; } if (0 >= xf86ValidateModes(pScrn, pScrn->monitor->Modes, @@ -1348,6 +1348,14 @@ qxl_pre_init(ScrnInfoPtr pScrn, int flags) xf86PruneDriverModes(pScrn); pScrn->currentMode = pScrn->modes; +/* If no modes are specified in xorg.conf, default to 1024x768 */ +if (pScrn->display->modes == NULL || pScrn->display->modes[0] == NULL) +for (mode = pScrn->modes; mode; mode = mode->next) +if (mode->HDisplay == 1024 && mode->VDisplay == 768) { +pScrn->currentMode = mode; +break; +} + xf86PrintModes(pScrn); xf86SetDpi(pScrn, 0, 0); -- 1.7.2.2 ___ Spice-devel mailing list Spice-devel@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/spice-devel