ug4
file_io_ug.cpp File Reference
#include <vector>
#include <string>
#include <fstream>
#include <sstream>
#include <cstdlib>
#include <cstring>
#include <algorithm>
#include <set>
#include "file_io_ug.h"
#include "lib_grid/lg_base.h"
#include "lib_grid/algorithms/attachment_util.h"
#include "lib_grid/algorithms/geom_obj_util/geom_obj_util.h"
#include "lib_grid/algorithms/orientation_util.h"
#include "lib_grid/algorithms/polychain_util.h"
#include "lib_grid/callbacks/callbacks.h"

Namespaces

 ug
 the ug namespace
 

Functions

static bool ug::CollectAllVerticesForNG (Grid &grid, VertexSelector &NgVrtSel, VertexSelector &SurfVrtSel, VertexSelector &InnVrtSel)
 collects all vertices in *.ng file order in a selector More...
 
static bool ug::CollectInnerVertices (Grid &grid, VertexSelector &InnVrtSel, VertexSelector &SurfVrtSel)
 collects inner-vertices in a selector More...
 
static bool ug::CollectLines (Grid &grid, const SubsetHandler &shFace, EdgeSelector &LineSel)
 collects lines in a selector More...
 
static bool ug::CollectSurfaceVertices (Grid &grid, const SubsetHandler &shFace, VertexSelector &SurfVrtSel)
 collects surface-vertices in a selector More...
 
bool ug::ExportGridToUG (const Grid &g, const SubsetHandler &shFace, const SubsetHandler &shVolume, const char *fileNamePrefix, const char *lgmName, const char *problemName, int convex)
 converts tetgen files (*.node, *.face and *.ele) to UG files (*.lgm, *.ng) More...
 
bool ug::ExportGridToUG_2D (Grid &grid, const char *fileName, const char *lgmName, const char *problemName, int convex, SubsetHandler *psh=NULL)
 exports a grid to a 2d lgm / ng file combination. More...
 
static bool ug::FaceIsOnRightSide (Face *f, Edge *e)
 
static int ug::GetFirstRegularVertex (Grid &grid, const SubsetHandler &sh, Face *q)
 
static bool ug::GetRightLeftUnitIndex (int &rightIndex, int &leftIndex, Grid &grid, Face *face, const SubsetHandler &shVolume)
 identifies the right and left unit index to a given surface More...
 
static bool ug::WriteLGM (Grid &grid, const char *lgmFilename, const char *problemName, const char *lgmName, int convex, const SubsetHandler &shFaces, const SubsetHandler &shVolumes, EdgeSelector &LineSel, VertexSelector &SurfVrtSel, Grid::EdgeAttachmentAccessor< AInt > &aaLineIndex, Grid::VertexAttachmentAccessor< AInt > &aaSurfVrtIndex, Grid::VertexAttachmentAccessor< AVector3 > &aaPos)
 writes an *lgm file More...
 
static bool ug::WriteNG (Grid &grid, const SubsetHandler &shFaces, const SubsetHandler &shVolumes, const char *ngFilename, VertexSelector &SurfVrtSel, VertexSelector &InnVrtSel, VertexSelector &NgVrtSel, EdgeSelector &LineSel, Grid::EdgeAttachmentAccessor< AInt > &aaLineIndex, Grid::VertexAttachmentAccessor< AInt > &aaInnVrtIndex, Grid::VertexAttachmentAccessor< AInt > &aaNgVrtIndex, Grid::FaceAttachmentAccessor< AInt > &aaFaceIndex, Grid::VertexAttachmentAccessor< AVector3 > &aaPos)
 writes an *ng file More...