Blender V5.3
RNA_types.hh
Go to the documentation of this file.
1/* SPDX-FileCopyrightText: 2023 Blender Authors
2 *
3 * SPDX-License-Identifier: GPL-2.0-or-later */
4
8
9/* Use a define instead of `#pragma once` because of `BKE_addon.h`, `ED_object.hh` & others. */
10#ifndef __RNA_TYPES_H__
11#define __RNA_TYPES_H__
12
13#include <optional>
14#include <string>
15
20
21namespace blender {
22
23struct BlenderRNA;
24struct FunctionRNA;
25struct ID;
26struct Main;
27struct ParameterList;
28struct PropertyRNA;
29struct ReportList;
30struct StructRNA;
31struct bContext;
32
41
43
51
52struct PointerRNA {
58 ID *owner_id = nullptr;
63 StructRNA *type = nullptr;
67 void *data = nullptr;
68
91
93 PointerRNA() = default;
94 PointerRNA(const PointerRNA &) = default;
95 PointerRNA(PointerRNA &&) = default;
96 PointerRNA &operator=(const PointerRNA &other) = default;
97 PointerRNA &operator=(PointerRNA &&other) = default;
98
112
114 void reset()
115 {
116 *this = {};
117 }
118
126 {
127 this->reset();
128 }
129
139 template<typename T> T *data_as() const
140 {
141 return static_cast<T *>(this->data);
142 }
143
148 {
149 if (ancestors.is_empty()) {
150 return PointerRNA();
151 }
152
153 return PointerRNA(owner_id, ancestors.last().type, ancestors.last().data);
154 }
155
160 operator bool() const
161 {
162 return this->has_data();
163 }
164
169 bool has_data() const
170 {
171 /* If there is data, there should also be a type. */
172 BLI_assert(!this->data || this->type);
173 return this->data != nullptr;
174 }
175
180 bool has_type() const
181 {
182 return this->type != nullptr;
183 }
184
186 bool has_owner_id() const
187 {
188 return this->owner_id != nullptr;
189 }
190};
191
196
202 PropertyRNA *prop = nullptr;
204 int prop_index = -1;
205};
206
207/* Property */
208
218
219/* also update rna_property_subtype_unit when you change this */
221 PROP_UNIT_NONE = (0 << 16),
222 PROP_UNIT_LENGTH = (1 << 16), /* m */
223 PROP_UNIT_AREA = (2 << 16), /* m^2 */
224 PROP_UNIT_VOLUME = (3 << 16), /* m^3 */
225 PROP_UNIT_MASS = (4 << 16), /* kg */
226 PROP_UNIT_ROTATION = (5 << 16), /* radians */
227 PROP_UNIT_TIME = (6 << 16), /* frame */
228 PROP_UNIT_TIME_ABSOLUTE = (7 << 16), /* time in seconds (independent of scene) */
229 PROP_UNIT_VELOCITY = (8 << 16), /* m/s */
230 PROP_UNIT_ACCELERATION = (9 << 16), /* m/(s^2) */
231 PROP_UNIT_CAMERA = (10 << 16), /* mm */
232 PROP_UNIT_POWER = (11 << 16), /* W */
233 PROP_UNIT_TEMPERATURE = (12 << 16), /* C */
234 PROP_UNIT_WAVELENGTH = (13 << 16), /* `nm` (independent of scene). */
235 PROP_UNIT_COLOR_TEMPERATURE = (14 << 16), /* K */
236 PROP_UNIT_FREQUENCY = (15 << 16), /* Hz */
237};
239
240
265
266#define RNA_SUBTYPE_UNIT(subtype) ((subtype) & 0x00FF0000)
267#define RNA_SUBTYPE_VALUE(subtype) ((subtype) & ~0x00FF0000)
268#define RNA_SUBTYPE_UNIT_VALUE(subtype) ((subtype) >> 16)
269
270#define RNA_ENUM_BITFLAG_SIZE 32
271
272#define RNA_TRANSLATION_PREC_DEFAULT 5
273
274#define RNA_STACK_ARRAY 32
275
282
283 /* strings */
296 /* 5 was used by "PROP_TRANSLATE" sub-type, which is now a flag. */
299
300 /* numbers */
315
316 /* number arrays */
332
333 /* booleans */
336
339
340 /* temperature */
342
343 /* wavelength */
345
346 /* wavelength */
348
354};
355
357inline PropertySubType operator|(const PropertySubType subtype, const PropertyUnit unit)
358{
359 return PropertySubType(int(subtype) | int(unit));
360}
361
362inline int operator&(const PropertySubType subtype, const PropertyUnit unit)
363{
364 return int(subtype) & int(unit);
365}
366
367/* Make sure enums are updated with these */
368/* HIGHEST FLAG IN USE: 1u << 31
369 * FREE FLAGS: NONE. */
376 PROP_EDITABLE = (1 << 0),
389 PROP_ANIMATABLE = (1 << 1),
397
398 /* icon */
401
408 PROP_HIDDEN = (1 << 19),
414 PROP_SKIP_SAVE = (1 << 28),
415
416 /* numbers */
417
419 PROP_PROPORTIONAL = (1 << 26),
420
421 /* pointers */
422
435
447 PROP_NEVER_NULL = (1 << 18),
454 PROP_NEVER_UNLINK = (1 << 25),
455
466
474 PROP_ENUM_FLAG = (1 << 21),
475
476 /* need context for update function */
479
480 /* registering */
481 PROP_REGISTER = (1 << 4),
483
493 PROP_THICK_WRAP = (1 << 23),
494
496 PROP_IDPROPERTY = (1 << 10),
498 PROP_DYNAMIC = (1 << 17),
503
510
516
527
541
543 PROP_SKIP_PRESET = (1 << 11),
544
547
552 PROP_FORCE_UNDO = (1 << 13),
553
554};
556
557
565 /* Only supports general and type-specific variables, no purpose-specific
566 * variables. */
568
569 /* Supports render output variables.
570 *
571 * \see BKE_add_template_variables_for_render_path() */
573
574 /* Supports only project variables, for project settings.
575 *
576 * \see BKE_add_template_variables_for_project() */
578};
579
589
597
610
611 /*** Collections-related ***/
612
615
623};
625
646
647struct CollectionPropertyIterator;
648struct Link;
649using IteratorSkipFunc = bool (*)(CollectionPropertyIterator *iter, void *data);
650
656
658 char *ptr;
660 char *endptr;
662 void *free_ptr;
664
670
677};
678
680 void *ptr;
681 int item;
682};
683
685 /* internal */
689 union {
690 /* Keep biggest object first in the union, for zero-initialization to work properly. */
694 void *custom;
697 int level;
698
699 /* external */
701 bool valid;
702};
703
707
722
729
736 int value;
743 const char *identifier;
745 int icon;
747 const char *name;
749 const char *description;
750};
751
759#define RNA_ENUM_ITEM_HEADING(name, description) {0, "", 0, name, description}
760
762#define RNA_ENUM_ITEM_SEPR {0, "", 0, NULL, NULL}
763
765#define RNA_ENUM_ITEM_SEPR_COLUMN RNA_ENUM_ITEM_HEADING("", NULL)
766
767/* Extended versions with PropertyRNA argument. Used in particular by the bpy code to wrap all the
768 * py-defined callbacks when defining a property using `bpy.props` module.
769 *
770 * The 'Transform' ones allow to add a transform step (applied after getting, or before setting the
771 * value), which only modifies the value, but does not handle actual storage. Currently only used
772 * by `bpy`, more details in the documentation of #BPyPropStore.
773 */
774using BooleanPropertyGetFunc = bool (*)(PointerRNA *ptr, PropertyRNA *prop);
775using BooleanPropertySetFunc = void (*)(PointerRNA *ptr, PropertyRNA *prop, bool value);
777 PropertyRNA *prop,
778 bool value,
779 bool is_set);
781 bool (*)(PointerRNA *ptr, PropertyRNA *prop, bool new_value, bool curr_value, bool is_set);
782
783using BooleanArrayPropertyGetFunc = void (*)(PointerRNA *ptr, PropertyRNA *prop, bool *r_values);
785 PropertyRNA *prop,
786 const bool *r_values);
788 PointerRNA *ptr, PropertyRNA *prop, const bool *curr_values, bool is_set, bool *r_values);
790 PropertyRNA *prop,
791 const bool *new_values,
792 const bool *curr_values,
793 bool is_set,
794 bool *r_values);
795
796using IntPropertyGetFunc = int (*)(PointerRNA *ptr, PropertyRNA *prop);
797using IntPropertySetFunc = void (*)(PointerRNA *ptr, PropertyRNA *prop, int value);
799 PropertyRNA *prop,
800 int value,
801 bool is_set);
803 int (*)(PointerRNA *ptr, PropertyRNA *prop, int new_value, int curr_value, bool is_set);
804using IntArrayPropertyGetFunc = void (*)(PointerRNA *ptr, PropertyRNA *prop, int *values);
805using IntArrayPropertySetFunc = void (*)(PointerRNA *ptr, PropertyRNA *prop, const int *values);
807 PointerRNA *ptr, PropertyRNA *prop, const int *curr_values, bool is_set, int *r_values);
809 PropertyRNA *prop,
810 const int *new_values,
811 const int *curr_values,
812 bool is_set,
813 int *r_values);
815 void (*)(PointerRNA *ptr, PropertyRNA *prop, int *min, int *max, int *softmin, int *softmax);
816
818using FloatPropertySetFunc = void (*)(PointerRNA *ptr, PropertyRNA *prop, float value);
820 PropertyRNA *prop,
821 float value,
822 bool is_set);
824 float (*)(PointerRNA *ptr, PropertyRNA *prop, float new_value, float curr_value, bool is_set);
825using FloatArrayPropertyGetFunc = void (*)(PointerRNA *ptr, PropertyRNA *prop, float *values);
827 PropertyRNA *prop,
828 const float *values);
830 PointerRNA *ptr, PropertyRNA *prop, const float *curr_values, bool is_set, float *r_values);
832 PropertyRNA *prop,
833 const float *new_values,
834 const float *curr_values,
835 bool is_set,
836 float *r_values);
837using FloatPropertyRangeFunc = void (*)(
838 PointerRNA *ptr, PropertyRNA *prop, float *min, float *max, float *softmin, float *softmax);
839
840using StringPropertyGetFunc = std::string (*)(PointerRNA *ptr, PropertyRNA *prop);
842using StringPropertySetFunc = void (*)(PointerRNA *ptr,
843 PropertyRNA *prop,
844 const std::string &value);
845using StringPropertyGetTransformFunc = std::string (*)(PointerRNA *ptr,
846 PropertyRNA *prop,
847 const std::string &value,
848 bool is_set);
849using StringPropertySetTransformFunc = std::string (*)(PointerRNA *ptr,
850 PropertyRNA *prop,
851 const std::string &new_value,
852 const std::string &curr_value,
853 bool is_set);
855using PointerPropertySetFunc = void (*)(PointerRNA *ptr, PointerRNA value, ReportList *reports);
857
858using StructPathFunc = std::optional<std::string> (*)(const PointerRNA *ptr);
859
862 std::string text;
864 std::optional<std::string> info;
865 /* Optional icon instead of #ICON_NONE. */
866 std::optional<int> icon_id;
867};
868
886
887
898 void (*)(const bContext *C,
899 PointerRNA *ptr,
900 PropertyRNA *prop,
901 const char *edit_text,
903
908using StringPropertyPathFilterFunc = std::optional<std::string> (*)(const bContext *C,
909 PointerRNA *ptr,
910 PropertyRNA *prop);
911
912using EnumPropertyGetFunc = int (*)(PointerRNA *ptr, PropertyRNA *prop);
913using EnumPropertySetFunc = void (*)(PointerRNA *ptr, PropertyRNA *prop, int value);
915 PropertyRNA *prop,
916 int value,
917 bool is_set);
919 int (*)(PointerRNA *ptr, PropertyRNA *prop, int new_value, int curr_value, bool is_set);
920/* same as PropEnumItemFunc */
922 PointerRNA *ptr,
923 PropertyRNA *prop,
924 bool *r_free);
925
926struct PropertyRNA;
927
928/* Parameter List */
929
932 void *data;
933
936
939
941};
942
945 // PointerRNA funcptr; /* UNUSED */
946 void *data;
948
950 bool valid;
951};
952
959
960/* Function */
961
980 FUNC_USE_SELF_ID = (1 << 11),
981
991 FUNC_SELF_AS_RNA = (1 << 13),
998 FUNC_NO_SELF = (1 << 0),
1001
1002 /* Pass Main, bContext and/or ReportList. */
1003 FUNC_USE_MAIN = (1 << 2),
1006
1007 /***** Registering of Python subclasses. *****/
1012 FUNC_REGISTER = (1 << 5),
1020 FUNC_ALLOW_WRITE = (1 << 12),
1021
1022 /***** Internal flags. *****/
1024 FUNC_BUILTIN = (1 << 7),
1026 FUNC_EXPORT = (1 << 8),
1028 FUNC_RUNTIME = (1 << 9),
1034};
1036
1037using CallFunc = void (*)(bContext *C, ReportList *reports, PointerRNA *ptr, ParameterList *parms);
1038
1039struct FunctionRNA;
1040
1041/* Struct */
1042
1045 STRUCT_ID = (1 << 0),
1058 STRUCT_UNDO = (1 << 2),
1059
1060 /* internal flags */
1061 STRUCT_RUNTIME = (1 << 3),
1062 /* STRUCT_GENERATED = (1 << 4), */ /* UNUSED */
1091};
1093
1094using StructValidateFunc = int (*)(PointerRNA *ptr, void *data, bool *have_function);
1096 PointerRNA *ptr,
1097 FunctionRNA *func,
1099using StructFreeFunc = void (*)(void *data);
1100using StructRegisterFunc = StructRNA *(*)(Main * bmain,
1101 ReportList *reports,
1102 void *data,
1103 const char *identifier,
1104 StructValidateFunc validate,
1105 StructCallbackFunc call,
1108using StructUnregisterFunc = bool (*)(Main *bmain, StructRNA *type);
1109using StructInstanceFunc = void **(*)(PointerRNA * ptr);
1110
1111struct StructRNA;
1112
1118struct BlenderRNA;
1119
1136
1145 const char *note;
1151 short version;
1158};
1159
1160/* Primitive types. */
1161
1163 const char *value;
1164};
1165
1168};
1169
1171 float value;
1172};
1173
1175 bool value;
1176};
1177
1178} // namespace blender
1179
1180#endif /* __RNA_TYPES_H__ */
#define ENUM_OPERATORS(_enum_type)
#define C
Definition RandGen.cpp:29
btScalar max
void append(const T &value)
const T & last(const int64_t n=0) const
bool is_empty() const
#define T
ENUM_OPERATORS(Layer::Flags)
void free(Subdiv *subdiv)
Definition subdiv.cc:192
BMesh Iterators.
BLI_assert(slot->slot_subtype.map==BMO_OP_SLOT_SUBTYPE_MAP_FLT)
bool(*)(PointerRNA *ptr, PropertyRNA *prop, bool value, bool is_set) BooleanPropertyGetTransformFunc
Definition RNA_types.hh:776
__int64 int64_t
Definition BKE_text.h:90
int(*)(PointerRNA *ptr, void *data, bool *have_function) StructValidateFunc
void(*)(PointerRNA *ptr, PropertyRNA *prop, const int *new_values, const int *curr_values, bool is_set, int *r_values) IntArrayPropertySetTransformFunc
Definition RNA_types.hh:808
constexpr int64_t ANCESTOR_POINTERRNA_DEFAULT_SIZE
Definition RNA_types.hh:42
@ STRUCT_ID_REFCOUNT
@ STRUCT_PUBLIC_NAMESPACE_INHERIT
@ STRUCT_NO_IDPROPERTIES
@ STRUCT_RNA_DEFINITION
@ STRUCT_PUBLIC_NAMESPACE
@ STRUCT_CONTAINS_DATABLOCK_IDPROPERTIES
@ STRUCT_NO_DATABLOCK_IDPROPERTIES
@ STRUCT_FREE_POINTERS
@ STRUCT_NO_CONTEXT_WITHOUT_OWNER_ID
@ STRUCT_RUNTIME
int(*)(PointerRNA *ptr, PropertyRNA *prop, int value, bool is_set) EnumPropertyGetTransformFunc
Definition RNA_types.hh:914
void(*)(PointerRNA *ptr, PropertyRNA *prop, bool *r_values) BooleanArrayPropertyGetFunc
Definition RNA_types.hh:783
std::string(*)(PointerRNA *ptr, PropertyRNA *prop) StringPropertyGetFunc
Definition RNA_types.hh:840
void(*)(PointerRNA *ptr, PropertyRNA *prop, const float *values) FloatArrayPropertySetFunc
Definition RNA_types.hh:826
void(*)(PointerRNA *ptr, PropertyRNA *prop, const bool *r_values) BooleanArrayPropertySetFunc
Definition RNA_types.hh:784
void(*)(PointerRNA *ptr, PropertyRNA *prop, float *values) FloatArrayPropertyGetFunc
Definition RNA_types.hh:825
@ PROP_UNIT_POWER
Definition RNA_types.hh:232
@ PROP_UNIT_LENGTH
Definition RNA_types.hh:222
@ PROP_UNIT_CAMERA
Definition RNA_types.hh:231
@ PROP_UNIT_TIME_ABSOLUTE
Definition RNA_types.hh:228
@ PROP_UNIT_VELOCITY
Definition RNA_types.hh:229
@ PROP_UNIT_COLOR_TEMPERATURE
Definition RNA_types.hh:235
@ PROP_UNIT_FREQUENCY
Definition RNA_types.hh:236
@ PROP_UNIT_ROTATION
Definition RNA_types.hh:226
@ PROP_UNIT_AREA
Definition RNA_types.hh:223
@ PROP_UNIT_TEMPERATURE
Definition RNA_types.hh:233
@ PROP_UNIT_NONE
Definition RNA_types.hh:221
@ PROP_UNIT_VOLUME
Definition RNA_types.hh:224
@ PROP_UNIT_ACCELERATION
Definition RNA_types.hh:230
@ PROP_UNIT_WAVELENGTH
Definition RNA_types.hh:234
@ PROP_UNIT_MASS
Definition RNA_types.hh:225
@ PROP_UNIT_TIME
Definition RNA_types.hh:227
@ FUNC_USE_SELF_TYPE
@ FUNC_ALLOW_WRITE
@ FUNC_USE_REPORTS
@ FUNC_USE_SELF_ID
Definition RNA_types.hh:980
@ FUNC_USE_MAIN
@ FUNC_FREE_POINTERS
@ FUNC_NO_SELF
Definition RNA_types.hh:998
@ FUNC_SELF_AS_RNA
Definition RNA_types.hh:991
@ FUNC_REGISTER_OPTIONAL
@ FUNC_REGISTER
@ FUNC_USE_CONTEXT
int(*)(PointerRNA *ptr, PropertyRNA *prop) IntPropertyGetFunc
Definition RNA_types.hh:796
void(*)(PointerRNA *ptr, PropertyRNA *prop, const int *values) IntArrayPropertySetFunc
Definition RNA_types.hh:805
std::optional< std::string >(*)(const bContext *C, PointerRNA *ptr, PropertyRNA *prop) StringPropertyPathFilterFunc
Definition RNA_types.hh:908
bool(*)(PointerRNA *ptr, PropertyRNA *prop, bool new_value, bool curr_value, bool is_set) BooleanPropertySetTransformFunc
Definition RNA_types.hh:780
void(*)(PointerRNA *ptr, PropertyRNA *prop, int value) EnumPropertySetFunc
Definition RNA_types.hh:913
PropertyPathTemplateType
Definition RNA_types.hh:564
@ PROP_VARIABLES_NONE
Definition RNA_types.hh:567
@ PROP_VARIABLES_PROJECT
Definition RNA_types.hh:577
@ PROP_VARIABLES_RENDER_OUTPUT
Definition RNA_types.hh:572
PropertyOverrideFlag
Definition RNA_types.hh:586
@ PROPOVERRIDE_NO_PROP_NAME
Definition RNA_types.hh:622
@ PROPOVERRIDE_LIBRARY_INSERTION
Definition RNA_types.hh:614
@ PROPOVERRIDE_OVERRIDABLE_LIBRARY
Definition RNA_types.hh:588
@ PROPOVERRIDE_IGNORE
Definition RNA_types.hh:609
@ PROPOVERRIDE_NO_COMPARISON
Definition RNA_types.hh:596
void(*)(PointerRNA *ptr, PropertyRNA *prop, int *values) IntArrayPropertyGetFunc
Definition RNA_types.hh:804
void(*)(PointerRNA *ptr, PropertyRNA *prop, int *min, int *max, int *softmin, int *softmax) IntPropertyRangeFunc
Definition RNA_types.hh:814
int(*)(PointerRNA *ptr, PropertyRNA *prop, int value, bool is_set) IntPropertyGetTransformFunc
Definition RNA_types.hh:798
StructRNA *(*)(PointerRNA *ptr) PointerPropertyTypeFunc
Definition RNA_types.hh:856
float(*)(PointerRNA *ptr, PropertyRNA *prop, float value, bool is_set) FloatPropertyGetTransformFunc
Definition RNA_types.hh:819
unsigned int uint32_t
Definition BKE_text.h:81
int(*)(PointerRNA *ptr, PropertyRNA *prop) EnumPropertyGetFunc
Definition RNA_types.hh:912
void(*)(PointerRNA *ptr, PropertyRNA *prop, bool value) BooleanPropertySetFunc
Definition RNA_types.hh:775
PropertyScaleType
Definition RNA_types.hh:251
@ PROP_SCALE_LOG
Definition RNA_types.hh:258
@ PROP_SCALE_CUBIC
Definition RNA_types.hh:263
@ PROP_SCALE_LINEAR
Definition RNA_types.hh:253
std::string(*)(PointerRNA *ptr, PropertyRNA *prop, const std::string &new_value, const std::string &curr_value, bool is_set) StringPropertySetTransformFunc
Definition RNA_types.hh:849
PropertySubType operator|(const PropertySubType subtype, const PropertyUnit unit)
Definition RNA_types.hh:357
eStringPropertySearchFlag
Definition RNA_types.hh:869
@ PROP_STRING_SEARCH_SUPPORTED
Definition RNA_types.hh:874
@ PROP_STRING_SEARCH_SORT
Definition RNA_types.hh:876
@ PROP_STRING_SEARCH_SUGGESTION
Definition RNA_types.hh:883
@ PROP_BOOLEAN
Definition RNA_types.hh:210
@ PROP_POINTER
Definition RNA_types.hh:215
@ PROP_STRING
Definition RNA_types.hh:213
@ PROP_COLLECTION
Definition RNA_types.hh:216
BMesh const char void * data
bool(*)(Main *bmain, StructRNA *type) StructUnregisterFunc
@ PROP_RAW_UINT8
Definition RNA_types.hh:716
@ PROP_RAW_DOUBLE
Definition RNA_types.hh:714
@ PROP_RAW_INT8
Definition RNA_types.hh:720
@ PROP_RAW_UINT16
Definition RNA_types.hh:717
@ PROP_RAW_INT
Definition RNA_types.hh:710
@ PROP_RAW_UINT64
Definition RNA_types.hh:719
@ PROP_RAW_SHORT
Definition RNA_types.hh:711
@ PROP_RAW_FLOAT
Definition RNA_types.hh:715
@ PROP_RAW_INT64
Definition RNA_types.hh:718
@ PROP_RAW_BOOLEAN
Definition RNA_types.hh:713
@ PROP_RAW_UNSET
Definition RNA_types.hh:709
@ PROP_RAW_CHAR
Definition RNA_types.hh:712
void(*)( PointerRNA *ptr, PropertyRNA *prop, float *min, float *max, float *softmin, float *softmax) FloatPropertyRangeFunc
Definition RNA_types.hh:837
int(*)(PointerRNA *ptr, PropertyRNA *prop) StringPropertyLengthFunc
Definition RNA_types.hh:841
void(*)(PointerRNA *ptr, PropertyRNA *prop, const float *new_values, const float *curr_values, bool is_set, float *r_values) FloatArrayPropertySetTransformFunc
Definition RNA_types.hh:831
int(*)(PointerRNA *ptr, PropertyRNA *prop, int new_value, int curr_value, bool is_set) IntPropertySetTransformFunc
Definition RNA_types.hh:802
void(*)(void *data) StructFreeFunc
void(*)(PointerRNA *ptr, PropertyRNA *prop, const bool *new_values, const bool *curr_values, bool is_set, bool *r_values) BooleanArrayPropertySetTransformFunc
Definition RNA_types.hh:789
void(*)(PointerRNA *ptr, PropertyRNA *prop, float value) FloatPropertySetFunc
Definition RNA_types.hh:818
void(*)(bContext *C, ReportList *reports, PointerRNA *ptr, ParameterList *parms) CallFunc
void(*)( PointerRNA *ptr, PropertyRNA *prop, const float *curr_values, bool is_set, float *r_values) FloatArrayPropertyGetTransformFunc
Definition RNA_types.hh:829
StructRNA *(*)(Main *bmain, ReportList *reports, void *data, const char *identifier, StructValidateFunc validate, StructCallbackFunc call, StructFreeFunc free) StructRegisterFunc
bool(*)(PointerRNA *ptr, PropertyRNA *prop) BooleanPropertyGetFunc
Definition RNA_types.hh:774
float(*)(PointerRNA *ptr, PropertyRNA *prop, float new_value, float curr_value, bool is_set) FloatPropertySetTransformFunc
Definition RNA_types.hh:823
void(*)(const bContext *C, PointerRNA *ptr, PropertyRNA *prop, const char *edit_text, FunctionRef< void(StringPropertySearchVisitParams)> visit_fn) StringPropertySearchFunc
Definition RNA_types.hh:897
@ PROP_TEXTEDIT_UPDATE
Definition RNA_types.hh:396
@ PROP_DEG_SYNC_ONLY
Definition RNA_types.hh:515
@ PROP_CONTEXT_UPDATE
Definition RNA_types.hh:477
@ PROP_CONTEXT_PROPERTY_UPDATE
Definition RNA_types.hh:478
@ PROP_EDITABLE
Definition RNA_types.hh:376
@ PROP_ENUM_NO_CONTEXT
Definition RNA_types.hh:500
@ PROP_ENUM_FLAG
Definition RNA_types.hh:474
@ PROP_PROPORTIONAL
Definition RNA_types.hh:419
@ PROP_ICONS_REVERSE
Definition RNA_types.hh:400
@ PROP_ICONS_CONSECUTIVE
Definition RNA_types.hh:399
@ PROP_SKIP_PRESET
Definition RNA_types.hh:543
@ PROP_PATH_OUTPUT
Definition RNA_types.hh:521
@ PROP_PATH_SUPPORTS_TEMPLATES
Definition RNA_types.hh:540
@ PROP_FORCE_UNDO
Definition RNA_types.hh:552
@ PROP_DYNAMIC
Definition RNA_types.hh:498
@ PROP_THICK_WRAP
Definition RNA_types.hh:493
@ PROP_IDPROPERTY
Definition RNA_types.hh:496
@ PROP_FORCE_GEOMETRY_EVAL
Definition RNA_types.hh:546
@ PROP_SKIP_SAVE
Definition RNA_types.hh:414
@ PROP_PTR_NO_OWNERSHIP
Definition RNA_types.hh:465
@ PROP_REGISTER_OPTIONAL
Definition RNA_types.hh:482
@ PROP_REGISTER
Definition RNA_types.hh:481
@ PROP_ENUM_NO_TRANSLATE
Definition RNA_types.hh:502
@ PROP_PATH_SUPPORTS_BLEND_RELATIVE
Definition RNA_types.hh:526
@ PROP_NEVER_UNLINK
Definition RNA_types.hh:454
@ PROP_ID_REFCOUNT
Definition RNA_types.hh:434
@ PROP_ID_SELF_CHECK
Definition RNA_types.hh:440
@ PROP_NEVER_NULL
Definition RNA_types.hh:447
@ PROP_HIDDEN
Definition RNA_types.hh:408
@ PROP_ANIMATABLE
Definition RNA_types.hh:389
@ PROP_NO_DEG_UPDATE
Definition RNA_types.hh:509
@ PROP_LIB_EXCEPTION
Definition RNA_types.hh:382
signed int int32_t
Definition BKE_text.h:78
const EnumPropertyItem *(*)(bContext *C, PointerRNA *ptr, PropertyRNA *prop, bool *r_free) EnumPropertyItemFunc
Definition RNA_types.hh:921
void(*)(PointerRNA *ptr, PropertyRNA *prop, const std::string &value) StringPropertySetFunc
Definition RNA_types.hh:842
std::optional< std::string >(*)(const PointerRNA *ptr) StructPathFunc
Definition RNA_types.hh:858
void(*)( PointerRNA *ptr, PropertyRNA *prop, const bool *curr_values, bool is_set, bool *r_values) BooleanArrayPropertyGetTransformFunc
Definition RNA_types.hh:787
float(*)(PointerRNA *ptr, PropertyRNA *prop) FloatPropertyGetFunc
Definition RNA_types.hh:817
void(*)(PointerRNA *ptr, PropertyRNA *prop, int value) IntPropertySetFunc
Definition RNA_types.hh:797
int(*)(PointerRNA *ptr, PropertyRNA *prop, int new_value, int curr_value, bool is_set) EnumPropertySetTransformFunc
Definition RNA_types.hh:918
PointerRNA(*)(PointerRNA *ptr) PointerPropertyGetFunc
Definition RNA_types.hh:854
std::string(*)(PointerRNA *ptr, PropertyRNA *prop, const std::string &value, bool is_set) StringPropertyGetTransformFunc
Definition RNA_types.hh:845
@ PROP_ACCELERATION
Definition RNA_types.hh:321
@ PROP_TEMPERATURE
Definition RNA_types.hh:341
@ PROP_PERCENTAGE
Definition RNA_types.hh:307
@ PROP_DISTANCE_CAMERA
Definition RNA_types.hh:314
@ PROP_TIME_ABSOLUTE
Definition RNA_types.hh:311
@ PROP_XYZ_LENGTH
Definition RNA_types.hh:327
@ PROP_FACTOR
Definition RNA_types.hh:308
@ PROP_LAYER_MEMBER
Definition RNA_types.hh:335
@ PROP_TRANSLATION
Definition RNA_types.hh:318
@ PROP_COORDS
Definition RNA_types.hh:331
@ PROP_FILENAME
Definition RNA_types.hh:286
@ PROP_DISTANCE_DIAMETER
Definition RNA_types.hh:351
@ PROP_MATRIX
Definition RNA_types.hh:322
@ PROP_BYTESTRING
Definition RNA_types.hh:295
@ PROP_DISTANCE
Definition RNA_types.hh:313
@ PROP_PIXEL_DIAMETER
Definition RNA_types.hh:350
@ PROP_VELOCITY
Definition RNA_types.hh:320
@ PROP_FILEPATH
Definition RNA_types.hh:284
@ PROP_QUATERNION
Definition RNA_types.hh:324
@ PROP_DIRPATH
Definition RNA_types.hh:285
@ PROP_FREQUENCY
Definition RNA_types.hh:349
@ PROP_COLOR_TEMPERATURE
Definition RNA_types.hh:347
@ PROP_AXISANGLE
Definition RNA_types.hh:325
@ PROP_PASSWORD
Definition RNA_types.hh:298
@ PROP_WAVELENGTH
Definition RNA_types.hh:344
@ PROP_DIRECTION
Definition RNA_types.hh:319
@ PROP_COLOR_GAMMA
Definition RNA_types.hh:329
@ PROP_UNSIGNED
Definition RNA_types.hh:306
@ PARM_REQUIRED
Definition RNA_types.hh:631
@ PARM_PYFUNC_REGISTER_OPTIONAL
Definition RNA_types.hh:643
@ PARM_RNAPTR
Definition RNA_types.hh:633
@ PARM_OUTPUT
Definition RNA_types.hh:632
void(*)(PointerRNA *ptr, PointerRNA value, ReportList *reports) PointerPropertySetFunc
Definition RNA_types.hh:855
int operator&(const PropertySubType subtype, const PropertyUnit unit)
Definition RNA_types.hh:362
void **(*)(PointerRNA *ptr) StructInstanceFunc
int(*)(bContext *C, PointerRNA *ptr, FunctionRNA *func, ParameterList *list) StructCallbackFunc
bool(*)(CollectionPropertyIterator *iter, void *data) IteratorSkipFunc
Definition RNA_types.hh:649
signed short int16_t
Definition BKE_text.h:77
void(*)( PointerRNA *ptr, PropertyRNA *prop, const int *curr_values, bool is_set, int *r_values) IntArrayPropertyGetTransformFunc
Definition RNA_types.hh:806
_W64 int intptr_t
Definition BKE_text.h:119
KERNEL_FEATURE_LIGHT_PASSES KERNEL_FEATURE_PATH_GUIDING float
#define min(a, b)
Definition sort.cc:38
IteratorSkipFunc skip
Definition RNA_types.hh:676
Vector< PointerRNA > items
Definition RNA_types.hh:705
StructCallbackFunc call
StructFreeFunc free
IteratorSkipFunc skip
Definition RNA_types.hh:654
T * data_as() const
Definition RNA_types.hh:139
PointerRNA(ID *owner_id, StructRNA *type, void *data)
Definition RNA_types.hh:99
bool has_type() const
Definition RNA_types.hh:180
PointerRNA(PointerRNA &&)=default
PointerRNA(ID *owner_id, StructRNA *type, void *data, Span< AncestorPointerRNA > parents)
Definition RNA_types.hh:108
PointerRNA(const PointerRNA &)=default
StructRNA * type
Definition RNA_types.hh:63
PointerRNA parent() const
Definition RNA_types.hh:147
Vector< AncestorPointerRNA, ANCESTOR_POINTERRNA_DEFAULT_SIZE > ancestors
Definition RNA_types.hh:90
PointerRNA(ID *owner_id, StructRNA *type, void *data, const PointerRNA &parent)
Definition RNA_types.hh:103
bool has_data() const
Definition RNA_types.hh:169
PointerRNA & operator=(const PointerRNA &other)=default
PointerRNA & operator=(PointerRNA &&other)=default
bool has_owner_id() const
Definition RNA_types.hh:186
RawPropertyType type
Definition RNA_types.hh:725
std::optional< std::string > info
Definition RNA_types.hh:864
bool is_set(uint i)