This is too untable.... Stress in example is crashed by this.

Revert "svg_loader: limiting the ploted area of svg to viewBox"

This reverts commit 2bb108b2f1.
This commit is contained in:
Hermet Park 2021-03-12 18:09:19 +09:00
parent efd4741a78
commit 9f0fafa5df

View file

@ -363,14 +363,7 @@ unique_ptr<Scene> _sceneBuildHelper(const SvgNode* node, float vx, float vy, flo
scene->push(_sceneBuildHelper(*child, vx, vy, vw, vh));
} else {
auto shape = _shapeBuildHelper(*child, vx, vy, vw, vh);
// clipping the viewBox
if (shape) {
auto viewBoxClip = Shape::gen();
viewBoxClip->appendRect(vx, vy, vw, vh, 0, 0);
viewBoxClip->fill(0, 0, 0, 255);
shape->composite(move(viewBoxClip), tvg::CompositeMethod::ClipPath);
scene->push(move(shape));
}
if (shape) scene->push(move(shape));
}
}
//Apply composite node