At the 2018 Unity GDC Keynote they mentioned a SVG importer was coming to 2018.2 yet I cannot find any information on it, any info available yet?
It’s on Github - GitHub - Unity-Technologies/vector-graphics-samples: SVG and Vector Graphics Sample Project at least I believe that’s it.
Thanks.
I’ve loaded the project up and can see it running. It’s very interesting. Can I ask if anyone knows whether the SVG asset is being converted to a raster file? I want to know if it’s being treated more like a mesh where we could scale up as high as we want without pixelation and also keep a really small SVG file size?
It’s a tessellated mesh - You can see it in action here
Roadmap video for 2018 cycle
Great thanks for the link.
Hi, thank you for your interest in the SVG importer! The SVG feature is still in development, but a preview release should be available quite soon. The SVG importer will be released as a package and we will make a forum post with more information once it’s ready.
Great, it’s a really exciting feature.
Will assets file size be the same as the SVGs file size or will the conversion process add some extra size?
The SVG will be tessellated into triangles, so the final asset size will be based on the number of vertices/indices that was generated. If there are gradients and/or textures in the SVG file, these will be packed in a texture atlas, which will add to the size of the asset as well.
Can there be an option to render to a texture like NoesisGUI does?
The SVG importer will not have this option in its first version, but it will be possible to render the imported SVG sprite to a texture in an editor script. We will certainly consider adding this feature in the importer itself since it seems like a basic feature.
In the current svg importer posted above on Github is it possible to view the generated size of the converted asset?
I don’t see a direct way to get that size at this time. We will have to consider providing this kind of information right in the inspector, at least for the number of triangles that was generated.
Will it support xaml as well?
I assume you are referring to the WPF markup? The SVG importer doesn’t support that, but we have a new (still experimental) UIElements framework that has something similar called UXML. Note that this is still in development and documentation is still lean:
https://docs.unity3d.com/Manual/UIElements.html
Hope this helps!
Is the svg generated sprite supposed to work also in UI elements? Thanks
SVG will eventually become a “first-class citizen” of UIElements, but it’s not yet ready at this time. A workaround would be to render the sprite in a texture, then draw the texture in UIElements. But that’s a bit cumbersome and quite slow, unfortunately.
SVG is also not compatible with Unity’s runtime UI at this time. We’re still investigating how we can enable this.
Hi, we have IntegratorTool2D that is capable to export svg items from Illustrator CC file ( even complex scenes ) and recreate them with one click in Unity. Right now we do this with PNG files but as I understand we will be able to do it soon with SVG files. Can I talk privately with anyone from unity and see how can we help you with our feedback and integration. Thank you, Marek.
Sure thing! We’ll get in contact with you soon. Thank you!
For anyone interested in trying the SVG importer, please read everything about it in this forum thread: Vector Graphics Preview Package