GBRUnion DLL Revision History

Summary of changes and fixes to each release of GBRUnion DLL.

Version 1.17d 2/16/2024

Bug fix to Boolean component acsbool64.dll

The built in error reporting system had a bug which was introduced on 29 January 2024 causing the program to crash. This has now been fixed.

Version 1.17c 02/13/2024

Improved circularization

Improve -circularize functionality.

  • When [circularize_chord_error] is absent, the minimum nonzero circular aperture diameter is compared against its default value and the smaller of the two is used.
  • The [circularize_chord_error] default when absent has been changed from 5um to 2um or its equivalent.
  • The minimum [arc segmentation chord error] allowed is 0.01um or its equivalent.
  • The [circularize_chord_error] is enforced to be eight time the arc segmentation chord error.
  • Updated Boolean Components

    The Boolean libraries used by GerberUnion have been updated to the most recent version.
    Updated the Gerber validation module.

    Version 1.17b 08/30/2023

    Updated Boolean Components

    The Boolean libraries used by GerberUnion have been updated to the most recent version.
    Updated the Gerber validation module.

    Version 1.17a 07/26/2023

    Updated Boolean Components

    The Boolean libraries used by GerberUnion have been updated to the most recent version.
    Updated the Gerber validation module.

    Version 1.17 03/17/2023

    Bug fix to ACS_Gbrunion_GetTile

    Updated to use latest boolean functions.
    Updated to allow for polygon formats other than Leonov.

    Added "-testtilefunc" argument to sample code

    Sample code was updated to test ACS_Gbrunion_GetTile. If "-testtilefunc" is invoked, it will generate four output files formed from windows that split the entire set of polygons into four quadrants of data.
    The test output is as follows:

           FILE NAME                         DESCRIPTION
           [output_base_name]_q1.[gbr|txt]   Upper Right Quadrant
           [output_base_name]_q2.[gbr|txt]   Upper Left Quadrant
           [output_base_name]_q3.[gbr|txt]   Lower Left Quadrant
           [output_base_name]_q4.[gbr|txt]   Lower Right Quadrant

    Version 1.16 03/14/2023

    Bug fix to -engargs

    There were arguments added by the library that should not have followed the "-engargs" argument when they should have preceded it. This has now been fixed.

    Update to -sizingvalue command line

    The -sizingvalue command line argument can now be used in the following ways:

    -sizingvalue:[value in x and y direction] 
    -sizingvalue:[value in x direction],[value in y direction]
    Note that unit specifiers are supported.

    Version 1.15e 09/14/2022

    The Boolean libraries have been updated to the most recent version.
    Updated the Gerber validation module.
    Reduced sleep time of the wrunbat module between program launches.

    Version 1.15d 06/21/2022

    Updated Boolean Components

    The Boolean libraries have been updated to the most recent version. Specifically, the speed of the boolean engine was improved when sizing is used.

    Version 1.15c 06/07/2022

    Boolean Components Updated

    The Boolean libraries used in this DLL have been updated to the current version.

    Version 1.15b 06/04/2022

    File name with Comma

    Fixed a problem when a file name or folder name had a comma. This problem manifested itself as a problem because comma is used as a delimiter in the job file (a dynamically created resource file) for the actual import of the Gerber data into various modules. If the path or base name contained one or more commas this would/could cause some confusion when reading the job file.

    Version 1.15a 03/11/2022

    Updated Boolean Engine

    New boolean engine with improved speed.

    Version 1.14 09/21/2021

    Fixed Polygon Assumption

    Bug Fix:Assuming Polygon Input is LEONOV when "skip_gdscompact" is invoked. If gdscompact is skipped, the input data comes from gbr2gdxb engine which does not produce LEONOV polygons. This incorrect assumption has now been fixed.

    For Input Files with > 1000 Layers, Skip GDSCompact

    The GDSCompact routine is skipped over when total Gerber layer count exceeds 1000. Why? Performance Issues?

    Job File Reading Speed Improved

    The job file read module was significantly sped up for files with large layer counts

    Updated Boolean Libraries

    The Boolean engine library used by GBRUnion has been updated to the most recent version.

    Updated Gerber Validation Module

    The module that validates the input Gerber file has been updated.

    Gerber Interpreter Updated

    The Gerber interpreter module has been updated to handle input files with very large layer counts. Prior to this update, input files wit >48,000 layers caused problems.

    Version 1.13a 6/29/2021

    Updated 32 bit version

    Updated the 32 bit release of GerberUnion library to be in sync with the 64 bit version.

    Passing arguments to the manager

    Both "gbrunmgr.exe" and "gbrunmgr64.exe" can be passed a set of arguments directly by using the following:

    -bgn_mgr_args [manager_args] -end_mgr_args
    The sample programs, "gbrunion_dynamic.exe" and "gbrunion_dynamic64.exe" have been adapted to use these arguments.

    Version 1.13 4/13/2021

    Fixed interpretation of X multiplication in Gerber Macro

    The 'x' multiplication operator was being supported but not the 'X'. This has now been fixed.

    Scaling large files over 2GB

    Scaling would fail and report error when some of the intermediate files were over 2GB. This has now been fixed.

    Version 1.12k 3/3/2021

    Software Updates
    Boolean and Gerber validation components have been updated.
    This version was compiled with VS2015. VS2008 is discontinued.

    Version 1.12j 2/9/2021

    Software Updates

    Boolean components were updated.

    Gerber validation components were updated.

    Merging stage (gdsfilt64.exe) input/output synchronization was fixed on Windows.

    Version 1.12i 1/20/2021

    Software Updates

    Boolean components were updated.

    Alter boolean flow for Manhattan sizing -manh and -dirtydata.

    Version 1.12h 12/20/2020

    Software Updates

    Fix for memory corruption when -dirtydata or -manh with non zero sizing was used. When these arguments are encountered, the boolean step is altered. This means that the intended boolean engine command line is processed and altered to become two command lines. The memory corruption occurred when an argument greater than 260 characters was encountered. This can happen when there are a large enough set of Gerber mass parameters, Layer Polarity Dark/Clear switches (i.e. %LPD*% and %LPC*).

    Version 1.12g 11/20/2020

    Software Updates

    Added "-dirtydata" argument and alter boolean flow for Manhattan sizing. If -dirtydata is present in gbrunmgr command line or manhattan sizing is found, the following will occur :
    (a) Data will be unionized separately in each layer.
    (b) It will be sized by 10 percent of target size.
    (c) Data will then be unionized sequentially.
    (d) It will be sized by target size minus 10 percent of target size.

    Version 1.12f 11/4/2020

    Software Updates

    New boolean flow for Manhattan sizing.

    Fix -macro_tol command line parsing.

    Update Gerber validation component and boolean components.

    Version 1.12e 10/19/2020

    Software Updates

    New "Mesh Adjust" command line option - This will slightly grow apertures to handle mesh hatches with edges that barely touch. Validation must be set in "Preferences" for this to work.

    Gerber union manager fix to -macro_tol argument parsing.

    Updated Gerber validation and boolean components.

    Version 1.12d 08/7/2020

    Software Updates

    This version fixes a problem parsing of -bgn_split_args.

    This version fixes a problem with the stage progress operation count. When scaling was invoked, this count was off. This problem was introduced in the command line parsing of (v1.87 01/16/2020 rcs 1.134).

    This version fixes a problem with -progstatcb:DLL_FIL_NAME.
    Check and report problem during Gerber validation caused the problem of default progress dialog appearing rather than callback dialog. Order of argument parsed needed to be changed. This has now been fixed.

    Version 1.12c 03/13/2020

    Software Updates

    This version fixes a problem with the Gerber Union interpreter when two point trace draws done on the same point and failing to draw correctly.

    Errors and warnings for processes are more informative.

    Invoke logging for gerber layer and aperture import.

    Call GDSFILT only when there are multiple input gerber files.

    Automatically stops execution when error is detected - If any program launched by Gerber Union returns an error code, Gerber Union will terminate itself.

    Version 1.12b 11/25/2019

    Software Updates

    This version is the same as 1.12a with the exception that 32 bit .LIB and .DLL were added for running the 32 bit gbrunion sample program (also added).
    In addition, VS2008 source example folders were added as well as batch files to the examples folder.

    Version 1.12a 11/21/2019

    Software Updates

    This version fixes an overlapping issue that occurred when exceeding max points or with manual partitioning.

    Enhancements have been added to boolean engine with respect to validation.

    Unionization has been improved to be nearly thread independent

    Version 1.12 64 bit 9/6/2019

    Added Gerber Output

    Added -gbr command line option to export Gerber from Gbrunion DLL64. This new option is also available in the sample code and the batch file in the examples folder.

    Software Updates

    Added support for embedding level. The sample code includes -emblevel as an example.
    In this version Cutline polygon format is the default.
    In this version Silent mode is the default.
    Remove 32 bit support.

    Version 1.11b 64 bit 10/11/2018

    Licensing Update

    Gbrunion DLL64 is now installed in a new folder (not in the 32 bit folder).
    Gbrunion DLL64 has its own product number.

    Version 1.11a 64 bit 10/9/2018

    Arc Segmentation in Sync with Arc Recovery and circularization

    Sizing values are taken into account when considering chord error to be used for, segmenting, arc recovery, and circularization. This is designed to preserve sized shapes and to optimally circularize them.

    Version 1.11 64 bit 9/24/2018

    New Support for Engine Arguments

    "split274x64.dll" -bgn_split_args [eng_args_1] -end_split_args

    "gdscomp64.exe" -bgn_gdscomp_args [eng_args_2] -end_gdscomp_args

    "boolw64.exe" -engargs [eng_args_3]

    [eng_args_x] refers to the set of arguments corresponding to a particular program.
    -engargs should always precede the last set of arguments on the commandline that are intended for boolw64.exe

    Invoke Arc Recovery When Large Sizing and Circularization is Used

    Arc recovery takes place before durung unionization. It is designed to remove jagged edges found in segmented sized curves soa as to permit circularization.

    Ported all EXE and DLL to 64 Bit VS2015

    Only the interface DLL is 32 / 64 bit. The sample program can be 32 / 64 bit and VS2008 / VS2015.

    Note: You will need to include the following redistributable packages:
    Microsoft Visual C++ 2015 Redistributable Package (x64)
    Microsoft Visual C++ 2015 Redistributable Package (x86)

    Version 1.10b 6/7/2018

    Deformed Circular Data

    Circular data of donut shape is drawn in two parts. One half was being drawn with the expected precision while the other was not. This has now been fixed.

    Software Updates

    Updated the boolean components in the release.
    Updated the gerber conditioning module.
    Gerber Union Manager now loads usage(64).dll dynamically.

    Version 1.10a 3/5/2018

    GerberUnion DXF Fix

    DXF layer base name was not being passed out. This has now been fixed.

    Mass Parameter Fix

    Split274x components were fixed to handle a problem with a file that included consecutive empty mass parameters.

    Version 1.10 2/17/2018

    Arc Recovery

    Not all data that should have been converted to circular was converted. This has now been fixed.

    Version 1.09 11/27/2017

    Arc resolution and Chord error fix

    When Gbrunion started using gbrunmgr.exe" instead of the integrated viewer model, "gbrvu.exe", the viewer failed to pass on the arcres and arcsag arguments to "gbrunmgr.exe". This has now been fixed..

    Multiple consecutive SR Mass Parameter Fix

    Multiple consecutive SR Mass Parameter are now handled properly and only the last SR parameter is taken into account.

    New circularization output

    New -circularize command line option can take a collection of vertices and produce an arc or even circle in the output file. Default is off

    Version 1.08 5/3/2017

    Licensing update

    Recompiled DLL for flexl tolerant capability - This allows validation to be retried for communication problem events.

    Adapted to use "split274x.dll"

    This allows updates to be done to the Gerber preprocessor without having to recompile executables dependent on its code.The current "split274x.dll" reflects the following:
    (a) More implied intelligence is applied with respect to G75 codes.
    (b) Bug fix for multiply defined dcodes higher than 40000.

    Version 1.07 11/20/2016

    Macro Tolerance

    Added -macro_tol:val[unit] to help identify similar RS274X AM MACROS.
    The tolerance value is used in the Gerber preconditioner, split274x, to map similar aperture macros into one. The default has always used 0.001 MM or 0.0004 Inches. This control is now provided to allow the user to specify the tolerance. The default is 0.001 MM or 0.00004 IN. The value must be no negative and no greater than 10 UM.

    Command line Change

    Replaced "-no_part" argument with -single_part argument in GBRUNION.
    The "-single_part" argument is made to run with one single partition window. This is functionally the same as enforcing that a single thread is applied to compacting and boolean operations. The absence of partition arguments, provided by "-no_part", used to do it, but multi threading, specified by the argument "-thrnum:number" or automatically detected, caused partitioning to happen anyway.

    Software Updates

    Updated Flexlm to version
    GDSII output in GerberUnion is safe guarded against circularize option.
    -no_joinpart command line argument was removed.
    Fixed a problem where arc traces with radii greater than width were segmented incorrectly.

    Version 1.06d 10/7/2016

    Gerber Union Updates

    When a butterfly figure interacts with something else it created a self touching polygon which was problematic for subsequent boolean operations.

    After union, some polygons with touching holes had very acute angles touching butting lines mistakenly, causing gaps in the data. This has been fixed.

    The text file passed to gbrunmgr's (-polywin:file command line option)" now accepts comma and tab characters in addition to space characters as delimiters for xy coordinates.

    Version 1.06c 9/22/2016

    Smoothing Issue

    Certain cases of smoothing and the amount of partitioning resulted in cracks appearing in the polygons generated by GerberUnion. This was because the partition edges were not being excluded from the smoothing.

    Version 1.06b 8/15/2016

    GBRUNION Manager Unit Problem

    Unit values on the command line carrying an exponent in their expression (for example 1.0e-005) were not handled properly. This has now been fixed.

    Version 1.06a 8/9/2016

    GBRUNION Manager Update

    Allow unit specification where unit can be INCH, MIL, CM, MM, or UM.
        This has been added for the following arguments:
        -xform:xform_parms    Set transformation settings (comma separated).
                        xform_parms is rotation_parms,mirror_parms,scale_parms,offset_parms
                        rotation_parms are anchor_x[unit],anchor_y[unit],rotation
                        mirror_parms are mirror_x,mirror_y
                        scale_parms are scale_x,scale_y
                        offset_parms are offset_x[unit],offset_y[unit]

    Version 1.06 5/20/2016

    -joinpart option

    Added support of -joinpart argument into library. This turns on data partition joining

    -overlapvalue option

    Added support of -overlapvalue:value argument into library. This Generates an overlap of value in butting mode. (use it with -polyformat:butting)

    Software Updates

    Added a usage dialog box into sample program, found in the bin sub folder, showing all available arguments that can be passed into library.

    Fixed usage box to display correct executable name.

    (5) The DLL manual has been updated to show the same information as the usage box displayed from the sample program.

    Version 1.05c 4/20/2016

    Revision to Gerber PreProcessor

    This is now applied all the time instead of conditionally as indicated below:

  • Format specified was too high.
  • Multiply defined apertures were detected.
  • High dcode value was detected.

  • Format is pushed to best precision during input processing. If Gerber data is in mm, data is converted to 5 places of precision before it's interpreted and unionized. Likewise, if data is is in inch, data is converted to 6 places of precision.

    Union components Updates

    Optimization has been applied for handling polygons with large vertex counts.
    Robustness has been improved by adding internal checks between steps.

    Version 1.05b 3/15/2016

    Missing contours

    Missing contours were discovered and fixed.

    Horizontal separation

    Horizontal separation of boundary removed.

    Version 1.05a 1/18/2016

    Boolean Sizing Bug

    Data was being dropped when sizing was used on a customer Gerber file. This has now been fixed.
    Convex partitioning for each polygon required using double comparison rather than rounded integer comparisons.

    Gerber Union Circularization speed improved

    Gerber Union circularization speed was improved by applying multithreading, and optimizing self touching check.

    Version 1.04 10/1/2015

    Program crash

    Circularize functionality improved. Unspecified circularize chord error uses 5 um equivalent by default.
    Usage is
    Where value is a user specified value in file units (MM or INCH).

    New Licensing

    Adopted new Flexlm license model, and no more support for disk serial number.

    Version 1.03a 09/10/2015

    Program crash

    Various components have been updated including the one concerning Gerber interpretation which caused a software crash.

    Version 1.03 04/16/2015

    Support new ACS Softkey Licensing

    All customers wishing to use ACS Softkey Licensing will require a uniform supplemental soft key kit, a customer vendor key file, and two static vendor files.

    Note to OEM: You should carry out the following instructions
    to properly compile and use the soft key license test program and the
    Gbrunion Dll test program.
    (a) You will receive an email with a link to download soft key kit.
    Install soft key kit after this installation.
    (b) This same email will contain a zip file.
    File Name Description Instructions
    --------- ----------- ------------
    vkf.txt Vendor Key File Place in [Installation_Directory]
    (Expires 04/15/2018)or wherever else desired, [VKF_Directory].
    acsvendor_s.lib 32 bit Softkey LibPlace in [Installation_Directory]\lib
    acsvendor64_s.lib 64 bit Softkey LibPlace in [Installation_Directory]\lib
    Follow instructions above for placement of three files mentioned above.
    (c) Open solution file in [Installation_Directory]/softkey_sample_vs2008
    using Microsoft Visual Studio 2008 and compile win32 and x64 target
    (d) Run softkeyshell.exe or softkeyshell64.exe in a similar manner as indicated below.
    "[Installation_Directory]\artwork\gbrunmgr.exe" [Program_Arguments] "-acsp:[VKF_Directory]\vkf.txt"
    Note that there is a solution file that creates a test program for Gbrunion DLL
    and the followingset of instructions, (e) and (f), correspond to this.
    (e) Open solution file, gbrunion_dynamic_oem.sln, in
    [Installation_Directory]/gbrunion_dll_sample_vs2008 using
    Microsoft Visual Studio 2008 and compile win32 and x64 target
    (f) Run run_dynamic_oem.bat or run_dynamic64_oem.bat to execute above Gbrunion DLL test programs
    (g) Read [Installation_Directory]\documentation\oem_readme.txt for more detailed instructions.

    Gerber Union Updates

  • Improved on circularize functionality
  • Added 64 bit "gbrunmgr64.exe" program to scan large file
  • Allow thread control, "-thrnum:[thread_count]", to affect flattened output.
  • Add "-gdscmpargs [ARGS] _END_GDSCOMP_ARGS_" argument setto gbrunmgr.exe.
    This appends arguments to the gdscomp engine which is responsible for unionizing Gerber SR data.
  • Allow any OEM licensed product...

    This version allows any OEM licensed product to do the following:

  • Output GDSII ASCII format.
  • Support licensing for existing output types, RS274, DXF,GDS, GDSII ASCII, and EGS, in gbrunmgr.exe

  • Version 1.02a 01/15/2015

    Support Files

    Batch files, benchmark files, and sample code has been changed to show one window run and one data extents window run. Tiling has been removed from sample code.

    Version 1.02 01/12/2015

    64 bit Gbrunion DLL (gbrunion64.dll) has been added

    64 bit Windows OS is checked for, and if found, 64 bit executables are used to execute the following:

  • Gerber scanning - gbrunmgr64.exe
  • Gerber interpretation - gbr2gdxb64.exe
  • Gerber SR optimization - gdscompact64.exe
  • unionization - boolw64f.exe
  • New Installation

    Install Shield 2014 is used.

    New Directory Structure

  • artwork - contains gbrunion.dll (32 bit), gbrunion64.dll (64 bit) and all supporting exe's and dll's for the gbrunion dll's

  • bin - contains sample exe's which are:
    gbrunion_dynamic.exe (32 bit)
    gbrunion_dynamic64.exe (64 bit) and their backups
    gbrunion_dynamic_orig.exe (32 bit)
    gbrunion_dynamic64_orig.exe (64 bit)

  • documentation - text file with usage for sample executables

  • examples - Contains input file, two batch files, and benchmark files. Batch files are:
    run_dynamic.bat - test for 32 bit sample and dll.
    run_dynamic64.bat - test for 64 bit sample and dll.

  • gbrunion_dll_sample_vs2008 - Contains sample code and Visual 2008 solution file to produce either 32 or 64 bit executables into the bin folder

  • include - Contains header files required for compiling programs using Gbrunion DLL

  • lib - Contains gbrunion.lib and gbrunion64.lib files for 32 or 64 bit static builds should anyone wish it. The library and sample code rely on _ACS_GBRUNION_STATIC_LINK_ compiler directive for this.

  • Version 1.01 05/04/2012

    Add Extents information to ACS_GBRUNION_FileInfo Data Structure

    By calling ACS_Gbrunion_GetFileInfo, a user can extract the data extents of the input Gerber file in the units of that same file.
    The new data structure field is shown below.

    typedef struct
      char   libname[_MAX_PATH];  - internal name generated from opening input Gerber file
      char   unit[32];            - units of input Gerber file
      int    igrid;               - integer grid of input Gerber file
      double dataexts[4];         - extents of loaded data <------ >>>>> New data field <<<<<<
    } ACS_GBRUNION_FileInfo;

    Add ACS_Gbrunion_GetTile Function

    int ACS_Gbrunion_GetTile ACS_Gbrunion_GetTile(double *window, ACS_GBRUNION_Polygon **ppolylist, int *ppolycnt);
    Generates a list of unionized polygons clipped to a specified window
    and returns a list of polygons. May only be called after ACS_Gbrunion_Open.
    double *window                   -  clipping window extents in units
                                         of input Gerber data.
                                         (minx, miny, maxx, maxy)
    ACS_GBRUNION_Polygon **ppolylist -  returned list of polygons which may or
                                         may not contain holes.
    int *ppolycnt                    - returned polygon count
    0       : success
    nonzero : failure

    Allow for Dynamic linking in addition to static linking

    Static linking requires:

  • _ACS_GBRUNION_STATIC_LINK_ compiler directive
  • gbrunion.lib to be linked in

  • Dynamic linking is default and requires the following:
  • First call ACS_GBRUNION_LoadGbrUnion( [DLL_NAME] ) to use ibrary - [DLL_NAME] must be full path name
  • Second Call ACS_GBRUNION_ErrorLoadingGbrUnion() for any errors detected during call of ACS_GBRUNION_LoadGbrUnion(...). (0 : success , nonzero : failure) This does not work with ACS_Gbrunion_GetErrCode.
  • Finally Call ACS_GBRUNION_FreeGbrUnion() when done using library.

  • Notes:
    The directory gbrunion_dll_sample_vc6 now contains two projectsinstead of one:
    gbrunion_dynamic.dsw - which compiles a sample program that dynamically loads gbrunion.dll from a different directory. The program name is gbrunion_dynamic.exe
    gbrunion_static.dsw - which compiles a sample program that is statically linked to gbrunion.lib forcing it to run in the same directory as gbrnion.dll. The program name is gbrunion_static.exe.

    There is a folder called dynamic which has one executable calledgbrunion_dynamic.exe. The Install_Directory now contains gbrnion_static.exe instead of gbrunion.exe.

    The Install_Directory/examples folder now contains two batch files instead of one:
    run_dynamic.bat - tests gbrunion_dynamic.exe
    run_static.bat - tests gbrunion_static.exe

    Version 1.00 04/25/2012

    Initial Release

    This is the initial release of the DLL.