raster web page

Comparing Large Bitmaps

Designers and Engineers working in mask or direct-write lithography often need to compare two large bitmaps to determine if changes to the software or flow have produced small but critical differences. For smaller bitmaps this is straightforward to do using tools such as Adobe Photoshop or various open source programs.

However once the size of our bitmaps increases (for example a bitmap of 100,000 by 100,000 pixels) these tools either take too long or are completely unable to process the data.

Artwork created this comparison software for our own use during development of high resolution rasterizers for lithography applications. Our customers have indicated that they also would like such a tool, so we have released it as a commercially available package.


rstrcmp does a bit by bit XOR on each pixel

rstrcmp does a bit by bit XOR to produce a 3rd image.


The inputs to rstrcmp are two bitmaps. The program supports:


A number of different outputs are available. These include bitmaps, vector data and a list of difference coordinates.

Unionizing Bitmaps

For use cases where one wants a vector output such as GDSII or Gerber, rstrcmp can unionize adjacent pixels into polygons. This results in a much smaller vector file than if each pixel were converted by itself into a tiny square.

Command Line Syntax

rstrcmp is controlled via the command line. The syntax is shown below:

rstrcmp.exe   input_1   input_2   output   [options]


full path and name of the executable
name/path of the first bitmap file
the name/path of the second bitmap file
Control and Configuration options
Logical Operations
Output Format
output compressed (packbits)tiff
output -bmp (uncompressed)
output lgraw format
output raw bitmap format
output GDSII stream; user may specify units and grid. If not specified units defaults to UM and grid to 0.001. (programmer please provide an example)
output RS274X Gerber; user may specify units of inch or mm.
Other Program Controls
suppresses union operation; use this option when output is bitmap only.
after computing the bitmap output, reverse the pixels from 0->1 and 1-->0 (programmer - does this work with vector output?)
sets pixels within the marging area to either 1 or 0. (programmer - need an example of this)
auto-find the best alignment value;(programmer this needs further explanation of what the parameters mean and do)
specify maximum difference allowed (% value); (programmer - please explain, I have no idea what this does)
specify output dpi
specify output width in pixels
specify a offset for input_1
specify a offset for input_2
specify sliver value for filtering out small differences.
specify number of threads to use for the comparison
enable logging and send results to the specified file name
run in silent mode

417 Ingalls St. Unit C, Santa Cruz, CA 95060 831.426.6163  email: info@artwork.com