Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHans Goudey <h.goudey@me.com>2021-07-02 19:37:01 +0300
committerHans Goudey <h.goudey@me.com>2021-07-02 19:37:01 +0300
commit5f8969bb4b43afd20cfe859ad5f00c3cdd28bcf1 (patch)
treed9601691f3167bf9714766bcc0cc4e3cf7d041d7 /source/blender/blenkernel/BKE_bvhutils.h
parenta1609340b436ff58e7e3522cc5e6d3ad1506b3ed (diff)
Cleanup: Use const mesh to ensure BVH and triangulation cache
As noted in a comment now, these functions only update a cache, so they don't change the logical state of the mesh, which is "it will have the data when necessary." Using a const argument will help const correctness when accessing an object's evaluated mesh.
Diffstat (limited to 'source/blender/blenkernel/BKE_bvhutils.h')
-rw-r--r--source/blender/blenkernel/BKE_bvhutils.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/blenkernel/BKE_bvhutils.h b/source/blender/blenkernel/BKE_bvhutils.h
index 78908908343..8be2fcbdb83 100644
--- a/source/blender/blenkernel/BKE_bvhutils.h
+++ b/source/blender/blenkernel/BKE_bvhutils.h
@@ -218,7 +218,7 @@ BVHTree *bvhtree_from_mesh_looptri_ex(struct BVHTreeFromMesh *data,
ThreadMutex *mesh_eval_mutex);
BVHTree *BKE_bvhtree_from_mesh_get(struct BVHTreeFromMesh *data,
- struct Mesh *mesh,
+ const struct Mesh *mesh,
const BVHCacheType bvh_cache_type,
const int tree_type);