aboutsummaryrefslogtreecommitdiff
path: root/src/server/collision/BoundingIntervalHierarchy.h
diff options
context:
space:
mode:
authorShauren <shauren.trinity@gmail.com>2012-07-05 14:16:44 +0200
committerShauren <shauren.trinity@gmail.com>2012-07-05 14:16:44 +0200
commit32ba32c4ebe56ba931c8638460c24cd57ae29a75 (patch)
tree2f757648b85ec8989a7dfc573b954b9b4d718650 /src/server/collision/BoundingIntervalHierarchy.h
parentc95905ddbb22e2b5b5362b790aa851ef10d4e27e (diff)
parented6f3e2deff55f913f9646db5f540b7704088478 (diff)
Merge branch '4.x' of github.com:TrinityCore/TrinityCore into 4.3.4
Diffstat (limited to 'src/server/collision/BoundingIntervalHierarchy.h')
-rwxr-xr-xsrc/server/collision/BoundingIntervalHierarchy.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/server/collision/BoundingIntervalHierarchy.h b/src/server/collision/BoundingIntervalHierarchy.h
index ea70fc3e322..a4bbe21006a 100755
--- a/src/server/collision/BoundingIntervalHierarchy.h
+++ b/src/server/collision/BoundingIntervalHierarchy.h
@@ -128,7 +128,7 @@ class BIH
delete[] dat.primBound;
delete[] dat.indices;
}
- uint32 primCount() { return objects.size(); }
+ uint32 primCount() const { return objects.size(); }
template<typename RayCallback>
void intersectRay(const Ray &r, RayCallback& intersectCallback, float &maxDist, bool stopAtFirst=false) const
@@ -400,7 +400,8 @@ class BIH
void buildHierarchy(std::vector<uint32> &tempTree, buildData &dat, BuildStats &stats);
- void createNode(std::vector<uint32> &tempTree, int nodeIndex, uint32 left, uint32 right) {
+ void createNode(std::vector<uint32> &tempTree, int nodeIndex, uint32 left, uint32 right) const
+ {
// write leaf node
tempTree[nodeIndex + 0] = (3 << 30) | left;
tempTree[nodeIndex + 1] = right - left + 1;