From 3851c2d9a6bd17c8dd4ca116711120f893167ab6 Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Mon, 8 Jul 2019 01:40:18 +0200 Subject: GRAPHICS: Added source transparency parameter to ManagedSurface::transBlit --- graphics/managed_surface.h | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) (limited to 'graphics/managed_surface.h') diff --git a/graphics/managed_surface.h b/graphics/managed_surface.h index c143222bbc..b643d1b8cf 100644 --- a/graphics/managed_surface.h +++ b/graphics/managed_surface.h @@ -235,8 +235,9 @@ public: * @param flipped Specifies whether to horizontally flip the image * @param overrideColor Optional color to use instead of non-transparent pixels from * the source surface + * @param srcAlpha Optional additional transparency applied to src */ - void transBlitFrom(const Surface &src, uint transColor = 0, bool flipped = false, uint overrideColor = 0); + void transBlitFrom(const Surface &src, uint transColor = 0, bool flipped = false, uint overrideColor = 0, uint srcAlpha = 0xff); /** * Copies another surface into this one ignoring pixels of a designated transparent color @@ -246,9 +247,10 @@ public: * @param flipped Specifies whether to horizontally flip the image * @param overrideColor Optional color to use instead of non-transparent pixels from * the source surface + * @param srcAlpha Optional additional transparency applied to src */ void transBlitFrom(const Surface &src, const Common::Point &destPos, - uint transColor = 0, bool flipped = false, uint overrideColor = 0); + uint transColor = 0, bool flipped = false, uint overrideColor = 0, uint srcAlpha = 0xff); /** * Copies another surface into this one ignoring pixels of a designated transparent color @@ -259,9 +261,10 @@ public: * @param flipped Specifies whether to horizontally flip the image * @param overrideColor Optional color to use instead of non-transparent pixels from * the source surface + * @param srcAlpha Optional additional transparency applied to src */ void transBlitFrom(const Surface &src, const Common::Rect &srcRect, const Common::Point &destPos, - uint transColor = 0, bool flipped = false, uint overrideColor = 0); + uint transColor = 0, bool flipped = false, uint overrideColor = 0, uint srcAlpha = 0xff); /** * Copies another surface into this one ignoring pixels of a designated transparent color @@ -273,9 +276,10 @@ public: * @param flipped Specifies whether to horizontally flip the image * @param overrideColor Optional color to use instead of non-transparent pixels from * the source surface + * @param srcAlpha Optional additional transparency applied to src */ void transBlitFrom(const Surface &src, const Common::Rect &srcRect, const Common::Rect &destRect, - uint transColor = 0, bool flipped = false, uint overrideColor = 0); + uint transColor = 0, bool flipped = false, uint overrideColor = 0, uint srcAlpha = 0xff); /** * Clear the entire surface -- cgit v1.2.3