Closed Giwayume closed 1 year ago
Fixed by a1ba95e265a9c2928efff62a18aede3ca5b8c978
For this particular image, anyway. My SVG parser is really a hackjob. It doesn't really compare to yours. Your parser with my shader would probably make for pretty decent SVG rendering results. With the notable exception that my rendering model doesn't have a concept of "host coordinate system", since it's not painted inside a box, so any SVGs that try to be "responsive" would necessarily behave weird.
Yeah it looks like perhaps the coordinate space for some of the gradients is not being calculated correctly? Or maybe alpha values in the gradients are being treated as fully opaque?
Maybe it would make sense to merge these projects at some point, but I'm going to at least POC everything the mesh conversion approach can do first. I am curious if the path simplification + triangulation can be done fast enough for a sensible animation use case. So much of the code is "get it working" and not "get it running fast" right now.
Odd. It's working fine for me. Did you re-import it after getting on the latest patch? Godot can be annoying on re-import. It's usually necessary to turn the plugin on and off, and delete the .import
file, then switch away from Godot and switch back, and only then it re-imports. If you try the "reimport" button it will usually ask for a (completely superfluous) restart.
The issue was that it was assuming gradient stop offsets are represented as percentage, so it was dividing everything by 100 unnecessarily. Note that representing as a percentage is valid, but only if the %
sign appears
Oh, yeah reimport worked.