Made getVoxel() bounds checking optional, based on a function parameter.

This commit is contained in:
Daviw Williams
2013-05-17 14:32:20 +02:00
parent db1c2bf0f8
commit 617834bed4
8 changed files with 46 additions and 25 deletions

View File

@@ -155,9 +155,9 @@ namespace PolyVox
~SimpleVolume();
/// Gets a voxel at the position given by <tt>x,y,z</tt> coordinates
VoxelType getVoxel(int32_t uXPos, int32_t uYPos, int32_t uZPos) const;
VoxelType getVoxel(int32_t uXPos, int32_t uYPos, int32_t uZPos, bool bPerformBoundsChecks = true) const;
/// Gets a voxel at the position given by a 3D vector
VoxelType getVoxel(const Vector3DInt32& v3dPos) const;
VoxelType getVoxel(const Vector3DInt32& v3dPos, bool bPerformBoundsChecks = true) const;
/// Gets a voxel at the position given by <tt>x,y,z</tt> coordinates
VoxelType getVoxelAt(int32_t uXPos, int32_t uYPos, int32_t uZPos) const;
/// Gets a voxel at the position given by a 3D vector