diff options
Diffstat (limited to 'common/system.h')
-rw-r--r-- | common/system.h | 42 |
1 files changed, 15 insertions, 27 deletions
diff --git a/common/system.h b/common/system.h index dc74533861..94bf7f01eb 100644 --- a/common/system.h +++ b/common/system.h @@ -380,33 +380,22 @@ public: * * * The next layer is the overlay. It is composed over the game - * graphics. By default, it has exactly the same size and - * resolution as the game graphics. However, client code can - * specify an overlay scale (as an additional parameter to - * initSize()). This is meant to increase the resolution of the - * overlay while keeping its size the same as that of the game - * graphics. For example, if the overlay scale is 2, and the game - * graphics have a resolution of 320x200; then the overlay shall - * have a resolution of 640x400, but it still has the same - * physical size as the game graphics. - * The overlay usually uses 16bpp, but on some ports, only 8bpp - * are availble, so that is supported, too, via a compile time - * switch (see also the OverlayColor typedef in scummsys.h). - * + * graphics. Historically the overlay size had always been a + * multiple of the game resolution, for example when the game + * resolution was 320x200 and the user selected a 2x scaler and did + * not enable aspect ratio correction it had a size of 640x400. + * An exception was the aspect ratio correction, which did allow + * for non multiples of the vertical resolution of the game screen. + * Nowadays the overlay size does not need to have any relation to + * the game resolution though, for example the overlay resolution + * might be the same as the physical screen resolution. + * The overlay is forced to a 16bpp mode right now. * * Finally, there is the mouse layer. This layer doesn't have to * actually exist within the backend -- it all depends on how a * backend chooses to implement mouse cursors, but in the default * SDL backend, it really is a separate layer. The mouse can * have a palette of its own, if the backend supports it. - * The scale of the mouse cursor is called 'cursorTargetScale'. - * This is meant as a hint to the backend. For example, let us - * assume the overlay is not visible, and the game graphics are - * displayed using a 2x scaler. If a mouse cursor with a - * cursorTargetScale of 1 is set, then it should be scaled by - * factor 2x, too, just like the game graphics. But if it has a - * cursorTargetScale of 2, then it shouldn't be scaled again by - * the game graphics scaler. * * On a note for OSystem users here. We do not require our graphics * to be thread safe and in fact most/all backends using OpenGL are @@ -758,13 +747,11 @@ public: * In order to be able to display dialogs atop the game graphics, backends * must provide an overlay mode. * - * The overlay can be 8 or 16 bpp. Depending on which it is, OverlayColor - * is 8 or 16 bit. + * The overlay is currently forced at 16 bpp. * * For 'coolness' we usually want to have an overlay which is blended over * the game graphics. On backends which support alpha blending, this is - * no issue; but on other systems (in particular those which only support - * 8bpp), this needs some trickery. + * no issue; but on other systems this needs some trickery. * * Essentially, we fake (alpha) blending on these systems by copying the * current game graphics into the overlay buffer when activating the overlay, @@ -883,10 +870,11 @@ public: * @param keycolor transparency color value. This should not exceed the maximum color value of the specified format. * In case it does the behavior is undefined. The backend might just error out or simply ignore the * value. (The SDL backend will just assert to prevent abuse of this). - * @param cursorTargetScale scale factor which cursor is designed for + * @param dontScale Whether the cursor should never be scaled. An exception are high ppi displays, where the cursor + * would be too small to notice otherwise, these are allowed to scale the cursor anyway. * @param format pointer to the pixel format which cursor graphic uses (0 means CLUT8) */ - virtual void setMouseCursor(const byte *buf, uint w, uint h, int hotspotX, int hotspotY, uint32 keycolor, int cursorTargetScale = 1, const Graphics::PixelFormat *format = NULL) = 0; + virtual void setMouseCursor(const byte *buf, uint w, uint h, int hotspotX, int hotspotY, uint32 keycolor, bool dontScale = false, const Graphics::PixelFormat *format = NULL) = 0; /** * Replace the specified range of cursor the palette with new colors. |