xmlgraphics-batik-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From DeWeese Thomas <thomas.dewe...@gmail.com>
Subject Re: Barcodes in SVG
Date Sat, 22 Sep 2012 11:28:00 GMT
Hi Robert,
	You should try adding style="image-rendering:optimizeSpeed" to the image elements (you can
put it in the templates probably).  That should disable the anti-aliasing when resizing the
barcodes.

	Thomas

On Sep 21, 2012, at 11:00 AM, Robert Jenks <rjenks@animefest.org> wrote:

> I am currently using Batik as part of a workflow to print badges for a convention.  
I have a java desktop application which:
> polls a web server for badges to print
> retrieves the data (type, template name, person's name, id, etc...)
> loads an appropriate SVG template
> Uses ZXing to generate a code-128 barcode and an QR code
> Loads the appropriate picture for the badge
> converts the barcode and picture PNGs into data: urls
> find the appropriate elements in the svg dom and replaces the dummy images with the picture
and barcode data: urls
> sets the batik transcoder output resolution
> rasterizes the svg to a png file
> sends the png to a photo printer
> The problem I am having is that resulting badge png has artifacts in the barcodes.  They're
either antialiasing or scaling artifacts.  This makes the barcode a little hard to scan with
readers and slowed down our registration system.  Does anyone have any suggestions on how
I can keep the barcode images as crisp black and white images inside the full color badge?
> 
> Thanks,
> Robert


Mime
View raw message