Opened 11 months ago
Last modified 2 weeks ago
#22096 closed defect
VMSVGA/VBoxSVGA: Accelerated cursor bugs — at Initial Version
Reported by: | JHRobotics | Owned by: | |
---|---|---|---|
Component: | GUI | Version: | VirtualBox-7.0.18 |
Keywords: | VMSVGA cursor | Cc: | JHRobotics |
Guest type: | all | Host type: | all |
Description
Hello, when I try to use SVGA commands for mouse acceleration, I found following bugs:
1) When is used SVGA_CMD_DEFINE_CURSOR
command (cursor is defined by AND and XOR mask), cursor is draw wrongly and “White colour” (AND=1, XOR=0) is drawing as transparent.
(screenshot screen1-mask-bug.png).
Investigation of problem led me to that mask is calculated but not used and also QT probably haven’t multiplatform way how to perform classical AND and XOR blit, so I suggest converting all cursors to image with alpha mask (VBox it already doing for all non 1bpp cursors). Only one drawback is that in this way we cannot handle colour inverse (usually used by text selection cursor) for these cases I suggest using grey colour so cursor is visible on both black na white.
2) When screen is scaled cursor is keeps in scale of host system – for example when you have 150% DPI the cursor has 150% regardless to virtual screen scale setting. Also, virtual screen scale settings have no effect to cursor size.
(screenshot screen2-scale-bug.png).
3) When I write 0
to FIFO SVGA_FIFO_CURSOR_ON
registry (and update SVGA_FIFO_CURSOR_COUNT reg), the cursor should disappear, the cursor should disappear, but it doesn't.
I also attached patches for these bugs for SVN and for stable version. Bugs also appears with official driver from VMWare (you must set display to VMSVGA and VRAM around 24 MB or lower).
Cursor acceleration is pretty important for fast rendering, because with SW cursor you have to synchronously erase it before rendering operation and blit it back after it.
Screenshot when my patches are applied: screen4-fixed.png. Screenshot with emulation of inverse: screen3-inv-emulation.png. Best regards
JH
Patch for 1st bug (SVN)