From efc4284b42678ebc55d901902dc7db20c7aa2ff6 Mon Sep 17 00:00:00 2001 From: Tobia Tesan Date: Thu, 19 Sep 2013 02:00:35 +0200 Subject: WINTERMUTE: Keep _alphaMode private in TransparentSurface --- engines/wintermute/graphics/transparent_surface.cpp | 7 +++++++ engines/wintermute/graphics/transparent_surface.h | 8 +++++--- 2 files changed, 12 insertions(+), 3 deletions(-) (limited to 'engines/wintermute/graphics') diff --git a/engines/wintermute/graphics/transparent_surface.cpp b/engines/wintermute/graphics/transparent_surface.cpp index cd200354f7..200cffb237 100644 --- a/engines/wintermute/graphics/transparent_surface.cpp +++ b/engines/wintermute/graphics/transparent_surface.cpp @@ -612,4 +612,11 @@ void TransparentSurface::applyColorKey(uint8 rKey, uint8 gKey, uint8 bKey, bool } } +TransparentSurface::AlphaType TransparentSurface::getAlphaMode() { + return _alphaMode; +} + +void TransparentSurface::setAlphaMode(TransparentSurface::AlphaType mode) { + _alphaMode = mode; +} } // End of namespace Wintermute diff --git a/engines/wintermute/graphics/transparent_surface.h b/engines/wintermute/graphics/transparent_surface.h index 598aaa55d7..fe5dc08fc0 100644 --- a/engines/wintermute/graphics/transparent_surface.h +++ b/engines/wintermute/graphics/transparent_surface.h @@ -81,8 +81,6 @@ struct TransparentSurface : public Graphics::Surface { ALPHA_FULL = 2 }; - AlphaType _alphaMode; - /** @brief renders the surface to another surface @param pDest a pointer to the target image. In most cases this is the framebuffer. @@ -120,6 +118,11 @@ struct TransparentSurface : public Graphics::Surface { TransparentSurface *scale(uint16 newWidth, uint16 newHeight) const; TransparentSurface *rotoscale(const TransformStruct &transform) const; + AlphaType getAlphaMode(); + void setAlphaMode(AlphaType); +private: + AlphaType _alphaMode; + }; /** @@ -134,7 +137,6 @@ struct TransparentSurface : public Graphics::Surface { } };*/ - } // End of namespace Wintermute -- cgit v1.2.3 From 5afb297e396fa3ad40559e552008741c6cd6ba66 Mon Sep 17 00:00:00 2001 From: Einar Johan Trøan Sømåen Date: Mon, 30 Sep 2013 11:12:25 +0200 Subject: WINTERMUTE: Constify some getters in TransparentSurface, UIObject and UIWindow --- engines/wintermute/graphics/transparent_surface.cpp | 2 +- engines/wintermute/graphics/transparent_surface.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'engines/wintermute/graphics') diff --git a/engines/wintermute/graphics/transparent_surface.cpp b/engines/wintermute/graphics/transparent_surface.cpp index 200cffb237..ca6f29791a 100644 --- a/engines/wintermute/graphics/transparent_surface.cpp +++ b/engines/wintermute/graphics/transparent_surface.cpp @@ -612,7 +612,7 @@ void TransparentSurface::applyColorKey(uint8 rKey, uint8 gKey, uint8 bKey, bool } } -TransparentSurface::AlphaType TransparentSurface::getAlphaMode() { +TransparentSurface::AlphaType TransparentSurface::getAlphaMode() const { return _alphaMode; } diff --git a/engines/wintermute/graphics/transparent_surface.h b/engines/wintermute/graphics/transparent_surface.h index fe5dc08fc0..5a9c16d73f 100644 --- a/engines/wintermute/graphics/transparent_surface.h +++ b/engines/wintermute/graphics/transparent_surface.h @@ -118,7 +118,7 @@ struct TransparentSurface : public Graphics::Surface { TransparentSurface *scale(uint16 newWidth, uint16 newHeight) const; TransparentSurface *rotoscale(const TransformStruct &transform) const; - AlphaType getAlphaMode(); + AlphaType getAlphaMode() const; void setAlphaMode(AlphaType); private: AlphaType _alphaMode; -- cgit v1.2.3 From 12e7cb401f80d8e1dee1af67817333d897508dfb Mon Sep 17 00:00:00 2001 From: Einar Johan Trøan Sømåen Date: Mon, 30 Sep 2013 11:18:54 +0200 Subject: WINTERMUTE: Formatting with Astyle (UIButton, UIEdit, UIObject, UIWindow, TransparentSurface) --- engines/wintermute/graphics/transparent_surface.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'engines/wintermute/graphics') diff --git a/engines/wintermute/graphics/transparent_surface.cpp b/engines/wintermute/graphics/transparent_surface.cpp index ca6f29791a..470e2cc1cb 100644 --- a/engines/wintermute/graphics/transparent_surface.cpp +++ b/engines/wintermute/graphics/transparent_surface.cpp @@ -181,7 +181,7 @@ void doBlitOpaque(byte *ino, byte *outo, uint32 width, uint32 height, uint32 pit void doBlitBinary(byte *ino, byte *outo, uint32 width, uint32 height, uint32 pitch, int32 inStep, int32 inoStep) { byte *in, *out; - + #ifdef SCUMM_LITTLE_ENDIAN const int aIndex = 0; #else -- cgit v1.2.3