Android: SVG Support
I've recently started using the SVG Importer to test some SVG files as assets. What I've noticed so far is that not all SVGs seem to import properly or is recognized. It appears that SVGs exported from Illustrator CC do not work and Illustrator CS5 works fine. For those that have worked with SVGs successfully, is there a recommended setting or settings for Illustrator to export SVGs?
Additionally, although certain SVGs import fine with the SVG Importer, they show up with partially missing parts or gradients become invisible. I've experienced this as I generate and build an APK for Android and seems to only appear on an actual device. Oddly this does not occur if I run the APK on an emulator. Am I missing a step or setting?
Any help would be appreciated as I'm wondering if this is a lost cause and I would be better off working with large sprites. TIA!
Answer by JonPQ · Feb 01, 2021 at 11:04 PM
I got it mostly working as intended... Set TessellationOptions values to float.max as indicated here... https://docs.unity3d.com/Packages/com.unity.vectorgraphics@1.0/api/Unity.VectorGraphics.VectorUtils.TessellationOptions.html.
and the other two parameters to 1.0 and 10 yielded decent results. ...however I can't seem to control scale of mesh import, but a kludge fix is just to scale the transform. For the gradients, you need to manually add the vector gradient material to the renderer
Your answer
Follow this Question
Related Questions
Why Won't My Sprite Go Transparent? 2 Answers
Render transparent mesh over sprite 0 Answers
Mysterious Visual Bug - Android 0 Answers
Sprite rendering problem on Android device 3 Answers
How can I move 2d sprites on android? 0 Answers