gmsh-TingyuanDoc  0.1
An Open-Source Timing-driven Analytical Mixed-size FPGA Placer
GeomMeshMatcher.cpp File Reference
#include <cstdarg>
#include <algorithm>
#include <list>
#include <vector>
#include "GeomMeshMatcher.h"
#include "Pair.h"
#include "discreteVertex.h"
#include "GmshMessage.h"
#include "SOrientedBoundingBox.h"
#include "MElement.h"
#include "MTriangle.h"
#include "MQuadrangle.h"
#include "MVertex.h"
#include "MLine.h"
#include "MPyramid.h"
#include "MTrihedron.h"
#include "MPrism.h"
#include "MPoint.h"
#include "MHexahedron.h"
#include "MTetrahedron.h"
#include "OS.h"
#include "Context.h"
#include "closestVertex.h"
Include dependency graph for GeomMeshMatcher.cpp:

Go to the source code of this file.

Functions

template<class T , class container >
void getIntersection (std::vector< T > &res, std::vector< container > &lists)
 
template<class T >
findMatching (std::vector< Pair< T, T > > &matching, T &entity)
 
static GVertexgetGVertex (MVertex *v1, GModel *gm, const double TOL)
 
static GPoint getGEdge (MVertex *v1, GModel *gm, const double TOL)
 
static GPoint getGFace (MVertex *v1, GModel *gm, const double TOL)
 
template<class GEType >
static void copy_periodicity (std::vector< Pair< GEType *, GEType * > > &eCor, std::map< MVertex *, MVertex * > &mesh_to_geom)
 
template<class GEType >
static bool apply_periodicity (std::vector< Pair< GEType *, GEType * > > &eCor)
 
static void copy_vertices (GVertex *to, GVertex *from, std::map< MVertex *, MVertex * > &_mesh_to_geom)
 
static void copy_vertices (GRegion *to, GRegion *from, std::map< MVertex *, MVertex * > &_mesh_to_geom)
 
static void copy_vertices (GEdge *to, GEdge *from, std::map< MVertex *, MVertex * > &_mesh_to_geom)
 
static void copy_vertices (GFace *to, GFace *from, std::map< MVertex *, MVertex * > &_mesh_to_geom)
 
template<class ELEMENT >
static void copy_elements (std::vector< ELEMENT * > &to, std::vector< ELEMENT * > &from, std::map< MVertex *, MVertex * > &_mesh_to_geom)
 
void copy_vertices (GModel *geom, GModel *mesh, std::map< MVertex *, MVertex * > &_mesh_to_geom, std::vector< Pair< GVertex *, GVertex * > > *coresp_v, std::vector< Pair< GEdge *, GEdge * > > *coresp_e, std::vector< Pair< GFace *, GFace * > > *coresp_f, std::vector< Pair< GRegion *, GRegion * > > *coresp_r)
 
void copy_elements (GModel *geom, GModel *mesh, std::map< MVertex *, MVertex * > &_mesh_to_geom, std::vector< Pair< GVertex *, GVertex * > > *coresp_v, std::vector< Pair< GEdge *, GEdge * > > *coresp_e, std::vector< Pair< GFace *, GFace * > > *coresp_f, std::vector< Pair< GRegion *, GRegion * > > *coresp_r)
 

Function Documentation

◆ apply_periodicity()

template<class GEType >
static bool apply_periodicity ( std::vector< Pair< GEType *, GEType * > > &  eCor)
static

Definition at line 654 of file GeomMeshMatcher.cpp.

Referenced by GeomMeshMatcher::match().

Here is the caller graph for this function:

◆ copy_elements() [1/2]

void copy_elements ( GModel geom,
GModel mesh,
std::map< MVertex *, MVertex * > &  _mesh_to_geom,
std::vector< Pair< GVertex *, GVertex * > > *  coresp_v,
std::vector< Pair< GEdge *, GEdge * > > *  coresp_e,
std::vector< Pair< GFace *, GFace * > > *  coresp_f,
std::vector< Pair< GRegion *, GRegion * > > *  coresp_r 
)

Definition at line 809 of file GeomMeshMatcher.cpp.

◆ copy_elements() [2/2]

template<class ELEMENT >
static void copy_elements ( std::vector< ELEMENT * > &  to,
std::vector< ELEMENT * > &  from,
std::map< MVertex *, MVertex * > &  _mesh_to_geom 
)
static

Definition at line 765 of file GeomMeshMatcher.cpp.

Referenced by GeomMeshMatcher::match().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ copy_periodicity()

template<class GEType >
static void copy_periodicity ( std::vector< Pair< GEType *, GEType * > > &  eCor,
std::map< MVertex *, MVertex * > &  mesh_to_geom 
)
static

Definition at line 597 of file GeomMeshMatcher.cpp.

Referenced by GeomMeshMatcher::match().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ copy_vertices() [1/5]

static void copy_vertices ( GEdge to,
GEdge from,
std::map< MVertex *, MVertex * > &  _mesh_to_geom 
)
static

Definition at line 710 of file GeomMeshMatcher.cpp.

Here is the call graph for this function:

◆ copy_vertices() [2/5]

static void copy_vertices ( GFace to,
GFace from,
std::map< MVertex *, MVertex * > &  _mesh_to_geom 
)
static

Definition at line 736 of file GeomMeshMatcher.cpp.

Here is the call graph for this function:

◆ copy_vertices() [3/5]

void copy_vertices ( GModel geom,
GModel mesh,
std::map< MVertex *, MVertex * > &  _mesh_to_geom,
std::vector< Pair< GVertex *, GVertex * > > *  coresp_v,
std::vector< Pair< GEdge *, GEdge * > > *  coresp_e,
std::vector< Pair< GFace *, GFace * > > *  coresp_f,
std::vector< Pair< GRegion *, GRegion * > > *  coresp_r 
)

Definition at line 788 of file GeomMeshMatcher.cpp.

Here is the call graph for this function:

◆ copy_vertices() [4/5]

static void copy_vertices ( GRegion to,
GRegion from,
std::map< MVertex *, MVertex * > &  _mesh_to_geom 
)
static

Definition at line 697 of file GeomMeshMatcher.cpp.

Here is the call graph for this function:

◆ copy_vertices() [5/5]

static void copy_vertices ( GVertex to,
GVertex from,
std::map< MVertex *, MVertex * > &  _mesh_to_geom 
)
static

Definition at line 684 of file GeomMeshMatcher.cpp.

Referenced by copy_vertices(), and GeomMeshMatcher::match().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ findMatching()

template<class T >
T findMatching ( std::vector< Pair< T, T > > &  matching,
T &  entity 
)

Definition at line 64 of file GeomMeshMatcher.cpp.

◆ getGEdge()

static GPoint getGEdge ( MVertex v1,
GModel gm,
const double  TOL 
)
static

Definition at line 439 of file GeomMeshMatcher.cpp.

Referenced by GeomMeshMatcher::forceTomatch().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getGFace()

static GPoint getGFace ( MVertex v1,
GModel gm,
const double  TOL 
)
static

Definition at line 460 of file GeomMeshMatcher.cpp.

Referenced by GeomMeshMatcher::forceTomatch().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getGVertex()

static GVertex* getGVertex ( MVertex v1,
GModel gm,
const double  TOL 
)
static

Definition at line 410 of file GeomMeshMatcher.cpp.

Referenced by GeomMeshMatcher::forceTomatch().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getIntersection()

template<class T , class container >
void getIntersection ( std::vector< T > &  res,
std::vector< container > &  lists 
)

Definition at line 38 of file GeomMeshMatcher.cpp.