sw_engine: fixed a bug where strokes were not showing.

Basic shapes were trimmed entirely when they were outside of the canvas,
even if they had a big enough stroke to be partially on the canvas.

This fixes the issue.

Issue: https://github.com/thorvg/thorvg/issues/1785
This commit is contained in:
Hermet Park 2023-11-17 21:06:11 +09:00
parent 802fb3efc6
commit b8b8188879

View file

@ -139,7 +139,9 @@ struct SwShapeTask : SwTask
visibleFill = (alpha > 0 || rshape->fill);
if (visibleFill || clipper) {
shapeReset(&shape);
if (!shapePrepare(&shape, rshape, transform, clipRegion, bbox, mpool, tid, clips.count > 0 ? true : false)) goto err;
if (!shapePrepare(&shape, rshape, transform, clipRegion, bbox, mpool, tid, clips.count > 0 ? true : false)) {
visibleFill = false;
}
}
}
//Fill