fix blobs dirty tracking #87

Merged
AramJonghu merged 20 commits from blob-testing into main 2026-05-19 23:18:58 +02:00
Showing only changes of commit 8fba953f52 - Show all commits
+7 -7
View File
@@ -167,19 +167,19 @@ void BlobShape::updatePolish() {
continue; continue;
const QPointF otherScene = other->mapToScene(QPointF(0, 0)); const QPointF otherScene = other->mapToScene(QPointF(0, 0));
bool include = false;
if (isInvertedRect()) {
include = true;
} else if (m_hasExpandedRect) {
include = m_expandedRect.intersects(otherPadded);
} else {
const float otherHW = static_cast<float>(other->width()) * 0.5f; const float otherHW = static_cast<float>(other->width()) * 0.5f;
const float otherHH = static_cast<float>(other->height()) * 0.5f; const float otherHH = static_cast<float>(other->height()) * 0.5f;
const float otherPad = pad + deformPadding(other->m_deformMatrix, otherHW, otherHH); const float otherPad = pad + deformPadding(other->m_deformMatrix, otherHW, otherHH);
const QRectF otherPadded(otherScene.x() - static_cast<double>(otherPad), const QRectF otherPadded(otherScene.x() - static_cast<double>(otherPad),
otherScene.y() - static_cast<double>(otherPad), other->width() + 2.0 * static_cast<double>(otherPad), otherScene.y() - static_cast<double>(otherPad), other->width() + 2.0 * static_cast<double>(otherPad),
other->height() + 2.0 * static_cast<double>(otherPad)); other->height() + 2.0 * static_cast<double>(otherPad));
bool include = false;
if (isInvertedRect()) {
include = true;
} else if (m_hasExpandedRect) {
include = m_expandedRect.intersects(otherPadded);
} else {
include = myPadded.intersects(otherPadded); include = myPadded.intersects(otherPadded);
} }