drawinglayer/source/primitive2d/sceneprimitive2d.cxx  |   10 +++++-----
 include/drawinglayer/primitive2d/sceneprimitive2d.hxx |    8 ++++----
 2 files changed, 9 insertions(+), 9 deletions(-)

New commits:
commit ec177c313cfaf4c709bd5c01e07f3c15bf234be2
Author:     Noel Grandin <noel.gran...@collabora.co.uk>
AuthorDate: Thu Aug 7 09:09:10 2025 +0200
Commit:     Noel Grandin <noel.gran...@collabora.co.uk>
CommitDate: Thu Aug 7 16:16:11 2025 +0200

    BitmapEx->Bitmap in ScenePrimitive2D
    
    now that Bitmap can handle transparency
    
    Change-Id: Ie0ffa2cc8f74232be7770c5f8813536980084d67
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/189068
    Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk>
    Tested-by: Jenkins

diff --git a/drawinglayer/source/primitive2d/sceneprimitive2d.cxx 
b/drawinglayer/source/primitive2d/sceneprimitive2d.cxx
index 930dcda34e37..8631b316ffdc 100644
--- a/drawinglayer/source/primitive2d/sceneprimitive2d.cxx
+++ b/drawinglayer/source/primitive2d/sceneprimitive2d.cxx
@@ -44,9 +44,9 @@ using namespace com::sun::star;
 
 namespace
 {
-    BitmapEx BPixelRasterToBitmapEx(const basegfx::BZPixelRaster& rRaster, 
sal_uInt16 mnAntiAlialize)
+    Bitmap BPixelRasterToBitmap(const basegfx::BZPixelRaster& rRaster, 
sal_uInt16 mnAntiAlialize)
     {
-        BitmapEx aRetval;
+        Bitmap aRetval;
         const sal_uInt32 nWidth(mnAntiAlialize ? 
rRaster.getWidth()/mnAntiAlialize : rRaster.getWidth());
         const sal_uInt32 nHeight(mnAntiAlialize ? 
rRaster.getHeight()/mnAntiAlialize : rRaster.getHeight());
 
@@ -510,7 +510,7 @@ namespace drawinglayer::primitive2d
                 aZBufferProcessor3D.finish();
             }
 
-            const_cast< ScenePrimitive2D* >(this)->maOldRenderedBitmap = 
BPixelRasterToBitmapEx(aBZPixelRaster, nOversampleValue);
+            const_cast< ScenePrimitive2D* >(this)->maOldRenderedBitmap = 
BPixelRasterToBitmap(aBZPixelRaster, nOversampleValue);
             const Size aBitmapSizePixel(maOldRenderedBitmap.GetSizePixel());
 
             if(!(aBitmapSizePixel.getWidth() && aBitmapSizePixel.getHeight()))
@@ -530,7 +530,7 @@ namespace drawinglayer::primitive2d
             // create bitmap primitive and add
             aContainer.push_back(
                 new BitmapPrimitive2D(
-                    maOldRenderedBitmap,
+                    BitmapEx(maOldRenderedBitmap),
                     aNew2DTransform));
 
             // test: Allow to add an outline in the debugger when tests are 
needed
@@ -616,7 +616,7 @@ namespace drawinglayer::primitive2d
             const sal_Int32 nY(basegfx::fround(fRelativeY * 
aBitmapSizePixel.Height()));
 
             // try to get a statement about transparency in that pixel
-            o_rResult = (0 != maOldRenderedBitmap.GetAlpha(nX, nY));
+            o_rResult = (0 != maOldRenderedBitmap.GetPixelColor(nX, 
nY).GetAlpha());
             return true;
         }
 
diff --git a/include/drawinglayer/primitive2d/sceneprimitive2d.hxx 
b/include/drawinglayer/primitive2d/sceneprimitive2d.hxx
index 5b3ca6bb840f..f6879cecd3bd 100644
--- a/include/drawinglayer/primitive2d/sceneprimitive2d.hxx
+++ b/include/drawinglayer/primitive2d/sceneprimitive2d.hxx
@@ -78,10 +78,10 @@ namespace drawinglayer::primitive2d
             double                                              
mfOldDiscreteSizeY;
             basegfx::B2DRange                                   
maOldUnitVisiblePart;
 
-            /** the last created BitmapEx, e.g. for fast HitTest. This does 
not really need
-                memory since BitmapEx is internally RefCounted
+            /** the last created Bitmap, e.g. for fast HitTest. This does not 
really need
+                memory since Bitmap is internally RefCounted
              */
-            BitmapEx                                            
maOldRenderedBitmap;
+            Bitmap                                              
maOldRenderedBitmap;
 
             /// private helpers
             bool impGetShadow3D() const;
@@ -103,7 +103,7 @@ namespace drawinglayer::primitive2d
             Primitive2DContainer getGeometry2D() const;
             Primitive2DContainer getShadow2D() const;
 
-            /** Fast HitTest which uses the last buffered BitmapEx from the 
last
+            /** Fast HitTest which uses the last buffered Bitmap from the last
                 rendered area if available. The return value describes if the 
check
                 could be done with the current information, so do NOT use 
o_rResult
                 when it returns false. o_rResult will be changed on return 
true and

Reply via email to