Commit cddaf4e0 authored by Dmitry Kazakov's avatar Dmitry Kazakov Committed by Blackbeard (alberto flores)

Disable AVX optimizations for 32-bit composite ops

They cause artifacts and we don't have a fix yet :(

CCBUG:404133

Note from the committer:
This commit was initially made on krita/4.2 branch.
However between 4.2.1 and 4.2.2 the stable branch was
reconstructed, which caused all commits that were exclusively
on the previous krita/4.2 (and not on master) to be missing.

The previous commit hash: d3e4c3aa

Also regarding the artifacts: it never worked, optimization were
enabled during the creamy flow implementation, but they never should
be enabled until someone fix them properly.
parent 50d51715
......@@ -94,9 +94,20 @@ template<>
struct OptimizedOpsSelector<KoRgbF32Traits>
{
static KoCompositeOp* createAlphaDarkenOp(const KoColorSpace *cs) {
return useCreamyAlphaDarken() ?
KoOptimizedCompositeOpFactory::createAlphaDarkenOpCreamy128(cs) :
KoOptimizedCompositeOpFactory::createAlphaDarkenOpHard128(cs);
// TODO: optimized code is disabled for 4.2 release,
// becasue it causes bug https://bugs.kde.org/show_bug.cgi?id=404133
if (useCreamyAlphaDarken()) {
return new KoCompositeOpAlphaDarken<KoRgbF32Traits, KoAlphaDarkenParamsWrapperCreamy>(cs);
} else {
return new KoCompositeOpAlphaDarken<KoRgbF32Traits, KoAlphaDarkenParamsWrapperHard>(cs);
}
// TODO: please restore this optimized version when the bug is fixed
// return useCreamyAlphaDarken() ?
// KoOptimizedCompositeOpFactory::createAlphaDarkenOpCreamy128(cs) :
// KoOptimizedCompositeOpFactory::createAlphaDarkenOpHard128(cs);
}
static KoCompositeOp* createOverOp(const KoColorSpace *cs) {
return KoOptimizedCompositeOpFactory::createOverOp128(cs);
......
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