Commit daac6985 authored by Ivan Yossi's avatar Ivan Yossi 👌 Committed by Dmitry Kazakov

FIX: Missing Antialias on Vectorized Circular Gauss

ref T8734

(cherry picked from commit 884dcc10)
parent a329a3c1
......@@ -160,6 +160,8 @@ template<> void KisGaussCircleMaskGenerator::
FastRowProcessor::process<Vc::CurrentImplementation::current()>(float* buffer, int width, float y, float cosa, float sina,
float centerX, float centerY)
{
const bool antialiasOn = d->fadeMaker.getAliasingEnabled();
float y_ = y - centerY;
float sinay_ = sina * y_;
float cosay_ = cosa * y_;
......@@ -204,8 +206,12 @@ FastRowProcessor::process<Vc::CurrentImplementation::current()>(float* buffer, i
Vc::float_m outsideMask = dist > vFadeRadius;
dist(outsideMask) = vOne;
Vc::float_m fadeStartMask = dist > vFadeAFadeStart;
dist((outsideMask ^ fadeStartMask) & fadeStartMask) = (vFadeStartValue + (dist - vFadeAFadeStart) * vFadeAFadeCoeff) / vValMax;
Vc::float_m fadeStartMask(false);
// if antialias is off, do not process
if(antialiasOn){
Vc::float_m fadeStartMask = dist > vFadeAFadeStart;
dist((outsideMask ^ fadeStartMask) & fadeStartMask) = (vFadeStartValue + (dist - vFadeAFadeStart) * vFadeAFadeCoeff) / vValMax;
}
Vc::float_m excludeMask = outsideMask | fadeStartMask;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment