SVGs import in solid black
Hi - I have multiple projects I am importing SVG formatted images into. It was working fine until mid-day yesterday and the SVGs started importing as solid black. Now, the only way I can import the image in correct color is to convert to a PNG, which involves more steps. The SVGs that I am trying to import are fine in every other program but RIVE. Any advice to fix this issue?
I am working on a Mac Studio with current system Sonoma 14.5.
That sounds like that Rive is applying a fill to an otherwise transparant shape.
You could try clean the SVG files using a tool like https://svgomg.net/
What also helps is to check for any elements that you can remove using an application like Adobe Illustrator and make the vector image so that you can fill it with a single color.
I sometimes remove the 'fill' property in the .svg file using a text editor, so the application you import it in, can set it to any color.
If you send me one of your problematic .svg's I will have a look for you. I cannot reproduce the issue using my own .svg files; so Rive is probably not the issue:
Thanks for your reply. Attached is an SVG I am having trouble importing. I don't have issues with it other than importing into RIVE so I can't see a way to troubleshoot this from my end.
If you run it through the svgomg.net site to cleanup the svg syntax, you can import it just fine in Rive:
https://www.dropbox.com/scl/fi/olm187hf3k60dmoqdp9ck/4-SunshineYellow-01-2-optimized.svg?rlkey=tzf8l2mo55gczjirlh2tz6s60&dl=1
If you exported from Illustrator, you should be using "Inline Style" or "Presentation Attributes" in the SVG Options. Or, depending on the version of Illustrator you are using, you may try "Style Attributes". A few more details here: https://rive.app/community/doc/importing-assets/docO2hh4U88G#illustrator