From 48d0d525d0cc579be2b1ba195ee797fd6f670276 Mon Sep 17 00:00:00 2001 From: Christopher Sherlock Date: Thu, 14 Nov 2024 00:38:25 +1100 Subject: vcl: fix call sites for createBlendFrame(), rename to createAlphaBlendFrame() The call sites are actually passing in transparency, in fact to be consistent with current conventions we are actually dealing with alpha values. So we need to take the transparent values at the call sites and convert to alpha values by just subtracting 255. Hence fixing the FIXME comment. Change-Id: Ibc55ea77f469ec8afcab0cc26d2b8cdf25ea8a72 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/173858 Tested-by: Jenkins Reviewed-by: Michael Weghorn --- include/vcl/bitmapex.hxx | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'include') diff --git a/include/vcl/bitmapex.hxx b/include/vcl/bitmapex.hxx index b102ced8ba9b..ebc56930192e 100644 --- a/include/vcl/bitmapex.hxx +++ b/include/vcl/bitmapex.hxx @@ -467,7 +467,7 @@ private: }; -/** Create a blend frame as BitmapEx +/** Create a blend frame as BitmapEx using an alpha value @param nAlpha The blend value defines how strong the frame will be blended with the @@ -480,14 +480,13 @@ private: @param rSize The size of the frame in pixels */ -BitmapEx VCL_DLLPUBLIC createBlendFrame( +BitmapEx VCL_DLLPUBLIC createAlphaBlendFrame( const Size& rSize, sal_uInt8 nAlpha, Color aColorTopLeft, Color aColorBottomRight); - -/** Create a blend frame as BitmapEx +/** Create a blend frame as BitmapEx using an alpha value @param nAlpha The blend value defines how strong the frame will be blended with the @@ -499,7 +498,7 @@ BitmapEx VCL_DLLPUBLIC createBlendFrame( @param rSize The size of the frame in pixels */ -BitmapEx createBlendFrame( +BitmapEx createAlphaBlendFrame( const Size& rSize, sal_uInt8 nAlpha, Color aColorTopLeft, -- cgit