Morton-indexed 2D or 3D matrix containers. More...
|class||ash::dense_hashmatrix< Coord, Data, Alloc >|
|A hashmatrix with dense_hashtable as a backend. More...|
|class||ash::sparse_hashmatrix< Coord, Data, Alloc >|
|A hashmatrix with sparse_hashtable as a backend. More...|
Morton-indexed 2D or 3D matrix containers.
A Hash Matrix is a geometric hashed container which implements the STL concepts Unique Hashed Associative Container and Pair Associative Container . As such, it has many similarities with STL's
hash_map. The only area where the
hash_map semantics are not valid for a
hash_matrix is in the template parameters. The major difference is that you cannot specify an arbitrary key type, it must be a pcoord type. In reality you are specifying 2 things this way: the size of the key, and the dimensionality of the data (2D or 3D). Since the key type is mostly pre-defined, the hash functor and key equality functor are also built-in; you cannot specify either. As a result, there are only 3 template parameters:
As a geometric container, it is useful to have a way to iterate through elements by axis, and for this purpose we provide hash_matrix::navigator and hash_matrix::const_navigator. They work similarly to iterators, except that it is not possible to increment and decrement them directly. Instead, they have x, y, and (for 3D) z members, which allow intuitive semantics like ++nav.x, nav.y++, --nav.z, etc. Another important difference is that navigators may be at "empty" locations: they may represent any valid coordinate, but are only dereferenceable if there is an element associated with the coordinate in the container. To determine if the navigator is dereferencable, they provide the valid() method.
|© 2012||Licensed under||Hosted by||Generated by 1.7.4|