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-02-16 20:32:37 +0300
committerHans Goudey <h.goudey@me.com>2022-02-16 20:32:37 +0300
commitc324cf153924ae2ec5b7c59eabff71652847aeae (patch)
treef12f07ed61b018481e4bc45a7687567c48c952aa /source/blender/blenkernel/BKE_curves.h
parent5b73017ddb679bb050fe13e4d9e3e5b04ea559b9 (diff)
Curves: Further implementation of new curves data structure
The general idea here is to wrap the `CurvesGeometry` DNA struct with a C++ class that can do most of the heavy lifting for the curve geometry. Using a C++ class allows easier ways to group methods, easier const correctness, and code that's more readable and faster to write. This way, it works much more like a version of `CurveEval` that uses more efficient attribute storage. This commit adds the structure of some yet-to-be-implemented code, the largest thing being mutexes and vectors meant to hold lazily calculated evaluated positions, tangents, and normals. That part might change slightly, but it's helpful to be able to see the direction this commit is aiming in. In particular, the inherently single-threaded accumulated lengths and Bezier evaluated point offsets might be cached. Ref T95355 Differential Revision: https://developer.blender.org/D14054
Diffstat (limited to 'source/blender/blenkernel/BKE_curves.h')
-rw-r--r--source/blender/blenkernel/BKE_curves.h8
1 files changed, 3 insertions, 5 deletions
diff --git a/source/blender/blenkernel/BKE_curves.h b/source/blender/blenkernel/BKE_curves.h
index 2cce15fbfd6..88bb1c67fd1 100644
--- a/source/blender/blenkernel/BKE_curves.h
+++ b/source/blender/blenkernel/BKE_curves.h
@@ -2,9 +2,11 @@
#pragma once
+#include "DNA_curves_types.h"
+
/** \file
* \ingroup bke
- * \brief Low-level operations for curves.
+ * \brief Low-level operations for curves that cannot be defined in the C++ header yet.
*/
#ifdef __cplusplus
@@ -23,14 +25,10 @@ void *BKE_curves_add(struct Main *bmain, const char *name);
struct BoundBox *BKE_curves_boundbox_get(struct Object *ob);
-void BKE_curves_update_customdata_pointers(struct Curves *curves);
bool BKE_curves_customdata_required(struct Curves *curves, struct CustomDataLayer *layer);
/* Depsgraph */
-struct Curves *BKE_curves_new_for_eval(const struct Curves *curves_src,
- int totpoint,
- int totcurve);
struct Curves *BKE_curves_copy_for_eval(struct Curves *curves_src, bool reference);
void BKE_curves_data_update(struct Depsgraph *depsgraph,