|
FiberVISH 0.2
Fish - The Fiber Bundle API for the Vish Visualization Shell
|
Use this class to compute a local cell index and fragment ID (if neccessary) of any coordinate field on a given slice and grid. More...
#include <LocalFromWorldPoint.hpp>
Classes | |
| class | BBSelectorMemoryTree |
| Select fragment candidates out of all the candidates by doing a query into the KDTree and provide a method to step through the candidates. More... | |
| class | FindCell |
| Base class for finding the cell containing the point in a fragment. More... | |
| class | HexaHedralCellNewton |
| Finds a cell containing a world point by using the UniGridMapper. More... | |
| class | ProjectiveCell |
Public Member Functions | |
| RefPtr< Grid > & | grid () |
| LocalFromWorldPoint (Slice &SourceSliceP, const RefPtr< Grid > &SourceGridP, const string &Gridname, double res_scale=1.0, double prec_scale=0.1, tvector tree_query_scale=tvector(1., 1., 1.)) | |
| Constructor does some initialization, like iterating over the fragments to build a KDTree if not already found in the Field's intercube and storing fragmentids and bounding boxes back into the grids' bundle. | |
| ~LocalFromWorldPoint () | |
| Destructor. | |
| bool | get (const point &position, LocalPoint &result) |
| Get the local index coordinates of a world point and the fragment id of the fragment it is contained in. | |
| bool | getViaTree (LocalPoint &result) |
| void | setBlockBoundaryEpsilon (const double block_epsilonP) |
| int | numberOfBordersOfCell (const pair< point, string > localdata, int &hint1, int &hint2) |
| returns the number of bordersurfaces of the given cell | |
| bool | getBorderIntersectionNormal (const point worldposition, const pair< point, string > localpoint, const tvector direction, point &intersection, bivector &normal) |
| Some helper function that returns the point where the cell is left and the normal of the cells face. | |
Public Member Functions inherited from MemCore::ReferenceBase< LocalFromWorldPoint > | |
| auto | getObjectCountID () const noexcept |
| bool | isIdentical (const WeakPtr< Object, Object > &PossibleSelf) const noexcept |
| void | mkAutoDestructive () |
| refcount_t | refcount () const noexcept |
| ReferenceBase (Object *that) noexcept | |
| const auto & | self () const |
| refcount_t | wrefcount () const noexcept |
Public Attributes | |
| double | block_epsilon |
| double | res_scale |
| double | prec_scale |
| int | MaxListSize |
Additional Inherited Members | |
Public Types inherited from MemCore::ReferenceBase< LocalFromWorldPoint > | |
| typedef Object | reference_domain_t |
| typedef WeakPtr< Object, Object > | SelfPtr_t |
Protected Member Functions inherited from MemCore::ReferenceBase< LocalFromWorldPoint > | |
| virtual void | extremeUnction () |
| ReferenceBase & | operator= (const ReferenceBase &R) |
| void | suicide () |
Use this class to compute a local cell index and fragment ID (if neccessary) of any coordinate field on a given slice and grid.
The reason this is encapulated in a class rather in a function is that there are several things done in the constructor once for initialisation once thus speeding up the get function. Also some inner classes are encapsulated and hidden for the user.
| Fiber::LocalFromWorldPoint::LocalFromWorldPoint | ( | Slice & | SourceSliceP, |
| const RefPtr< Grid > & | SourceGridP, | ||
| const string & | Gridname, | ||
| double | res_scale = 1.0, |
||
| double | prec_scale = 0.1, |
||
| tvector | tree_query_scale = tvector(1.,1.,1.) |
||
| ) |
Constructor does some initialization, like iterating over the fragments to build a KDTree if not already found in the Field's intercube and storing fragmentids and bounding boxes back into the grids' bundle.
UniGridMappers are stored for each fragment in a separate grid object either at the provided slice or at the provided uniGrid pointer.
| sliceP | actual time slice |
| SourceGridP | the grid of the coordinates |
| res_scale | this is a scaling factor to influence the number of cells created for the uniform grid of the unigrid mapper. A higher value will result in a higher resolution of the uniform grid. |
| prec_scale | influences the precision of the newton interation |
References Fiber::PointSearch::FragmentBoxes.
| bool Fiber::LocalFromWorldPoint::get | ( | const point & | position, |
| LocalPoint & | result | ||
| ) |
Get the local index coordinates of a world point and the fragment id of the fragment it is contained in.
| position | world point |
| data | return float index (local position) and fragment name, which can be used to create a FragmentID object |
should just return a pair<> here as return value, and rather use a fragment ID itself instead of a string
CHECK WHETHER PARAMETERS REALLY NEED TO BE COPIED HERE
References std::cout, std::endl(), and std::exception::what().
| bool Fiber::LocalFromWorldPoint::getBorderIntersectionNormal | ( | const point | worldposition, |
| const pair< point, string > | localpoint, | ||
| const tvector | direction, | ||
| point & | intersection, | ||
| bivector & | normal | ||
| ) |
Some helper function that returns the point where the cell is left and the normal of the cells face.
A direction and a position (in world and local positions).
References floor(), and numberOfBordersOfCell().
| int Fiber::LocalFromWorldPoint::numberOfBordersOfCell | ( | const pair< point, string > | localdata, |
| int & | hint1, | ||
| int & | hint2 | ||
| ) |
returns the number of bordersurfaces of the given cell
References floor().
Referenced by getBorderIntersectionNormal().