Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.sys.acorn.programmer > #6147 > unrolled thread
| Started by | "Rob Hemmings (News)" <rhnews@dsl.pipex.com> |
|---|---|
| First post | 2020-06-10 14:50 +0100 |
| Last post | 2020-06-10 19:04 +0100 |
| Articles | 3 — 2 participants |
Back to article view | Back to comp.sys.acorn.programmer
Odd results from GhostScript "Rob Hemmings (News)" <rhnews@dsl.pipex.com> - 2020-06-10 14:50 +0100
Re: Odd results from GhostScript Theo <theom+news@chiark.greenend.org.uk> - 2020-06-10 17:57 +0100
Re: Odd results from GhostScript "Rob Hemmings (News)" <rhnews@dsl.pipex.com> - 2020-06-10 19:04 +0100
| From | "Rob Hemmings (News)" <rhnews@dsl.pipex.com> |
|---|---|
| Date | 2020-06-10 14:50 +0100 |
| Subject | Odd results from GhostScript |
| Message-ID | <587e72e8f9rhnews@dsl.pipex.com> |
I've been playing with GhostScript (version 9.26) on RISC OS as I was intending to write a RISC OS front end to calculate printing costs and I need to use GhostScript to give an estimation of the amount of each colour of ink needed to print a (pdf) file. However, I'm getting some strange results and would appreciate any ideas or suggestions. I'm using the GhostScript device of ink_cov to do the calculation. An actual command line that demonstrates the issue is: gs -o - -sDEVICE=ink_cov inputfile (where I replace "inputfile" with the name of the file I am trying to analyse) I'm using version 9.2 of GhostScript on Windows and that is producing consistent results with any type of pdf file. On RISC OS I get a believable result if I use a pdf file that has been created on Windows with colour in CMYK format although a little oddly the results are slightly different from those produced on Windows with the same file which I would have expected to be the same. However, much more of a problem on RISC OS is that with a pdf file that has not been created in CMYK colour it reports exactly the same (incorrect) figure for each ink instead of giving the correct proportions. Running GhostScript on the same file on Windows gives a correct result with the usage of each ink being different. Can anyone suggest what might be going on? -- ------------------------------------------------------------- Rob Hemmings Southport rhnews@dsl.pipex.com
[toc] | [next] | [standalone]
| From | Theo <theom+news@chiark.greenend.org.uk> |
|---|---|
| Date | 2020-06-10 17:57 +0100 |
| Message-ID | <l9u*5qeUx@news.chiark.greenend.org.uk> |
| In reply to | #6147 |
"Rob Hemmings (News)" <rhnews@dsl.pipex.com> wrote: > I'm using version 9.2 of GhostScript on Windows and that is producing > consistent results with any type of pdf file. On RISC OS I get a > believable result if I use a pdf file that has been created on Windows > with colour in CMYK format although a little oddly the results are > slightly different from those produced on Windows with the same file > which I would have expected to be the same. > > However, much more of a problem on RISC OS is that with a pdf file that > has not been created in CMYK colour it reports exactly the same > (incorrect) figure for each ink instead of giving the correct > proportions. Running GhostScript on the same file on Windows gives a > correct result with the usage of each ink being different. Can anyone > suggest what might be going on? > How strange. It appears there are two devices, 'ink_cov' and 'inkcov' which follow different code paths: https://github.com/ArtifexSoftware/ghostpdl/blob/master/devices/gdevicov.c Are you sure you're using the same one? Also, are you sure the DPI is the same (default is 75 dpi) and not getting set by some config file maybe? Otherwise I'm wondering if there's some undefined behaviour in there somewhere, but I can't see anything obvious... Theo
[toc] | [prev] | [next] | [standalone]
| From | "Rob Hemmings (News)" <rhnews@dsl.pipex.com> |
|---|---|
| Date | 2020-06-10 19:04 +0100 |
| Message-ID | <587e8a2dferhnews@dsl.pipex.com> |
| In reply to | #6148 |
In article <l9u*5qeUx@news.chiark.greenend.org.uk>, Theo <theom+news@chiark.greenend.org.uk> wrote: > "Rob Hemmings (News)" <rhnews@dsl.pipex.com> wrote: > > I'm using version 9.2 of GhostScript on Windows and that is producing > > consistent results with any type of pdf file. On RISC OS I get a > > believable result if I use a pdf file that has been created on Windows > > with colour in CMYK format although a little oddly the results are > > slightly different from those produced on Windows with the same file > > which I would have expected to be the same. > > > > However, much more of a problem on RISC OS is that with a pdf file > > that has not been created in CMYK colour it reports exactly the same > > (incorrect) figure for each ink instead of giving the correct > > proportions. Running GhostScript on the same file on Windows gives a > > correct result with the usage of each ink being different. Can > > anyone suggest what might be going on? > > > How strange. It appears there are two devices, 'ink_cov' and 'inkcov' > which follow different code paths: > https://github.com/ArtifexSoftware/ghostpdl/blob/master/devices/gdevicov.c > Are you sure you're using the same one? Also, are you sure the DPI is > the same (default is 75 dpi) and not getting set by some config file > maybe? > Otherwise I'm wondering if there's some undefined behaviour in there > somewhere, but I can't see anything obvious... > Theo Hi Theo, thanks for the thoughts. I'm definitely using ink_cov as inkcov does not report on ink usage but on which areas of the page include an ink (i.e. it takes no notice of density). That confused me quite a bit to begin with as the documentation for them is fairly thin. I hadn't thought about DPI but as far as I know I've done nothing to affect that as I've just tried running exactly the same command on the same file on both platforms, admittedly with a slightly different version number of GhostScript. I suppose it is possible that could affect the first issue I've mentioned above. However, I don't see how altering DPI surely could not make all ink coverage values the same when they are clearly not if you look at the document. -- ------------------------------------------------------------- Rob Hemmings Southport rhnews@dsl.pipex.com
[toc] | [prev] | [standalone]
Back to top | Article view | comp.sys.acorn.programmer
csiph-web