OpenFOAM logo
Open Source CFD Toolkit

octreeDataTriSurface Class Reference

Collaboration diagram for octreeDataTriSurface:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 ClassName ("octreeDataTriSurface")
 octreeDataTriSurface (const triSurface &)
 Construct from triSurface. Holds reference. Bounding box.
 octreeDataTriSurface (const triSurface &, const treeBoundBoxList &)
 Construct from triSurface and bounding box.
const triSurfacesurface () const
const treeBoundBoxListallBb () const
label size () const
label getSampleType (const octree< octreeDataTriSurface > &, const point &) const
 Get type of sample.
bool overlaps (const label index, const treeBoundBox &sampleBb) const
 Does (bb of) shape at index overlap bb.
bool contains (const label index, const point &sample) const
 Does shape at index contain sample.
bool intersects (const label index, const point &start, const point &end, point &intersectionPoint) const
 Segment (from start to end) intersection with shape.
bool findTightest (const label index, const point &sample, treeBoundBox &tightest) const
 Sets newTightest to bounding box (and returns true) if.
scalar calcSign (const label index, const point &sample, vector &n) const
 Given index get unit normal and calculate (numerical) sign.
scalar calcNearest (const label index, const point &sample, point &nearest) const
 Calculates nearest (to sample) point in shape.
scalar calcNearest (const label index, const linePointRef &ln, point &linePt, point &shapePt) const
 Calculates nearest (to line segment) point in shape.
void write (Ostream &os, const label index) const

Friends

Istreamoperator>> (Istream &, octreeDataTriSurface &)
Ostreamoperator<< (Ostream &, const octreeDataTriSurface &)

Constructor & Destructor Documentation

octreeDataTriSurface const triSurface  ) 
 

Construct from triSurface. Holds reference. Bounding box.

calculated from triangle points.

octreeDataTriSurface const triSurface ,
const treeBoundBoxList
 

Construct from triSurface and bounding box.

Holds references.


Member Function Documentation

const treeBoundBoxList& allBb  )  const [inline]
 

Definition at line 144 of file octreeDataTriSurface.H.

References Foam::label, and Foam::point.

scalar calcNearest const label  index,
const linePointRef ln,
point linePt,
point shapePt
const
 

Calculates nearest (to line segment) point in shape.

Returns distance and both point.

scalar calcNearest const label  index,
const point sample,
point nearest
const
 

Calculates nearest (to sample) point in shape.

Returns point and mag(nearest - sample)

scalar calcSign const label  index,
const point sample,
vector n
const
 

Given index get unit normal and calculate (numerical) sign.

of sample. Used to determine accuracy of calcNearest or inside/outside.

ClassName "octreeDataTriSurface"   ) 
 

bool contains const label  index,
const point sample
const
 

Does shape at index contain sample.

bool findTightest const label  index,
const point sample,
treeBoundBox tightest
const
 

Sets newTightest to bounding box (and returns true) if.

nearer to sample than tightest bounding box. Otherwise returns false.

label getSampleType const octree< octreeDataTriSurface > &  ,
const point
const
 

Get type of sample.

bool intersects const label  index,
const point start,
const point end,
point intersectionPoint
const
 

Segment (from start to end) intersection with shape.

at index. If intersects returns true and sets intersectionPoint

bool overlaps const label  index,
const treeBoundBox sampleBb
const
 

Does (bb of) shape at index overlap bb.

label size  )  const [inline]
 

Definition at line 149 of file octreeDataTriSurface.H.

References Foam::label, Foam::linePointRef, Foam::point, and Foam::vector.

const triSurface& surface  )  const [inline]
 

Definition at line 139 of file octreeDataTriSurface.H.

void write Ostream os,
const label  index
const
 


Friends And Related Function Documentation

Ostream& operator<< Ostream ,
const octreeDataTriSurface
[friend]
 

Istream& operator>> Istream ,
octreeDataTriSurface
[friend]
 


The documentation for this class was generated from the following file:
For further information go to www.openfoam.org