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:
authorJoseph Eagar <joeedh@gmail.com>2022-07-30 05:01:32 +0300
committerJoseph Eagar <joeedh@gmail.com>2022-07-30 05:03:51 +0300
commitd7cfb6ac71e4225a654487ab134c89051dad03ed (patch)
tree28aeec264ad7dac127e8a5542cb3147a1e88c34e /source/blender/editors/space_buttons
parent27a16abe81a63c4ac72c218bef19b1a85d2eec4b (diff)
Sculpt: Opaque vertex type for sculpt
This is a port of sculpt-dev's `SculptVertRef` refactor (note that `SculptVertRef was renamed to PBVHVertRef`) to master. `PBVHVertRef` is a structure that abstracts the concept of a vertex in the sculpt code; it's simply an `intptr_t` wrapped in a struct. For `PBVH_FACES` and `PBVH_GRIDS` this struct stores a vertex index, but for `BMesh` it stores a direct pointer to a BMVert. The intptr_t is wrapped in a struct to prevent the accidental usage of it as an index. There are many reasons to do this: * Right now `BMesh` verts are not logical sculpt verts; to use the sculpt API they must first be converted to indices. This requires a lot of indirect lookups into tables, leading to performance loss. It has also led to greater code complexity and duplication. * Having an abstract vertex type makes it feasible to have one unified temporary attribute API for all three PBVH modes, which in turn made it rather trivial to port sculpt brushes to DynTopo in sculpt-dev (e.g. the layer brush, draw sharp, the smooth brushes, the paint brushes, etc). This attribute API will be in a future patch. * We need to do this anyway for the eventual move to C++. Differential Revision: https://developer.blender.org/D14272 Reviewed By: Brecht Van Lommel Ref D14272
Diffstat (limited to 'source/blender/editors/space_buttons')
-rw-r--r--source/blender/editors/space_buttons/CMakeLists.txt1
1 files changed, 1 insertions, 0 deletions
diff --git a/source/blender/editors/space_buttons/CMakeLists.txt b/source/blender/editors/space_buttons/CMakeLists.txt
index 7d4f38b1841..b509eae8ea6 100644
--- a/source/blender/editors/space_buttons/CMakeLists.txt
+++ b/source/blender/editors/space_buttons/CMakeLists.txt
@@ -11,6 +11,7 @@ set(INC
../../windowmanager
../../../../intern/glew-mx
../../../../intern/guardedalloc
+ ../../bmesh
# RNA_prototypes.h
${CMAKE_BINARY_DIR}/source/blender/makesrna
)