JasonK
JasonK

Reputation: 361

How to convert a vector eps file to pdf?

I have a EPS file in vector format that I need to convert to PDF, retaining its vector format. I'm using a Windows 7 system, and I'm trying to find a tool that I can redistribute with my application. It can't be GUI or online based; I need my application to use it as a library or via a system call.

I have tried the following tools without success:

Of course, I'm not an expert with any of these tools listed so it's quite possible I'm just not running the tool with the correct configuration; if anyone recognizes a blank pdf as being a symptom of an incorrectly configured run with one of the tools, please let me know of possible fixes. Thank you for any help.

Here is the header of the eps file:

%!PS-Adobe-2.0 EPSF-1.2
%%Creator:Adobe Illustrator(TM) 1.1
%%For:OPS MANUAL FLOE
%%Title:ILLUS.MAC
%%CreationDate:7/27/87 3:40 PM
%%DocumentProcSets:Adobe_Illustrator_1.1 0 0
%%DocumentSuppliedProcSets:Adobe_Illustrator_1.1 0 0
%%DocumentFonts:Courier
%%+Helvetica
%%BoundingBox:000 -750 650 50
%%TemplateBox:288 -360 288 -360
%%EndComments
%%BeginProcSet:Adobe_Illustrator_1.1 0 0

Upvotes: 1

Views: 4934

Answers (1)

KenS
KenS

Reputation: 31199

The Bounding box says the marks extend from 0,-750 to 650, 50

So almost the entire content (750/800) is below the page. Note that Ghostscript ignores DSC comments, they are, after all, comments.

In order to position this on the page, you must translate the origin and potentially scale the page. Please note that EPS files are intended for inclusion in other documents, not for printing on their own, and its up to the document manager to read the BoundingVox comments and position the EPS correctly.

In the absence of a document manager, you will have to do this yourself. Note that changing the comments will have no effect at all.

I would suggest you start by prepending the line:

0 750 translate

which will move the origin 750 units vertically and so the page will then extend from 0,0 to 650,800 and see what effect that has.

Upvotes: 2

Related Questions