Age | Commit message (Collapse) | Author |
|
The SDL graphics manager was just ignoring calls from CursorMan to
set the cursor to a blank cursor, which meant engines that did not
immediately send a cursor to CursorMan at startup would still show
the launcher's cursor (usually with a broken palette).
The OpenGL graphics manager would try to generate and draw an
invalid cursor surface when receiving an empty cursor.
|
|
the cursor
The only reason we show the system cursor outside the game area is
to show users where their mouse is when the window is resized and
the mouse is outside the game area. If the game cannot be
interacted with, then the mouse also does not need to be shown in
the black areas.
|
|
This patch refactors the OpenGL and SDL graphics backends,
primarily to unify window scaling and mouse handling, and to
fix coordinate mapping between the ScummVM window and the
virtual game screen when they have different aspect ratios.
Unified code for these two backends has been moved to a new
header-only WindowedGraphicsManager class, so named because it
contains code for managing graphics managers that interact with
a windowing system and render virtual screens within a larger
physical content window.
The biggest behavioral change here is with the coordinate
system mapping:
Previously, mouse offsets were converted by mapping the whole
space within the window as input to the virtual game screen
without maintaining aspect ratio. This was done to prevent
'stickiness' when the mouse cursor was within the window but
outside of the virtual game screen, but it caused noticeable
distortion of mouse movement speed on the axis with blank
space.
Instead of introducing mouse speed distortion to prevent
stickiness, this patch changes coordinate transformation to
show the system cursor when the mouse moves outside of the virtual
game screen when mouse grab is off, or by holding the mouse inside
the virtual game screen (instead of the entire window) when mouse
grab is on.
This patch also improves some other properties of the
GraphicsManager/PaletteManager interfaces:
* Nullipotent operations (getWidth, getHeight, etc.) of the
PaletteManager/GraphicsManager interfaces are now const
* Methods marked `virtual` but not inherited by any subclass have
been de-virtualized
* Extra unnecessary calculations of hardware height in
SurfaceSdlGraphicsManager have been removed
* Methods have been renamed where appropriate for clarity
(setWindowSize -> handleResize, etc.)
* C++11 support improved with `override` specifier added on
overridden virtual methods in subclasses (primarily to avoid
myself accidentally creating new methods in the subclasses
by changing types/names during refactoring)
Additional refactoring can and should be done at some point to
continue to deduplicate code between the OpenGL and SDL backends.
Since the primary goal here was to improve the coordinate mapping,
full refactoring of these backends was not completed here.
|
|
This matches the other ScummVM and SDL APIs for mouse warp.
|
|
The GUI is not redrawn when the window size changes, but that is
not as important as being able to resize the games themselves.
|
|
|
|
Currently translated at 100.0% (959 of 959 strings)
|
|
Currently translated at 100.0% (959 of 959 strings)
|
|
Currently translated at 100.0% (959 of 959 strings)
|
|
Currently translated at 100.0% (959 of 959 strings)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Note that this still doesn't compile with the library package provided
by bSr43 because this package is missing libvorbisfile.a and has a
non standard name for libglib-2.0.a. But it would probably be better
to fix the package than maintain non-standard packages.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Numerouse additions - the file was not update for almost a year.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Fixes Trac#10263.
|
|
It's quite difficult to patch. I hope this finally solved it.
|
|
Added this already through last commit by accident
Was supposed to get added by this.
Workaround for reading uninitialized temp game bug.
|
|
Also add a bit more documentation / Fix some documentation
|
|
|
|
|
|
|
|
|
|
|
|
When decoding blocks, the YUV planes' pitches were computed using the
target video surface size instead of the block based size, resulting in
decoded plane data being overwritten for some video sizes.
Affected videos are LEOS-11102.bik and LEOS-11152.bik from Myst III.
|
|
|