Blender V5.3
RNA_define.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
5#pragma once
6
12
13#include <float.h>
14#include <inttypes.h>
15#include <limits.h>
16
17#include "DNA_listBase.h"
18
19#include "RNA_types.hh"
20
21namespace blender {
22
23#ifdef UNIT_TEST
24# define RNA_MAX_ARRAY_LENGTH 64
25#else
26# define RNA_MAX_ARRAY_LENGTH 64
27#endif
28
29#define RNA_MAX_ARRAY_DIMENSION 3
30
31/* Blender RNA */
32
33struct Scene;
34
35BlenderRNA *RNA_create();
40BlenderRNA *RNA_create_runtime();
41void RNA_define_free(BlenderRNA *brna);
42void RNA_free(BlenderRNA *brna);
43
57void RNA_define_verify_sdna(bool verify);
58void RNA_define_animate_sdna(bool animate);
59void RNA_define_fallback_property_update(int noteflag, const char *updatefunc);
64void RNA_define_lib_overridable(bool make_overridable);
65
66void RNA_init();
67void RNA_bpy_exit();
68void RNA_exit();
69
70/* Struct */
71
75StructRNA *RNA_def_struct_ptr(BlenderRNA *brna, const char *identifier, StructRNA *srnafrom);
76StructRNA *RNA_def_struct(BlenderRNA *brna, const char *identifier, const char *from);
77void RNA_def_struct_sdna(StructRNA *srna, const char *structname);
78void RNA_def_struct_sdna_from(StructRNA *srna, const char *structname, const char *propname);
85void RNA_def_struct_name_property(StructRNA *srna, PropertyRNA *prop, bool allow_replace = false);
86void RNA_def_struct_nested(BlenderRNA *brna, StructRNA *srna, const char *structname);
87void RNA_def_struct_flag(StructRNA *srna, StructFlag flag);
88void RNA_def_struct_clear_flag(StructRNA *srna, StructFlag flag);
89void RNA_def_struct_property_tags(StructRNA *srna, const EnumPropertyItem *prop_tag_defines);
90void RNA_def_struct_refine_func(StructRNA *srna, const char *refine);
91void RNA_def_struct_idprops_func(StructRNA *srna, const char *idproperties);
95void RNA_def_struct_system_idprops_func(StructRNA *srna, const char *system_idproperties);
96void RNA_def_struct_register_funcs(StructRNA *srna,
97 const char *reg,
98 const char *unreg,
99 const char *instance);
108void RNA_def_struct_path_func(StructRNA *srna, const char *path);
109void RNA_def_struct_path_func_runtime(StructRNA *srna, StructPathFunc path_fn);
113void RNA_def_struct_identifier_no_struct_map(StructRNA *srna, const char *identifier);
114void RNA_def_struct_identifier(BlenderRNA *brna, StructRNA *srna, const char *identifier);
115void RNA_def_struct_ui_text(StructRNA *srna, const char *name, const char *description);
116void RNA_def_struct_ui_icon(StructRNA *srna, int icon);
118void RNA_struct_free(BlenderRNA *brna, StructRNA *srna);
119
120void RNA_def_struct_translation_context(StructRNA *srna, const char *context);
121
122/* Compact Property Definitions */
123
125
127 const char *identifier,
128 bool default_value,
129 const char *ui_name,
130 const char *ui_description);
132 const char *identifier,
133 int len,
134 const bool *default_value,
135 const char *ui_name,
136 const char *ui_description);
138 const char *identifier,
139 int len,
140 const bool *default_value,
141 const char *ui_name,
142 const char *ui_description);
144 const char *identifier,
145 int len,
146 const bool *default_value,
147 const char *ui_name,
148 const char *ui_description);
150 const char *identifier,
151 int len,
152 const bool *default_value,
153 const char *ui_name,
154 const char *ui_description);
155
157 const char *identifier,
158 int default_value,
159 int hardmin,
160 int hardmax,
161 const char *ui_name,
162 const char *ui_description,
163 int softmin,
164 int softmax);
166 const char *identifier,
167 int len,
168 const int *default_value,
169 int hardmin,
170 int hardmax,
171 const char *ui_name,
172 const char *ui_description,
173 int softmin,
174 int softmax);
176 const char *identifier,
177 int len,
178 const int *default_value,
179 int hardmin,
180 int hardmax,
181 const char *ui_name,
182 const char *ui_description,
183 int softmin,
184 int softmax);
185
187 const char *identifier,
188 const char *default_value,
189 int maxlen,
190 const char *ui_name,
191 const char *ui_description);
193 const char *identifier,
194 const char *default_value,
195 int maxlen,
196 const char *ui_name,
197 const char *ui_description);
199 const char *identifier,
200 const char *default_value,
201 int maxlen,
202 const char *ui_name,
203 const char *ui_description);
205 const char *identifier,
206 const char *default_value,
207 int maxlen,
208 const char *ui_name,
209 const char *ui_description);
210
212 const char *identifier,
213 const EnumPropertyItem *items,
214 int default_value,
215 const char *ui_name,
216 const char *ui_description);
221 const char *identifier,
222 const EnumPropertyItem *items,
223 int default_value,
224 const char *ui_name,
225 const char *ui_description);
227
229 const char *identifier,
230 float default_value,
231 float hardmin,
232 float hardmax,
233 const char *ui_name,
234 const char *ui_description,
235 float softmin,
236 float softmax);
238 const char *identifier,
239 int len,
240 const float *default_value,
241 float hardmin,
242 float hardmax,
243 const char *ui_name,
244 const char *ui_description,
245 float softmin,
246 float softmax);
248 const char *identifier,
249 int len,
250 const float *default_value,
251 float hardmin,
252 float hardmax,
253 const char *ui_name,
254 const char *ui_description,
255 float softmin,
256 float softmax);
258 const char *identifier,
259 int len,
260 const float *default_value,
261 float hardmin,
262 float hardmax,
263 const char *ui_name,
264 const char *ui_description,
265 float softmin,
266 float softmax);
268 const char *identifier,
269 int rows,
270 int columns,
271 const float *default_value,
272 float hardmin,
273 float hardmax,
274 const char *ui_name,
275 const char *ui_description,
276 float softmin,
277 float softmax);
279 const char *identifier,
280 int len,
281 const float *default_value,
282 float hardmin,
283 float hardmax,
284 const char *ui_name,
285 const char *ui_description,
286 float softmin,
287 float softmax);
289 const char *identifier,
290 int len,
291 const float *default_value,
292 float hardmin,
293 float hardmax,
294 const char *ui_name,
295 const char *ui_description,
296 float softmin,
297 float softmax);
299 const char *identifier,
300 float default_value,
301 float hardmin,
302 float hardmax,
303 const char *ui_name,
304 const char *ui_description,
305 float softmin,
306 float softmax);
308 const char *identifier,
309 int len,
310 const float *default_value,
311 float hardmin,
312 float hardmax,
313 const char *ui_name,
314 const char *ui_description,
315 float softmin,
316 float softmax);
317
318#if 0
319PropertyRNA *RNA_def_float_dynamic_array(StructOrFunctionRNA *cont,
320 const char *identifier,
321 float hardmin,
322 float hardmax,
323 const char *ui_name,
324 const char *ui_description,
325 float softmin,
326 float softmax,
327 unsigned int dimension,
328 unsigned short dim_size[]);
329#endif
330
332 const char *identifier,
333 float default_value,
334 float hardmin,
335 float hardmax,
336 const char *ui_name,
337 const char *ui_description,
338 float softmin,
339 float softmax);
341 const char *identifier,
342 float default_value,
343 float hardmin,
344 float hardmax,
345 const char *ui_name,
346 const char *ui_description,
347 float softmin,
348 float softmax);
349
351 const char *identifier,
352 const char *type,
353 const char *ui_name,
354 const char *ui_description);
356 const char *identifier,
357 StructRNA *type,
358 const char *ui_name,
359 const char *ui_description);
360
362 const char *identifier,
363 const char *type,
364 const char *ui_name,
365 const char *ui_description);
367 const char *identifier,
368 StructRNA *type,
369 const char *ui_name,
370 const char *ui_description);
371
372/* Extended Property Definitions */
373
375 const char *identifier,
376 int type,
377 int subtype);
378
388 const char *structname,
389 const char *propname,
390 int64_t booleanbit);
392 const char *structname,
393 const char *propname,
394 int64_t booleanbit);
410 PropertyRNA *prop, const char *structname, const char *propname, int64_t booleanbit, int len);
411void RNA_def_property_int_sdna(PropertyRNA *prop, const char *structname, const char *propname);
412void RNA_def_property_float_sdna(PropertyRNA *prop, const char *structname, const char *propname);
413void RNA_def_property_string_sdna(PropertyRNA *prop, const char *structname, const char *propname);
430void RNA_def_property_enum_sdna(PropertyRNA *prop, const char *structname, const char *propname);
449 const char *structname,
450 const char *propname);
452 const char *structname,
453 const char *propname);
455 const char *structname,
456 const char *propname,
457 const char *lengthpropname);
458
463
471
479void RNA_def_property_tags(PropertyRNA *prop, int tags);
482void RNA_def_property_multi_array(PropertyRNA *prop, int dimension, const int length[]);
483void RNA_def_property_range(PropertyRNA *prop, double min, double max);
484
490void RNA_def_property_enum_native_type(PropertyRNA *prop, const char *native_enum_type);
491void RNA_def_property_string_maxlength(PropertyRNA *prop, int maxlength);
492void RNA_def_property_struct_type(PropertyRNA *prop, const char *type);
494 PropertyRNA *prop,
495 StructRNA *type);
496
497void RNA_def_property_boolean_default(PropertyRNA *prop, bool value);
499void RNA_def_property_int_default(PropertyRNA *prop, int value);
501void RNA_def_property_float_default(PropertyRNA *prop, float value);
506void RNA_def_property_enum_default(PropertyRNA *prop, int value);
507void RNA_def_property_string_default(PropertyRNA *prop, const char *value);
508
509void RNA_def_property_ui_text(PropertyRNA *prop, const char *name, const char *description);
510void RNA_def_property_ui_name_func(PropertyRNA *prop, const char *name_func);
511void RNA_def_property_ui_description_func(PropertyRNA *prop, const char *description_func);
512
522 const char *note,
523 short version,
524 short removal_version);
525
538 PropertyRNA *prop, double min, double max, double step, int precision);
540void RNA_def_property_ui_icon(PropertyRNA *prop, int icon, int consecutive);
541
542void RNA_def_property_update(PropertyRNA *prop, int noteflag, const char *updatefunc);
543void RNA_def_property_editable_func(PropertyRNA *prop, const char *editable);
544void RNA_def_property_editable_array_func(PropertyRNA *prop, const char *editable);
545
552 const char *diff,
553 const char *store,
554 const char *apply);
555
556using RNAPropertyUpdateFunc = void (*)(Main *, Scene *, PointerRNA *);
558 PointerRNA *ptr,
559 PropertyRNA *prop);
560
564void RNA_def_property_update_notifier(PropertyRNA *prop, int noteflag);
565void RNA_def_property_poll_runtime(PropertyRNA *prop, const void *func);
566
567void RNA_def_property_dynamic_array_funcs(PropertyRNA *prop, const char *getlength);
568void RNA_def_property_boolean_funcs(PropertyRNA *prop, const char *get, const char *set);
570 const char *get,
571 const char *set,
572 const char *range);
574 const char *get,
575 const char *set,
576 const char *range);
578 const char *get,
579 const char *set,
580 const char *item);
582 const char *get,
583 const char *length,
584 const char *set);
586 const char *search,
587 eStringPropertySearchFlag search_flag);
590 PropertyRNA *prop, const char *get, const char *set, const char *type_fn, const char *poll);
592 const char *begin,
593 const char *next,
594 const char *end,
595 const char *get,
596 const char *length,
597 const char *lookupint,
598 const char *lookupstring,
599 const char *assignint);
600
601void RNA_def_property_float_default_func(PropertyRNA *prop, const char *get_default);
602void RNA_def_property_int_default_func(PropertyRNA *prop, const char *get_default);
603void RNA_def_property_boolean_default_func(PropertyRNA *prop, const char *get_default);
604void RNA_def_property_enum_default_func(PropertyRNA *prop, const char *get_default);
605void RNA_def_property_string_default_func(PropertyRNA *prop, const char *get_default);
606
607void RNA_def_property_srna(PropertyRNA *prop, const char *type);
608void RNA_def_py_data(PropertyRNA *prop, void *py_data);
609
610/* API to define callbacks for runtime-defined properties (mainly for Operators, and from the
611 * Python `bpy.props` API).
612 *
613 * These expect 'extended' versions of the callbacks, with both the StructRNA owner and the
614 * PropertyRNA as first arguments.
615 *
616 * The 'Transform' ones allow to add a transform step (applied after getting, or before setting the
617 * value), which only modifies the value, but does not handle actual storage. Currently only used
618 * by `bpy`, more details in the documentation of #BPyPropStore.
619 */
623 BooleanPropertyGetTransformFunc get_transform_fn,
624 BooleanPropertySetTransformFunc set_transform_fn);
626 PropertyRNA *prop,
630 BooleanArrayPropertySetTransformFunc set_transform_fn);
632 IntPropertyGetFunc getfunc,
633 IntPropertySetFunc setfunc,
634 IntPropertyRangeFunc rangefunc,
635 IntPropertyGetTransformFunc get_transform_fn,
636 IntPropertySetTransformFunc set_transform_fn);
640 IntPropertyRangeFunc rangefunc,
641 IntArrayPropertyGetTransformFunc get_transform_fn,
642 IntArrayPropertySetTransformFunc set_transform_fn);
644 FloatPropertyGetFunc getfunc,
645 FloatPropertySetFunc setfunc,
646 FloatPropertyRangeFunc rangefunc,
647 FloatPropertyGetTransformFunc get_transform_fn,
648 FloatPropertySetTransformFunc set_transform_fn);
650 PropertyRNA *prop,
653 FloatPropertyRangeFunc rangefunc,
654 FloatArrayPropertyGetTransformFunc get_transform_fn,
655 FloatArrayPropertySetTransformFunc set_transform_fn);
657 EnumPropertyGetFunc getfunc,
658 EnumPropertySetFunc setfunc,
659 EnumPropertyItemFunc itemfunc,
660 EnumPropertyGetTransformFunc get_transform_fn,
661 EnumPropertySetTransformFunc set_transform_fn);
663 StringPropertyGetFunc getfunc,
664 StringPropertyLengthFunc lengthfunc,
665 StringPropertySetFunc setfunc,
666 StringPropertyGetTransformFunc get_transform_fn,
667 StringPropertySetTransformFunc set_transform_fn);
669 StringPropertySearchFunc search_fn,
670 eStringPropertySearchFlag search_flag);
674 PointerPropertyTypeFunc typefunc);
676
677void RNA_def_property_translation_context(PropertyRNA *prop, const char *context);
678
679/* Function */
680
681FunctionRNA *RNA_def_function(StructRNA *srna, const char *identifier, const char *call);
682FunctionRNA *RNA_def_function_runtime(StructRNA *srna, const char *identifier, CallFunc call);
689void RNA_def_function_ui_description(FunctionRNA *func, const char *description);
690
692 PropertyFlag flag_property,
693 ParameterFlag flag_parameter);
695 PropertyFlag flag_property,
696 ParameterFlag flag_parameter);
698 PropertyPathTemplateType path_template_type);
699
700/* Dynamic Enums
701 * strings are not freed, assumed pointing to static location. */
702
703void RNA_enum_item_add(EnumPropertyItem **items, int *totitem, const EnumPropertyItem *item);
704void RNA_enum_item_add_separator(EnumPropertyItem **items, int *totitem);
705void RNA_enum_items_add(EnumPropertyItem **items, int *totitem, const EnumPropertyItem *item);
707 int *totitem,
708 const EnumPropertyItem *item,
709 int value);
710void RNA_enum_item_end(EnumPropertyItem **items, int *totitem);
711
712/* Memory management */
713
720int RNA_def_property_free_identifier(StructOrFunctionRNA *cont_, const char *identifier);
721
723 const char *identifier,
724 void **handle);
726
728 void (*py_data_clear_fn)(PropertyRNA *prop));
729
730/* Utilities. */
731
732const char *RNA_property_typename(PropertyType type);
733
734bool RNA_validate_identifier(const char *identifier,
735 bool is_property,
736 const char **r_error = nullptr);
737void RNA_identifier_sanitize(char *identifier, bool is_property);
738
739/* Common arguments for length. */
740
741extern const int rna_matrix_dimsize_3x3[];
742extern const int rna_matrix_dimsize_4x4[];
743extern const int rna_matrix_dimsize_4x2[];
744
745/* Common arguments for defaults. */
746
747extern const float rna_default_axis_angle[4];
748extern const float rna_default_quaternion[4];
749extern const float rna_default_scale_3d[3];
750
752#define RNA_DYN_DESCR_MAX 1024
753
754} // namespace blender
These structs are the foundation for all linked lists in the library system.
#define C
Definition RandGen.cpp:29
btScalar max
Definition scene.h:133
IMETHOD Vector diff(const Vector &a, const Vector &b, double dt)
Definition frames.inl:1166
VecBase< float, D > step(VecOp< float, D >, VecOp< float, D >) RET
float length(VecOp< float, D >) RET
ccl_device_inline dual1 len(const ccl_private dual< T > &a)
Definition math_dual.h:263
BMesh Iterators.
void RNA_def_property_srna(PropertyRNA *prop, const char *type)
void RNA_def_struct_ui_text(StructRNA *srna, const char *name, const char *description)
bool(*)(PointerRNA *ptr, PropertyRNA *prop, bool value, bool is_set) BooleanPropertyGetTransformFunc
Definition RNA_types.hh:776
void RNA_def_enum_funcs(PropertyRNA *prop, EnumPropertyItemFunc itemfunc)
PropertyRNA * RNA_def_string_file_path(StructOrFunctionRNA *cont_, const char *identifier, const char *default_value, const int maxlen, const char *ui_name, const char *ui_description)
void RNA_def_property_tags(PropertyRNA *prop, int tags)
void RNA_def_property_editable_func(PropertyRNA *prop, const char *editable)
void RNA_def_property_boolean_funcs_runtime(PropertyRNA *prop, BooleanPropertyGetFunc getfunc, BooleanPropertySetFunc setfunc, BooleanPropertyGetTransformFunc get_transform_fn, BooleanPropertySetTransformFunc set_transform_fn)
void RNA_enum_item_add(EnumPropertyItem **items, int *totitem, const EnumPropertyItem *item)
__int64 int64_t
Definition BKE_text.h:90
void RNA_def_property_ui_text(PropertyRNA *prop, const char *name, const char *description)
void RNA_def_property_deprecated(PropertyRNA *prop, const char *note, const short version, const short removal_version)
void RNA_def_property_float_funcs_runtime(PropertyRNA *prop, FloatPropertyGetFunc getfunc, FloatPropertySetFunc setfunc, FloatPropertyRangeFunc rangefunc, FloatPropertyGetTransformFunc get_transform_fn, FloatPropertySetTransformFunc set_transform_fn)
void RNA_def_property_dynamic_array_funcs(PropertyRNA *prop, const char *getlength)
BlenderRNA * RNA_create_runtime()
void RNA_def_struct_ui_icon(StructRNA *srna, int icon)
void RNA_def_property_string_sdna(PropertyRNA *prop, const char *structname, const char *propname)
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
PropertyRNA * RNA_def_string(StructOrFunctionRNA *cont_, const char *identifier, const char *default_value, const int maxlen, const char *ui_name, const char *ui_description)
void RNA_def_function_output(FunctionRNA *, PropertyRNA *ret)
void RNA_def_property_boolean_bitset_array_sdna(PropertyRNA *prop, const char *structname, const char *propname, const int64_t booleanbit, const int length)
void RNA_def_property_boolean_negative_sdna(PropertyRNA *prop, const char *structname, const char *propname, int64_t booleanbit)
void RNA_def_property_enum_default(PropertyRNA *prop, int value)
void RNA_def_property_free_pointers_set_py_data_callback(void(*py_data_clear_fn)(PropertyRNA *prop))
void RNA_def_property_free_identifier_deferred_finish(StructOrFunctionRNA *cont_, void *handle)
void RNA_def_struct_identifier(BlenderRNA *brna, StructRNA *srna, const char *identifier)
void RNA_def_property_override_funcs(PropertyRNA *prop, const char *diff, const char *store, const char *apply)
void RNA_def_property_boolean_array_default(PropertyRNA *prop, const bool *array)
int(*)(PointerRNA *ptr, PropertyRNA *prop, int value, bool is_set) EnumPropertyGetTransformFunc
Definition RNA_types.hh:914
void RNA_def_property_enum_default_func(PropertyRNA *prop, const char *get_default)
void(*)(PointerRNA *ptr, PropertyRNA *prop, bool *r_values) BooleanArrayPropertyGetFunc
Definition RNA_types.hh:783
void RNA_def_property_ui_scale_type(PropertyRNA *prop, PropertyScaleType ui_scale_type)
std::string(*)(PointerRNA *ptr, PropertyRNA *prop) StringPropertyGetFunc
Definition RNA_types.hh:840
void RNA_def_property_float_funcs(PropertyRNA *prop, const char *get, const char *set, const char *range)
void RNA_def_property_pointer_sdna(PropertyRNA *prop, const char *structname, const char *propname)
void RNA_def_property_ui_description_func(PropertyRNA *prop, const char *description_func)
void RNA_def_property_pointer_funcs(PropertyRNA *prop, const char *get, const char *set, const char *type_fn, const char *poll)
void RNA_def_property_collection_sdna(PropertyRNA *prop, const char *structname, const char *propname, const char *lengthpropname)
PropertyRNA * RNA_def_float_array(StructOrFunctionRNA *cont_, const char *identifier, const int len, const float *default_value, const float hardmin, const float hardmax, const char *ui_name, const char *ui_description, const float softmin, const float softmax)
void(*)(PointerRNA *ptr, PropertyRNA *prop, const float *values) FloatArrayPropertySetFunc
Definition RNA_types.hh:826
PropertyRNA * RNA_def_float_color(StructOrFunctionRNA *cont_, const char *identifier, const int len, const float *default_value, const float hardmin, const float hardmax, const char *ui_name, const char *ui_description, const float softmin, const float softmax)
void RNA_def_struct_refine_func(StructRNA *srna, const char *refine)
void RNA_def_property_boolean_funcs(PropertyRNA *prop, const char *get, const char *set)
void RNA_def_property_multi_array(PropertyRNA *prop, int dimension, const int length[])
void(*)(PointerRNA *ptr, PropertyRNA *prop, const bool *r_values) BooleanArrayPropertySetFunc
Definition RNA_types.hh:784
void RNA_def_struct_system_idprops_func(StructRNA *srna, const char *system_idproperties)
void(*)(PointerRNA *ptr, PropertyRNA *prop, float *values) FloatArrayPropertyGetFunc
Definition RNA_types.hh:825
void RNA_def_function_ui_description(FunctionRNA *func, const char *description)
PropertyRNA * RNA_def_boolean_vector(StructOrFunctionRNA *cont_, const char *identifier, const int len, const bool *default_value, const char *ui_name, const char *ui_description)
void RNA_def_property_string_funcs_runtime(PropertyRNA *prop, StringPropertyGetFunc getfunc, StringPropertyLengthFunc lengthfunc, StringPropertySetFunc setfunc, StringPropertyGetTransformFunc get_transform_fn, StringPropertySetTransformFunc set_transform_fn)
void RNA_define_lib_overridable(const bool make_overridable)
PropertyRNA * RNA_def_enum(StructOrFunctionRNA *cont_, const char *identifier, const EnumPropertyItem *items, const int default_value, const char *ui_name, const char *ui_description)
PropertyRNA * RNA_def_int_vector(StructOrFunctionRNA *cont_, const char *identifier, const int len, const int *default_value, const int hardmin, const int hardmax, const char *ui_name, const char *ui_description, const int softmin, const int softmax)
void RNA_def_property_path_template_type(PropertyRNA *prop, PropertyPathTemplateType path_template_type)
int(*)(PointerRNA *ptr, PropertyRNA *prop) IntPropertyGetFunc
Definition RNA_types.hh:796
PropertyRNA * RNA_def_pointer(StructOrFunctionRNA *cont_, const char *identifier, const char *type, const char *ui_name, const char *ui_description)
void(*)(PointerRNA *ptr, PropertyRNA *prop, const int *values) IntArrayPropertySetFunc
Definition RNA_types.hh:805
PropertyRNA * RNA_def_string_dir_path(StructOrFunctionRNA *cont_, const char *identifier, const char *default_value, const int maxlen, const char *ui_name, const char *ui_description)
void RNA_def_property_flag_hide_from_ui_workaround(PropertyRNA *prop)
bool(*)(PointerRNA *ptr, PropertyRNA *prop, bool new_value, bool curr_value, bool is_set) BooleanPropertySetTransformFunc
Definition RNA_types.hh:780
PropertyRNA * RNA_def_collection_runtime(StructOrFunctionRNA *cont, const char *identifier, StructRNA *type, const char *ui_name, const char *ui_description)
void RNA_def_property_struct_type(PropertyRNA *prop, const char *type)
PropertyRNA * RNA_def_boolean_array(StructOrFunctionRNA *cont_, const char *identifier, const int len, const bool *default_value, const char *ui_name, const char *ui_description)
void(*)(PointerRNA *ptr, PropertyRNA *prop, int value) EnumPropertySetFunc
Definition RNA_types.hh:913
PropertyRNA * RNA_def_float_translation(StructOrFunctionRNA *cont_, const char *identifier, const int len, const float *default_value, const float hardmin, const float hardmax, const char *ui_name, const char *ui_description, const float softmin, const float softmax)
void RNA_def_property_pointer_funcs_runtime(PropertyRNA *prop, PointerPropertyGetFunc getfunc, PointerPropertySetFunc setfunc, PointerPropertyTypeFunc typefunc)
void RNA_def_struct_nested(BlenderRNA *brna, StructRNA *srna, const char *structname)
void RNA_free(BlenderRNA *brna)
void RNA_def_property_string_maxlength(PropertyRNA *prop, int maxlength)
PropertyRNA * RNA_def_pointer_runtime(StructOrFunctionRNA *cont, const char *identifier, StructRNA *type, const char *ui_name, const char *ui_description)
PropertyRNA * RNA_def_float_percentage(StructOrFunctionRNA *cont_, const char *identifier, const float default_value, const float hardmin, const float hardmax, const char *ui_name, const char *ui_description, const float softmin, const float softmax)
void RNA_def_property_enum_bitflag_sdna(PropertyRNA *prop, const char *structname, const char *propname)
void RNA_define_animate_sdna(bool animate)
PropertyPathTemplateType
Definition RNA_types.hh:564
void RNA_init()
Definition rna_access.cc:88
void RNA_def_property_duplicate_pointers(StructOrFunctionRNA *cont_, PropertyRNA *prop)
void RNA_def_property_pointer_default_runtime(PropertyRNA *prop, uint32_t id_session_uid)
const float rna_default_axis_angle[4]
void RNA_def_property_float_array_default(PropertyRNA *prop, const float *array)
void RNA_def_property_ui_range(PropertyRNA *prop, double min, double max, double step, int precision)
void RNA_def_property_float_sdna(PropertyRNA *prop, const char *structname, const char *propname)
PropertyRNA * RNA_def_float_vector(StructOrFunctionRNA *cont_, const char *identifier, const int len, const float *default_value, const float hardmin, const float hardmax, const char *ui_name, const char *ui_description, const float softmin, const float softmax)
PropertyOverrideFlag
Definition RNA_types.hh:586
void RNA_def_property_float_default(PropertyRNA *prop, float value)
void(*)(PointerRNA *ptr, PropertyRNA *prop, int *values) IntArrayPropertyGetFunc
Definition RNA_types.hh:804
void RNA_def_struct_free_pointers(BlenderRNA *brna, StructRNA *srna)
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
void RNA_bpy_exit()
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
PropertyRNA * RNA_def_float_factor(StructOrFunctionRNA *cont_, const char *identifier, const float default_value, const float hardmin, const float hardmax, const char *ui_name, const char *ui_description, const float softmin, const float softmax)
PropertyRNA * RNA_def_property(StructOrFunctionRNA *cont_, const char *identifier_c_str, int type, int subtype)
void RNA_def_property_float_array_funcs_runtime(PropertyRNA *prop, FloatArrayPropertyGetFunc getfunc, FloatArrayPropertySetFunc setfunc, FloatPropertyRangeFunc rangefunc, FloatArrayPropertyGetTransformFunc get_transform_fn, FloatArrayPropertySetTransformFunc set_transform_fn)
unsigned int uint32_t
Definition BKE_text.h:81
void RNA_def_struct_identifier_no_struct_map(StructRNA *srna, const char *identifier)
int(*)(PointerRNA *ptr, PropertyRNA *prop) EnumPropertyGetFunc
Definition RNA_types.hh:912
void RNA_def_property_update_runtime_with_context_and_property(PropertyRNA *prop, RNAPropertyUpdateFuncWithContextAndProperty func)
void RNA_def_struct_sdna(StructRNA *srna, const char *structname)
void(*)(PointerRNA *ptr, PropertyRNA *prop, bool value) BooleanPropertySetFunc
Definition RNA_types.hh:775
void RNA_def_parameter_clear_flags(PropertyRNA *prop, PropertyFlag flag_property, ParameterFlag flag_parameter)
void RNA_def_property_enum_items(PropertyRNA *prop, const EnumPropertyItem *item)
PropertyScaleType
Definition RNA_types.hh:251
void RNA_def_property_string_default(PropertyRNA *prop, const char *value)
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
void RNA_struct_free(BlenderRNA *brna, StructRNA *srna)
bool RNA_validate_identifier(const char *identifier, bool is_property, const char **r_error)
const float rna_default_scale_3d[3]
eStringPropertySearchFlag
Definition RNA_types.hh:869
void RNA_def_parameter_flags(PropertyRNA *prop, PropertyFlag flag_property, ParameterFlag flag_parameter)
void RNA_enum_items_add(EnumPropertyItem **items, int *totitem, const EnumPropertyItem *item)
void RNA_def_property_collection_funcs(PropertyRNA *prop, const char *begin, const char *next, const char *end, const char *get, const char *length, const char *lookupint, const char *lookupstring, const char *assignint)
void RNA_def_property_int_funcs(PropertyRNA *prop, const char *get, const char *set, const char *range)
BlenderRNA * RNA_create()
void RNA_def_property_override_flag(PropertyRNA *prop, PropertyOverrideFlag flag)
void RNA_exit()
void RNA_def_property_string_search_func_runtime(PropertyRNA *prop, StringPropertySearchFunc search_fn, const eStringPropertySearchFlag search_flag)
void RNA_def_property_int_funcs_runtime(PropertyRNA *prop, IntPropertyGetFunc getfunc, IntPropertySetFunc setfunc, IntPropertyRangeFunc rangefunc, IntPropertyGetTransformFunc get_transform_fn, IntPropertySetTransformFunc set_transform_fn)
void RNA_def_property_boolean_sdna(PropertyRNA *prop, const char *structname, const char *propname, int64_t booleanbit)
void RNA_def_property_range(PropertyRNA *prop, double min, double max)
void(*)( PointerRNA *ptr, PropertyRNA *prop, float *min, float *max, float *softmin, float *softmax) FloatPropertyRangeFunc
Definition RNA_types.hh:837
void RNA_def_struct_path_func(StructRNA *srna, const char *path)
void RNA_def_property_string_filepath_filter_func(PropertyRNA *prop, const char *filter)
void RNA_def_property_float_default_func(PropertyRNA *prop, const char *get_default)
void RNA_def_property_subtype(PropertyRNA *prop, PropertySubType subtype)
void RNA_def_property_free_pointers(PropertyRNA *prop)
int(*)(PointerRNA *ptr, PropertyRNA *prop) StringPropertyLengthFunc
Definition RNA_types.hh:841
void RNA_def_function_return(FunctionRNA *func, PropertyRNA *ret)
void RNA_def_struct_duplicate_pointers(BlenderRNA *brna, StructRNA *srna)
void RNA_def_property_ui_name_func(PropertyRNA *prop, const char *name_func)
void RNA_enum_items_add_value(EnumPropertyItem **items, int *totitem, const EnumPropertyItem *item, int value)
void RNA_def_struct_clear_flag(StructRNA *srna, StructFlag flag)
void RNA_def_struct_property_tags(StructRNA *srna, const EnumPropertyItem *prop_tag_defines)
void RNA_enum_item_end(EnumPropertyItem **items, int *totitem)
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
void RNA_def_property_enum_funcs(PropertyRNA *prop, const char *get, const char *set, const char *item)
int(*)(PointerRNA *ptr, PropertyRNA *prop, int new_value, int curr_value, bool is_set) IntPropertySetTransformFunc
Definition RNA_types.hh:802
void RNA_def_struct_sdna_from(StructRNA *srna, const char *structname, const char *propname)
void RNA_def_property_enum_funcs_runtime(PropertyRNA *prop, EnumPropertyGetFunc getfunc, EnumPropertySetFunc setfunc, EnumPropertyItemFunc itemfunc, EnumPropertyGetTransformFunc get_transform_fn, EnumPropertySetTransformFunc set_transform_fn)
FunctionRNA * RNA_def_function(StructRNA *srna, const char *identifier_c_str, const char *call)
void RNA_def_struct_register_funcs(StructRNA *srna, const char *reg, const char *unreg, const char *instance)
void RNA_def_property_enum_sdna(PropertyRNA *prop, const char *structname, const char *propname)
PropertyRNA * RNA_def_collection(StructOrFunctionRNA *cont_, const char *identifier, const char *type, const char *ui_name, const char *ui_description)
void RNA_def_property_boolean_default(PropertyRNA *prop, bool value)
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 RNA_def_property_translation_context(PropertyRNA *prop, const char *context)
void RNA_def_property_clear_flag(PropertyRNA *prop, PropertyFlag flag)
const int rna_matrix_dimsize_4x2[]
void RNA_def_struct_idprops_func(StructRNA *srna, const char *idproperties)
void RNA_def_property_struct_runtime(StructOrFunctionRNA *cont, PropertyRNA *prop, StructRNA *type)
void(*)( PointerRNA *ptr, PropertyRNA *prop, const float *curr_values, bool is_set, float *r_values) FloatArrayPropertyGetTransformFunc
Definition RNA_types.hh:829
void RNA_identifier_sanitize(char *identifier, bool is_property)
void RNA_def_function_flag(FunctionRNA *func, FunctionFlag flag)
void RNA_def_property_flag(PropertyRNA *prop, PropertyFlag flag)
PropertyRNA * RNA_def_int(StructOrFunctionRNA *cont_, const char *identifier, const int default_value, const int hardmin, const int hardmax, const char *ui_name, const char *ui_description, const int softmin, const int softmax)
void RNA_def_struct_flag(StructRNA *srna, StructFlag flag)
PropertyRNA * RNA_def_float_vector_xyz(StructOrFunctionRNA *cont_, const char *identifier, const int len, const float *default_value, const float hardmin, const float hardmax, const char *ui_name, const char *ui_description, const float softmin, const float softmax)
void RNA_define_fallback_property_update(int noteflag, const char *updatefunc)
void RNA_def_struct_path_func_runtime(StructRNA *srna, StructPathFunc path_fn)
void RNA_def_property_boolean_default_func(PropertyRNA *prop, const char *get_default)
PropertyRNA * RNA_def_boolean_layer(StructOrFunctionRNA *cont_, const char *identifier, const int len, const bool *default_value, const char *ui_name, const char *ui_description)
bool(*)(PointerRNA *ptr, PropertyRNA *prop) BooleanPropertyGetFunc
Definition RNA_types.hh:774
FunctionRNA * RNA_def_function_runtime(StructRNA *srna, const char *identifier, CallFunc call)
void RNA_def_property_override_clear_flag(PropertyRNA *prop, PropertyOverrideFlag flag)
float(*)(PointerRNA *ptr, PropertyRNA *prop, float new_value, float curr_value, bool is_set) FloatPropertySetTransformFunc
Definition RNA_types.hh:823
void RNA_def_struct_translation_context(StructRNA *srna, const char *context)
void RNA_def_property_int_array_default(PropertyRNA *prop, const int *array)
void StructOrFunctionRNA
const float rna_default_quaternion[4]
void RNA_enum_item_add_separator(EnumPropertyItem **items, int *totitem)
PropertyRNA * RNA_def_float_rotation(StructOrFunctionRNA *cont_, const char *identifier, const int len, const float *default_value, const float hardmin, const float hardmax, const char *ui_name, const char *ui_description, const float softmin, const float softmax)
void RNA_def_property_enum_native_type(PropertyRNA *prop, const char *native_enum_type)
void(*)(const bContext *C, PointerRNA *ptr, PropertyRNA *prop, const char *edit_text, FunctionRef< void(StringPropertySearchVisitParams)> visit_fn) StringPropertySearchFunc
Definition RNA_types.hh:897
void RNA_def_property_editable_array_func(PropertyRNA *prop, const char *editable)
iter begin(iter)
void RNA_def_property_poll_runtime(PropertyRNA *prop, const void *func)
const char * RNA_property_typename(PropertyType type)
StructRNA * RNA_def_struct(BlenderRNA *brna, const char *identifier, const char *from)
void RNA_def_property_int_sdna(PropertyRNA *prop, const char *structname, const char *propname)
void RNA_def_property_update_notifier(PropertyRNA *prop, const int noteflag)
PropertyRNA * RNA_def_float_distance(StructOrFunctionRNA *cont_, const char *identifier, const float default_value, const float hardmin, const float hardmax, const char *ui_name, const char *ui_description, const float softmin, const float softmax)
void(*)(bContext *C, PointerRNA *ptr, PropertyRNA *prop) RNAPropertyUpdateFuncWithContextAndProperty
void RNA_def_property_update_runtime(PropertyRNA *prop, RNAPropertyUpdateFunc func)
PropertyRNA * RNA_def_int_array(StructOrFunctionRNA *cont_, const char *identifier, const int len, const int *default_value, const int hardmin, const int hardmax, const char *ui_name, const char *ui_description, const int softmin, const int softmax)
const EnumPropertyItem *(*)(bContext *C, PointerRNA *ptr, PropertyRNA *prop, bool *r_free) EnumPropertyItemFunc
Definition RNA_types.hh:921
void RNA_def_property_int_array_funcs_runtime(PropertyRNA *prop, IntArrayPropertyGetFunc getfunc, IntArrayPropertySetFunc setfunc, IntPropertyRangeFunc rangefunc, IntArrayPropertyGetTransformFunc get_transform_fn, IntArrayPropertySetTransformFunc set_transform_fn)
PropertyRNA * RNA_def_enum_flag(StructOrFunctionRNA *cont_, const char *identifier, const EnumPropertyItem *items, const int default_value, const char *ui_name, const char *ui_description)
PropertyRNA * RNA_def_boolean_layer_member(StructOrFunctionRNA *cont_, const char *identifier, const int len, const bool *default_value, const char *ui_name, const char *ui_description)
void(*)(PointerRNA *ptr, PropertyRNA *prop, const std::string &value) StringPropertySetFunc
Definition RNA_types.hh:842
void RNA_def_property_update(PropertyRNA *prop, int noteflag, const char *func)
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
PropertyRNA * RNA_def_string_file_name(StructOrFunctionRNA *cont_, const char *identifier, const char *default_value, const int maxlen, const char *ui_name, const char *ui_description)
void(*)(Main *, Scene *, PointerRNA *) RNAPropertyUpdateFunc
int RNA_def_property_free_identifier(StructOrFunctionRNA *cont_, const char *identifier)
void RNA_def_property_string_funcs(PropertyRNA *prop, const char *get, const char *length, const char *set)
void RNA_def_func_free_pointers(FunctionRNA *func)
void RNA_define_verify_sdna(bool verify)
int(*)(PointerRNA *ptr, PropertyRNA *prop, int new_value, int curr_value, bool is_set) EnumPropertySetTransformFunc
Definition RNA_types.hh:918
int RNA_def_property_free_identifier_deferred_prepare(StructOrFunctionRNA *cont_, const char *identifier, void **handle)
PointerRNA(*)(PointerRNA *ptr) PointerPropertyGetFunc
Definition RNA_types.hh:854
void RNA_def_func_duplicate_pointers(FunctionRNA *func)
std::string(*)(PointerRNA *ptr, PropertyRNA *prop, const std::string &value, bool is_set) StringPropertyGetTransformFunc
Definition RNA_types.hh:845
PropertyRNA * RNA_def_boolean(StructOrFunctionRNA *cont_, const char *identifier, const bool default_value, const char *ui_name, const char *ui_description)
PropertyRNA * RNA_def_float_matrix(StructOrFunctionRNA *cont_, const char *identifier, const int rows, const int columns, const float *default_value, const float hardmin, const float hardmax, const char *ui_name, const char *ui_description, const float softmin, const float softmax)
void RNA_define_free(BlenderRNA *)
void RNA_def_property_int_default(PropertyRNA *prop, int value)
void RNA_struct_free_extension(StructRNA *srna, ExtensionRNA *rna_ext)
void RNA_def_struct_name_property(StructRNA *srna, PropertyRNA *prop, const bool allow_replace)
void(*)(PointerRNA *ptr, PointerRNA value, ReportList *reports) PointerPropertySetFunc
Definition RNA_types.hh:855
void RNA_def_property_int_default_func(PropertyRNA *prop, const char *get_default)
PropertyRNA * RNA_def_float(StructOrFunctionRNA *cont_, const char *identifier, const float default_value, const float hardmin, const float hardmax, const char *ui_name, const char *ui_description, const float softmin, const float softmax)
void RNA_def_property_array(PropertyRNA *prop, int length)
const int rna_matrix_dimsize_4x4[]
void RNA_def_property_boolean_array_funcs_runtime(PropertyRNA *prop, BooleanArrayPropertyGetFunc getfunc, BooleanArrayPropertySetFunc setfunc, BooleanArrayPropertyGetTransformFunc get_transform_fn, BooleanArrayPropertySetTransformFunc set_transform_fn)
void RNA_def_py_data(PropertyRNA *prop, void *py_data)
void RNA_def_property_ui_icon(PropertyRNA *prop, int icon, int consecutive)
void RNA_def_property_string_search_func(PropertyRNA *prop, const char *search, const eStringPropertySearchFlag search_flag)
void RNA_def_property_string_default_func(PropertyRNA *prop, const char *get_default)
void(*)( PointerRNA *ptr, PropertyRNA *prop, const int *curr_values, bool is_set, int *r_values) IntArrayPropertyGetTransformFunc
Definition RNA_types.hh:806
const int rna_matrix_dimsize_3x3[]
StructRNA * RNA_def_struct_ptr(BlenderRNA *brna, const char *identifier, StructRNA *srnafrom)
#define min(a, b)
Definition sort.cc:38