5
$\begingroup$

I‘m looking for a way to import vector graphics, which have been created with Adobe software like Photoshop or Indesign, into Mathematica.

While exporting vector graphics from Mathematica supports various formats, looking at $ImportFormats only allows .EPS (or am I missing a format?). However, the documentation states

"Import and Export generally create PostScript level 2 files, and include certain level 3 features if appropriate.",

all my attempts to import EPS 3 files failed. Unfortunately, EPS 2 can't be created (or converted to) by any of the recent Adobe software or web based converters.

Is there a (different) way to convert or directly import a commonly used vector graphics format into Mathematica?

$\endgroup$
0

2 Answers 2

5
$\begingroup$

Convert the graphics to PDF and import that. Mathematica supports PDFs.

If the result is not good, try simplifying the PDF with various tools, and converting to earlier PDF specifications (1.3). Also try outlining fonts. Acrobat, Ghostscript and mupdf are useful.

I have imported Illustrator-produced PDFs multiple times.

$\endgroup$
3
$\begingroup$

Actually recent versions of Illustrator can create Level 2 EPS. As can be seen from the screenshot below, Illustrator 17 by default writes Level 2 EPS (I have also selected "Illustrator 3 EPS" for better compatibility with Mathematica's importer):

screenshot

I have successfully imported EPS generated this way into Mathematica. But in general it is better to save as PDF for this purpose.


Also you can use Poppler for converting Level 3 files to Level 2 as I show in this answer.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.