[ scummvm-Patches-1491859 ] Possible fix for recent cursor regressions

SourceForge.net noreply at sourceforge.net
Fri May 19 23:17:50 CEST 2006


Patches item #1491859, was opened at 2006-05-19 23:17
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=418822&aid=1491859&group_id=37116

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: None
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: Torbjörn Andersson (eriktorbjorn)
Assigned to: Eugene Sandulenko (sev)
Summary: Possible fix for recent cursor regressions

Initial Comment:
The recent GUI changes appear to have introduced a
couple of regressions with in-game cursors:

* Hotspots are off, except with the 1x scaler.
* Cursor position is not adjusted by the "shake position".

This patch attempts to fix both, while at the same time
simplifying the code a bit. But I'm not as familiar
with the cursor handling as I should be, so I'm not
sure I got it right.

The general idea is that I'm trying to calculate a
_mouseBackup rect in unscaled, unadjusted coordinates.
I'm not sure how this interacts with cursor scaling,
though, so please take a closer look at that.

Once we have the unscaled dimensions, we adjust them by
scale, shake position and aspect ratio correction, and
use them for blitting the pre-scaled image.

I've made a slight change to addDirtyRect() so that if
the clipped rect is outside the screen, it's not added.
This eliminates the need for clipping _mouseBackup. We
don't need to clip the pre-scaled cursor image either,
since SDL_BlitSurface() should handle that by itself.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=418822&aid=1491859&group_id=37116




More information about the Scummvm-tracker mailing list