All of lore.kernel.org
 help / color / mirror / Atom feed
* [Printing-architecture] better support for 203dpi label printer
@ 2016-08-12 11:13 YaoCL
  2016-08-12 13:47 ` Till Kamppeter
  0 siblings, 1 reply; 5+ messages in thread
From: YaoCL @ 2016-08-12 11:13 UTC (permalink / raw)
  To: printing-architecture

Hi

CUPS support 203dpi label printer, when print from pdf to label printer, cups use gstoraster to rasterlizing pdf.
as discussed in <http://bugs.ghostscript.com/show_bug.cgi?id=696758> due to low resolution of 203dpi and any-part-of-pixel rule,
the produced barcode may scannable. Ghostscript has a operator to control center-of-pixel rule  or any-part-of-pixel rule, which is `0 .setfilladjust`.
I tested a pdf with and without this operator, and checked the result raster files. with this operator the barcode is more accurate.

Can we add a option to enable or disable this adjustment?

—
YaoCL

^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [Printing-architecture] better support for 203dpi label printer
  2016-08-12 11:13 [Printing-architecture] better support for 203dpi label printer YaoCL
@ 2016-08-12 13:47 ` Till Kamppeter
  2016-08-12 17:13   ` James Cloos
  0 siblings, 1 reply; 5+ messages in thread
From: Till Kamppeter @ 2016-08-12 13:47 UTC (permalink / raw)
  To: printing-architecture

On 08/12/2016 08:13 AM, YaoCL wrote:
> Hi
>
> CUPS support 203dpi label printer, when print from pdf to label printer, cups use gstoraster to rasterlizing pdf.
> as discussed in <http://bugs.ghostscript.com/show_bug.cgi?id=696758> due to low resolution of 203dpi and any-part-of-pixel rule,
> the produced barcode may scannable. Ghostscript has a operator to control center-of-pixel rule  or any-part-of-pixel rule, which is `0 .setfilladjust`.
> I tested a pdf with and without this operator, and checked the result raster files. with this operator the barcode is more accurate.
>
> Can we add a option to enable or disable this adjustment?

It is no problem if you can tell me how you exactly apply this 
parameter, like Ghostscript command line for example. Especially I need 
to know how to do it in the gstoraster filter (patch) and in a way that 
it also works with PDF input files (apps send PDF by default, non-PDF is 
converted to PDF by CUPS/cups-filters).

Best is to post a feature request on

https://bugs.linuxfoundation.org/

Product OpenPrinting, component cups-filters.

with all this info and the link to the Ghostscript bug report.

Thanks.

    Till



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [Printing-architecture] better support for 203dpi label printer
  2016-08-12 13:47 ` Till Kamppeter
@ 2016-08-12 17:13   ` James Cloos
  2016-08-12 23:27     ` YaoCL
  0 siblings, 1 reply; 5+ messages in thread
From: James Cloos @ 2016-08-12 17:13 UTC (permalink / raw)
  To: Till Kamppeter; +Cc: printing-architecture

Adding 0 .setfilladjust to a postscript job should be done just like how
the ps2ps filter adds snippets from ppd files.

For rendering pdf w/ gs, I'd expect:

    -c '0 .setfilladjust'

is required.  Yes?

-JimC
-- 
James Cloos <cloos@jhcloos.com>         OpenPGP: 0x997A9F17ED7DAEA6



^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [Printing-architecture] better support for 203dpi label printer
  2016-08-12 17:13   ` James Cloos
@ 2016-08-12 23:27     ` YaoCL
  2016-08-13  0:04       ` Till Kamppeter
  0 siblings, 1 reply; 5+ messages in thread
From: YaoCL @ 2016-08-12 23:27 UTC (permalink / raw)
  To: printing-architecture


> 在 2016年8月13日,上午1:13,James Cloos <cloos@jhcloos.com> 写道:
> 
> Adding 0 .setfilladjust to a postscript job should be done just like how
> the ps2ps filter adds snippets from ppd files.
> 
> For rendering pdf w/ gs, I'd expect:
> 
>    -c '0 .setfilladjust'
> 
> is required.  Yes?

Yes, append this to gs command line is required. I tested with this method.
I created a pdf with 0.125mm width parallel lines, render in 203.2 dpi, with `-c ‘0 .setfilladjust’`
It generate perfect result. 0.125mm is dot size in 203.2 dpi. 

—
YaoCL


^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [Printing-architecture] better support for 203dpi label printer
  2016-08-12 23:27     ` YaoCL
@ 2016-08-13  0:04       ` Till Kamppeter
  0 siblings, 0 replies; 5+ messages in thread
From: Till Kamppeter @ 2016-08-13  0:04 UTC (permalink / raw)
  To: printing-architecture

On 08/12/2016 08:27 PM, YaoCL wrote:
>
>> 在 2016年8月13日,上午1:13,James Cloos <cloos@jhcloos.com> 写道:
>>
>> Adding 0 .setfilladjust to a postscript job should be done just like how
>> the ps2ps filter adds snippets from ppd files.
>>
>> For rendering pdf w/ gs, I'd expect:
>>
>>    -c '0 .setfilladjust'
>>
>> is required.  Yes?
>
> Yes, append this to gs command line is required. I tested with this method.
> I created a pdf with 0.125mm width parallel lines, render in 203.2 dpi, with `-c ‘0 .setfilladjust’`
> It generate perfect result. 0.125mm is dot size in 203.2 dpi.

Will we also have to make sure that CUPS, cups-filters, and Ghostscript 
use always floating point numbers for dpi resolutions?

    Till



^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2016-08-13  0:04 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-08-12 11:13 [Printing-architecture] better support for 203dpi label printer YaoCL
2016-08-12 13:47 ` Till Kamppeter
2016-08-12 17:13   ` James Cloos
2016-08-12 23:27     ` YaoCL
2016-08-13  0:04       ` Till Kamppeter

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.