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>2022-08-03 21:19:43 +0300
committerHans Goudey <h.goudey@me.com>2022-08-03 21:20:01 +0300
commita5a60d0f4f65cec0a018af6a3c0b4d01daf29c64 (patch)
tree6debf702d95525b40f7e75fc84af8e01e118619d /source/blender/blenkernel/intern/customdata.cc
parent09df97e89706ff7e4015c7bab222eb9de538d4a4 (diff)
Cleanup: Fix doxygen section for custom data type
Diffstat (limited to 'source/blender/blenkernel/intern/customdata.cc')
-rw-r--r--source/blender/blenkernel/intern/customdata.cc62
1 files changed, 34 insertions, 28 deletions
diff --git a/source/blender/blenkernel/intern/customdata.cc b/source/blender/blenkernel/intern/customdata.cc
index f686f5cca64..4d11f4daedf 100644
--- a/source/blender/blenkernel/intern/customdata.cc
+++ b/source/blender/blenkernel/intern/customdata.cc
@@ -222,34 +222,6 @@ static void layerFree_mdeformvert(void *data, const int count, const int size)
}
}
-/* copy just zeros in this case */
-static void layerCopy_bmesh_elem_py_ptr(const void *UNUSED(source), void *dest, const int count)
-{
- const int size = sizeof(void *);
-
- for (int i = 0; i < count; i++) {
- void **ptr = (void **)POINTER_OFFSET(dest, i * size);
- *ptr = nullptr;
- }
-}
-
-#ifndef WITH_PYTHON
-void bpy_bm_generic_invalidate(struct BPy_BMGeneric *UNUSED(self))
-{
- /* dummy */
-}
-#endif
-
-static void layerFree_bmesh_elem_py_ptr(void *data, const int count, const int size)
-{
- for (int i = 0; i < count; i++) {
- void **ptr = (void **)POINTER_OFFSET(data, i * size);
- if (*ptr) {
- bpy_bm_generic_invalidate(static_cast<BPy_BMGeneric *>(*ptr));
- }
- }
-}
-
static void layerInterp_mdeformvert(const void **sources,
const float *weights,
const float *UNUSED(sub_weights),
@@ -744,6 +716,40 @@ static size_t layerFilesize_mdisps(CDataFile *UNUSED(cdf), const void *data, con
/** \} */
/* -------------------------------------------------------------------- */
+/** \name Callbacks for (#CD_BM_ELEM_PYPTR)
+ * \{ */
+
+/* copy just zeros in this case */
+static void layerCopy_bmesh_elem_py_ptr(const void *UNUSED(source), void *dest, const int count)
+{
+ const int size = sizeof(void *);
+
+ for (int i = 0; i < count; i++) {
+ void **ptr = (void **)POINTER_OFFSET(dest, i * size);
+ *ptr = nullptr;
+ }
+}
+
+#ifndef WITH_PYTHON
+void bpy_bm_generic_invalidate(struct BPy_BMGeneric *UNUSED(self))
+{
+ /* dummy */
+}
+#endif
+
+static void layerFree_bmesh_elem_py_ptr(void *data, const int count, const int size)
+{
+ for (int i = 0; i < count; i++) {
+ void **ptr = (void **)POINTER_OFFSET(data, i * size);
+ if (*ptr) {
+ bpy_bm_generic_invalidate(static_cast<BPy_BMGeneric *>(*ptr));
+ }
+ }
+}
+
+/** \} */
+
+/* -------------------------------------------------------------------- */
/** \name Callbacks for (`float`, #CD_PAINT_MASK)
* \{ */