MeshKit
1.0
|
Keyword-based text input file describing the assembly geometry.
File can be found in data folder: assygen_default.inp
#include "meshkit/MKCore.hpp" #include "meshkit/MeshOp.hpp" #include "meshkit/ModelEnt.hpp" #include "meshkit/AssyGen.hpp" #include "meshkit/CopyGeom.hpp" using namespace MeshKit; MKCore *mk; bool save_mesh = true; int main(int argc, char *argv[]) { mk = new MKCore(); // create a model entity vector for construting AssyGen meshop, note that NO model entities are required for AssyGen meshop. MEntVector volso; // construct the meshop and set name AssyGen *ag = (AssyGen*) mk->construct_meshop("AssyGen", volso); ag->set_name("AssyGen"); // setup input/output AssyGen files for creating the 'Reactor Assembly' geometry ag->PrepareIO(argc, argv, MESH_DIR); mk->setup_and_execute(); // AssyGen MeshOp internally saves the resulting geometry with the name specified in input file delete mk; return 0; }