]> granicus.if.org Git - imagemagick/commitdiff
...
authorCristy <urban-warrior@imagemagick.org>
Sun, 7 Oct 2018 16:19:59 +0000 (12:19 -0400)
committerCristy <urban-warrior@imagemagick.org>
Sun, 7 Oct 2018 16:19:59 +0000 (12:19 -0400)
MagickCore/draw.c

index 537ea992b53556da83b3fc5f2c14edfd6c547506..c50aa3303cc64af461bf4883ecb1154c3a8b0aad 100644 (file)
@@ -2868,8 +2868,11 @@ static MagickBooleanType RenderMVGContent(Image *image,
             if (token == next_token)
               ThrowPointExpectedException(token,exception);
             graphic_context[n]->fill_alpha*=opacity;
-            if (graphic_context[n]->fill_alpha != OpaqueAlpha)
+            if (graphic_context[n]->fill.alpha != TransparentAlpha)
               graphic_context[n]->fill.alpha=graphic_context[n]->fill_alpha;
+            else
+              graphic_context[n]->fill.alpha=ClampToQuantum(QuantumRange*
+                opacity);
             break;
           }
         if (LocaleCompare("fill-rule",keyword) == 0)
@@ -3653,8 +3656,11 @@ static MagickBooleanType RenderMVGContent(Image *image,
             if (token == next_token)
               ThrowPointExpectedException(token,exception);
             graphic_context[n]->stroke_alpha*=opacity;
-            if (graphic_context[n]->stroke_alpha != OpaqueAlpha)
+            if (graphic_context[n]->stroke.alpha != TransparentAlpha)
               graphic_context[n]->stroke.alpha=graphic_context[n]->stroke_alpha;
+            else
+              graphic_context[n]->stroke.alpha=ClampToQuantum(QuantumRange*
+                opacity);
             break;
           }
         if (LocaleCompare("stroke-width",keyword) == 0)