ODB to GDSII Web page header

acs_odb.h

Header file shipped with odb2gds64 v3.10


#if(!defined(_acs_odb_h_))
#define _acs_odb_h_

#include "acs_odb_structs.h"

/****************************************************************
 ** openODB - Initializes the ODB internal database.
 ** odbName     - name of the odb (compressed file or path to uncompressed odb job dir)
 ** workingDir  - if not NULL and is a valid path this will be set as the working dir. 
 **             - if NULL or invalid, the working dir will be set to the value of the
 **               TEMP, TMP or TMPDIR env vars (whichever is found first in their respective order)
 **             - if the working_dir cannot be set, this function will fail.
 ** odbInitPtr  - reserved param, its elements are: ExecPath, argc, argv
 **               - ExecPath: the executable path
 **               - argc:     number of additional arguments
 **               - argv:     list of additional arguments. The possible additional args are:
 **                             -dbg                          :to enable debugging
 **                             -log[:<log fullpath>]         :to enable logging (default)
 **                             -nolog                        :to disable logging
 **                             -keep_tmpfiles                :to keep intermmediate files
 **                             -non_std                      :to evaluate system defined attr
 **                             -nosropt                      :to disable Step-Repeat optimization
 **                             -nocopyin                     :to use/modify the ODB++ as is (must be writeable)
 **                             -netex                        :to read ODB++ nets
 **                             -userattr                     :to read ODB++ user attributes
 **                             -show_progress                :to enable progress dialog
 **                             -thrnum:<thrnum_int_val>      :to set the max thread
 ** 
 ** Return: 0 if successful and 1 if failed 
 ****************************************************************/
int ACS_openODB(char * odbName, char * workingDir, struct ODB_InputParam * odbInitPtr);



/****************************************************************
 ** getODBOutputDir - Returns the output directory.
 **
 ** Return: the full path of the output directory or NULL if it failed
 ****************************************************************/
char * ACS_getODBOutputDir();



/****************************************************************
 ** getODBWorkingDir - Returns the working directory.
 **
 ** Return: the full path of the working directory or NULL if it failed
 ****************************************************************/
char * ACS_getODBWorkingDir();



/****************************************************************
 ** getODBLastErr - Returns the last error encountered.
 **
 ** Return: the last error message encountered or NULL if there is none
 **         - errCode will be set to the last encountered error code or 0 if there is none
 ****************************************************************/
char * ACS_getODBLastErr(int * errCode);



/****************************************************************
 ** getODBStepCount - Returns the number of steps in the ODB.
 **
 ** Return: the number of steps in the ODB or -1 if it failed
 ****************************************************************/
int ACS_getODBStepCount();



/****************************************************************
 ** getODBStepInfoList - Returns a list of all the steps in the ODB.
 **
 ** Return: 0 if successful and 1 if failed
 **         - stepList[0] will be set to the first array element in stepList
 **         - stepCount will be set to the number of steps in stepList
 **
 ** USER NOTE: stepList must be freed after it is no longer needed
 ****************************************************************/
int ACS_getODBStepInfoList(struct ODB_StepInfo ** stepList, int * stepCount);



/****************************************************************
 ** freeODBStepInfoList - Frees the list of all the steps in the ODB
 **                       allocated by getODBStepInfoList.
 ****************************************************************/
void ACS_freeODBStepInfoList(struct ODB_StepInfo * stepList, int stepCount);



/****************************************************************
 ** getODBTopStepListName - Returns the list of the top steps.
 **
 ** Return: 0 if successful and 1 if failed
 **         - topStepList will be set to the list of the top steps names
 **         - numTopStepList will be set to the number of top steps
 ****************************************************************/
int ACS_getODBTopStepListName(char *** topStepList, int * numTopStepList);



/****************************************************************
 ** getODBTopStepListIndex - Returns the list of the top steps.
 **
 ** Return: 0 if successful and 1 if failed
 **         - topStepList will be set to the list of the top steps index
 **         - numTopStepList will be set to the number of top steps
 ****************************************************************/
int ACS_getODBTopStepListIndex(int ** topStepList, int * numTopStepList);



/****************************************************************
 ** getODBMostLikelyTopStepName - Returns the name of the top step.
 **
 ** Return: the step name or NULL if it failed 
 ****************************************************************/
char * ACS_getODBMostLikelyTopStepName();



/****************************************************************
 ** getODBMostLikelyTopStepIndex - Returns the index of the top step.
 **
 ** Return: the step's index in stepList or -1 if it failed
 ****************************************************************/
int ACS_getODBMostLikelyTopStepIndex();



/****************************************************************
 ** getODBStepName - Returns the name of the specified step.
 ** stepIdx     - step's index in stepList (starts with 0)
 **
 ** Return: the step name or NULL if it failed 
 ****************************************************************/
char * ACS_getODBStepName(int stepIdx);



/****************************************************************
 ** getODBStepIndex - Returns the index of the specified step.
 ** stepName    - step's name
 **
 ** Return: the step's index in stepList or -1 if it failed
 ****************************************************************/
int ACS_getODBStepIndex(char * stepName);



/****************************************************************
 ** getODBStepNameProfileExtent - Returns the profile's extent of the specified step.
 ** stepName   - step's name
 ** 
 ** Return: 0 if successful and 1 if failed
 **         - extent will be set to step's profile extent value (minx,miny,maxx,maxy)
 ****************************************************************/
int ACS_getODBStepNameProfileExtent(char * stepName, double * extent);



/****************************************************************
 ** getODBStepIdxProfileExtent - Returns the profile's extent of the specified step.
 ** stepIdx     - step's index in stepList (starts with 0)
 ** 
 ** Return: 0 if successful and 1 if failed
 **         - extent will be set to step's profile extent value (minx,miny,maxx,maxy)
 ****************************************************************/
int ACS_getODBStepIdxProfileExtent(int stepIdx, double * extent);



/****************************************************************
 ** getODBLayerCount - Returns the number of layers in the ODB.
 **
 ** Return: the number of layers in the ODB
 ****************************************************************/
int ACS_getODBLayerCount();



/****************************************************************
 ** getODBLayerInfoList - Returns a list of all the layers in the ODB.
 **
 ** Return: 0 if successful and 1 if failed
 **         - layerList[0] will be set to the first array element in layerList
 **         - layerCount will be set to the number of layers in layerList
 **
 ** USER NOTE: layerList must be freed after it is no longer needed
 ****************************************************************/
int ACS_getODBLayerInfoList(struct ODB_LayerInfo ** layerList, int * layerCount);



/****************************************************************
 ** freeODBLayerInfoList - Frees the list of all the layers in the ODB
 **                       allocated by getODBLayerInfoList.
 ****************************************************************/
void ACS_freeODBLayerInfoList(struct ODB_LayerInfo * layerList, int layerCount);



/****************************************************************
 ** getODBLayerName - Returns the name of the specified layer.
 ** layerIdx     - layer's index in layerList (starts with 0)
 **
 ** Return: the layer name or NULL if it failed 
 ****************************************************************/
char * ACS_getODBLayerName(int layerIdx);



/****************************************************************
 ** getODBLayerIndex - Returns the index of the specified layer.
 ** layerName    - layer's name
 **
 ** Return: the layer's index in layerList or -1 if it failed
 ****************************************************************/
int ACS_getODBLayerIndex(char * layerName);



/****************************************************************
** getODBOutScale - Returns the out_x_scale and out_y_scale value
** of the specified step/layer combination.
** stepName - step's name
** layerName - layer's name
**
** Return: 0 if successful and 1 if failed
** - x will be set to layer's out_x_scale value
** - y will be set to layer's out_y_scale value
**   * x and y will be negative if Break S&R == Y
****************************************************************/
int ACS_getODBOutScale(char * stepName, char * layerName, double * x, double * y);



/****************************************************************
** getODBOutAngle - Returns the out_angle of the specified step/layer combination.
** stepName - step's name
** layerName - layer's name
**
** Return: 0 if successful and 1 if failed
** - a will be set to layer's out_angle value
**   * a will be negative if Break S&R == Y
****************************************************************/
int ACS_getODBOutAngle(char * stepName, char * layerName, double * a);



/****************************************************************
** getODBOutMirror - Fills a character string corresponding to the specified
** step/layer combination
** stepName - step's name
** layerName - layer's name
**
** Return: 0 if successful and 1 if failed
** - m will be set to Y if yes mirror
** - m will be set to N if no mirror
**   * m will be set to -N or -Y if Break S&R == Y
****************************************************************/
int ACS_getODBOutMirror(char * stepName, char * layerName, char m[4]);



/****************************************************************
** getODBOutPolarity - Fills a character string corresponding to the specified
** step/layer combination
** stepName - step's name
** layerName - layer's name
**
** Return: 0 if successful and 1 if failed
** - p will be set to P if positive polarity
** - p will be set to N if negative polarity
**   * p will be set to -P or -N if Break S&R == Y
****************************************************************/
int ACS_getODBOutPolarity(char * stepName, char * layerName, char p[4]);



/****************************************************************
** getODBProfileInch - Returns profile information for a given step
**
** stepName - step’s name
**
** Return: 0 if successful and 1 if failed
** - numPolys will be set to the number of polygons
** - polyVcnt will be set to the list of vertex counts for each polygons
** - polyXYdata will be set to the list of vertex for each polygons
** Note: one vertex is a pair of x,y coordinates
**	 Example:
**	 Vertex Count: polyVcnt[0] = 2
**	 Vertex 1: polyXYdata[0][0], polyXYdata[0][1]   (x,y)
**	 Vertex 2: polyXYdata[0][2], polyXYdata[0][3]   (x,y)
****************************************************************/
int ACS_getODBProfileInch(char * stepName,int *numPolys, int **polyVcnt, double ***polyXYdata);



/****************************************************************
** getODBProfileMM - Returns profile information for a given step
**
** stepName - step’s name
**
** Return: 0 if successful and 1 if failed
** - numPolys will be set to the number of polygons
** - polyVcnt will be set to the list of vertex counts for each polygons
** - polyXYdata will be set to the list of vertex for each polygons
** Note: one vertex is a pair of x,y coordinates
**	 Example:
**	 Vertex Count: polyVcnt[0] = 2
**	 Vertex 1: polyXYdata[0][0], polyXYdata[0][1]   (x,y)
**	 Vertex 2: polyXYdata[0][2], polyXYdata[0][3]   (x,y)
****************************************************************/
int ACS_getODBProfileMM(char * stepName,int *numPolys, int **polyVcnt, double ***polyXYdata);



/****************************************************************
** freeODBProfile - Cleanup function for getODBProfile
**
** numPolys - pointer to the number of polygons
** polyVcnt - pointer to the list of vertex counts for each polygons
** polyXYdata - pointer to the list of vertex for each polygons
**
** Return: void
****************************************************************/
void ACS_freeODBProfile(int numPolys, int *polyVcnt, double **polyXYdata);



/****************************************************************
 ** getODBSymbolInfoList - Returns a list of all the user defined symbols in the ODB.
 **
 ** Return: 0 if successful and 1 if failed
 **         - symbolList[0] will be set to the first array element in symbolList
 **         - symbolCount will be set to the number of symbols in symbolList
 **
 ** USER NOTE: symbolList must be freed after it is no longer needed
 ****************************************************************/
int ACS_getODBSymbolInfoList(struct ODB_SymbolInfo ** symbolList, int * symbolCount);



/****************************************************************
 ** freeODBSymbolInfoList - Frees the list of all user defined the symbols in the ODB
 **                       allocated by ACS_getODBSymbolInfoList.
 ****************************************************************/
void ACS_freeODBSymbolInfoList(struct ODB_SymbolInfo * symbolList, int symbolCount);



/****************************************************************
 ** printODBTree - Returns a string of the ODB info for the specified step/layerlist combination.
 ** stepName    - step's name 
 ** layerList   - list of layer names
 ** layernum    - num of layers
 ** traverse    - 1 if traverse the step-repeat, 0 otherwise
 **
 ** if stepName!=NULL && layer!=NULL - getODBInfo will return info of the specified step/layerlist combination
 ** if stepName!=NULL && layer==NULL - getODBInfo will return info of the specified step and all its layers
 ** if stepName==NULL                - getODBInfo will return an error
 **
 ** Return: a string of the given step's info (and the info of it's children) or NULL if failed
 **         - must free the string it returns
 ****************************************************************/
char * ACS_printODBTree(char * stepName, char ** layerList, int layernum, int traverse);



/****************************************************************
 ** getODBInfo - Returns the ODB info for the specified step/layerlist combination.
 ** stepName    - step's name 
 ** layerList   - list of layer names
 ** layernum    - num of layers
 **
 ** if stepName!=NULL && layer!=NULL - getODBInfo will return info of the specified step/layerlist combination
 ** if stepName!=NULL && layer==NULL - getODBInfo will return info of the specified step and all its layers
 ** if stepName==NULL                - getODBInfo will return an error
 **
 ** Return: 0 if successful and 1 if failed
 **         - stepInfo will be set to the ODB_StepInfo of the specified step
 **           stepInfo will contain step_index, extent, profile extent and a list of ODB_LayerInfo (as specified).
 **           each layerInfo in stepInfo will contain layer_name, layer_index, context, type, extent, polarity, 
 **           startname, endname, addtype, color. stepInfo.Layer_list must be freed after.
 ****************************************************************/
int ACS_getODBInfo(char * stepName, char ** layerList, int layernum, struct ODB_StepInfo ** stepInfo);



/****************************************************************
 ** freeODBInfo - Frees the step info allocated by getODBInfo.
 ****************************************************************/
void ACS_freeODBInfo(struct ODB_StepInfo * stepInfo);



/****************************************************************
 ** convertODBInput - Converts the ODB and creates a file for each of the step/layerlist combination.
 ** stepName    - step's name 
 ** layerList   - list of layer names
 ** layernum    - num of layers
 ** outputName  - output directory
 ** argc        - number of additional arguments
 ** argv        - list of additional arguments. The possible additional args are:
 **                 -gbr[:<gbr basename>]                    :gbr output (default)
 **                 -gds[:<gds basename>]                    :gds output
 **                 +gds[:<gds filename>]                    :gds output (combine layers into one GDSII)
 **                 -oas[:<oas basename>]                    :oas output
 **                 +oas[:<oas filename>]                    :oas output (combine layers into one OASIS)
 **                 -mic[:<mic filename>]                    :mic output (can only convert one layer)
 **                 -lyrmap:<fname>                          :set layer mapping file (use with +gds and +oas)
 **                 -usegbrflow                              :use in conjunction with -mic (odb->gbr->mic)
 **                 -exclude:<stepnames>                     :to set steps to be excluded
 **                 -excludel:<layernames>                   :to set layers to be excluded
 **                 -window:<minx,miny,maxx,maxy>            :to set window clip (GDSII, OASIS, RIP only)
 **                 -gds_layer:<layer_int_val>               :to set GDSII layer output
 **                 -gds_struct:<struct_name>                :to set GDSII top structure output
 **                 -oas_compressed                          :to compress OASIS output
 **                 -oas_arg <args>                          :to pass additional args for OASIS (end with -end_arg)
 **                 -g2k_ver:<0 | 1 | 2 | 3>                 :to set genesis emulation version
 **                 -g2k_order:<0 | 1 | 2>                   :to set translation order (2 is no mirror)
 **                 -g2k_break_sr:<0 | 1 | 2>                :to set break SR on or off
 **                 -g2k_scale_mode:<1 | 2 | 3>              :to set scaling mode
 **                 -g2k_scalexy:<x,y>                       :to override .out_x_scale and .out_y_scale (double val)
 **                 -g2k_anchor:<0 | 1 | 2 | 3>              :to set anchor mode
 **                 -g2k_inch_anchor:<x,y>                   :to set anchor inch value (double val)
 **                 -g2k_mm_anchor:<x,y>                     :to set anchor mm value (double val)
 **                 -g2k_offset:<0 | 1 | 2 | 3 | 4 | 5>      :to set offset mode
 **                 -g2k_inch_offset:<x,y>                   :to set offset inch value (double val)
 **                 -g2k_mm_offset:<x,y>                     :to set offset mm value (double val)
 **                 -show_progress                           :to enable progress dialog
 **                 -unit:<mils|inch|um|mm|cm>               :to set the unit of conversion  (GBR: inch/mm only MIC: not used)
 **                 -format:<fmt_dbl_val>                    :to set the format of conversion (N.M)
 **                 -scale:<scale_dbl_val>                   :to set the scale of conversion
 **                 -cir_map_min_cnt:<int_val>               :to set the minimum circ surface to convert into a flash
 **                 -arcres:<res_dbl_val>                    :to set the arcres of conversion
 **                 -arcsag:<sag_dbl_val>                    :to set the arcsag of conversion
 **                 -circularize[:<dbl_val>]                 :to circularize arcs (gbr output)
 **                 -maxpts:<intval>                         :to specify max points for surfaces (use with -circularize)
 **                 -rotate:<0|90|180|270>                   :to rotate (counterclockwise) the gbr output
 **                 -mirror:<x|y|xy>                         :to mirror (after rotating) the gbr output
 **                 -dropzerow                               :to drop zero width draws/flash of the gbr output
 **                 -ply_arg <args>                          :to pass args to split274x (end with -end_arg)
 **                 -circular                                :to circularize arcs (mic output)
 **                 -keepzerow                               :to set zero width mode (mic output)
 **                 -odb_symbols                             :to keep the user defined symbols as a macro
 **                 -explode_all                             :to explode all symbols (no macro)
 **                 -butting                                 :to enable butting edge instead of cutline
 **                 -polyedge                                :to enable butting/cutline edge patch
 **                 -step_repeat                             :to enable step repeat on the files
 **                 -nobreaksr                               :to disable SR break of interacting siblings
 **                 -filter_text                             :to enable filtering out of text
 **                 -filter_barc                             :to enable filtering out of barcodes
 **                 -attrout:<attrname>,<0 | 1>              :to output information regarding specified attrname, convert nonzero pad (default:1)
 **                 -plotout                                 :to output information regarding attribute .orbotech_plot_stamp
 **                 -attributeson                            :to enable attribute output (set by -attrout and -plotout by default)
 **                 -log_dyntxt_info                         :to output information regarding dynamic 
 **                 -deemb_surf:<0|1>                        :to deembed surface polygons (holes on top, default is 1)
 **                 -cc_ir                                   :to use counter clockwise rotation on IR
 **                 -out_scale:<default | sf |scale | local> :to set the out_scale mode of conversion
 **                 -njb[:<njb filename>]                    :to create an njb file (don't specify full path)
 **                 -engargs <args>                          :to pass additional args to odb2gdx (end with -end_arg)
 **                 -end_arg                                 :to end additional args (-oas_arg, -ply_arg, -engargs)
 **
 ** if stepName!=NULL && layer!=NULL - convertODBInput will convert the specified step/layerlist combination
 ** if stepName!=NULL && layer==NULL - convertODBInput will convert the specified step and all its layers
 ** if stepName==NULL                - convertODBInput will return an error
 **
 ** Return: 0 if successful and 1 if failed
 ****************************************************************/
int ACS_convertODBInput(char * stepName, char ** layerList, int layernum, char * outputName, int argc, char ** argv);



/****************************************************************
 ** ACS_convertODBAttr - Converts the ODB attributes and creates a file for each of the step/layerlist combination.
 ** stepName    - step's name 
 ** layerName   - layer's names
 ** attrlist    - list of attributes separated by semicolon (;)
 ** outputName  - attribute output file name
 ** argc        - number of additional arguments
 ** argv        - list of additional arguments. The possible additional args are:
 **                 -g2k_ver:<0 | 1 | 2 | 3>                 :to set genesis emulation version
 **                 -g2k_order:<0 | 1 | 2>                   :to set translation order (2 is no mirror)
 **                 -g2k_break_sr:<0 | 1 | 2>                :to set break SR on or off
 **                 -g2k_scale_mode:<1 | 2 | 3>              :to set scaling mode
 **                 -g2k_scalexy:<x,y>                       :to override .out_x_scale and .out_y_scale (double val)
 **                 -g2k_anchor:<0 | 1 | 2 | 3>              :to set anchor mode
 **                 -g2k_inch_anchor:<x,y>                   :to set anchor inch value (double val)
 **                 -g2k_mm_anchor:<x,y>                     :to set anchor mm value (double val)
 **                 -g2k_offset:<0 | 1 | 2 | 3 | 4 | 5>      :to set offset mode
 **                 -g2k_inch_offset:<x,y>                   :to set offset inch value (double val)
 **                 -g2k_mm_offset:<x,y>                     :to set offset mm value (double val)
 **                 -unit:<inch|mm>                          :to set the unit of conversion
 **                 -scale:<scale_dbl_val>                   :to set the scale of conversion
 **                 -arcres:<res_dbl_val>                    :to set the arcres of conversion
 **                 -arcsag:<sag_dbl_val>                    :to set the arcsag of conversion
 **                 -out_scale:<default | sf |scale | local> :to set the out_scale mode of conversion
 **
 ** if stepName==NULL || layer==NULL - convertODBInput will return an error
 **
 ** Return: 0 if successful and 1 if failed
 ****************************************************************/
int ACS_convertODBAttr(char * stepName, char * layerName, char* attrlist, char * outputName, int argc, char ** argv);



/****************************************************************
 ** createODBOutputAttr - Converts the ODB and creates an attribute file for the step/layer combination.
 ** stepName    - step's name 
 ** layerName   - layer's name 
 ** outputName  - output file name
 ** attrName    - attribute to extract
 ** cvtnonzero  - 1 convert non zero pad, 0 do not convert non zero pad (used in conjunction with outcoor == 1)
 ** outcoor     - 1 output final coordinate, 0 do not output GBR/final coordinate
 **              (if 1 ACS_convertODBInput must be called beforehand with the argument -attributeson, 
 **               else ACS_openODB must be called beforehand)
 **
 ** if stepName==NULL || layer==NULL - createODBOutputAttr will return an error
 **
 ** Return: 0 if successful and 1 if failed
 ****************************************************************/
int ACS_createODBOutputAttr(char * stepName, char * layerName, char * outName, char * attrName, int cvtnonzero, int outcoor);



/****************************************************************
 ** createODBOutputPlot - Converts the ODB and creates a plot file for the step/layer combination.
 ** stepName    - step's name 
 ** layerName   - layer's name 
 ** outputName  - output file name
 ** outcoor     - 1 output final coordinate, 0 do not output GBR/final coordinate
 **              (if 1 ACS_convertODBInput must be called beforehand with the argument -attributeson, 
 **               else ACS_openODB must be called beforehand)
 **
 ** if stepName==NULL || layer==NULL - createODBOutputPlot will return an error
 **
 ** Return: 0 if successful and 1 if failed
 ****************************************************************/
int ACS_createODBOutputPlot(char * stepName, char * layerName, char * outName, int outcoor);



/****************************************************************
 ** createODBOutputDynTxt - Creates a dynamic text file for the step/layer combination.
 ** stepName    - step's name 
 ** layerName   - layer's name 
 ** outputName  - output file name
 **
 ** if stepName==NULL || layer==NULL - createODBOutputDynTxt will return an error
 **
 ** Return: 0 if successful and 1 if failed
 ****************************************************************/
int ACS_createODBOutputDynTxt(char * stepName, char * layerName, char * outName);



/****************************************************************
 ** ACS_setODBArcres - Sets the Arc Resolution for the final output files
 ** arcres      - new arc resolution     
 ****************************************************************/
void ACS_setODBArcres(double arcres);



/****************************************************************
 ** ACS_setODBArcsag - Sets the Arc Sag for the final output files
 ** arcsag      - new arc sag    
 ****************************************************************/
void ACS_setODBArcsag(double arcsag);



/****************************************************************
 ** ACS_getODBVersion - Gets the version number of the DLL
 ** returns the version  
 ****************************************************************/
char * ACS_getODBVersion();



/****************************************************************
 ** ACS_getODBRcs - Gets the rcs number of the DLL
 ** returns the rcs  
 ****************************************************************/
char * ACS_getODBRcs();



/****************************************************************
 ** ACS_getODBDate - Gets the date of the DLL
 ** returns the date  
 ****************************************************************/
char * ACS_getODBDate();



#if(!defined(_WinNT_))
/****************************************************************
 ** setParentDlg - Sets the parent dialog for the progress dialog
 ****************************************************************/
void ACS_setParentDlg(void *pt);
#endif



/****************************************************************
 ** closeODB - Closes the ODB internal database and cleans up
 **
 ** Return: 0 if successful and 1 if failed
 ****************************************************************/
int ACS_closeODB();



/****************************************************************
 ** getODBInfo - Returns the ODB job info
 **
 ** Return: 0 if successful and 1 if failed
 **         - jobInfo will be set to the ODB_JobInfo
 ****************************************************************/
void ACS_getODBJobInfo(struct ODB_JobInfo * jobInfo);



typedef void (*NOdb2GdxCB_InitPrgsDlg)(char *hdr, const int show);
typedef void (*NOdb2GdxCB_ExitPrgsDlg)();
typedef void (*NOdb2GdxCB_SetPhaseInit)(const char * header, const char * title, const int totalPhase);
typedef void (*NOdb2GdxCB_SetPhaseTitle)(const char * title);
typedef void (*NOdb2GdxCB_IncrementPhase)(const char * header, const char * title, const int inc, const int end);
typedef int (*NOdb2GdxCB_IsCancel)();

void RegInitPrgsDlg(NOdb2GdxCB_InitPrgsDlg ptr);
void RegExitPrgsDlg(NOdb2GdxCB_ExitPrgsDlg ptr);
void RegSetPhaseInit(NOdb2GdxCB_SetPhaseInit ptr);
void RegSetPhaseTitle(NOdb2GdxCB_SetPhaseTitle ptr);
void RegIncrementPhase(NOdb2GdxCB_IncrementPhase ptr);
void RegIsCancel(NOdb2GdxCB_IsCancel ptr);


#endif


acs_odb_structs.h

Structures for odb2gds64 API


#if(!defined(_acs_odb_structs_h_))
#define _acs_odb_structs_h_

/** Error Codes **/
#define NOERR             0
#define FAILCLOSEODB      -10

#define HASWARNINGS       -100

#define EXECFAIL          -101
#define INCORRECTOS       -102
#define INVALIDOPARAM     -103
#define MISSINGFILE       -104
#define KEYFAIL           -105
#define INVALIDPATH       -106
#define FAILOCHDIR        -107
#define LOGFAIL           -108
#define INVALIDJOBDIR     -109
#define INVALIDWRKDIR     -110
#define FAILMATRIXREAD    -111
#define FAILSTACKUPREAD   -112
#define FAILODBCOPY       -113
#define FAILODBREAD       -114
#define FAILHEADERREAD    -115
#define FAILPROFREAD      -116
#define FAILNETLREAD      -117
#define FAILEDAFREAD      -118
#define FAILTOOLREAD      -119
#define FAILCOMPREAD      -120
#define OPENEXCEPTION     -199

#define INVALIDOUTDIR     -201
#define INVALIDOUTTYPE    -202
#define INVALIDCPARAM     -203
#define FAILCREATESHX     -204
#define FAILCONVERTINPUT  -205
#define FAILCOMBINEGDX    -206
#define FAILCCHDIR        -207
#define FAILCREATEAPT     -208
#define FAILCREATEGBR     -209
#define FAILCREATEGDS     -210
#define FAILCREATEOAS     -211
#define FAILCREATEMIC     -212
#define FAILCREATEATR     -213
#define FAILCREATEPLT     -214
#define FAILCREATEDAT     -215
#define CONVERTEXCEPTION  -299

#define FAILINFOINPUT     -301
#define FAILSTEPINFO      -401
#define FAILLAYERINFO     -501
#define FAILSYMBOLINFO    -601

#define OPENCANCEL        -701
#define CONVERTCANCEL     -701

#define UNINITIALIZED     -32768
#define UNDEFINED         -32767
/** End Error Codes **/

enum{
  ACS_ODB_OUT_GBR,
  ACS_ODB_OUT_MIC,
  ACS_ODB_OUT_GDS,
  ACS_ODB_OUT_OAS,
  ACS_ODB_OUT_RIP,
  ACS_ODB_OUT_GNH,
  ACS_ODB_OUT_LAST
};

enum{
  ACS_ODB_UNIT_MILS,
  ACS_ODB_UNIT_INCH,
  ACS_ODB_UNIT_UM,
  ACS_ODB_UNIT_MM,
  ACS_ODB_UNIT_CM,
  ACS_ODB_UNIT_LAST
};

#if(defined(MAX_PATH))
#undef MAX_PATH
#endif
#define MAX_PATH          1024
#define MAX_STEP          32
#define MAX_LAYER         64
#define MAX_WHEEL         4
#define MAX_DCODE         500
#define MAX_SYMBOL        500
#define MAX_FONT          32
#define MAX_ATTR          1024
#define MAX_TEXT          1024
#define MAX_NAME_CHAR     256
#define MAX_STRING_CHAR	  2048
#define MAXDELIMSTR       1024

struct ODB_InputParam{
  char ExecPath[MAX_NAME_CHAR];
  int argc;
  char ** argv;
};

struct ODB_SymbolInfo{ 
  char Name[MAX_NAME_CHAR];
  
  int Dcode_start;
  int Dcode_count;
};

/*** Context ***/
#define BOARD             1
#define MISC              2
/*** End Context ***/
/*** Type ***/
#define SIGNALLYR         1
#define POWER_GROUND      2
#define DIELECTRIC        3
#define MIXED             4
#define SOLDER_MASK       5
#define SOLDER_PASTE      6
#define SILK_SCREEN       7
#define DRILL             8
#define ROUT              9
#define DOCUMENT          10
#define COMPONENT         11
#define MASK              12
#define CONDUCTIVE_PASTE  13
#define OTHERLAYERTYPE    14
#define OTHERSM           15
#define OTHERSS           16
/*** End Type ***/
/*** Polarity ***/
#define POSITIVE          1
#define NEGATIVE          2
/*** End Polarity ***/
struct ODB_LayerInfo{
  char Name[MAX_NAME_CHAR];
  int Layer_index; // or ROW

  int Context;
  int Type;
  int Polarity; 

  char OldName[MAX_NAME_CHAR];
  char StartName[MAX_NAME_CHAR];
  char EndName[MAX_NAME_CHAR];
  char AddType[MAX_NAME_CHAR];
  
  int Dcode_start;
  int Dcode_count;

  char Color[64];
};

struct ODB_StepInfo{
  char Name[MAX_NAME_CHAR];
  int Step_index;

  double ProfileExtent[4];
  
  int Dcode_start;
  int Dcode_count;

  struct ODB_LayerInfo * Layer_list;
  int Layer_index; //number of layers

  char ** Dep_list;
  int Dep_index;
};

struct ODB_JobInfo{
  char Name[MAX_NAME_CHAR];

  int VersionMajor;
  int VersionMinor;
  
  char Source[MAX_PATH];
  char CreationDate[MAX_PATH];
  char SaveDate[MAX_PATH];
  char SaveApp[MAX_PATH];
  char SaveUser[MAX_PATH];
};

#endif











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