Commit 1e0ef81f authored by Dmitry Kazakov's avatar Dmitry Kazakov

Fixed a bug when softness was set to zero for some tools

The default value should be 1.0, not zero.

BUG:308470
parent ed2a3582
......@@ -84,9 +84,7 @@ void KisColorSmudgeOp::updateMask(const KisPaintInformation& info, double scale,
color,
scale, scale,
rotation,
info,
0.0, 0.0,
0.0);
info);
m_maskBounds = m_maskDab->bounds();
}
......
......@@ -283,7 +283,7 @@ qreal KisDuplicateOp::paintAt(const KisPaintInformation& info)
KisFixedPaintDeviceSP dab =
m_dabCache->fetchDab(cs, color, scale, scale,
0.0, info, 0.0, 0.0, 0.0);
0.0, info);
QRect dstRect = QRect(x, y, dab->bounds().width(), dab->bounds().height());
if (dstRect.isEmpty()) return 1.0;
......
......@@ -121,7 +121,7 @@ qreal KisHatchingPaintOp::paintAt(const KisPaintInformation& info)
KisFixedPaintDeviceSP maskDab =
m_dabCache->fetchDab(cs, color, scale, scale,
0.0, info, xFraction, yFraction, 0.0);;
0.0, info, xFraction, yFraction);
/*-----Convenient renaming for the limits of the maskDab, this will be used
to hatch a dab of just the right size------*/
......
......@@ -46,16 +46,16 @@ public:
double scaleX, double scaleY,
double angle,
const KisPaintInformation& info,
double subPixelX, double subPixelY,
qreal softnessFactor);
double subPixelX = 0.0, double subPixelY = 0.0,
qreal softnessFactor = 1.0);
KisFixedPaintDeviceSP fetchDab(const KoColorSpace *cs,
const KisColorSource *colorSource,
double scaleX, double scaleY,
double angle,
const KisPaintInformation& info,
double subPixelX, double subPixelY,
qreal softnessFactor);
double subPixelX = 0.0, double subPixelY = 0.0,
qreal softnessFactor = 1.0);
private:
struct SavedDabParameters;
......
......@@ -99,7 +99,7 @@ void KisSketchPaintOp::drawConnection(const QPointF& start, const QPointF& end,
void KisSketchPaintOp::updateBrushMask(const KisPaintInformation& info, qreal scale, qreal rotation){
m_maskDab = m_dabCache->fetchDab(m_dab->colorSpace(), painter()->paintColor(), scale, scale,
rotation, info, 0.0, 0.0, 0.0);
rotation, info);
// update bounding box
m_brushBoundingBox = m_maskDab->bounds();
......
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