https://bugs.documentfoundation.org/show_bug.cgi?id=159515

--- Comment #12 from Patrick Luby <guibomac...@gmail.com> ---
(In reply to Patrick Luby from comment #11)
> Created attachment 192809 [details]
> Stack trace where extruded shapes alpha mask is created

I have done some debugging and I narrowed down where in the code the bug is
occurring. Using the following debug patch, the roses in the two attached
sample  documents render correctly, but the debug patch makes the cat photo in
attachment #192332 completely transparent. So, I am guessing that the alpha
channel needs to be inverted higher up the stack in attachment #192809:

diff --git a/drawinglayer/source/processor3d/zbufferprocessor3d.cxx
b/drawinglayer/source/processor3d/zbufferprocessor3d.cxx
index b9cb8ffb7a1d..2f24b916e587 100644
--- a/drawinglayer/source/processor3d/zbufferprocessor3d.cxx
+++ b/drawinglayer/source/processor3d/zbufferprocessor3d.cxx
@@ -302,7 +302,8 @@ void ZBufferRasterConverter3D::processLineSpan(const
basegfx::RasterConversionLi
         if(nNewZ > rOldZ)
         {
             // detect color and opacity for this pixel
-            const sal_uInt16 nOpacity(std::max(sal_Int16(0), static_cast<
sal_Int16 >(decideColorAndOpacity(aNewColor) * 255.0)));
+            // try inverting the opacity value
+            const sal_uInt16 nOpacity(255 - std::max(sal_Int16(0),
static_cast< sal_Int16 >(decideColorAndOpacity(aNewColor) * 255.0)));

             if(nOpacity > 0)
             {

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to