C# Ghostscript Wrapper

扶醉桌前 提交于 2019-12-07 05:45:21

问题


Has anyone encountered a nice wrapper for GhostScript in C#. My specific use is to take postscript and turn it into a pdf


回答1:


Open-source PDFSharp has a namespace for using GhostScript. Even if you can't directly use it, you can probably graft whatever you need out of the source.




回答2:


Matthew Ephraim has created a pretty simple C# wrapper called GhostScriptSharp that uses P/Invoke to access the unmanaged Ghostscript DLL in your C# application:

http://mattephraim.com/blog/2009/01/06/a-simple-c-wrapper-for-ghostscript/




回答3:


For completeness, there's also Gouda Ghostscript wrapper. You can also perform some ghostscript operations indirectly through imagemagick/graphicsmagick (they delegate to GS), so using a .NET library like GraphicsMagick.NET might be a good approach for you.

EDIT:

I just stumbled upon Ghostscript.NET as well. It claims to be

...the most completed managed wrapper library around the native Ghostscript library (32-bit & 64-bit), an interpreter for the PostScript language, PDF, related software and documentation

and among other features, allows you to run multiple Ghostscript instances simultaneously within a single process.



来源:https://stackoverflow.com/questions/1369681/c-sharp-ghostscript-wrapper

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!