Commit 15ccec55 authored by Ivan Yossi's avatar Ivan Yossi 👌

Apply negative rotation on mirrored View for Bristle Engine

BUG:384231
parent 9855b267
......@@ -76,8 +76,13 @@ KisHairyPaintOp::KisHairyPaintOp(const KisPaintOpSettingsSP settings, KisPainter
m_rotationOption.resetAllSensors();
m_opacityOption.resetAllSensors();
m_sizeOption.resetAllSensors();
bool mirrorXAxis = settings->getBool("runtimeCanvasMirroredX", false);
bool mirrorYAxis = settings->getBool("runtimeCanvasMirroredY", false);
m_mirrorFlip = mirrorXAxis != mirrorYAxis;
}
void KisHairyPaintOp::loadSettings(const KisBrushBasedPaintOpSettings *settings)
{
m_properties.inkAmount = settings->getInt(HAIRY_INK_AMOUNT);
......@@ -151,7 +156,7 @@ void KisHairyPaintOp::paintLine(const KisPaintInformation &pi1, const KisPaintIn
// during initialization), so we should just skip the distance info
// update
m_brush.paintLine(m_dab, m_dev, pi1, pi, scale * m_properties.scaleFactor, rotation);
m_brush.paintLine(m_dab, m_dev, pi1, pi, scale * m_properties.scaleFactor, m_mirrorFlip? -rotation : rotation);
//QRect rc = m_dab->exactBounds();
QRect rc = m_dab->extent();
......
......@@ -57,6 +57,8 @@ private:
KisPressureSizeOption m_sizeOption;
KisPressureOpacityOption m_opacityOption;
bool m_mirrorFlip;
void loadSettings(const KisBrushBasedPaintOpSettings* settings);
};
......
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