Krita Source Code Documentation
Loading...
Searching...
No Matches
KisColorSmudgeStrategyLightness.h
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
7#ifndef KRITA_KISCOLORSMUDGESTRATEGYLIGHTNESS_H
8#define KRITA_KISCOLORSMUDGESTRATEGYLIGHTNESS_H
9
10#include <QScopedPointer>
12#include "kis_painter.h"
14
16
18{
19public:
20
22 bool smearAlpha,
23 bool useDullingMode,
24 KisPaintThicknessOptionData::ThicknessMode thicknessMode);
25
26 void initializePainting() override;
27
29
30 void updateMask(KisDabCache *dabCache,
31 const KisPaintInformation& info,
32 const KisDabShape &shape,
33 const QPointF &cursorPoint,
34 QRect *dstDabRect, qreal lightnessStrength) override;
35
36 QVector<QRect> paintDab(const QRect &srcRect, const QRect &dstRect, const KoColor &currentPaintColor, qreal opacity,
37 qreal colorRateValue, qreal smudgeRateValue, qreal maxPossibleSmudgeRateValue,
38 qreal lightnessStrengthValue, qreal smudgeRadiusValue) override;
39private:
45 QScopedPointer<KisOverlayPaintDeviceWrapper> m_ownedOverlayDevice;
52 bool m_smearAlpha {true};
54 KisPaintThicknessOptionData::ThicknessMode m_thicknessMode;
55};
56
57
58#endif //KRITA_KISCOLORSMUDGESTRATEGYLIGHTNESS_H
DabColoringStrategy & coloringStrategy() override
void updateMask(KisDabCache *dabCache, const KisPaintInformation &info, const KisDabShape &shape, const QPointF &cursorPoint, QRect *dstDabRect, qreal lightnessStrength) override
QScopedPointer< KisOverlayPaintDeviceWrapper > m_ownedOverlayDevice
QVector< QRect > paintDab(const QRect &srcRect, const QRect &dstRect, const KoColor &currentPaintColor, qreal opacity, qreal colorRateValue, qreal smudgeRateValue, qreal maxPossibleSmudgeRateValue, qreal lightnessStrengthValue, qreal smudgeRadiusValue) override
KisColorSmudgeStrategyLightness(KisPainter *painter, bool smearAlpha, bool useDullingMode, KisPaintThicknessOptionData::ThicknessMode thicknessMode)
KisOverlayPaintDeviceWrapper * m_layerOverlayDevice
KisPaintThicknessOptionData::ThicknessMode m_thicknessMode
The KisDabCache class provides caching for dabs into the brush paintop.