Sample Application for GBRUnion LIB

Artwork provides a sample application, gbrunion_dynamic.exe, which illustrates how to use the library. We provide source code and project files for this sample app so that an OEM programmer can study it to see how to effectively use the library.

Command Line Syntax

gbrunion_dynamic.exe <input_gbr> [options]

options :

DLL API Options:

-wdir:<dir>                      Specify working directory. 
                                 (default: current working directory)

-arcres:<degrees>                Specify arc resolution in degrees. (default:9.0)

-arcsag:<value>                  Specify chord error in Gerber input units.
                                 (default: 0.0)

-thrnum:<n>                      Specify the number of threads to be used.

-polyformat:<fmt>                Specify polygon format where  can be.
				                 (1) leonov
				                 (2) cutlines
				                 (3) butting

-reversal:<marginx,marginy>      Specify image reversal.
                                 marginx increases background on leftt and right.
                                 marginy does it on top and bottom.
                                 Do not use with leonov polyformat.

-sizingvalue:<value>             Grow data by positive <value>.
                                 Shrink data by negative <value>.

-slivervalue:<value>             Remove data narrower than <value>

-maxpoints:<vertex_num>          Limit polygon vertex count to <vnum>.
                                 Do not use with leonov polyformat.

-outscale:<value>                Scale output data by <value>.

-overlapvalue:<value>            This Generates an overlap of value in butting mode - use it with -polyformat:butting

-joinpart                        Turns on data partition joining.

-useotherunits:<INCH|MIL|CM|MM|UM>    Specify output unit.
                                      (default: <Input_Gerber_Unit>).

-window:<xmin,ymin,xmax,ymax>         Clip data to specified window.
                                      If not specified, the entire data file is
                                      processed.


Test Program Options:

-dll:<dll_filename>              Specify Gerber Union DLL where <dll_filename> 
                                 is its full name.

-o:<output_txt>                  Specify output file of Test Program.

-useProgressCB                   Use callback function for progress display.





Command Line Examples

We want to convert a file called icsxseed.gbr into ascii using Leonov style polygons. The window we wish to extract goes from 5,5 to 6,6 (i.e about an inch square from a larger board)

Carriage returns have been inserted only for clarity. Comments are in italics.


"C:\WCAD\Gbrunion DLL\bin\gbrunion_dynamic.exe"           starts the calling application

"C:\WCAD\Gbrunion DLL\examples\icsxseed.gbr"              input file to process

"-dll:C:\WCAD\Gbrunion DLL\artwork\gbrunion.dll"          points to the location of the library

"-wdir:C:\WCAD\Gbrunion DLL\examples\work"                working directory is defined

"-o:C:\WCAD\Gbrunion DLL\examples\out\icsxseed_win.txt"   output file location and name

-thrnum:1                                                 number of concurrent threads

-useProgressCB                                            tells the app to use a callback for progress

-polyformat:1                                             tells the program to create Leonov polys

-window:5,5,6,6                                           extract this window: LLx,LLy,URx,URy




Download Functions Example Flow Polygon Data Structure Price Revision History


ARTWORK CONVERSION SOFTWARE, INC.                  Company Profile
417 Ingalls St.,     Santa Cruz, CA 95060         Tel (831) 426-6163     Fax 426-2824               email: info@artwork.com