Questions tagged [ghostscript.net]

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

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

Source code location: https://github.com/jhabjan/Ghostscript.NET

100 questions
0
votes
1 answer

Ghostscript adds whitespace no matter what bounding box I use

I'm trying to convert a page of a PDF to an image. I'm successful with most PDF's I've tried with but this one in particular always ends up with a lot of whitespace on one side or strange scaling. I've tried every combination of every fixed media,…
miapuffia
  • 31
  • 4
0
votes
0 answers

Ghostscript.Net error while opening stream

I'm using Ghostscript.Net (v1.2.3) to create images from PDF in my .NETCore (v3.1) web application. I'm trying to open the stream of the uploaded PDF file like this. for (int i = 0; i < request.Form.Files.Count; i++) { var file =…
Philiz
  • 429
  • 5
  • 25
0
votes
0 answers

Converting a PDF to text using GhostScript.net, I get an error trying to send the text to the anonymous pipe instead of the writing it to the disk

I am using Ghostscript to convert PDF files to text via the GhostScript.NET wrapper library. I was getting it to convert when writing the text to a file ("-sOutputFile=" + outputPipeHandle), but I'd rather write it to a stream ("-o" +…
Jonathan
  • 11
  • 5
0
votes
1 answer

MagicNET convert PDF to black and white (1bit) PNG

One of our customers need to convert PDF shipping labels to PNG images. The PDF images need to be 300 DPI and have a bit depth of 1 (pure black and white without grayscale). I have got this working but with some issues that i can not find any…
0
votes
0 answers

Does Ghostscript Display device rectangle_request work?

I am writing a little PDF-related app, thus I have chosen Ghostscript for the rendering purposes. I have taken gsdll64.dll from Ghostscript v9.54.0 into my project. The library starts up fine, but there is a quirk: it produces a memory access…
Vladislav Rishe
  • 691
  • 1
  • 6
  • 8
0
votes
1 answer

I am getting a errors: CS0116 A namspace cannot directly contain members such as fields or methods on Line 3

#nullable enable using System.Text; using Ghostscript.NET; using Ghostscript.NET.Processor; namespace Metro.MbaProcessing.Core { internal static class PdfToText { private const string HandleTag = "%handle%"; private const string…
Chris
  • 21
  • 1
  • 6
0
votes
1 answer

Ghostscript installation issue on .net

I followed a ton of SO guides in order to install Ghostscript in my MVC C# app but I cannot make the code below be recognized. It keeps saying "GhostscriptRasterizer could not be found (are you missing a using directive or an assembly…
newhouse-pt
  • 141
  • 2
  • 13
0
votes
1 answer

Printing PDF with Ghostscript.NET wrapper - Blank pages

I am printing a PDF file using the Ghostscript.NET wrapper. Printing is working fine but 2 blank pages appears before actual printing. Please can anyone help me? Am I doing anything wrong with following code? By the way, our printer is tiny and it…
mesha
  • 31
  • 5
0
votes
1 answer

How to generate proper PDF/A with embedding IIC profile using Ghostscript and Ghostscript .NET

Current scenario: I'm trying to generate proper and conformant PDF/A, based on normal PDF documents, and after spend some hours in investigation, we've decided to make use of Ghostscript capabilities. This bussiness requirement has been set for a…
Dave Miller
  • 536
  • 3
  • 19
0
votes
0 answers

Change DocumentName using Ghostscript

I have requirement of changing DocumentName that is being printed. This document name will display in printer spool. I am using Ghostscript c# wrapper to print PDF. It shows "Ghostscript output" in printer spool list. Ghostscript documentation…
Ashish Gehlot
  • 483
  • 8
  • 16
0
votes
2 answers

Can ghostscript.net divide a PDF file to multiple sections?

I have a very long PDF file (58x500 inches). The goal is to divide one large vector pdf file to a certain percentage. For example %25 = 125 inches in height while the width stay the same. So one large pdf will be divided into 4 pages. ImageMagick…
Lestrin
  • 3
  • 1
0
votes
1 answer

Ghostscript exports PNG but cuts half of the landscape page

I am trying to convert pdf to picture with Ghostscript. I have a landscape A3 PDF but no matter what I do, I only get the left half of every page.. I tried adding the -dPDFFitPage, -dFIXEDMEDIA, and other parameters but it didn’t seem to change…
0
votes
1 answer

What is the earliest version of GhostScript that is Windows 10 compatible?

What is the earliest version of Ghostscript that is compatible to run on Windows 10?
colin1804
  • 11
  • 1
0
votes
1 answer

Multiple Thread Run GhostScript.net With Error

i run two therad , each thread process it's pdf, and each thread thread has it's own GhostscriptProcessor, if i just start one thread there is no problem ,but if i start tow thread, gohstScript.net will give error "error occured when call…
steive
  • 11
  • 5
0
votes
1 answer

GhostScript.net not Recognize special character in fileName

private static string[] GetArgs(string inputFile, string outputFile) { return new[] { $"gs", $"-o", $"{outputFile}", $"-dNoOutputFonts", $"-sDEVICE=pdfwrite", $"{inputFile}", }; GhostscriptProcessor ghostscript = new…
steive
  • 11
  • 5