corysimmons
corysimmons

Reputation: 7675

Convert .ai to SVG on upload

I want users to be able to upload .ai files but to use them in the t-shirt editor I'm working on, they'll need to be <svg> elements. I know Inkscape offers this ability with --export-plain-svg but I'm having problems getting Inkscape to work with Heroku.

Are there other tools out there for converting .ai to SVG on upload?

To be incredibly specific, we're setting this t-shirt designer up in Rails, so it'd be extra cool if this tool was Ruby or JavaScript based.

Upvotes: 1

Views: 1940

Answers (2)

corysimmons
corysimmons

Reputation: 7675

You can upload .ai files that are saved with PDF-editing capabilities with this Ruby Gem: https://github.com/Bluejade/PrawnVectorImport

I also noticed you can simply change the extension on these PDF enabled .ai's to .pdf and they'll open with your artwork. So maybe you don't need the Gem at all?

There are a couple defunct libraries written in Perl (and ported to Python) that I couldn't get working, but if you can get them working, they seem to address older versions of .ai...

If anyone else has any luck with this, please post your results.

Upvotes: 0

Max
Max

Reputation: 1478

I think you would be smart to move off Heroku if ai support is a hard requirement. Perhaps deploy your app on AWS-EC2 (Which heroku uses internally) and install Inkscape on there. The time you will spend fighting Herokus limitations could be better spent on development. Plus it is cheaper. When you have a well-automated deployment process the easy of use should be almost the same. Take a look at Capistrano (http://capistranorb.com) in these regards.

Upvotes: 1

Related Questions