OpenFOAM logo
The Open Source CFD Toolbox
  Source Guide OpenCFD Solutions Contact OpenFOAM

triSurfaceSearch Class Reference

Helper class to search on triSurface. More...

Collaboration diagram for triSurfaceSearch:

List of all members.


Public Member Functions

 triSurfaceSearch (const triSurface &)
 Construct from surface. Holds reference to surface!
const indexedOctree
< treeDataTriSurface > & 
tree () const
const triSurface & surface () const
boolList calcInside (const pointField &searchPoints) const
 Calculate for each searchPoint inside/outside status.
labelList calcNearestTri (const pointField &samples, const vector &span) const
 Calculate index of nearest triangle (or -1) for each sample.
tmp< pointField > calcNearest (const pointField &samples, const vector &span) const
 Calculate nearest points (to searchPoints) on surface.
pointIndexHit nearest (const point &, const vector &span) const
 Calculate nearest point on surface for single searchPoint. Returns.

Static Public Attributes

static const point greatPoint
 Point far away; used for illegal finds.

Detailed Description

Helper class to search on triSurface.

Source files

Definition at line 53 of file triSurfaceSearch.H.


Constructor & Destructor Documentation

triSurfaceSearch ( const triSurface &  surface  ) 

Construct from surface. Holds reference to surface!

Definition at line 39 of file triSurfaceSearch.C.


Member Function Documentation

const indexedOctree<treeDataTriSurface>& tree (  )  const [inline]

Definition at line 90 of file triSurfaceSearch.H.

const triSurface& surface (  )  const [inline]

Definition at line 95 of file triSurfaceSearch.H.

boolList calcInside ( const pointField &  searchPoints  )  const

Calculate for each searchPoint inside/outside status.

Definition at line 77 of file triSurfaceSearch.C.

labelList calcNearestTri ( const pointField &  samples,
const vector &  span 
) const

Calculate index of nearest triangle (or -1) for each sample.

Looks only in box of size 2*span around sample.

Definition at line 107 of file triSurfaceSearch.C.

tmp< pointField > calcNearest ( const pointField &  samples,
const vector &  span 
) const

Calculate nearest points (to searchPoints) on surface.

Looks only in box of size 2*span around sample. Returns greatPoint if not found.

Definition at line 138 of file triSurfaceSearch.C.

pointIndexHit nearest ( const point &  pt,
const vector &  span 
) const

Calculate nearest point on surface for single searchPoint. Returns.

in pointIndexHit:

  • hit() : whether nearest point found within bounding box
  • hitPoint() : coordinate of nearest point
  • index() : surface triangle label

Definition at line 168 of file triSurfaceSearch.C.

References triSurfaceSearch::greatPoint.


Member Data Documentation

const point greatPoint [static]

Point far away; used for illegal finds.

Definition at line 78 of file triSurfaceSearch.H.

Referenced by triSurfaceSearch::nearest().


The documentation for this class was generated from the following files:
Copyright © 2000-2009 OpenCFD Ltd