#include <opennurbs_bounding_box.h>
◆ ON_BoundingBoxCache() [1/2]
ON_BoundingBoxCache::ON_BoundingBoxCache |
( |
| ) |
|
|
default |
◆ ~ON_BoundingBoxCache()
ON_BoundingBoxCache::~ON_BoundingBoxCache |
( |
| ) |
|
|
default |
◆ ON_BoundingBoxCache() [2/2]
◆ AddBoundingBox() [1/2]
Add a bounding box that can be found from a hash value.
- Parameters
-
bbox | [in] |
hash | [in] A hash of the information needed to create this bounding box. |
◆ AddBoundingBox() [2/2]
◆ BoundingBoxCount()
unsigned int ON_BoundingBoxCache::BoundingBoxCount |
( |
| ) |
const |
- Returns
- Number of cached boxes.
◆ GetBoundingBox()
Get a cached bounding box.
- Parameters
-
hash | [in] |
bbox | [out] If the hash identifies a bounding box in the cache, then that bounding box is returned. Otherwise ON_BoundingBox::NanBoundingBox is returned. |
- Returns
- true - cached bounding box returned false - bounding box not in cache.
◆ operator=()
◆ Read()
◆ RemoveAllBoundingBoxes()
void ON_BoundingBoxCache::RemoveAllBoundingBoxes |
( |
| ) |
|
Removes all bounding boxes.
If the hash values you are using are correctly computed and include all information that the bouding box depends on, then you never need to remove bounding boxes. Unused ones will get removed as new ones are added. If the hash does not include all information required to compute the bounding boxes, then call RemoveAllBoundingBoxes() when the non-hashed information changes.
◆ RemoveBoundingBox()
bool ON_BoundingBoxCache::RemoveBoundingBox |
( |
const ON_SHA1_Hash & |
hash | ) |
|
Remove a bounding box that can be found from a hash value.
- Parameters
-
- Returns
- true - hash was in the cache and removed. false - hash was not in the cache.
If the hash values you are using are correctly computed and include all information that the bouding box depends on, then you never need to remove bounding boxes. Unused ones will get removed as new ones are added.
◆ Write()