thoward / gouda Goto Github PK
View Code? Open in Web Editor NEWGouda is a .NET wrapper for Ghostscript
License: MIT License
Gouda is a .NET wrapper for Ghostscript
License: MIT License
What steps will reproduce the problem?
1. From a ASPX C# code-behind page, call the GS API using roughly the same
code as in Program.cs in the GoudaTestAppCLI project:
IntPtr instance = new IntPtr();
lock (Ghostscript.syncroot)
{
try
{
int result = Ghostscript.NewInstance(out instance,
IntPtr.Zero);
if (result == 0)
{
ConsoleStdioHandler hand = new ConsoleStdioHandler();
Ghostscript.SetStdio(instance, hand.StdInCallBack,
hand.StdOutCallBack, hand.StdErrCallBack);
int init = Ghostscript.InitWithArgs(instance,
args.Length, args);
Ghostscript.Exit(instance);
}
}
finally
{
Ghostscript.DeleteInstance(instance);
}
}
I'm using the following args to convert an EPS to JPG:
"-q",
"-dQUIET",
"-dSAFER",
"-dBATCH",
"-dNOPAUSE",
"-dNOPROMPT",
"-dMaxBitmap=500000000",
"-dFirstPage=1"
"-dLastPage=1"
"-sDEVICE=jpeg",
"-dJPEGQ=80"
"-dEPSCrop",
"-dAlignToPixels=0",
"-dGridFitTT=0",
"-dTextAlphaBits=4",
"-dGraphicsAlphaBits=4",
"-r300x300"
"-sOutputFile=C:\\temp\\out.jpg"
"C:\\temp\\in.eps"
2. Try to delete the output file afterwards using
File.Delete("C:\\temp\\out.jpg") -> throws an exception that the file is in
use.
What is the expected output? What do you see instead?
I expect that the GS DLL releases the output file after exiting but the
file remains locked.
What version of the product are you using? On what operating system?
Most recent trunk checkout (2009-09-27) i.c.w. GS 8.70. Also tested 8.60
and 8.63, neither work.
Please provide any additional information below.
-
Original issue reported on code.google.com by [email protected]
on 27 Sep 2009 at 9:08
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.