GDScpp is a C++ library that make GDS file manipulation easier. Even though GDScpp can be compiled as a stand-alone program, it is intended to be used as a library.
Version: 1.1
- Convert GDS data to ASCII.
- Easily create GDS files.
- Import GDS files.
- Extract the root GDS structures.
- Create a hierarchy diagram of all the GDS structure dependencies.
- Direct importing of GDS files with redundancy checking
- Create bounding box of all the GDS structures
The following packages is required to successfully compile and execute GDScpp.
apt install build-essencials cmake # for compiling
apt install graphviz # for creating hierarchy diagram(dot file)
# Current directory: GDScpp root
mkdir build && cd build
cmake ..
make
A few examples are provided in the examples folder to show some of GDScpp's functionality.
#include "gdsCpp.hpp"
int main(int argc, char *argv[]){
gdscpp fooGDS;
gdsSTR fooSTR;
fooSTR.name = "example";
std::vector<int> corX = { 0, 200, 400};
std::vector<int> corY = {700, 900, 700};
fooSTR.PATH.push_back(drawPath(1, 5, corX, corY));
corX = {200, 200};
corY = {900, 000};
fooSTR.PATH.push_back(drawPath(1, 5, corX, corY));
corX = {0, 150, 150, 250, 250, 150, 150, 400, 400, 0, 0};
corY = {0, 0, 250, 250, 150, 150, 0, 0, 400, 400, 0};
fooSTR.BOUNDARY.push_back(drawBoundary(2, corX, corY));
fooGDS.setSTR(fooSTR);
fooGDS.write(fileName);
return 0;
}
Translate GDS file directly to ASCII.
./gdscpp -i input.gds
or
./gdscpp -i input.gds >> outfile.txt
Imports a GDS file into memory and exports a minimal GDS file out.
./gdscpp -rw input.gds -o output.gds
Calculates the root structures of the GDS file
./gdscpp -rs input.gds
generates a diagram of the hierarchical structure of the GDS file.
./gdscpp -r input.gds
- Create a map to easily find the structures
- Refactoring of GDScpp into a more standard library format
- Extract a desired GDS structure to a separate file
- Text and nodes are not fully supported.
- Box is currently not supported.
2020-06-11 Improved GDS read-in redundancy checking; AREF, BOX and TEXT is working; Bug fixes. 2020-02-25 Updated Readme, added get_database_units_in_m function.