Helped by https://davetang.org/muse/2019/02/22/importing-vector-images-into-r/
So the best workflow, I have is SVG to EPS (encapsulated post script) through illustrator
EPS to RGML through PostScriptTrace
In this way icons can be used in images in R using the grid package...
https://github.com/sjp/grConvert
The RGML format is specific to the grImport package. It is a very simple graphics format that describes an image in terms that the R graphics system can understand. It will be described in more detail in later sections. ... The RGML formatin this example is roughly a one-to-one translation of the PostScript code.16 Apr 2009
https://www.rdocumentation.org/packages/grImport/versions/0.9-1.1/topics/PostScriptTrace
grImport::PostScriptTrace()
works and is maintained....
Inkscape - could be used in the command line...
http://tavmjong.free.fr/INKSCAPE/MANUAL/html/CommandLine.html
XSLT for converting from one kind of XML to another
https://github.com/ropensci/xslt
This may just be too difficult but who knows...
Ghostscript
https://stackoverflow.com/questions/9793120/how-to-covert-svg-to-eps-in-ghostscript
Converting from SVG to EPS...
Not sure about this but might be interesting
https://github.com/akrinke/svg2cairo
https://cairosvg.org/
Python library...
No comments:
Post a Comment