Closed tobireif closed 7 years ago
Hey Tobi,
Yes, that should be entirely possible. When I wrote this library, it was my intention to decouple the implementation from SVG, so I purposely didn't implement what you suggest. I never got around to it, but I was thinking another module could be created specifically for SVG. It would use an interface like you're suggesting, but it would ultimately include this module, calling it with this module's primitives.
-Kevin
Sounds great! I think it would be useful, eg for collision detection of complex SVG shapes.
Feel free to close the ticket for now, or you could leave it open for later - up to you :)
You can use this script http://www.quazistax.com/Scripts/SvgDom.intersectShapes.js
SvgDom.intersectShapes(someSvgCircleElement, someSvgCircleElement)
Awesome!
Perhaps you want to put it on GitHub.com ?
Hi Kevin :)
Automatic creation of shapes from SVG elements - is that a possibility?
Instead of
we could then write
(That would probably implicitly cause the ~same action as the current version - the lib would create/update its representation of the shape.)
Tobi