Commit 24b310b7 authored by Claudio Valerio's avatar Claudio Valerio

Merge remote-tracking branch 'origin/develop' into claudio-dev

parents 52103dde d1880119
......@@ -775,9 +775,9 @@ void UBGraphicsScene::eraseLineTo(const QPointF &pEndPoint, const qreal &pWidth)
QList<QGraphicsItem*> collidItems = items(eraserBoundingRect, Qt::IntersectsItemBoundingRect);
QList<UBGraphicsPolygonItem*> intersectedItems;
QList<QList<QPolygonF>> intersectedPolygons;
//qDebug() << "Start, eraser is " << eraserPath;
typedef QList<QPolygonF> POLYGONSLIST;
QList<POLYGONSLIST> intersectedPolygons;
#pragma omp parallel for
for(int i=0; i<collidItems.size(); i++)
......@@ -793,7 +793,6 @@ void UBGraphicsScene::eraseLineTo(const QPointF &pEndPoint, const qreal &pWidth)
{
#pragma omp critical
{
//qDebug() << itemPainterPath << " - delete!";
// Compele remove item
intersectedItems << pi;
intersectedPolygons << QList<QPolygonF>();
......@@ -805,7 +804,6 @@ void UBGraphicsScene::eraseLineTo(const QPointF &pEndPoint, const qreal &pWidth)
QPainterPath newPath = itemPainterPath.subtracted(eraserPath);
#pragma omp critical
{
//qDebug() << itemPainterPath << " - modify to - " << newPath;
intersectedItems << pi;
intersectedPolygons << newPath.simplified().toFillPolygons(pi->sceneTransform().inverted());
}
......
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