A special feature of Artwork's sample application, NextgenRaster64.exe, is that a command line option, -emitcode, outputs the C++ code used by the app when calling the library.
To see how this works let's create a batch file for the sample application that rasterizes a small window in our sample data file, rip_demo.gds. I've picked a 0.1 um pixel size because the smallest features in rip_demo.gds are 0.5 um. Notice that I've specified a log file and have set the -emitcode argument.
C:\WCAD\NextgenRaster\NextgenRaster64.exe "+input:c:\WCAD\NextgenRaster\Example Files\rip_demo.gds" "+out:c:\WCAD\NextgenRaster\Example Files\rip_demo.tif" -cell:32x48PIXEL -layers:4 pixelsize:0.1 -format:TIFF "-log:c:\WCAD\NextgenRaster\Example Files\rip_demo.log" -window:LLUR,32612,21950,33333,22370 -emitcode
There are two streams of information that are combined in the log file. One stream is reporting on actions and timings; the second stream is produced by the emitcode directive. This second stream of data lists any API calls made to the library along with some comments that explain the call.
Let's look at the first few lines of the log file:
NextGenRaster v1.0 (Jan 14 2015 15:16:43) (c) ARTWORK CONVERSION SOFTWARE Inc. 417 Ingalls St. Santa Cruz CA 95060 (T) 831-426-6163 (E) info@artwork.com (W) www.artwork.com COMMAND LINE: c:\WCAD\NextgenRaster\NextgenRaster64.exe "+input:c:\WCAD\NextgenRaster\Example Files\rip_demo.gds" "+out:c:\WCAD\NextgenRaster\Example Files\rip_demo.tif" -cell:32x48PIXEL -layers:4 pixelsize:0.1 -format:TIFF "-log:c:\WCAD\NextgenRaster\Example Files\rip_demo.log" -window:LLUR,32612,21950,33333,22370 -emitcode [c++] [c++] std::vector<const char*> argT; /* Argument Tags */ [c++] std::vector<void* argV; /* Argument Values */ [c++] [c++] /* Let NextGenRaster print information to stdout, stderr */ [c++] if(printToStdOut) { [c++] argT.resize(argT.size() + 1); argT.back() = "-stdout"; [c++] argV.resize(argV.size() + 1); argV.back() = NULL; [c++] } [c++] /* bool printToStdOut (true) */
The log starts by identifying the program version and date. It then echoes the command line.
Any lines that begin with [c++] indicate API calls made to the library. This makes it easy to follow the flow of calls made to the library.
I've included the entire log file as a link for detailed inspection.
rip_demo.log 13 KB