48 static const float VecZero[3] = {0, 0, 0};
49 static const float VecOne[3] = {1, 1, 1};
54 static const char OP_RESIZE[] =
"TRANSFORM_OT_resize";
56 static const char OP_SHEAR[] =
"TRANSFORM_OT_shear";
57 static const char OP_BEND[] =
"TRANSFORM_OT_bend";
60 static const char OP_TILT[] =
"TRANSFORM_OT_tilt";
62 static const char OP_MIRROR[] =
"TRANSFORM_OT_mirror";
180 uiItemsEnumO(layout,
"TRANSFORM_OT_select_orientation",
"orientation");
191 ot->
name =
"Select Orientation";
193 ot->
idname =
"TRANSFORM_OT_select_orientation";
239 ot->
name =
"Delete Orientation";
241 ot->
idname =
"TRANSFORM_OT_delete_orientation";
264 "Create Orientation's 'use' parameter only valid in a 3DView context");
287 ot->
name =
"Create Orientation";
288 ot->
description =
"Create transformation orientation from selection";
289 ot->
idname =
"TRANSFORM_OT_create_orientation";
302 "Use the current view instead of the active object to create the new orientation");
307 ot->
srna,
"use",
false,
"Use After Creation",
"Select orientation after its creation");
311 "Overwrite Previous",
312 "Overwrite previously created orientation with same name");
315 #ifdef USE_LOOPSLIDE_HACK
327 bool mesh_select_mode[3];
332 short selectmode_orig;
350 # error "loopslide hack removed!"
355 #ifdef USE_LOOPSLIDE_HACK
405 #if defined(WITH_INPUT_NDOF) && 0
425 if (
t->tsnap.targetSnap && ((
t->tsnap.status &
TARGET_INIT) == 0)) {
426 t->tsnap.targetSnap(
t);
439 if (mode_prev !=
t->mode) {
446 if (item->
mode ==
t->mode) {
537 if (
STREQ(prop_id,
"constraint_axis") &&
549 if (
STREQ(prop_id,
"orient_axis")) {
578 if (
STREQ(prop_id,
"use_snap_project")) {
614 ot->
srna,
"orient_matrix", 3, 3,
NULL, 0.0f, 0.0f,
"Matrix",
"", 0.0f, 0.0f);
641 "proportional_edit_falloff",
644 "Proportional Falloff",
645 "Falloff type for proportional editing mode");
692 ot->
srna,
"use_snap_selectable",
false,
"Target: Exclude Non-Selectable",
"");
696 ot->
srna,
"snap_point", 3,
NULL, -FLT_MAX, FLT_MAX,
"Point",
"", -FLT_MAX, FLT_MAX);
703 ot->
srna,
"snap_normal", 3,
NULL, -FLT_MAX, FLT_MAX,
"Normal",
"", -FLT_MAX, FLT_MAX);
713 "Edit Grease Pencil",
714 "Edit selected Grease Pencil strokes");
725 ot->
srna,
"texture_space", 0,
"Edit Texture Space",
"Edit object data texture space");
728 ot->
srna,
"remove_on_cancel", 0,
"Remove on Cancel",
"Remove elements on cancel");
734 ot->
srna,
"correct_uv",
true,
"Correct UVs",
"Correct UV coordinates when transforming");
747 ot->
srna,
"view2d_edge_pan",
false,
"Edge Pan",
"Enable edge panning in 2D view");
755 "Confirm on Release",
756 "Always confirm operation when releasing button");
765 "use_automerge_and_split",
767 "Auto Merge & Split",
768 "Forces the use of Auto Merge and Split");
790 ot->
srna,
"value", 3,
NULL, -FLT_MAX, FLT_MAX,
"Move",
"", -FLT_MAX, FLT_MAX);
817 ot->
srna,
"value", 3,
VecOne, -FLT_MAX, FLT_MAX,
"Scale",
"", -FLT_MAX, FLT_MAX);
821 "mouse_dir_constraint",
826 "Mouse Directional Constraint",
856 ot->
srna,
"value", 3,
VecOne, -FLT_MAX, FLT_MAX,
"Scale",
"", -FLT_MAX, FLT_MAX);
869 ot->
description =
"Trackball style rotation of selected items";
883 ot->
srna,
"value", 2,
NULL, -FLT_MAX, FLT_MAX,
"Angle",
"", -FLT_MAX, FLT_MAX);
923 ot->
description =
"Tilt selected control vertices of 3D curve";
947 ot->
description =
"Bend selected items between the 3D cursor and the mouse";
982 ot->
description =
"Shear selected items along the horizontal screen axis";
1019 RNA_def_float(
ot->
srna,
"value", 0, -FLT_MAX, FLT_MAX,
"Distance",
"", -FLT_MAX, FLT_MAX);
1029 ot->
name =
"Shrink/Fatten";
1030 ot->
description =
"Shrink/fatten selected vertices along normals";
1048 "Scale the offset to give more even thickness");
1059 ot->
description =
"Move selected items outward in a spherical shape around geometric center";
1082 ot->
description =
"Mirror selected items around one or more axes";
1100 ot->
name =
"Scale B-Bone";
1101 ot->
description =
"Scale selected bendy bones display size";
1114 ot->
srna,
"value", 3,
VecOne, -FLT_MAX, FLT_MAX,
"Display Size",
"", -FLT_MAX, FLT_MAX);
1147 "Make the edge loop match the shape of the adjacent edge loop");
1155 "When Even mode is active, flips between the two adjacent edge loops");
1164 ot->
name =
"Vertex Slide";
1182 "Make the edge loop match the shape of the adjacent edge loop");
1190 "When Even mode is active, flips between the two adjacent edge loops");
1199 ot->
name =
"Edge Crease";
1222 ot->
name =
"Vertex Crease";
1245 ot->
name =
"Edge Bevel Weight";
1267 ot->
name =
"Sequence Slide";
1283 ot->
srna,
"value", 2,
NULL, -FLT_MAX, FLT_MAX,
"Offset",
"", -FLT_MAX, FLT_MAX);
1294 ot->
name =
"Rotate Normals";
1319 ot->
idname =
"TRANSFORM_OT_transform";
1335 ot->
srna,
"value", 4,
NULL, -FLT_MAX, FLT_MAX,
"Values",
"", -FLT_MAX, FLT_MAX);
1351 if (gzgroup !=
NULL) {
1354 const int drag_action =
RNA_enum_get(&gzg_ptr,
"drag_action");
1355 const char *op_id =
NULL;
1356 switch (drag_action) {
1358 op_id =
"TRANSFORM_OT_translate";
1361 op_id =
"TRANSFORM_OT_rotate";
1364 op_id =
"TRANSFORM_OT_resize";
1387 ot->
name =
"Transform from Gizmo";
1389 ot->
idname =
"TRANSFORM_OT_from_gizmo";
struct ScrArea * CTX_wm_area(const bContext *C)
struct Scene * CTX_data_scene(const bContext *C)
struct View3D * CTX_wm_view3d(const bContext *C)
struct wmMsgBus * CTX_wm_message_bus(const bContext *C)
struct ARegion * CTX_wm_region(const bContext *C)
void BKE_report(ReportList *reports, eReportType type, const char *message)
void BKE_scene_orientation_slot_set_index(struct TransformOrientationSlot *orient_slot, int orientation)
MINLINE bool is_zero_v4(const float a[4]) ATTR_WARN_UNUSED_RESULT
#define BLT_I18NCONTEXT_ID_CURVE_LEGACY
Object is a sort of wrapper for general info.
#define SCE_SELECT_VERTEX
@ SCE_SNAP_MODE_INCREMENT
@ V3D_GIZMO_SHOW_OBJECT_ROTATE
@ V3D_GIZMO_SHOW_OBJECT_SCALE
@ V3D_GIZMO_SHOW_OBJECT_TRANSLATE
@ OP_IS_MODAL_GRAB_CURSOR
bool EDBM_selectmode_set_multi(struct bContext *C, short selectmode)
bool ED_operator_editmesh_region_view3d(struct bContext *C)
bool ED_operator_editcurve_3d(struct bContext *C)
bool ED_operator_sequencer_active(struct bContext *C)
bool ED_operator_areaactive(struct bContext *C)
bool ED_operator_screenactive(struct bContext *C)
bool ED_operator_view3d_active(struct bContext *C)
bool ED_operator_editmesh(struct bContext *C)
bool ED_operator_object_active(struct bContext *C)
bool ED_operator_region_view3d_active(struct bContext *C)
_GL_VOID GLfloat value _GL_VOID_RET _GL_VOID const GLuint GLboolean *residences _GL_BOOL_RET _GL_VOID GLsizei GLfloat GLfloat GLfloat GLfloat const GLubyte *bitmap _GL_VOID_RET _GL_VOID GLenum type
_GL_VOID GLfloat value _GL_VOID_RET _GL_VOID const GLuint GLboolean *residences _GL_BOOL_RET _GL_VOID GLsizei GLfloat GLfloat GLfloat GLfloat const GLubyte *bitmap _GL_VOID_RET _GL_VOID GLenum const void *lists _GL_VOID_RET _GL_VOID const GLdouble *equation _GL_VOID_RET _GL_VOID GLdouble GLdouble blue _GL_VOID_RET _GL_VOID GLfloat GLfloat blue _GL_VOID_RET _GL_VOID GLint GLint blue _GL_VOID_RET _GL_VOID GLshort GLshort blue _GL_VOID_RET _GL_VOID GLubyte GLubyte blue _GL_VOID_RET _GL_VOID GLuint GLuint blue _GL_VOID_RET _GL_VOID GLushort GLushort blue _GL_VOID_RET _GL_VOID GLbyte GLbyte GLbyte alpha _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble alpha _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat alpha _GL_VOID_RET _GL_VOID GLint GLint GLint alpha _GL_VOID_RET _GL_VOID GLshort GLshort GLshort alpha _GL_VOID_RET _GL_VOID GLubyte GLubyte GLubyte alpha _GL_VOID_RET _GL_VOID GLuint GLuint GLuint alpha _GL_VOID_RET _GL_VOID GLushort GLushort GLushort alpha _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLint GLsizei GLsizei GLenum type _GL_VOID_RET _GL_VOID GLsizei GLenum GLenum const void *pixels _GL_VOID_RET _GL_VOID const void *pointer _GL_VOID_RET _GL_VOID GLdouble v _GL_VOID_RET _GL_VOID GLfloat v _GL_VOID_RET _GL_VOID GLint GLint i2 _GL_VOID_RET _GL_VOID GLint j _GL_VOID_RET _GL_VOID GLfloat param _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble GLdouble GLdouble zFar _GL_VOID_RET _GL_UINT GLdouble *equation _GL_VOID_RET _GL_VOID GLenum GLint *params _GL_VOID_RET _GL_VOID GLenum GLfloat *v _GL_VOID_RET _GL_VOID GLenum GLfloat *params _GL_VOID_RET _GL_VOID GLfloat *values _GL_VOID_RET _GL_VOID GLushort *values _GL_VOID_RET _GL_VOID GLenum GLfloat *params _GL_VOID_RET _GL_VOID GLenum GLdouble *params _GL_VOID_RET _GL_VOID GLenum GLint *params _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_BOOL GLfloat param _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID GLenum GLfloat param _GL_VOID_RET _GL_VOID GLenum GLint param _GL_VOID_RET _GL_VOID GLushort pattern _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLint const GLdouble *points _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLint GLdouble GLdouble GLint GLint const GLdouble *points _GL_VOID_RET _GL_VOID GLdouble GLdouble u2 _GL_VOID_RET _GL_VOID GLdouble GLdouble GLint GLdouble GLdouble v2 _GL_VOID_RET _GL_VOID GLenum GLfloat param _GL_VOID_RET _GL_VOID GLenum GLint param _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLdouble GLdouble nz _GL_VOID_RET _GL_VOID GLfloat GLfloat nz _GL_VOID_RET _GL_VOID GLint GLint nz _GL_VOID_RET _GL_VOID GLshort GLshort nz _GL_VOID_RET _GL_VOID GLsizei const void *pointer _GL_VOID_RET _GL_VOID GLsizei const GLfloat *values _GL_VOID_RET _GL_VOID GLsizei const GLushort *values _GL_VOID_RET _GL_VOID GLint param _GL_VOID_RET _GL_VOID const GLuint const GLclampf *priorities _GL_VOID_RET _GL_VOID GLdouble y _GL_VOID_RET _GL_VOID GLfloat y _GL_VOID_RET _GL_VOID GLint y _GL_VOID_RET _GL_VOID GLshort y _GL_VOID_RET _GL_VOID GLdouble GLdouble z _GL_VOID_RET _GL_VOID GLfloat GLfloat z _GL_VOID_RET _GL_VOID GLint GLint z _GL_VOID_RET _GL_VOID GLshort GLshort z _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble w _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat w _GL_VOID_RET _GL_VOID GLint GLint GLint w _GL_VOID_RET _GL_VOID GLshort GLshort GLshort w _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble y2 _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat y2 _GL_VOID_RET _GL_VOID GLint GLint GLint y2 _GL_VOID_RET _GL_VOID GLshort GLshort GLshort y2 _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble z _GL_VOID_RET _GL_VOID GLdouble GLdouble z _GL_VOID_RET _GL_VOID GLuint *buffer _GL_VOID_RET _GL_VOID GLdouble t _GL_VOID_RET _GL_VOID GLfloat t _GL_VOID_RET _GL_VOID GLint t _GL_VOID_RET _GL_VOID GLshort t _GL_VOID_RET _GL_VOID GLdouble t
Read Guarded memory(de)allocation.
const EnumPropertyItem * rna_TransformOrientation_itemf(struct bContext *C, struct PointerRNA *ptr, struct PropertyRNA *prop, bool *r_free)
struct uiLayout * UI_popup_menu_layout(uiPopupMenu *pup)
void uiItemsEnumO(uiLayout *layout, const char *opname, const char *propname)
void UI_popup_menu_end(struct bContext *C, struct uiPopupMenu *pup)
uiPopupMenu * UI_popup_menu_begin(struct bContext *C, const char *title, int icon) ATTR_NONNULL()
@ OPTYPE_DEPENDS_ON_CURSOR
SyclQueue void void size_t num_bytes void
void(* MEM_freeN)(void *vmemh)
void *(* MEM_callocN)(size_t len, const char *str)
static void area(int d1, int d2, int e1, int e2, float weights[2])
const char * RNA_property_identifier(const PropertyRNA *prop)
void RNA_boolean_set(PointerRNA *ptr, const char *name, bool value)
bool RNA_property_is_set(PointerRNA *ptr, PropertyRNA *prop)
void RNA_property_boolean_get_array(PointerRNA *ptr, PropertyRNA *prop, bool *values)
PropertyRNA * RNA_struct_find_property(PointerRNA *ptr, const char *identifier)
bool RNA_property_boolean_get(PointerRNA *ptr, PropertyRNA *prop)
void RNA_string_get(PointerRNA *ptr, const char *name, char *value)
bool RNA_struct_property_is_set(PointerRNA *ptr, const char *identifier)
bool RNA_boolean_get(PointerRNA *ptr, const char *name)
int RNA_enum_get(PointerRNA *ptr, const char *name)
PropertyRNA * RNA_def_float(StructOrFunctionRNA *cont_, const char *identifier, float default_value, float hardmin, float hardmax, const char *ui_name, const char *ui_description, float softmin, float softmax)
PropertyRNA * RNA_def_boolean(StructOrFunctionRNA *cont_, const char *identifier, bool default_value, const char *ui_name, const char *ui_description)
PropertyRNA * RNA_def_float_matrix(StructOrFunctionRNA *cont_, const char *identifier, int rows, int columns, const float *default_value, float hardmin, float hardmax, const char *ui_name, const char *ui_description, float softmin, float softmax)
void RNA_def_property_enum_default(PropertyRNA *prop, int value)
PropertyRNA * RNA_def_float_distance(StructOrFunctionRNA *cont_, const char *identifier, float default_value, float hardmin, float hardmax, const char *ui_name, const char *ui_description, float softmin, float softmax)
void RNA_def_property_ui_text(PropertyRNA *prop, const char *name, const char *description)
PropertyRNA * RNA_def_float_vector(StructOrFunctionRNA *cont_, const char *identifier, int len, const float *default_value, float hardmin, float hardmax, const char *ui_name, const char *ui_description, float softmin, float softmax)
PropertyRNA * RNA_def_boolean_vector(StructOrFunctionRNA *cont_, const char *identifier, int len, bool *default_value, const char *ui_name, const char *ui_description)
void RNA_def_property_enum_items(PropertyRNA *prop, const EnumPropertyItem *item)
void RNA_def_property_array(PropertyRNA *prop, int length)
PropertyRNA * RNA_def_float_factor(StructOrFunctionRNA *cont_, const char *identifier, float default_value, float hardmin, float hardmax, const char *ui_name, const char *ui_description, float softmin, float softmax)
PropertyRNA * RNA_def_property(StructOrFunctionRNA *cont_, const char *identifier, int type, int subtype)
PropertyRNA * RNA_def_float_translation(StructOrFunctionRNA *cont_, const char *identifier, int len, const float *default_value, float hardmin, float hardmax, const char *ui_name, const char *ui_description, float softmin, float softmax)
PropertyRNA * RNA_def_string(StructOrFunctionRNA *cont_, const char *identifier, const char *default_value, int maxlen, const char *ui_name, const char *ui_description)
void RNA_def_property_translation_context(PropertyRNA *prop, const char *context)
void RNA_def_property_flag(PropertyRNA *prop, PropertyFlag flag)
void RNA_def_enum_funcs(PropertyRNA *prop, EnumPropertyItemFunc itemfunc)
void RNA_def_property_ui_range(PropertyRNA *prop, double min, double max, double step, int precision)
PropertyRNA * RNA_def_float_rotation(StructOrFunctionRNA *cont_, const char *identifier, int len, const float *default_value, float hardmin, float hardmax, const char *ui_name, const char *ui_description, float softmin, float softmax)
PropertyRNA * RNA_def_enum(StructOrFunctionRNA *cont_, const char *identifier, const EnumPropertyItem *items, int default_value, const char *ui_name, const char *ui_description)
const EnumPropertyItem rna_enum_axis_xyz_items[]
const EnumPropertyItem rna_enum_proportional_falloff_items[]
const EnumPropertyItem rna_enum_snap_source_items[]
const EnumPropertyItem rna_enum_snap_element_items[]
struct wmGizmoMap * gizmo_map
struct ToolSettings * toolsettings
TransformOrientationSlot orientation_slots[4]
struct wmGizmoGroupType * type
int(* invoke)(struct bContext *, struct wmOperator *, const struct wmEvent *) ATTR_WARN_UNUSED_RESULT
int(* modal)(struct bContext *, struct wmOperator *, const struct wmEvent *) ATTR_WARN_UNUSED_RESULT
bool(* poll)(struct bContext *) ATTR_WARN_UNUSED_RESULT
bool(* poll_property)(const struct bContext *C, struct wmOperator *op, const PropertyRNA *prop) ATTR_WARN_UNUSED_RESULT
void(* cancel)(struct bContext *, struct wmOperator *)
int(* exec)(struct bContext *, struct wmOperator *) ATTR_WARN_UNUSED_RESULT
struct ReportList * reports
struct wmOperatorType * type
void WM_operator_type_set(wmOperator *op, wmOperatorType *ot)
wmEventHandler_Op * WM_event_add_modal_handler(bContext *C, wmOperator *op)
int WM_operator_name_call_ptr(bContext *C, wmOperatorType *ot, wmOperatorCallContext context, PointerRNA *properties, const wmEvent *event)
void WM_event_add_notifier(const bContext *C, uint type, void *reference)
wmGizmoGroup * WM_gizmomap_group_find(struct wmGizmoMap *gzmap, const char *idname)
void WM_modalkeymap_assign(wmKeyMap *km, const char *opname)
#define WM_msg_publish_rna_prop(mbus, id_, data_, type_, prop_)
void WM_operatortype_props_advanced_begin(wmOperatorType *ot)
wmOperatorType * WM_operatortype_find(const char *idname, bool quiet)
void WM_operatortype_append(void(*opfunc)(wmOperatorType *))
void WM_operator_properties_create_ptr(PointerRNA *ptr, wmOperatorType *ot)
void WM_operator_properties_free(PointerRNA *ptr)