| 49 | \*---------------------------------------------------------------------------*/ |
| 50 | |
| 51 | class polyLineSet |
| 52 | : |
| 53 | public sampledSet |
| 54 | { |
| 55 | // Private data |
| 56 | |
| 57 | //- Sampling points |
| 58 | List<point> sampleCoords_; |
| 59 | |
| 60 | |
| 61 | // Private Member Functions |
| 62 | |
| 63 | //- Sample till hits boundary. Called with singleParticle at position |
| 64 | // inbetween sampleCoords_[sampleI] and sampleCoords_[sampleI+1]. |
| 65 | // Returns false if end of samples reached. |
| 66 | bool trackToBoundary |
| 67 | ( |
| 68 | passiveParticleCloud& particleCloud, |
| 69 | passiveParticle& singleParticle, |
| 70 | label& sampleI, |
| 71 | DynamicList<point>& samplingPts, |
| 72 | DynamicList<label>& samplingCells, |
| 73 | DynamicList<label>& samplingFaces, |
| 74 | DynamicList<scalar>& samplingCurveDist |
| 75 | ) const; |
| 76 | |
| 77 | //- Samples all point in sampleCoords_ |
| 78 | // samplingSegments contains segmentNo for each sample. |
| 79 | void calcSamples |
| 80 | ( |
| 81 | DynamicList<point>& samplingPts, |
| 82 | DynamicList<label>& samplingCells, |
| 83 | DynamicList<label>& samplingFaces, |
| 84 | DynamicList<label>& samplingSegments, |
| 85 | DynamicList<scalar>& samplingCurveDist |
| 86 | ) const; |
| 87 | |
| 88 | //- Uses calcSamples to obtain samples. Copies them into *this. |
| 89 | void genSamples(); |
| 90 | |
| 91 | |
| 92 | public: |
| 93 | |
| 94 | //- Runtime type information |
| 95 | TypeName("polyLine"); |
| 96 | |
| 97 | |
| 98 | // Static data |
| 99 | |
| 100 | //- Tolerance when comparing points relative to difference between |
| 101 | // start_ and end_ |
| 102 | static const scalar tol; |
| 103 | |
| 104 | |
| 105 | // Constructors |
| 106 | |
| 107 | //- Construct from components |
| 108 | polyLineSet |