67 func = rna_Gizmo_draw_func;
70 gzgroup->type->rna_ext.call(
const_cast<bContext *
>(
C), &gz_ptr, func, &
list);
74static void rna_gizmo_draw_select_cb(
const bContext *
C,
wmGizmo *gz,
int select_id)
82 func = rna_Gizmo_draw_select_func;
86 gzgroup->type->rna_ext.call(
const_cast<bContext *
>(
C), &gz_ptr, func, &
list);
90static int rna_gizmo_test_select_cb(
bContext *
C,
wmGizmo *gz,
const int location[2])
98 func = rna_Gizmo_test_select_func;
102 gzgroup->type->rna_ext.call(
C, &gz_ptr, func, &
list);
106 int intersect_id = *
static_cast<int *
>(
ret);
121 const int tweak_flag_int = tweak_flag;
124 func = rna_Gizmo_modal_func;
129 gzgroup->type->rna_ext.call(
C, &gz_ptr, func, &
list);
141static void rna_gizmo_setup_cb(
wmGizmo *gz)
149 func = rna_Gizmo_setup_func;
151 gzgroup->type->rna_ext.call(
static_cast<bContext *
>(
nullptr), &gz_ptr, func, &
list);
163 func = rna_Gizmo_invoke_func;
167 gzgroup->type->rna_ext.call(
C, &gz_ptr, func, &
list);
187 func = rna_Gizmo_exit_func;
191 int cancel_i = cancel;
194 gzgroup->type->rna_ext.call(
C, &gz_ptr, func, &
list);
198static void rna_gizmo_select_refresh_cb(
wmGizmo *gz)
206 func = rna_Gizmo_select_refresh_func;
208 gzgroup->type->rna_ext.call(
static_cast<bContext *
>(
nullptr), &gz_ptr, func, &
list);
215static void rna_Gizmo_bl_idname_set(
PointerRNA *ptr,
const char *value)
218 char *
str =
const_cast<char *
>(
data->type->idname);
226 BLI_assert_msg(0,
"setting the bl_idname on a non-builtin operator");
244 screen =
static_cast<bScreen *
>(screen->id.next))
247 for (
ScrArea &area : screen->areabase) {
248 for (
ARegion ®ion : area.regionbase) {
249 if (region.runtime->gizmo_map) {
250 wmGizmoMap *gzmap = region.runtime->gizmo_map;
252 for (
wmGizmo &gz : gzgroup.gizmos) {
253 if (gz.properties == properties) {
267 wmGizmo *gz = rna_GizmoProperties_find_operator(ptr);
270 return gz->type->srna;
277 return reinterpret_cast<IDProperty **
>(&ptr->data);
287# define RNA_GIZMO_GENERIC_FLOAT_RW_DEF(func_id, member_id) \
288 static float rna_Gizmo_##func_id##_get(PointerRNA *ptr) \
290 wmGizmo *gz = static_cast<wmGizmo *>(ptr->data); \
291 return gz->member_id; \
293 static void rna_Gizmo_##func_id##_set(PointerRNA *ptr, float value) \
295 wmGizmo *gz = static_cast<wmGizmo *>(ptr->data); \
296 gz->member_id = value; \
298# define RNA_GIZMO_GENERIC_FLOAT_ARRAY_INDEX_RW_DEF(func_id, member_id, index) \
299 static float rna_Gizmo_##func_id##_get(PointerRNA *ptr) \
301 wmGizmo *gz = static_cast<wmGizmo *>(ptr->data); \
302 return gz->member_id[index]; \
304 static void rna_Gizmo_##func_id##_set(PointerRNA *ptr, float value) \
306 wmGizmo *gz = static_cast<wmGizmo *>(ptr->data); \
307 gz->member_id[index] = value; \
310# define RNA_GIZMO_GENERIC_FLOAT_ARRAY_RW_DEF(func_id, member_id, len) \
311 static void rna_Gizmo_##func_id##_get(PointerRNA *ptr, float value[len]) \
313 wmGizmo *gz = static_cast<wmGizmo *>(ptr->data); \
314 memcpy(value, gz->member_id, sizeof(float[len])); \
316 static void rna_Gizmo_##func_id##_set(PointerRNA *ptr, const float value[len]) \
318 wmGizmo *gz = static_cast<wmGizmo *>(ptr->data); \
319 memcpy(gz->member_id, value, sizeof(float[len])); \
323# define RNA_GIZMO_GENERIC_FLAG_RW_DEF(func_id, member_id, flag_value) \
324 static bool rna_Gizmo_##func_id##_get(PointerRNA *ptr) \
326 wmGizmo *gz = static_cast<wmGizmo *>(ptr->data); \
327 return (gz->member_id & flag_value) != 0; \
329 static void rna_Gizmo_##func_id##_set(PointerRNA *ptr, bool value) \
331 wmGizmo *gz = static_cast<wmGizmo *>(ptr->data); \
332 SET_FLAG_FROM_TEST(gz->member_id, value, flag_value); \
336# define RNA_GIZMO_GENERIC_FLAG_NEG_RW_DEF(func_id, member_id, flag_value) \
337 static bool rna_Gizmo_##func_id##_get(PointerRNA *ptr) \
339 wmGizmo *gz = static_cast<wmGizmo *>(ptr->data); \
340 return (gz->member_id & flag_value) == 0; \
342 static void rna_Gizmo_##func_id##_set(PointerRNA *ptr, bool value) \
344 wmGizmo *gz = static_cast<wmGizmo *>(ptr->data); \
345 SET_FLAG_FROM_TEST(gz->member_id, !value, flag_value); \
348# define RNA_GIZMO_FLAG_RO_DEF(func_id, member_id, flag_value) \
349 static bool rna_Gizmo_##func_id##_get(PointerRNA *ptr) \
351 wmGizmo *gz = static_cast<wmGizmo *>(ptr->data); \
352 return (gz->member_id & flag_value) != 0; \
355RNA_GIZMO_GENERIC_FLOAT_ARRAY_RW_DEF(
color,
color, 3);
356RNA_GIZMO_GENERIC_FLOAT_ARRAY_RW_DEF(color_hi, color_hi, 3);
358RNA_GIZMO_GENERIC_FLOAT_ARRAY_INDEX_RW_DEF(alpha,
color, 3);
359RNA_GIZMO_GENERIC_FLOAT_ARRAY_INDEX_RW_DEF(alpha_hi, color_hi, 3);
361RNA_GIZMO_GENERIC_FLOAT_ARRAY_RW_DEF(matrix_space, matrix_space, 16);
362RNA_GIZMO_GENERIC_FLOAT_ARRAY_RW_DEF(matrix_basis, matrix_basis, 16);
363RNA_GIZMO_GENERIC_FLOAT_ARRAY_RW_DEF(matrix_offset, matrix_offset, 16);
365static void rna_Gizmo_matrix_world_get(
PointerRNA *ptr,
float value[16])
371RNA_GIZMO_GENERIC_FLOAT_RW_DEF(scale_basis, scale_basis);
372RNA_GIZMO_GENERIC_FLOAT_RW_DEF(line_width, line_width);
373RNA_GIZMO_GENERIC_FLOAT_RW_DEF(select_bias, select_bias);
385RNA_GIZMO_GENERIC_FLAG_RW_DEF(flag_use_operator_tool_properties,
397static void rna_Gizmo_state_select_set(
PointerRNA *ptr,
bool value)
412static bool rna_Gizmo_unregister(
Main *bmain,
StructRNA *type);
418 const char *identifier,
423 const char *error_prefix =
"Registering gizmo class:";
429 wmGizmo dummy_gizmo = {
nullptr};
432 bool have_function[8];
435 dummy_gizmo.
type = &dummy_gt;
436 dummy_gt.
idname = temp_buffers.idname;
440 temp_buffers.idname[0] =
'\0';
443 if (validate(&dummy_gizmo_ptr,
data, have_function) != 0) {
447 if (strlen(identifier) >=
sizeof(temp_buffers.idname)) {
450 "%s '%s' is too long, maximum length is %d",
453 int(
sizeof(temp_buffers.idname)));
463 "%s '%s', bl_idname '%s' has been registered before, unregistering previous",
469 if (!(srna && rna_Gizmo_unregister(bmain, srna))) {
472 "%s '%s', bl_idname '%s' %s",
476 srna ?
"is built-in" :
"could not be unregistered");
487 dummy_gt.idname =
BLI_strdup(temp_buffers.idname);
494 dummy_gt.rna_ext.data =
data;
495 dummy_gt.rna_ext.call = call;
496 dummy_gt.rna_ext.free =
free;
500 dummy_gt.draw = (have_function[i++]) ? rna_gizmo_draw_cb :
nullptr;
501 dummy_gt.draw_select = (have_function[i++]) ? rna_gizmo_draw_select_cb :
nullptr;
502 dummy_gt.test_select = (have_function[i++]) ? rna_gizmo_test_select_cb :
nullptr;
503 dummy_gt.modal = (have_function[i++]) ? rna_gizmo_modal_cb :
nullptr;
506 dummy_gt.setup = (have_function[i++]) ? rna_gizmo_setup_cb :
nullptr;
507 dummy_gt.invoke = (have_function[i++]) ? rna_gizmo_invoke_cb :
nullptr;
508 dummy_gt.exit = (have_function[i++]) ? rna_gizmo_exit_cb :
nullptr;
509 dummy_gt.select_refresh = (have_function[i++]) ? rna_gizmo_select_refresh_cb :
nullptr;
519 return dummy_gt.rna_ext.srna;
522static bool rna_Gizmo_unregister(
Main *bmain,
StructRNA *type)
543static void **rna_Gizmo_instance(
PointerRNA *ptr)
554 return (gz->type && gz->type->rna_ext.srna) ? gz->
type->
rna_ext.
srna : RNA_Gizmo;
572 wmGizmoGroupType *gzgt = rna_GizmoGroupProperties_find_gizmo_group_type(ptr);
582 return reinterpret_cast<IDProperty **
>(&ptr->data);
590 if (gzt ==
nullptr) {
597 if ((gzt->test_select ==
nullptr) && (gzt->draw_select !=
nullptr)) {
600 "GizmoType '%s' is for a 3D gizmo-group. "
601 "The 'draw_select' callback is set where only 'test_select' will be used.",
617 while (gzgroup->gizmos.first()) {
618 WM_gizmo_unlink(&gzgroup->gizmos, gzgroup->parent_gzmap, gzgroup->gizmos.first(),
C);
622static void rna_GizmoGroup_name_get(
PointerRNA *ptr,
char *value)
625 strcpy(value, gzgroup->type->name);
628static int rna_GizmoGroup_name_length(
PointerRNA *ptr)
631 return strlen(gzgroup->type->name);
635static void rna_GizmoGroup_bl_idname_set(
PointerRNA *ptr,
const char *value)
638 char *
str =
const_cast<char *
>(
data->type->idname);
646 BLI_assert_msg(0,
"setting the bl_idname on a non-builtin operator");
650static void rna_GizmoGroup_bl_label_set(
PointerRNA *ptr,
const char *value)
653 char *
str =
const_cast<char *
>(
data->type->name);
658 BLI_assert_msg(0,
"setting the bl_label on a non-builtin operator");
675 func = rna_GizmoGroup_poll_func;
679 gzgt->rna_ext.call(
const_cast<bContext *
>(
C), &ptr, func, &
list);
682 visible = *
static_cast<bool *
>(
ret);
697 nullptr, gzgroup->type->rna_ext.srna, gzgroup);
698 func = rna_GizmoGroup_setup_func;
702 gzgroup->type->rna_ext.call(
const_cast<bContext *
>(
C), &gzgroup_ptr, func, &
list);
709 extern FunctionRNA *rna_GizmoGroup_setup_keymap_func;
717 rna_GizmoGroup_setup_keymap_func;
721 gzgt->rna_ext.call(
nullptr, &ptr, func, &
list);
739 nullptr, gzgroup->type->rna_ext.srna, gzgroup);
740 func = rna_GizmoGroup_refresh_func;
744 gzgroup->type->rna_ext.call(
const_cast<bContext *
>(
C), &gzgroup_ptr, func, &
list);
751 extern FunctionRNA *rna_GizmoGroup_draw_prepare_func;
757 nullptr, gzgroup->type->rna_ext.srna, gzgroup);
759 rna_GizmoGroup_draw_prepare_func;
763 gzgroup->type->rna_ext.call(
const_cast<bContext *
>(
C), &gzgroup_ptr, func, &
list);
768static void rna_gizmogroup_invoke_prepare_cb(
const bContext *
C,
773 extern FunctionRNA *rna_GizmoGroup_invoke_prepare_func;
779 nullptr, gzgroup->type->rna_ext.srna, gzgroup);
781 func = rna_GizmoGroup_invoke_prepare_func;
787 gzgroup->type->rna_ext.call(
const_cast<bContext *
>(
C), &gzgroup_ptr, func, &
list);
793static bool rna_GizmoGroup_unregister(
Main *bmain,
StructRNA *type);
798 const char *identifier,
803 const char *error_prefix =
"Registering gizmogroup class:";
813 bool have_function[6];
816 dummy_gizmo_group.
type = &dummy_wgt;
817 dummy_wgt.
name = temp_buffers.name;
818 dummy_wgt.idname = temp_buffers.idname;
823 temp_buffers.idname[0] = temp_buffers.name[0] =
'\0';
826 if (validate(&wgptr,
data, have_function) != 0) {
830 if (strlen(identifier) >=
sizeof(temp_buffers.idname)) {
833 "%s '%s' is too long, maximum length is %d",
836 int(
sizeof(temp_buffers.idname)));
842 wmap_params.
spaceid = dummy_wgt.gzmap_params.spaceid;
843 wmap_params.regionid = dummy_wgt.gzmap_params.regionid;
846 if (gzmap_type ==
nullptr) {
856 if (!(srna && rna_GizmoGroup_unregister(bmain, srna))) {
859 "%s '%s', bl_idname '%s' %s",
863 srna ?
"is built-in" :
"could not be unregistered");
873 const char *strings[] = {
879 '\0', strings_table, strings,
ARRAY_SIZE(strings));
881 dummy_wgt.idname = strings_table[0];
882 dummy_wgt.name = strings_table[1];
893 dummy_wgt.rna_ext.data =
data;
894 dummy_wgt.rna_ext.call = call;
895 dummy_wgt.rna_ext.free =
free;
899 dummy_wgt.poll = (have_function[0]) ? rna_gizmogroup_poll_cb :
nullptr;
900 dummy_wgt.setup_keymap = (have_function[1]) ? rna_gizmogroup_setup_keymap_cb :
nullptr;
901 dummy_wgt.setup = (have_function[2]) ? rna_gizmogroup_setup_cb :
nullptr;
902 dummy_wgt.refresh = (have_function[3]) ? rna_gizmogroup_refresh_cb :
nullptr;
903 dummy_wgt.draw_prepare = (have_function[4]) ? rna_gizmogroup_draw_prepare_cb :
nullptr;
904 dummy_wgt.invoke_prepare = (have_function[5]) ? rna_gizmogroup_invoke_prepare_cb :
nullptr;
907 static_cast<void *
>(&dummy_wgt));
912 STRNCPY(gzgt->owner_id, owner_id);
923 return dummy_wgt.rna_ext.srna;
926static bool rna_GizmoGroup_unregister(
Main *bmain,
StructRNA *type)
947static void **rna_GizmoGroup_instance(
PointerRNA *ptr)
958 return (gzgroup->type && gzgroup->type->rna_ext.srna) ? gzgroup->
type->
rna_ext.
srna :
992 parm =
RNA_def_string(func,
"type",
"Type", 0,
"",
"Gizmo identifier");
1026 srna,
"rna_Gizmo_register",
"rna_Gizmo_unregister",
"rna_Gizmo_instance");
1078 "Region coordinates",
1083 func,
"intersect_id", -1, -1,
INT_MAX,
"",
"Use -1 to skip this gizmo", -1,
INT_MAX);
1090 {0,
nullptr, 0,
nullptr,
nullptr},
1131 parm =
RNA_def_boolean(func,
"cancel",
false,
"Cancel, otherwise confirm",
"");
1177 prop,
"rna_Gizmo_matrix_space_get",
"rna_Gizmo_matrix_space_set",
nullptr);
1184 prop,
"rna_Gizmo_matrix_basis_get",
"rna_Gizmo_matrix_basis_set",
nullptr);
1191 prop,
"rna_Gizmo_matrix_offset_get",
"rna_Gizmo_matrix_offset_set",
nullptr);
1203 prop,
"rna_Gizmo_scale_basis_get",
"rna_Gizmo_scale_basis_set",
nullptr);
1210 prop,
"rna_Gizmo_line_width_get",
"rna_Gizmo_line_width_set",
nullptr);
1217 prop,
"rna_Gizmo_select_bias_get",
"rna_Gizmo_select_bias_set",
nullptr);
1229 prop,
"rna_Gizmo_flag_hide_select_get",
"rna_Gizmo_flag_hide_select_set");
1235 prop,
"rna_Gizmo_flag_hide_keymap_get",
"rna_Gizmo_flag_hide_keymap_set");
1241 prop,
"rna_Gizmo_flag_use_grab_cursor_get",
"rna_Gizmo_flag_use_grab_cursor_set");
1248 prop,
"rna_Gizmo_flag_use_draw_hover_get",
"rna_Gizmo_flag_use_draw_hover_set");
1254 prop,
"rna_Gizmo_flag_use_draw_modal_get",
"rna_Gizmo_flag_use_draw_modal_set");
1260 prop,
"rna_Gizmo_flag_use_draw_value_get",
"rna_Gizmo_flag_use_draw_value_set");
1262 prop,
"Show Value",
"Show an indicator for the current value while dragging");
1267 "rna_Gizmo_flag_use_draw_offset_scale_get",
1268 "rna_Gizmo_flag_use_draw_offset_scale_set");
1270 prop,
"Scale Offset",
"Scale the offset matrix (use to apply screen-space offset)");
1275 prop,
"rna_Gizmo_flag_use_draw_scale_get",
"rna_Gizmo_flag_use_draw_scale_set");
1283 "rna_Gizmo_flag_use_select_background_get",
1284 "rna_Gizmo_flag_use_select_background_set");
1291 "rna_Gizmo_flag_use_operator_tool_properties_get",
1292 "rna_Gizmo_flag_use_operator_tool_properties_set");
1295 "Tool Property Init",
1296 "Merge active tool properties on activation (does not overwrite existing)");
1302 prop,
"rna_Gizmo_flag_use_event_handle_all_get",
"rna_Gizmo_flag_use_event_handle_all_set");
1304 "Handle All Events",
1305 "When highlighted, "
1306 "do not pass events through to be handled by other keymaps");
1312 prop,
"rna_Gizmo_flag_use_tooltip_get",
"rna_Gizmo_flag_use_tooltip_set");
1320 prop,
"rna_Gizmo_flag_use_undo_get",
"rna_Gizmo_flag_use_undo_set");
1361 srna,
"GizmoGroup",
"Storage of an operator being executed, or registered after execution");
1366 srna,
"rna_GizmoGroup_register",
"rna_GizmoGroup_unregister",
"rna_GizmoGroup_instance");
1400 prop,
"Region Type",
"The region where the panel is going to be used in");
1413 "Scale to respect zoom (otherwise zoom independent display size)"},
1418 "Supports culled depth by other objects in the view"},
1425 "Show all while interacting, as well as this group when another is being interacted with"},
1430 "Show all except this group while interacting"},
1435 "Postpone running until tool operator run (when used with a tool)"},
1437 "TOOL_FALLBACK_KEYMAP",
1439 "Use fallback tools keymap",
1440 "Add fallback tools keymap to this gizmo type"},
1445 "The gizmos are made for use with virtual reality sessions and require special redraw "
1447 {0,
nullptr, 0,
nullptr,
nullptr},
1470 func,
"Initialize keymaps for this gizmo group, use fallback keymap when not present");
1489 func,
"Refresh data (called on common state changes such as selection)");
1514 prop,
"rna_GizmoGroup_name_get",
"rna_GizmoGroup_name_length",
nullptr);
1523 "rna_GizmoGroup_gizmos_begin",
1524 "rna_iterator_listbase_next",
1525 "rna_iterator_listbase_end",
1526 "rna_iterator_listbase_get",
#define BLT_I18NCONTEXT_OPERATOR_DEFAULT
#define OPERATOR_RETVAL_CHECK(ret)
#define BLI_assert_msg(a, msg)
void free(Subdiv *subdiv)
void WM_main_add_notifier(uint type, void *reference)
void RNA_def_property_srna(PropertyRNA *prop, const char *type)
BLI_assert(slot->slot_subtype.map==BMO_OP_SLOT_SUBTYPE_MAP_FLT)
void RNA_def_struct_ui_text(StructRNA *srna, const char *name, const char *description)
BLI_STATIC_ASSERT(ARRAY_SIZE(data_mode_strings)==CTX_MODE_NUM+1, "Must have a string for each context mode") const char *CTX_data_mode_string(const bContext *C)
void RNA_def_property_ui_text(PropertyRNA *prop, const char *name, const char *description)
char * STRNCPY(char(&dst)[N], const char *src)
void RNA_def_property_string_sdna(PropertyRNA *prop, const char *structname, const char *propname)
int(*)(PointerRNA *ptr, void *data, bool *have_function) StructValidateFunc
const ListBaseT< wmGizmoGroup > * WM_gizmomap_group_list(wmGizmoMap *gzmap)
PropertyRNA * RNA_def_string(StructOrFunctionRNA *cont_, const char *identifier, const char *default_value, const int maxlen, const char *ui_name, const char *ui_description)
@ STRUCT_NO_DATABLOCK_IDPROPERTIES
void WM_gizmotype_remove_ptr(bContext *C, Main *bmain, wmGizmoType *gzt)
const EnumPropertyItem rna_enum_space_type_items[]
wmGizmoGroupType * WM_gizmogrouptype_append_ptr(void(*wtfunc)(wmGizmoGroupType *, void *), void *userdata)
void RNA_def_property_float_funcs(PropertyRNA *prop, const char *get, const char *set, const char *range)
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)
void RNA_def_struct_refine_func(StructRNA *srna, const char *refine)
const wmGizmoType * WM_gizmotype_find(const StringRef idname, bool quiet)
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 RNA_def_struct_system_idprops_func(StructRNA *srna, const char *system_idproperties)
bool RNA_struct_available_or_report(ReportList *reports, const char *identifier)
void RNA_def_function_ui_description(FunctionRNA *func, const char *description)
void RNA_def_wm_gizmo(BlenderRNA *brna)
void WM_gizmo_group_type_free_ptr(wmGizmoGroupType *gzgt)
const char * RNA_struct_state_owner_get()
char * BLI_strncpy_utf8(char *__restrict dst, const char *__restrict src, size_t dst_maxncpy) ATTR_NONNULL(1
void RNA_api_gizmo(StructRNA *srna)
void * RNA_struct_blender_type_get(StructRNA *srna)
PropertyRNA * RNA_def_pointer(StructOrFunctionRNA *cont_, const char *identifier, const char *type, const char *ui_name, const char *ui_description)
void BPY_RNA_gizmo_wrapper(wmGizmoType *gzt, void *userdata)
void WM_gizmo_group_type_add_ptr_ex(wmGizmoGroupType *gzgt, wmGizmoMapType *gzmap_type)
void RNA_def_property_struct_type(PropertyRNA *prop, const char *type)
void WM_gizmo_calc_matrix_final(const wmGizmo *gz, float r_mat[4][4])
wmGizmoGroupType * WM_gizmogrouptype_find(const StringRef idname, bool quiet)
static void rna_def_gizmogroup(BlenderRNA *brna)
void RNA_def_property_string_maxlength(PropertyRNA *prop, int maxlength)
void WM_gizmo_unlink(ListBaseT< wmGizmo > *gizmolist, wmGizmoMap *gzmap, wmGizmo *gz, bContext *C)
ParameterList * RNA_parameter_list_create(ParameterList *parms, PointerRNA *, FunctionRNA *func)
const EnumPropertyItem rna_enum_operator_return_items[]
PropertyRNA * RNA_def_property(StructOrFunctionRNA *cont_, const char *identifier_c_str, int type, int subtype)
void RNA_def_struct_sdna(StructRNA *srna, const char *structname)
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)
void RNA_struct_free(BlenderRNA *brna, StructRNA *srna)
void RNA_def_parameter_flags(PropertyRNA *prop, PropertyFlag flag_property, ParameterFlag flag_parameter)
void void char * BLI_string_join_array_by_sep_char_with_tableN(char sep, char *table[], const char *strings[], uint strings_num) ATTR_NONNULL(2
eWM_GizmoFlagTweak
Gizmo tweak flag. Bit-flag passed to gizmo while tweaking.
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)
BMesh const char void * data
void RNA_def_property_range(PropertyRNA *prop, double min, double max)
void RNA_def_function_return(FunctionRNA *func, PropertyRNA *ret)
constexpr size_t ARRAY_SIZE(const T(&arg)[N]) noexcept
PointerRNA RNA_pointer_create_discrete(ID *id, StructRNA *type, void *data)
void BPY_RNA_gizmogroup_wrapper(wmGizmoGroupType *gzgt, void *userdata)
static void rna_def_gizmos(BlenderRNA *brna, PropertyRNA *cprop)
void WM_gizmo_group_type_remove_ptr(Main *bmain, wmGizmoGroupType *gzgt)
void RNA_api_gizmogroup(StructRNA *srna)
void WM_gizmotype_free_ptr(wmGizmoType *gzt)
FunctionRNA * RNA_def_function(StructRNA *srna, const char *identifier_c_str, const char *call)
void WM_gizmotype_append_ptr(void(*gtfunc)(wmGizmoType *, void *), void *userdata)
void(*)(void *data) StructFreeFunc
static void rna_def_gizmo(BlenderRNA *brna, PropertyRNA *cprop)
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)
void RNA_def_property_boolean_default(PropertyRNA *prop, bool value)
void RNA_parameter_get_lookup(ParameterList *parms, const char *identifier, void **r_value)
void RNA_def_property_clear_flag(PropertyRNA *prop, PropertyFlag flag)
@ WM_GIZMOGROUPTYPE_DRAW_MODAL_ALL
@ WM_GIZMOGROUPTYPE_VR_REDRAWS
@ WM_GIZMOGROUPTYPE_DEPTH_3D
@ WM_GIZMOGROUPTYPE_PERSISTENT
@ WM_GIZMOGROUPTYPE_TOOL_FALLBACK_KEYMAP
@ WM_GIZMOGROUPTYPE_TOOL_INIT
@ WM_GIZMOGROUPTYPE_SCALE
@ WM_GIZMOGROUPTYPE_SELECT
@ WM_GIZMOGROUPTYPE_DRAW_MODAL_EXCLUDE
@ WM_GIZMO_OPERATOR_TOOL_INIT
@ WM_GIZMO_DRAW_OFFSET_SCALE
@ WM_GIZMO_EVENT_HANDLE_ALL
@ WM_GIZMO_SELECT_BACKGROUND
const EnumPropertyItem rna_enum_region_type_items[]
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)
void BKE_reportf(ReportList *reports, eReportType type, const char *format,...) ATTR_PRINTF_FORMAT(3
@ WM_GIZMO_STATE_HIGHLIGHT
void RNA_def_struct_translation_context(StructRNA *srna, const char *context)
char * BLI_strdup(const char *str) ATTR_WARN_UNUSED_RESULT ATTR_NONNULL(1) ATTR_MALLOC
bool WM_gizmo_select_set(wmGizmoMap *gzmap, wmGizmo *gz, bool select)
StructRNA * RNA_def_struct(BlenderRNA *brna, const char *identifier, const char *from)
void RNA_parameter_set_lookup(ParameterList *parms, const char *identifier, const void *value)
wmGizmoMapType * WM_gizmomaptype_ensure(const wmGizmoMapType_Params *gzmap_params)
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)
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)
void RNA_def_property_update(PropertyRNA *prop, int noteflag, const char *func)
PointerRNA RNA_pointer_create_with_parent(const PointerRNA &parent, StructRNA *type, void *data)
void RNA_def_property_string_funcs(PropertyRNA *prop, const char *get, const char *length, const char *set)
void RNA_define_verify_sdna(bool verify)
PropertyRNA * RNA_def_boolean(StructOrFunctionRNA *cont_, const char *identifier, const bool default_value, const char *ui_name, const char *ui_description)
void rna_iterator_listbase_begin(CollectionPropertyIterator *iter, PointerRNA *ptr, ListBase *lb, IteratorSkipFunc skip)
void RNA_struct_free_extension(StructRNA *srna, ExtensionRNA *rna_ext)
wmGizmo * WM_gizmo_new_ptr(const wmGizmoType *gzt, wmGizmoGroup *gzgroup, PointerRNA *properties)
void RNA_def_struct_name_property(StructRNA *srna, PropertyRNA *prop, const bool allow_replace)
void RNA_def_property_array(PropertyRNA *prop, int length)
const int rna_matrix_dimsize_4x4[]
int(*)(bContext *C, PointerRNA *ptr, FunctionRNA *func, ParameterList *list) StructCallbackFunc
void RNA_parameter_list_free(ParameterList *parms)
BlenderRNA RNA_blender_rna_get()
StructRNA * RNA_def_struct_ptr(BlenderRNA *brna, const char *identifier, StructRNA *srnafrom)