Krita Source Code Documentation
Loading...
Searching...
No Matches
KisColorSmudgeStrategyMask.cpp
Go to the documentation of this file.
1/*
2 * SPDX-FileCopyrightText: 2021 Dmitry Kazakov <dimula73@gmail.com>
3 *
4 * SPDX-License-Identifier: GPL-2.0-or-later
5 */
6
8
9#include "kis_image.h"
11
13 bool useDullingMode, bool useOverlayMode)
14 : KisColorSmudgeStrategyWithOverlay(painter, image, smearAlpha, useDullingMode, useOverlayMode)
15{
16}
17
22
24 const QPointF &cursorPoint, QRect *dstDabRect, qreal lightnessStrength)
25{
27 static KoColor color(Qt::black, cs);
28
29 m_maskDab = dabCache->fetchDab(cs,
30 color,
31 cursorPoint,
32 shape,
33 info,
34 1.0,
35 dstDabRect,
36 lightnessStrength);
37
39}
DabColoringStrategy & coloringStrategy() override
void updateMask(KisDabCache *dabCache, const KisPaintInformation &info, const KisDabShape &shape, const QPointF &cursorPoint, QRect *dstDabRect, qreal lightnessStrength) override
KisColorSmudgeStrategyMask(KisPainter *painter, KisImageSP image, bool smearAlpha, bool useDullingMode, bool useOverlayMode)
DabColoringStrategyMask m_coloringStrategy
The KisDabCache class provides caching for dabs into the brush paintop.
bool needSeparateOriginal() const
KisFixedPaintDeviceSP fetchDab(const KoColorSpace *cs, KisColorSource *colorSource, const QPointF &cursorPoint, KisDabShape const &, const KisPaintInformation &info, qreal softnessFactor, QRect *dstDabRect, qreal lightnessStrength=1.0)
static KoColorSpaceRegistry * instance()
const KoColorSpace * alpha8()