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:
authorBastien Montagne <montagne29@wanadoo.fr>2018-03-23 18:30:57 +0300
committerBastien Montagne <montagne29@wanadoo.fr>2018-03-23 18:35:53 +0300
commit0c753c1dc4ad2085fbdb9ea5fdc2a31d44d126e9 (patch)
tree77249a020f058f446c8712e0f988485897806d34 /source/blender/makesrna/RNA_types.h
parent21f16bb93e1e29a9737edc5bfddcecdcbdfd9f73 (diff)
RNA comparison/override: better control over property processing.
This commit essentially introduces a new RNA property flag, which when set prevents affected property from being processed at all in comparison code (also used to automatically generate static override rules). The idea is to use it on very low-level data in RNA, like e.g. mesh's geometry or psys' particles collections. For now only applied to psys' particle collections, on the main mesh of Agent327 pigeon, it goes from 100ms to 0.5ms on a full auto-override-generating comparison... Also added some new RNA property helper funcs to check on comparable and overridable status.
Diffstat (limited to 'source/blender/makesrna/RNA_types.h')
-rw-r--r--source/blender/makesrna/RNA_types.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/source/blender/makesrna/RNA_types.h b/source/blender/makesrna/RNA_types.h
index 57eeb9e11e0..77d9aabd661 100644
--- a/source/blender/makesrna/RNA_types.h
+++ b/source/blender/makesrna/RNA_types.h
@@ -158,7 +158,7 @@ typedef enum PropertySubType {
/* Make sure enums are updated with these */
/* HIGHEST FLAG IN USE: 1 << 31
- * FREE FLAGS: 3, 9, 11, 13, 14, 15, 30 */
+ * FREE FLAGS: 9, 11, 13, 14, 15, 30 */
typedef enum PropertyFlag {
/* editable means the property is editable in the user
* interface, properties are editable by default except
@@ -179,6 +179,10 @@ typedef enum PropertyFlag {
/* Means the property can be overriden by a local 'proxy' of some linked datablock. */
PROP_OVERRIDABLE_STATIC = (1 << 2),
+ /* Forbid usage of this property in comparison (& hence override) code.
+ * Useful e.g. for collections of data like mesh's geometry, particles, etc. */
+ PROP_NO_COMPARISON = (1 << 3),
+
/* This flag means when the property's widget is in 'textedit' mode, it will be updated
* after every typed char, instead of waiting final validation. Used e.g. for text searchbox.
* It will also cause UI_BUT_VALUE_CLEAR to be set for text buttons. We could add an own flag