|
Blender V4.3
|
#include "BLI_math_vector_types.hh"#include "ED_numinput.hh"#include "ED_transform.hh"#include "ED_view3d.hh"#include "DNA_listBase.h"#include "DNA_object_enums.h"#include "DNA_scene_types.h"#include "DEG_depsgraph.hh"#include "transform_data.hh"Go to the source code of this file.
Classes | |
| struct | TransSnapPoint |
| struct | TransSnap |
| struct | TransCon |
| struct | MouseInput |
| struct | TransCustomData |
| struct | TransCustomDataContainer |
| struct | TransDataContainer |
| struct | TransInfo |
Macros | |
Transform Types | |
| #define | TRANS_CUSTOM_DATA_ELEM_MAX (sizeof(TransCustomDataContainer) / sizeof(TransCustomData)) |
| #define DRAWLIGHT 1 |
Definition at line 802 of file transform.hh.
Referenced by drawConstraint(), drawLine(), and drawObjectConstraint().
| #define FOREACH_TRANS_DATA_CONTAINER | ( | t, | |
| th ) |
Definition at line 854 of file transform.hh.
Referenced by apply_shear_value(), apply_value_impl(), applyAlign(), applyBakeTime(), applyBoneEnvelope(), applyBoneRoll(), applyBoneSize(), applyCurveShrinkFatten(), applyGPOpacity(), applyGPShrinkFatten(), applyMaskShrinkFatten(), applyMirror(), applyNormalRotation(), applyPushPull(), applyResize(), applyRotationValue(), applySeqSlideValue(), applyShrinkFatten(), applySkinResize(), applyTilt(), applyTimeScaleValue(), applyTimeSlideValue(), applyTimeTranslateValue(), applyToSphere(), applyTrackballValue(), applyTranslationValue(), Bend(), calculateCenterBound(), calculateCenterLocal(), calculateCenterMedian(), calculatePropRatio(), clip_uv_transform_resize(), clip_uv_transform_translation(), clipUVData(), createTransArmatureVerts(), createTransCurveVerts(), createTransEdge(), createTransEditVerts(), createTransLatticeVerts(), createTransMBallVerts(), createTransMeshSkin(), createTransMeshVertCData(), createTransParticleVerts(), createTransPose(), createTransUVs(), doEdgeSlide(), doVertSlide(), drawObjectConstraint(), edge_slide_container_first_ok(), blender::ed::transform::flushTransNodes(), flushTransParticles(), flushTransUVs(), freeTransCustomDataForMode(), initEdgeSlide_ex(), initNormalRotation(), initTimeSlide(), initTransform(), initVertSlide_ex(), mesh_customdatacorrect_restore(), mesh_skin_apply_to_mirror(), blender::ed::transform::node_snap_grid_apply(), postTrans(), recalcData_curve(), recalcData_edit_armature(), recalcData_lattice(), recalcData_mball(), recalcData_mesh(), recalcData_mesh_cdata(), recalcData_mesh_edge(), recalcData_mesh_skin(), recalcData_objects(), recalcData_pose(), recalcData_texspace(), recalcData_uv(), restoreTransObjects(), set_prop_dist(), snap_source_closest_fn(), sort_trans_data_dist(), sort_trans_data_selected_first(), special_aftertrans_update__mesh(), special_aftertrans_update__pose(), to_sphere_radius_update(), tranform_snap_target_median_calc(), transform_autoik_update(), transform_convert_mesh_customdatacorrect_init(), transform_mode_edge_slide_reproject_input(), transform_mode_vert_slide_reproject_input(), transform_snap_project_individual_apply(), transformEnd(), uv_rotation_in_clip_bounds_test(), and uv_shear_in_clip_bounds_test().
| #define FOREACH_TRANS_DATA_CONTAINER_INDEX | ( | t, | |
| th, | |||
| i ) |
Definition at line 860 of file transform.hh.
| #define T_ALL_RESTRICTIONS (T_NO_CONSTRAINT | T_NULL_ONE) |
Definition at line 156 of file transform.hh.
| #define T_PROP_EDIT_ALL (T_PROP_EDIT | T_PROP_CONNECTED | T_PROP_PROJECTED) |
Definition at line 157 of file transform.hh.
Referenced by applyTrackball(), blender::ed::transform::curves::createTransCurvesVerts(), createTransEditVerts(), blender::ed::transform::greasepencil::createTransGreasePencilVerts(), createTransMeshSkin(), createTransMeshVertCData(), headerResize(), headerRotation(), headerTimeTranslate(), headerTranslation(), saveTransform(), to_sphere_radius_update(), and transform_convert_mesh_crazyspace_detect().
| #define TRANS_CUSTOM_DATA_ELEM_MAX (sizeof(TransCustomDataContainer) / sizeof(TransCustomData)) |
Definition at line 427 of file transform.hh.
Referenced by freeTransCustomDataContainer().
| #define TRANS_DATA_CONTAINER_FIRST_OK | ( | t | ) | (&(t)->data_container[0]) |
Definition at line 849 of file transform.hh.
Referenced by applyObjectConstraintRot(), calculateCenterActive(), drawEdgeSlide(), drawVertSlide(), handleEventVertSlide(), headerTimeTranslate(), headerTranslation(), initCurveShrinkFatten(), vert_slide_snap_apply(), vert_slide_transform_matrix_fn(), and vert_slide_update_input().
| #define TRANS_DATA_CONTAINER_FIRST_SINGLE | ( | t | ) | (BLI_assert((t)->data_container_len == 1), (&(t)->data_container[0])) |
Definition at line 851 of file transform.hh.
Referenced by applyTransObjects(), cancelTransTracking(), cancelTransTrackingCurves(), createTransActionData(), createTransGPencil_curves(), createTransGPencil_strokes(), createTransGraphEditData(), createTransMaskingData(), createTransNlaData(), blender::ed::transform::createTransNodeData(), createTransObject(), createTransPaintCurveVerts(), createTransSeqData(), createTransSeqImageData(), createTransSeqRetimingData(), createTransTrackingCurves(), createTransTrackingCurvesData(), createTransTrackingData(), createTransTrackingTracksData(), flushTransGraphData(), flushTransMasking(), flushTransPaintCurve(), flushTransSeq(), flushTransTracking(), flushTransTrackingCurves(), recalcData_actedit(), recalcData_gpencil_strokes(), recalcData_nla(), recalcData_sequencer(), recalcData_sequencer_image(), recalcData_sequencer_retiming(), remake_graph_transdata(), special_aftertrans_update__nla(), special_aftertrans_update__object(), special_aftertrans_update__sequencer(), special_aftertrans_update__sequencer_image(), transform_convert_sequencer_channel_clamp(), transform_snap_nla_calc(), translate_snap_increment_init(), and view2d_edge_pan_loc_compensate().
Definition at line 845 of file transform.hh.
Referenced by ApplySnapResize(), ResizeBetween(), and snap_source_closest_fn().
| #define TRANSFORM_SNAP_MAX_PX 100.0f |
Definition at line 844 of file transform.hh.
Referenced by updateSelectedSnapPoint().
| anonymous enum |
| Enumerator | |
|---|---|
| TFM_MODAL_CANCEL | |
| TFM_MODAL_CONFIRM | |
| TFM_MODAL_TRANSLATE | |
| TFM_MODAL_ROTATE | |
| TFM_MODAL_RESIZE | |
| TFM_MODAL_SNAP_INV_ON | |
| TFM_MODAL_SNAP_INV_OFF | |
| TFM_MODAL_SNAP_TOGGLE | |
| TFM_MODAL_AXIS_X | |
| TFM_MODAL_AXIS_Y | |
| TFM_MODAL_AXIS_Z | |
| TFM_MODAL_PLANE_X | |
| TFM_MODAL_PLANE_Y | |
| TFM_MODAL_PLANE_Z | |
| TFM_MODAL_CONS_OFF | |
| TFM_MODAL_ADD_SNAP | |
| TFM_MODAL_REMOVE_SNAP | |
| TFM_MODAL_PROPSIZE_UP | |
| TFM_MODAL_PROPSIZE_DOWN | |
| TFM_MODAL_AUTOIK_LEN_INC | |
| TFM_MODAL_AUTOIK_LEN_DEC | |
| TFM_MODAL_NODE_ATTACH_ON | |
| TFM_MODAL_NODE_ATTACH_OFF | |
| TFM_MODAL_PROPSIZE | For analog input, like trackpad. |
| TFM_MODAL_INSERTOFS_TOGGLE_DIR | Node editor insert offset (also called auto-offset) direction toggle. |
| TFM_MODAL_AUTOCONSTRAINT | |
| TFM_MODAL_AUTOCONSTRAINTPLANE | |
| TFM_MODAL_PRECISION | |
| TFM_MODAL_VERT_EDGE_SLIDE | |
| TFM_MODAL_TRACKBALL | |
| TFM_MODAL_ROTATE_NORMALS | |
| TFM_MODAL_EDIT_SNAP_SOURCE_ON | |
| TFM_MODAL_EDIT_SNAP_SOURCE_OFF | |
| TFM_MODAL_PASSTHROUGH_NAVIGATE | |
Definition at line 246 of file transform.hh.
| enum eRedrawFlag |
| Enumerator | |
|---|---|
| TREDRAW_NOTHING | |
| TREDRAW_SOFT | |
| TREDRAW_HARD | |
Definition at line 214 of file transform.hh.
| enum eSnapDir |
| Enumerator | |
|---|---|
| DIR_GLOBAL_X | |
| DIR_GLOBAL_Y | |
| DIR_GLOBAL_Z | |
Definition at line 183 of file transform.hh.
| enum eTConstraint |
TransCon.mode, #TransInfo.con.mode
Definition at line 191 of file transform.hh.
| enum eTContext |
| Enumerator | |
|---|---|
| CTX_NONE | |
| CTX_CAMERA | |
| CTX_CURSOR | |
| CTX_EDGE_DATA | |
| CTX_GPENCIL_STROKES | |
| CTX_MASK | |
| CTX_MOVIECLIP | |
| CTX_OBJECT | |
| CTX_PAINT_CURVE | |
| CTX_POSE_BONE | |
| CTX_TEXTURE_SPACE | |
| CTX_SEQUENCER_IMAGE | |
| CTX_NO_PET | |
| CTX_AUTOCONFIRM | |
| CTX_OBMODE_XFORM_OBDATA | When transforming object's, adjust the object data so it stays in the same place. |
| CTX_OBMODE_XFORM_SKIP_CHILDREN | Transform object parents without moving their children. |
| CTX_VIEW2D_EDGE_PAN | Enable edge scrolling in 2D views. |
Definition at line 61 of file transform.hh.
| enum eTFlag |
| Enumerator | |
|---|---|
| T_EDIT |
|
| T_POINTS | Transform points, having no rotation/scale. |
| T_NO_CONSTRAINT | Restrictions flags. |
| T_NULL_ONE | |
| T_PROP_EDIT | |
| T_PROP_CONNECTED | |
| T_PROP_PROJECTED | |
| T_V3D_ALIGN | |
| T_2D_EDIT | For 2D views such as UV or f-curve. |
| T_CLIP_UV | |
| T_AUTOIK | Auto-IK is on. |
| T_NO_MIRROR | Don't use mirror even if the data-block option is set. |
| T_INPUT_IS_VALUES_FINAL | To indicate that the value set in the |
| T_MODAL | To specify if we save back settings at the end. |
| T_NO_PROJECT | No re-topology (projection). |
| T_RELEASE_CONFIRM | |
| T_ALT_TRANSFORM | Alternative transformation. used to add offset to tracking markers. |
| T_OVERRIDE_CENTER | #TransInfo.center has been set, don't change it. |
| T_MODAL_CURSOR_SET | |
| T_CLNOR_REBUILD | |
| T_AUTOMERGE | Merges unselected into selected after transforming (runs after transforming). |
| T_AUTOSPLIT | Runs auto-merge & splits. |
| T_EVENT_DRAG_START | Use drag-start position of the event, otherwise use the cursor coordinates (unmodified). |
| T_NO_CURSOR_WRAP | No cursor wrapping on region bounds. |
| T_NO_GIZMO | Do not display Xform gizmo even though it is available. |
| T_DRAW_SNAP_SOURCE | |
| T_DUPLICATED_KEYFRAMES | Special flag for when the transform code is called after keys have been duplicated. |
Definition at line 89 of file transform.hh.
| enum eTHelpline |
| Enumerator | |
|---|---|
| HLP_NONE | |
| HLP_SPRING | |
| HLP_ANGLE | |
| HLP_HARROW | |
| HLP_VARROW | |
| HLP_CARROW | |
| HLP_TRACKBALL | |
Definition at line 222 of file transform.hh.
| enum eTModifier |
| Enumerator | |
|---|---|
| MOD_CONSTRAINT_SELECT_AXIS | |
| MOD_PRECISION | |
| MOD_SNAP | |
| MOD_SNAP_INVERT | |
| MOD_CONSTRAINT_SELECT_PLANE | |
| MOD_NODE_ATTACH | |
| MOD_SNAP_FORCED | |
| MOD_EDIT_SNAP_SOURCE | |
Definition at line 160 of file transform.hh.
| enum eTOType |
| Enumerator | |
|---|---|
| O_DEFAULT | |
| O_SCENE | |
| O_SET | |
Definition at line 232 of file transform.hh.
| enum eTSnap |
| Enumerator | |
|---|---|
| SNAP_RESETTED | |
| SNAP_SOURCE_FOUND | |
| SNAP_TARGET_FOUND | |
| SNAP_MULTI_POINTS | |
Definition at line 173 of file transform.hh.
| enum eTState |
| Enumerator | |
|---|---|
| TRANS_STARTING | |
| TRANS_RUNNING | |
| TRANS_CONFIRM | |
| TRANS_CANCEL | |
Definition at line 206 of file transform.hh.
| enum MouseInputMode |
Definition at line 740 of file transform.hh.
Definition at line 382 of file editors/transform/transform.cc.
References TransInfo::area, TransInfo::aspect, CTX_MASK, CTX_MOVIECLIP, CTX_PAINT_CURVE, ED_space_image_get_size(), ListBase::first, SpaceImage::flag, TransInfo::mode, TransInfo::options, SI_COORDFLOATS, SPACE_CLIP, SPACE_IMAGE, ScrArea::spacedata, TransInfo::spacetype, and TFM_TRANSLATION.
Referenced by headerTranslation().
| void applyMouseInput | ( | TransInfo * | t, |
| MouseInput * | mi, | ||
| const blender::float2 & | mval, | ||
| float | output[3] ) |
| void applyTransObjects | ( | TransInfo * | t | ) |
Definition at line 815 of file transform_generics.cc.
References copy_v3_v3(), TransDataContainer::data, TransDataContainer::data_len, TransData::ext, TransDataExtension::irot, TransDataExtension::isize, recalc_data(), TransDataExtension::rot, TransDataExtension::size, and TRANS_DATA_CONTAINER_FIRST_SINGLE.
| void calculateCenter | ( | TransInfo * | t | ) |
Definition at line 1190 of file transform_generics.cc.
References TransInfo::around, calculateCenter2D(), calculateCenter_FromAround(), calculateCenterLocal(), calculateZfac(), TransInfo::center2d, TransInfo::center_global, copy_v3_v3(), CTX_CAMERA, CTX_OBJECT, TransInfo::flag, TransInfo::mode, normalize_v3(), TransInfo::options, projectFloatView(), TransInfo::region, ARegion::regiontype, RGN_TYPE_WINDOW, SPACE_VIEW3D, TransInfo::spacetype, T_OVERRIDE_CENTER, TFM_TRANSLATION, and TransInfo::viewinv.
Referenced by calculateTransformCenter(), and initTransform().
| void calculateCenter2D | ( | TransInfo * | t | ) |
Definition at line 909 of file transform_generics.cc.
References TransInfo::aspect, BLI_assert, TransInfo::center2d, TransInfo::center_global, is_zero_v3(), and projectFloatView().
Referenced by calculateCenter(), initTransInfo(), and transformViewUpdate().
| select_only | only get active center from data being transformed. |
Definition at line 1082 of file transform_generics.cc.
References PaintCurve::add_index, BASE_SELECTED, PaintCurvePoint::bez, BKE_brush_tag_unsaved_changes(), BKE_paint_brush(), BKE_paint_get_active(), BKE_view_layer_active_base_get(), BKE_view_layer_active_object_get(), BKE_view_layer_synced_ensure(), blender::ed::object::calc_active_center_for_editmode(), blender::ed::object::calc_active_center_for_posemode(), copy_v3_v3(), CTX_PAINT_CURVE, CTX_POSE_BONE, Base::flag, mul_m4_v3(), TransDataContainer::obedit, Base::object, TransInfo::options, Brush::paint_curve, PaintCurve::points, TransInfo::scene, SPACE_VIEW3D, TransInfo::spacetype, TRANS_DATA_CONTAINER_FIRST_OK, BezTriple::vec, and TransInfo::view_layer.
Referenced by calculateCenter_FromAround(), and snap_source_active_fn().
Definition at line 1057 of file transform_generics.cc.
References FOREACH_TRANS_DATA_CONTAINER, INIT_MINMAX, mid_v3_v3v3(), min, minmax_v3v3_v3(), and transdata_center_global_get().
Referenced by calculateCenter_FromAround().
Definition at line 929 of file transform_generics.cc.
References copy_v3_v3(), CTX_PAINT_CURVE, Scene::cursor, ED_view3d_project_float_global(), View3DCursor::location, TransInfo::options, TransInfo::region, TransInfo::scene, V3D_PROJ_RET_OK, V3D_PROJ_TEST_NOP, ARegion::winx, and ARegion::winy.
Referenced by calculateCenter_FromAround(), and initBend().
Definition at line 946 of file transform_generics.cc.
References TransInfo::area, TransInfo::aspect, BKE_mask_coord_from_image(), BKE_mask_coord_from_movieclip(), BLI_assert_msg, SpaceClip::clip, CTX_MASK, CTX_PAINT_CURVE, SpaceClip::cursor, SpaceImage::cursor, SpaceSeq::cursor, ListBase::first, SpaceImage::image, SpaceImage::iuser, TransInfo::options, TransInfo::region, TransInfo::scene, SEQ_image_preview_unit_to_px(), SPACE_CLIP, SPACE_IMAGE, SPACE_SEQ, ScrArea::spacedata, TransInfo::spacetype, UI_view2d_view_to_region_x(), UI_view2d_view_to_region_y(), SpaceClip::user, and ARegion::v2d.
Referenced by calculateCenter_FromAround().
Definition at line 997 of file transform_generics.cc.
References TransInfo::area, SpaceGraph::cursorTime, SpaceGraph::cursorVal, ListBase::first, float, SpaceGraph::mode, TransInfo::scene, SIPO_MODE_DRIVERS, and ScrArea::spacedata.
Referenced by calculateCenter_FromAround().
Definition at line 915 of file transform_generics.cc.
References copy_v3_v3(), FOREACH_TRANS_DATA_CONTAINER, and mul_v3_m4v3().
Referenced by calculateCenter(), initBend(), and initTransInfo().
Definition at line 1031 of file transform_generics.cc.
References add_v3_v3(), copy_v3_v3(), FOREACH_TRANS_DATA_CONTAINER, mul_v3_fl(), and transdata_center_global_get().
Referenced by calculateCenter_FromAround().
| void calculatePropRatio | ( | TransInfo * | t | ) |
Definition at line 1265 of file transform_generics.cc.
References BLI_rng_get_float(), BLI_rng_new(), BLI_time_now_seconds_i(), TransData::dist, TransData::factor, TransInfo::flag, FOREACH_TRANS_DATA_CONTAINER, IFACE_, N_, PROP_CONST, PROP_INVSQUARE, PROP_LIN, TransInfo::prop_mode, PROP_RANDOM, PROP_ROOT, PROP_SHARP, TransInfo::prop_size, PROP_SMOOTH, PROP_SPHERE, TransInfo::proptext, TransData::rdist, restoreElement(), TransInfo::rng, sqrtf, STRNCPY_UTF8, T_PROP_CONNECTED, T_PROP_EDIT, TD_SELECTED, and UINT_MAX.
Referenced by initTransform(), and transformEvent().
| bool checkUseAxisMatrix | ( | TransInfo * | t | ) |
Definition at line 2198 of file editors/transform/transform.cc.
References TransInfo::around, ELEM, TransInfo::flag, OB_ARMATURE, OB_CURVES_LEGACY, OB_MBALL, OB_MESH, TransInfo::obedit_type, T_EDIT, and V3D_AROUND_LOCAL_ORIGINS.
Referenced by setUserConstraint().
Definition at line 181 of file editors/transform/transform.cc.
References TransInfo::aspect, convertViewVec2D(), convertViewVec2D_mask(), CTX_MASK, CTX_PAINT_CURVE, ED_view3d_win_to_delta(), ELEM, float, TransInfo::options, printf, TransInfo::region, ARegion::regiontype, RGN_TYPE_WINDOW, SPACE_CLIP, SPACE_GRAPH, SPACE_IMAGE, SPACE_NLA, SPACE_NODE, SPACE_SEQ, SPACE_VIEW3D, TransInfo::spacetype, ARegion::v2d, TransInfo::view, zero_v3(), and TransInfo::zfac.
Referenced by drawConstraint(), InputVector(), snap_grid_uv_apply(), and snapObjectsTransform().
| ENUM_OPERATORS | ( | eTFlag | , |
| T_DUPLICATED_KEYFRAMES | ) |
| void freeCustomNormalArray | ( | TransInfo * | t, |
| TransDataContainer * | tc, | ||
| TransCustomData * | custom_data ) |
Definition at line 41 of file transform_mode_edge_rotate_normal.cc.
References BKE_editmesh_from_object(), BKE_lnor_space_custom_normal_to_data(), bm, BMEditMesh::bm, BM_loop_normal_editdata_array_free(), BMLoopNorEditData::clnors_data, TransDataContainer::custom, TransCustomData::data, TransCustomData::free_cb, BMLoopNorEditDataArray::lnor_editdata, BMesh::lnor_spacearr, BMLoopNorEditData::loop_index, MLoopNorSpaceArray::lspacearr, TransCustomDataContainer::mode, BMLoopNorEditData::niloc, TransDataContainer::obedit, TransInfo::state, BMLoopNorEditDataArray::totloop, and TRANS_CANCEL.
Referenced by storeCustomLNorValue().
| void freeTransCustomDataForMode | ( | TransInfo * | t | ) |
Needed for mode switching.
Definition at line 731 of file transform_generics.cc.
References TransInfo::custom, FOREACH_TRANS_DATA_CONTAINER, freeTransCustomData(), and TransCustomDataContainer::mode.
Referenced by resetTransModal().
| void initMouseInput | ( | TransInfo * | t, |
| MouseInput * | mi, | ||
| const blender::float2 & | center, | ||
| const blender::float2 & | mval, | ||
| bool | precision ) |
Referenced by initTimeScale(), and initTransform().
| void initMouseInputMode | ( | TransInfo * | t, |
| MouseInput * | mi, | ||
| MouseInputMode | mode ) |
Definition at line 351 of file transform_input.cc.
References MouseInput::apply, calcSpringFactor(), TransInfo::context, CTX_wm_space_seq(), CTX_wm_window(), data, MouseInput::data, MouseInput::factor, SpaceSeq::flag, TransInfo::flag, TransInfo::helpline, HLP_ANGLE, HLP_CARROW, HLP_HARROW, HLP_NONE, HLP_SPRING, HLP_TRACKBALL, HLP_VARROW, MouseInput::imval, INPUT_ANGLE, INPUT_ANGLE_SPRING, INPUT_CUSTOM_RATIO, INPUT_CUSTOM_RATIO_FLIP, INPUT_HORIZONTAL_ABSOLUTE, INPUT_HORIZONTAL_RATIO, INPUT_NONE, INPUT_SPRING, INPUT_SPRING_DELTA, INPUT_SPRING_FLIP, INPUT_TRACKBALL, INPUT_VECTOR, INPUT_VERTICAL_ABSOLUTE, INPUT_VERTICAL_RATIO, InputAngle(), InputAngleSpring(), InputCustomRatio(), InputCustomRatioFlip(), InputHorizontalAbsolute(), InputHorizontalRatio(), InputSpring(), InputSpringDelta(), InputSpringFlip(), InputTrackBall(), InputVector(), InputVerticalAbsolute(), InputVerticalRatio(), MEM_callocN, MEM_freeN(), TransInfo::mode, InputAngle_Data::mval_prev, MouseInput::precision_factor, T_MODAL, T_MODAL_CURSOR_SET, TFM_SEQ_SLIDE, transform_mode_edge_seq_slide_use_restore_handle_selection(), transform_seq_slide_cursor_get(), MouseInput::use_virtual_mval, WM_cursor_modal_set(), WM_CURSOR_NONE, and WM_CURSOR_NSEW_SCROLL.
Referenced by init_mode_impl(), initAlign(), initBakeTime(), initBend(), initBoneEnvelope(), initBoneRoll(), initBoneSize(), initCurveShrinkFatten(), initEdgeSlide_ex(), initGPOpacity(), initGPShrinkFatten(), initMaskShrinkFatten(), initMirror(), initNormalRotation(), initPushPull(), initResize(), initRotation(), initSeqSlide(), initShear_mouseInputMode(), initShrinkFatten(), initSkinResize(), initTilt(), initTimeScale(), initTimeSlide(), initTimeTranslate(), initToSphere(), initTrackball(), initTranslation(), and initVertSlide_ex().
| bool initTransform | ( | bContext * | C, |
| TransInfo * | t, | ||
| wmOperator * | op, | ||
| const wmEvent * | event, | ||
| int | mode ) |
t on a 0 return. Definition at line 1873 of file editors/transform/transform.cc.
References applyMouseInput(), BKE_editmesh_lnorspace_update(), BMEditMesh::bm, BM_lnorspace_invalidate(), C, calculateCenter(), calculatePropRatio(), TransInfo::center2d, TransInfo::con, CON_APPLY, TransInfo::context, create_trans_data(), CTX_CURSOR, CTX_GPENCIL_STROKES, CTX_TEXTURE_SPACE, CTX_VIEW2D_EDGE_PAN, CTX_wm_manager(), TransInfo::data_len_all, TransInfo::data_type, TransInfo::draw_handle_cursor, TransInfo::draw_handle_pixel, TransInfo::draw_handle_view, drawTransformPixel(), drawTransformView(), ED_region_draw_cb_activate(), ELEM, EVT_LEFTALTKEY, EVT_LEFTCTRLKEY, EVT_LEFTSHIFTKEY, EVT_OSKEY, EVT_RIGHTALTKEY, EVT_RIGHTCTRLKEY, EVT_RIGHTSHIFTKEY, TransInfo::flag, FOREACH_TRANS_DATA_CONTAINER, MouseInput::imval, initMouseInput(), initSnapping(), initTransInfo(), TransInfo::is_launch_event_drag, wmKeyMap::items, TransInfo::keymap, KM_ALT, KM_CLICK_DRAG, KM_CTRL, KM_OSKEY, KM_PRESS, KM_SHIFT, KMI_INACTIVE, TransInfo::launch_event, LISTBASE_FOREACH, MOD_NODE_ATTACH, MOD_SNAP_INVERT, wmOperatorType::modalkeymap, TransCon::mode, TransInfo::mode, wmEvent::modifier, TransInfo::modifiers, TransInfo::mouse, TransInfo::mval, OB_MESH, TransInfo::obedit_type, options, TransInfo::options, TransInfo::orient_axis, TransInfo::orient_axis_ortho, postTrans(), wmOperator::ptr, TransInfo::region, REGION_DRAW_POST_PIXEL, REGION_DRAW_POST_VIEW, RGN_TYPE_ANY, RNA_property_boolean_get(), RNA_property_boolean_set(), RNA_property_enum_get(), RNA_property_is_set(), RNA_struct_find_property(), setUserConstraint(), SPACE_ACTION, SPACE_CLIP, SPACE_GRAPH, SPACE_IMAGE, SPACE_NODE, SPACE_SEQ, SPACE_TYPE_ANY, SPACE_VIEW3D, TransInfo::spacemtx, TransInfo::spacetype, TransInfo::state, T_CLNOR_REBUILD, T_EDIT, T_MODAL, T_PROP_EDIT, TD_SELECTED, TFM_MODAL_NODE_ATTACH_OFF, TFM_MODAL_SNAP_INV_ON, TFM_RESIZE, TFM_ROTATION, TFM_TRANSLATION, BMesh::totvert, BMesh::totvertsel, TRANS_CANCEL, TRANS_STARTING, TransConvertType_Node, transform_draw_cursor_draw(), transform_draw_cursor_poll(), transform_mode_init(), transform_mode_really_used(), ARegion::type, wmEvent::type, wmOperator::type, unit_m3(), TransInfo::values, WM_keymap_active(), WM_paint_cursor_activate(), and WM_userdef_event_type_from_keymap_type().
Referenced by transformops_data().
| void initTransInfo | ( | bContext * | C, |
| TransInfo * | t, | ||
| wmOperator * | op, | ||
| const wmEvent * | event ) |
Setup internal data, mouse, vectors
Definition at line 116 of file transform_generics.cc.
References bScreen::animtimer, TransInfo::animtimer, TransInfo::area, TransInfo::around, TransInfo::aspect, AUTO_MERGE, AUTO_MERGE_AND_SPLIT, ToolSettings::automerge, BIF_countTransformOrientation(), BKE_paint_brush(), BKE_paint_get_active_from_context(), BKE_view_layer_active_object_get(), BKE_view_layer_synced_ensure(), BLI_assert, BRUSH_CURVE, calculateCenter2D(), calculateCenterLocal(), TransInfo::center_global, TransInfo::con, CON_APPLY, CON_AXIS0, CON_AXIS1, CON_AXIS2, copy_v4_v4(), CTX_CURSOR, CTX_data_depsgraph_pointer(), CTX_data_scene(), CTX_data_tool_settings(), CTX_data_view_layer(), CTX_EDGE_DATA, CTX_GPENCIL_STROKES, CTX_MASK, CTX_MOVIECLIP, CTX_NO_PET, CTX_PAINT_CURVE, CTX_SEQUENCER_IMAGE, CTX_TEXTURE_SPACE, CTX_VIEW2D_EDGE_PAN, CTX_wm_area(), CTX_wm_manager(), CTX_wm_message_bus(), CTX_wm_region(), TransInfo::data_container, TransInfo::data_container_len, TransInfo::data_len_all, TransInfo::depsgraph, ED_screen_animation_playing(), ED_space_clip_check_show_maskedit(), ED_space_clip_check_show_trackedit(), ED_space_image_show_uvedit(), ED_view3d_navigation_init(), ELEM, Brush::flag, TransInfo::flag, wmOperator::flag, TransInfo::helpline, HLP_NONE, ToolSettings::imapaint, MouseInput::imval, TransformOrientationSlot::index_custom, initNumInput(), TransInfo::is_orient_default_overwrite, ISMOUSE_BUTTON, wmKeyMap::items, KMI_INACTIVE, TransInfo::launch_event, LISTBASE_FOREACH, TransInfo::mat, TransInfo::matrix, TransInfo::mbus, MEM_callocN, wmOperatorType::modalkeymap, Object::mode, SpaceImage::mode, TransCon::mode, TransInfo::mode, TransInfo::mode_info, TransInfo::mouse, mul_v3_v3(), TransInfo::mval, wmEvent::mval, TransInfo::num, O_DEFAULT, O_SCENE, O_SET, OB_GREASE_PENCIL, OB_MESH, OB_MODE_ALL_PAINT, OB_MODE_EDIT, OB_MODE_EDIT_GPENCIL_LEGACY, OB_MODE_OBJECT, OB_MODE_SCULPT_CURVES, TransInfo::obedit_type, OP_IS_REPEAT_LAST, TransInfo::options, TransInfo::orient, TransInfo::orient_axis, TransInfo::orient_axis_ortho, TransInfo::orient_type_mask, Scene::orientation_slots, ImagePaintSettings::paint, printf, PROP_EDIT_CONNECTED, PROP_EDIT_PROJECTED, PROP_EDIT_USE, TransInfo::prop_mode, TransInfo::prop_size, wmOperator::ptr, TransInfo::redraw, TransInfo::region, ARegion::regiontype, TransInfo::remove_on_cancel, TransInfo::reports, wmOperator::reports, RGN_TYPE_PREVIEW, RGN_TYPE_WINDOW, RNA_boolean_get(), RNA_property_array_check(), RNA_property_boolean_get(), RNA_property_boolean_get_array(), RNA_property_boolean_set(), RNA_property_enum_get(), RNA_property_float_get(), RNA_property_float_get_array(), RNA_property_is_set(), RNA_struct_find_property(), SCE_ORIENT_DEFAULT, SCE_XFORM_AXIS_ALIGN, TransInfo::scene, SET_FLAG_FROM_TEST, TransInfo::settings, setTransformViewAspect(), setTransformViewMatrices(), SI_MODE_MASK, SI_MODE_PAINT, SPACE_ACTION, SPACE_CLIP, SPACE_EMPTY, SPACE_GRAPH, SPACE_IMAGE, SPACE_NODE, SPACE_SEQ, SPACE_VIEW3D, TransInfo::spacetype, T_ALT_TRANSFORM, t_around_get(), T_AUTOMERGE, T_AUTOSPLIT, T_DUPLICATED_KEYFRAMES, T_EVENT_DRAG_START, T_INPUT_IS_VALUES_FINAL, T_MODAL, T_NO_CURSOR_WRAP, T_NO_MIRROR, T_OVERRIDE_CENTER, T_PROP_CONNECTED, T_PROP_EDIT, T_PROP_PROJECTED, T_RELEASE_CONFIRM, T_V3D_ALIGN, t_view_get(), TFM_BWEIGHT, TFM_EDGE_CREASE, TFM_EDGE_SLIDE, TFM_MODAL_PASSTHROUGH_NAVIGATE, TFM_RESIZE, TFM_ROTATION, TFM_SHRINKFATTEN, TFM_TRACKBALL, TFM_TRANSLATION, TFM_VERT_SLIDE, Scene::toolsettings, transdata_check_local_islands(), ToolSettings::transform_flag, transform_gizmo_3d_model_from_constraint_and_mode_init(), transform_orientation_matrix_get(), transform_orientations_current_set(), TREDRAW_HARD, Object::type, TransformOrientationSlot::type, TransInfo::type, wmOperator::type, unit_m3(), USER_RELEASECONFIRM, ToolSettings::uvcalc_flag, UVCALC_TRANSFORM_CORRECT_SLIDE, V3D_AROUND_LOCAL_ORIGINS, V3D_ORIENT_CUSTOM, V3D_ORIENT_CUSTOM_MATRIX, V3D_ORIENT_GLOBAL, V3D_ORIENT_LOCAL, TransInfo::values, TransInfo::values_modal_offset, TransInfo::view, TransInfo::view_layer, TransInfo::vod, WM_event_drag_start_mval_fl(), WM_keymap_active(), and zero_v3().
Referenced by calculateTransformCenter(), and initTransform().
Here I would suggest only TransInfo related issues, like free data & reset variables. Not redraws.
Definition at line 739 of file transform_generics.cc.
References TransInfo::area, BLI_freelistN(), BLI_rng_free(), CTX_MASK, CTX_PAINT_CURVE, CTX_wm_window(), TransInfo::custom, MouseInput::data, TransInfo::data_container, TransInfo::data_len_all, TransInfo::draw_handle_cursor, TransInfo::draw_handle_pixel, TransInfo::draw_handle_view, ED_region_draw_cb_exit(), ED_uvedit_live_unwrap_end(), ED_view3d_navigation_free(), ELEM, ListBase::first, SpaceImage::flag, TransInfo::flag, FOREACH_TRANS_DATA_CONTAINER, freeSnapping(), freeTransCustomDataContainer(), TransData::hdata, MEM_freeN(), MEM_SAFE_FREE, TransInfo::mouse, OB_CURVES_LEGACY, OB_GPENCIL_LEGACY, OB_SURF, TransInfo::obedit_type, TransInfo::options, TransSnap::points, TransInfo::region, TransInfo::rng, SI_LIVE_UNWRAP, SPACE_GRAPH, SPACE_IMAGE, ScrArea::spacedata, TransInfo::spacetype, TransInfo::state, T_MODAL_CURSOR_SET, TD_BEZTRIPLE, TRANS_CANCEL, TransInfo::tsnap, ARegion::type, TransInfo::vod, WM_cursor_modal_restore(), and WM_paint_cursor_end().
Referenced by calculateTransformCenter(), initTransform(), and transformEnd().
Definition at line 377 of file editors/transform/transform.cc.
References projectFloatViewEx(), and V3D_PROJ_TEST_NOP.
Referenced by calculateCenter(), calculateCenter2D(), initTimeScale(), setNearestAxis3d(), and snapsource_confirm().
| void projectFloatViewEx | ( | TransInfo * | t, |
| const float | vec[3], | ||
| float | adr[2], | ||
| eV3DProjTest | flag ) |
Definition at line 349 of file editors/transform/transform.cc.
References CTX_PAINT_CURVE, ED_view3d_project_float_global(), flag, TransInfo::options, projectIntView(), TransInfo::region, ARegion::regiontype, RGN_TYPE_WINDOW, SPACE_VIEW3D, TransInfo::spacetype, V3D_PROJ_RET_OK, ARegion::winx, and ARegion::winy.
Referenced by projectFloatView(), and transform_draw_cursor_draw().
Definition at line 344 of file editors/transform/transform.cc.
References projectIntViewEx(), and V3D_PROJ_TEST_NOP.
Referenced by projectFloatViewEx().
| void projectIntViewEx | ( | TransInfo * | t, |
| const float | vec[3], | ||
| int | adr[2], | ||
| eV3DProjTest | flag ) |
Definition at line 231 of file editors/transform/transform.cc.
References TransInfo::area, TransInfo::aspect, BKE_mask_coord_to_image(), BKE_mask_coord_to_movieclip(), BLI_assert, SpaceClip::clip, CTX_MASK, CTX_MOVIECLIP, CTX_PAINT_CURVE, ED_clip_point_stable_pos__reverse(), ED_image_point_pos__reverse(), ED_space_clip_get_clip(), ED_view3d_project_int_global(), ELEM, ListBase::first, flag, SpaceAction::flag, SpaceImage::image, int, SpaceImage::iuser, TransInfo::options, TransInfo::region, ARegion::regiontype, RGN_TYPE_WINDOW, SACTION_DRAWTIME, SPACE_ACTION, SPACE_CLIP, SPACE_GRAPH, SPACE_IMAGE, SPACE_NLA, SPACE_NODE, SPACE_SEQ, SPACE_VIEW3D, ScrArea::spacedata, TransInfo::spacetype, UI_view2d_view_to_region(), SpaceClip::user, v, V3D_PROJ_RET_OK, and TransInfo::view.
Referenced by projectIntView().
Definition at line 408 of file editors/transform/transform.cc.
References TransInfo::area, TransInfo::aspect, CTX_MASK, CTX_MOVIECLIP, ED_space_image_get_size(), ListBase::first, SpaceImage::flag, TransInfo::mode, TransInfo::options, SI_COORDFLOATS, SPACE_CLIP, SPACE_IMAGE, ScrArea::spacedata, TransInfo::spacetype, and TFM_TRANSLATION.
Referenced by applyTranslation().
| void resetTransModal | ( | TransInfo * | t | ) |
Free data before switching to another mode.
Definition at line 53 of file transform_generics.cc.
References freeTransCustomDataForMode().
Referenced by transformEvent().
| void resetTransRestrictions | ( | TransInfo * | t | ) |
Definition at line 58 of file transform_generics.cc.
References TransInfo::flag.
Referenced by transformEvent().
| void restoreTransObjects | ( | TransInfo * | t | ) |
Definition at line 876 of file transform_generics.cc.
References FOREACH_TRANS_DATA_CONTAINER, TransData2D::h1, TransData2D::h2, TransData2D::ih1, TransData2D::ih2, TransInfo::mat, recalc_data(), restoreElement(), transdata_restore_basic(), and unit_m3().
Referenced by transform_mode_snap_source_init(), transformEnd(), and transformEvent().
| void saveTransform | ( | bContext * | C, |
| TransInfo * | t, | ||
| wmOperator * | op ) |
Definition at line 1655 of file editors/transform/transform.cc.
References BKE_view_layer_active_object_get(), BKE_view_layer_synced_ensure(), TransInfo::con, CON_APPLY, CON_AXIS0, CON_AXIS1, CON_AXIS2, constraintModeToIndex(), CTX_data_tool_settings(), CTX_MASK, CTX_NO_PET, ELEM, TransInfo::flag, wmOperator::flag, Scene::id, TransInfo::mbus, MOD_SNAP, MOD_SNAP_FORCED, Object::mode, TransCon::mode, TransInfo::mode, TransSnap::mode, TransInfo::modifiers, OB_MODE_OBJECT, OP_IS_REPEAT, TransInfo::options, TransInfo::orient, TransInfo::orient_axis, TransInfo::orient_axis_ortho, TransInfo::orient_curr, wmMsgParams_RNA::prop, PROP_EDIT_CONNECTED, PROP_EDIT_PROJECTED, PROP_EDIT_USE, ToolSettings::prop_mode, TransInfo::prop_mode, TransInfo::prop_size, ToolSettings::proportional_action, ToolSettings::proportional_edit, ToolSettings::proportional_fcurve, ToolSettings::proportional_mask, ToolSettings::proportional_objects, ToolSettings::proportional_size, wmMsgParams_RNA::ptr, wmOperator::ptr, RNA_boolean_set(), RNA_enum_set(), RNA_float_set(), RNA_float_set_array(), RNA_pointer_create(), RNA_property_array_check(), RNA_property_boolean_set(), RNA_property_boolean_set_array(), RNA_property_enum_get(), RNA_property_enum_set(), RNA_property_float_get(), RNA_property_float_set(), RNA_property_float_set_array(), RNA_property_is_set(), RNA_property_unset(), RNA_struct_find_property(), SCE_SNAP, SCE_SNAP_INDIVIDUAL_PROJECT, SCE_SNAP_TARGET_NOT_ACTIVE, SCE_SNAP_TARGET_NOT_EDITED, SCE_SNAP_TARGET_NOT_NONEDITED, SCE_SNAP_TARGET_ONLY_SELECTABLE, TransInfo::scene, SET_FLAG_FROM_TEST, TransInfo::settings, TransSnap::source_operation, SPACE_ACTION, SPACE_GRAPH, TransInfo::spacemtx, TransInfo::spacetype, TransInfo::state, T_ALT_TRANSFORM, T_MODAL, T_NO_MIRROR, T_PROP_CONNECTED, T_PROP_EDIT, T_PROP_EDIT_ALL, T_PROP_PROJECTED, TransSnap::target_operation, TFM_SHRINKFATTEN, TRANS_CANCEL, transform_snap_flag_from_spacetype_ptr(), transformModeUseSnap(), TransInfo::tsnap, TransInfo::type, ToolSettings::uvcalc_flag, UVCALC_TRANSFORM_CORRECT_SLIDE, V3D_ORIENT_CUSTOM_MATRIX, TransInfo::values_final, TransInfo::view_layer, and WM_msg_publish_rna_params().
Referenced by transformops_exit().
| void setCustomPoints | ( | TransInfo * | t, |
| MouseInput * | mi, | ||
| const int | mval_start[2], | ||
| const int | mval_end[2] ) |
Definition at line 226 of file transform_input.cc.
References data, MouseInput::data, and MEM_reallocN.
Referenced by calcEdgeSlideCustomPoints(), initResize(), setCustomPointsFromDirection(), transform_mode_edge_slide_reproject_input(), and vert_slide_update_input().
| void setCustomPointsFromDirection | ( | TransInfo * | t, |
| MouseInput * | mi, | ||
| const blender::float2 & | dir ) |
Referenced by initShear_mouseInputMode().
| void setInputPostFct | ( | MouseInput * | mi, |
| void(* | post )(TransInfo *t, float values[3]) ) |
Definition at line 482 of file transform_input.cc.
References MouseInput::post.
Definition at line 109 of file editors/transform/transform.cc.
References TransInfo::area, copy_v3_fl(), CTX_CURSOR, CTX_MASK, CTX_MOVIECLIP, CTX_PAINT_CURVE, ED_space_clip_get_aspect(), ED_space_clip_get_aspect_dimension_aware(), ED_space_image_get_aspect(), ED_space_image_get_uv_aspect(), ListBase::first, TransInfo::options, TransInfo::scene, SEQ_image_preview_unit_to_px(), SPACE_CLIP, SPACE_GRAPH, SPACE_IMAGE, SPACE_SEQ, ScrArea::spacedata, and TransInfo::spacetype.
Referenced by initTransInfo().
| void setTransformViewMatrices | ( | TransInfo * | t | ) |
Definition at line 87 of file editors/transform/transform.cc.
References copy_m4_m4(), CTX_PAINT_CURVE, TransInfo::options, RegionView3D::persinv, TransInfo::persinv, RegionView3D::persmat, TransInfo::persmat, RegionView3D::persp, TransInfo::persp, TransInfo::region, ARegion::regiondata, ARegion::regiontype, RGN_TYPE_WINDOW, RV3D_ORTHO, SPACE_VIEW3D, TransInfo::spacetype, unit_m4(), RegionView3D::viewinv, TransInfo::viewinv, RegionView3D::viewmat, and TransInfo::viewmat.
Referenced by initTransInfo(), and transformViewUpdate().
| bool transdata_check_local_islands | ( | TransInfo * | t, |
| short | around ) |
Definition at line 74 of file editors/transform/transform.cc.
References CTX_CURSOR, CTX_TEXTURE_SPACE, ELEM, OB_GPENCIL_LEGACY, OB_MESH, TransInfo::obedit_type, TransInfo::options, and V3D_AROUND_LOCAL_ORIGINS.
Referenced by initTransInfo(), and set_prop_dist().
Transform a single matrix using the current t->final_values.
Definition at line 2213 of file editors/transform/transform.cc.
References TransInfo::mode_info, and TransModeInfo::transform_matrix_fn.
Referenced by gizmo_modal(), and nla_transform_apply().
Rotate an element, low level code, ignore protected channels. (use for objects or pose-bones) Similar to ElementRotation.
Definition at line 1384 of file transform_generics.cc.
References angle(), axis_angle_to_mat3(), copy_qt_qt(), copy_v3_v3(), TransDataExtension::dquat, TransDataExtension::drot, eulO_to_mat3(), TransData::ext, invert_m3_m3(), TransDataExtension::iquat, TransDataExtension::irot, TransDataExtension::irotAngle, TransDataExtension::irotAxis, mat3_to_axis_angle(), mat3_to_compatible_eulO(), mat3_to_quat(), TransData::mtx, mul_m3_m3m3(), normalize_qt_qt(), TransDataExtension::quat, quat_to_mat3(), TransDataExtension::rot, ROT_MODE_AXISANGLE, ROT_MODE_QUAT, TransDataExtension::rotAngle, TransDataExtension::rotAxis, TransDataExtension::rotOrder, TransData::smtx, and unit_m3().
Referenced by applyFaceProject().
Definition at line 2222 of file editors/transform/transform.cc.
References TransInfo::values_final.
Referenced by gizmo_modal().
| void transform_input_reset | ( | TransInfo * | t, |
| const blender::float2 & | mval ) |
Referenced by snapsource_confirm().
Definition at line 526 of file transform_input.cc.
References MouseInput::accum, add_v2_v2_db(), MouseInput::apply, MouseInput::center, TransInfo::center2d, copy_v2_v2(), copy_v2_v2_db(), MouseInput::data, ELEM, MouseInput::factor, MouseInput::imval, InputAngle(), InputAngleSpring(), TransInfo::mode, TransInfo::mouse, InputAngle_Data::mval_prev, MouseInput::prev, sub_v2_v2v2(), sub_v2_v2v2_db(), TFM_EDGE_SLIDE, TFM_VERT_SLIDE, transform_mode_edge_slide_reproject_input(), transform_mode_vert_slide_reproject_input(), MouseInput::use_virtual_mval, and MouseInput::virtual_mval.
Referenced by transformViewUpdate().
| void transform_input_virtual_mval_reset | ( | TransInfo * | t | ) |
Definition at line 563 of file transform_input.cc.
References InputAngle_Data::angle, MouseInput::apply, MouseInput::data, ELEM, MouseInput::imval, InputAngle(), InputAngleSpring(), TransInfo::mouse, and MouseInput::virtual_mval.
Referenced by transform_modal().
| wmKeyMap * transform_modal_keymap | ( | wmKeyConfig * | keyconf | ) |
Called in transform_ops.cc, on each regeneration of key-maps.
Definition at line 734 of file editors/transform/transform.cc.
References NUM_MODAL_INCREMENT_DOWN, NUM_MODAL_INCREMENT_UP, wmKeyMap::poll_modal_item, TFM_MODAL_ADD_SNAP, TFM_MODAL_AUTOCONSTRAINT, TFM_MODAL_AUTOCONSTRAINTPLANE, TFM_MODAL_AUTOIK_LEN_DEC, TFM_MODAL_AUTOIK_LEN_INC, TFM_MODAL_AXIS_X, TFM_MODAL_AXIS_Y, TFM_MODAL_AXIS_Z, TFM_MODAL_CANCEL, TFM_MODAL_CONFIRM, TFM_MODAL_CONS_OFF, TFM_MODAL_EDIT_SNAP_SOURCE_OFF, TFM_MODAL_EDIT_SNAP_SOURCE_ON, TFM_MODAL_INSERTOFS_TOGGLE_DIR, TFM_MODAL_NODE_ATTACH_OFF, TFM_MODAL_NODE_ATTACH_ON, TFM_MODAL_PASSTHROUGH_NAVIGATE, TFM_MODAL_PLANE_X, TFM_MODAL_PLANE_Y, TFM_MODAL_PLANE_Z, TFM_MODAL_PRECISION, TFM_MODAL_PROPSIZE, TFM_MODAL_PROPSIZE_DOWN, TFM_MODAL_PROPSIZE_UP, TFM_MODAL_REMOVE_SNAP, TFM_MODAL_RESIZE, TFM_MODAL_ROTATE, TFM_MODAL_ROTATE_NORMALS, TFM_MODAL_SNAP_INV_OFF, TFM_MODAL_SNAP_INV_ON, TFM_MODAL_SNAP_TOGGLE, TFM_MODAL_TRACKBALL, TFM_MODAL_TRANSLATE, TFM_MODAL_VERT_EDGE_SLIDE, transform_modal_item_poll(), and WM_modalkeymap_ensure().
Referenced by ED_keymap_transform().
Definition at line 1484 of file transform_generics.cc.
References BASE_VISIBLE, BKE_modifiers_is_deformed_by_armature(), BKE_view_layer_base_find(), BKE_view_layer_synced_ensure(), Object::mode, OB_MODE_ALL_WEIGHT_PAINT, OB_MODE_POSE, TransInfo::scene, TransInfo::view, and TransInfo::view_layer.
Referenced by convert_type_get(), and transform_orientation_matrix_get().
Calculates projection vector based on a location.
Definition at line 63 of file editors/transform/transform.cc.
References copy_v3_v3(), normalize_v3(), TransInfo::persp, RV3D_ORTHO, sub_v3_v3v3(), and TransInfo::viewinv.
Definition at line 2132 of file editors/transform/transform.cc.
References C, TransInfo::context, CTX_AUTOCONFIRM, TransInfo::mode_info, TransInfo::options, TransInfo::redraw, selectConstraint(), TransInfo::state, TRANS_CONFIRM, TransModeInfo::transform_fn, TREDRAW_HARD, TREDRAW_NOTHING, TREDRAW_SOFT, and viewRedrawForce().
Referenced by transform_exec(), transform_invoke(), and transform_modal().
Definition at line 2157 of file editors/transform/transform.cc.
References BKE_editmesh_from_object(), BMEditMesh::bm, BM_lnorspace_rebuild(), C, TransInfo::context, ELEM, TransInfo::flag, FOREACH_TRANS_DATA_CONTAINER, OPERATOR_CANCELLED, OPERATOR_FINISHED, OPERATOR_RUNNING_MODAL, postTrans(), restoreTransObjects(), special_aftertrans_update(), TransInfo::state, T_CLNOR_REBUILD, TRANS_CANCEL, TRANS_RUNNING, TRANS_STARTING, transform_gizmo_3d_model_from_constraint_and_mode_restore(), viewRedrawForce(), and viewRedrawPost().
Referenced by transform_cancel(), transform_exec(), and transform_modal().
| int transformEvent | ( | TransInfo * | t, |
| wmOperator * | op, | ||
| const wmEvent * | event ) |
Definition at line 984 of file editors/transform/transform.cc.
References addSnapPoint(), applyMouseInput(), TransInfo::area, BKE_workspace_status_clear(), BLI_assert, calculatePropRatio(), TransInfo::con, CON_APPLY, CON_AXIS2, TransInfo::context, CTX_CAMERA, CTX_NO_PET, CTX_wm_window(), CTX_wm_workspace(), wmEvent::customdata, TransInfo::data_type, ED_uvedit_live_unwrap_timer_check(), ELEM, EVT_CKEY, EVT_LEFTALTKEY, EVT_MODAL_MAP, EVT_OKEY, EVT_PADMINUS, EVT_PADPLUSKEY, EVT_RIGHTALTKEY, ListBase::first, TransInfo::flag, wmEvent::flag, TransModeInfo::handle_event_fn, handleNumInput(), handleSnapping(), hasNumInput(), IFACE_, initSelectConstraint(), initSnapping(), SpaceNode::insert_ofs_dir, ISMOUSE_MOTION, KM_ALT, KM_PRESS, KM_RELEASE, KM_SHIFT, TransInfo::launch_event, max_ff(), min_ff(), MOD_CONSTRAINT_SELECT_AXIS, MOD_CONSTRAINT_SELECT_PLANE, MOD_EDIT_SNAP_SOURCE, MOD_NODE_ATTACH, MOD_PRECISION, MOD_SNAP, MOD_SNAP_INVERT, TransCon::mode, TransInfo::mode, TransInfo::mode_info, wmEvent::modifier, TransInfo::modifiers, TransInfo::mouse, MOUSEMOVE, TransInfo::mval, wmEvent::mval, TransInfo::num, OPERATOR_PASS_THROUGH, TransInfo::options, TransInfo::orient, TransInfo::orient_curr, TransInfo::persp, postSelectConstraint(), MouseInput::precision, wmEvent::prev_type, wmEvent::prev_val, TransInfo::prop_mode, PROP_MODE_MAX, TransInfo::prop_size, TransInfo::redraw, TransInfo::region, ARegion::regiondata, removeSnapPoint(), resetTransModal(), resetTransRestrictions(), restoreTransObjects(), RV3D_NAVIGATING, RV3D_ORTHO, SCE_SNAP_TO_GRID, setLocalConstraint(), SNODE_INSERTOFS_DIR_LEFT, SNODE_INSERTOFS_DIR_RIGHT, sort_trans_data_dist(), SPACE_IMAGE, SPACE_NODE, SPACE_SEQ, SPACE_VIEW3D, ScrArea::spacedata, ScrArea::spacetype, TransInfo::spacetype, TransInfo::state, stopConstraint(), T_ALT_TRANSFORM, T_AUTOIK, T_NO_CONSTRAINT, T_PROP_CONNECTED, T_PROP_EDIT, T_PROP_SIZE_MAX, T_PROP_SIZE_MIN, T_RELEASE_CONFIRM, TransSnap::target_type, TFM_EDGE_SLIDE, TFM_MODAL_ADD_SNAP, TFM_MODAL_AUTOCONSTRAINT, TFM_MODAL_AUTOCONSTRAINTPLANE, TFM_MODAL_AUTOIK_LEN_DEC, TFM_MODAL_AUTOIK_LEN_INC, TFM_MODAL_AXIS_X, TFM_MODAL_AXIS_Y, TFM_MODAL_AXIS_Z, TFM_MODAL_CANCEL, TFM_MODAL_CONFIRM, TFM_MODAL_CONS_OFF, TFM_MODAL_EDIT_SNAP_SOURCE_ON, TFM_MODAL_INSERTOFS_TOGGLE_DIR, TFM_MODAL_NODE_ATTACH_OFF, TFM_MODAL_NODE_ATTACH_ON, TFM_MODAL_PLANE_X, TFM_MODAL_PLANE_Y, TFM_MODAL_PLANE_Z, TFM_MODAL_PRECISION, TFM_MODAL_PROPSIZE, TFM_MODAL_PROPSIZE_DOWN, TFM_MODAL_PROPSIZE_UP, TFM_MODAL_REMOVE_SNAP, TFM_MODAL_RESIZE, TFM_MODAL_ROTATE, TFM_MODAL_ROTATE_NORMALS, TFM_MODAL_SNAP_INV_OFF, TFM_MODAL_SNAP_INV_ON, TFM_MODAL_SNAP_TOGGLE, TFM_MODAL_TRACKBALL, TFM_MODAL_TRANSLATE, TFM_MODAL_VERT_EDGE_SLIDE, TFM_NORMAL_ROTATION, TFM_RESIZE, TFM_ROTATION, TFM_TRACKBALL, TFM_TRANSLATION, TFM_VERT_SLIDE, TIMER, TRANS_CANCEL, TRANS_CONFIRM, TRANS_RUNNING, TRANS_STARTING, TransConvertType_Mesh, TransConvertType_Tracking, transform_autoik_update(), transform_event_modal_constraint(), transform_mode_init(), transform_mode_is_changeable(), transform_mode_snap_source_init(), transform_snap_flag_from_modifiers_set(), TREDRAW_HARD, TREDRAW_SOFT, TransInfo::tsnap, TransInfo::type, wmEvent::type, V3D_ORIENT_NORMAL, wmEvent::val, validSnap(), TransInfo::values, TransInfo::view, TransInfo::vod, WM_EVENT_IS_REPEAT, and WM_window_status_area_tag_redraw().
Referenced by transform_modal().
| void transformViewUpdate | ( | TransInfo * | t | ) |
Called every time the view changes due to navigation. Adjusts the mouse position relative to the object.
Definition at line 1227 of file transform_generics.cc.
References ARRAY_SIZE, calculateCenter2D(), calculateZfac(), copy_m3_m3(), copy_m3_m4(), invert_m3_m3_safe_ortho(), len_v3(), TransInfo::matrix, normalize_m3(), TransInfo::orient, TransInfo::orient_curr, TransInfo::persinv, TransInfo::persp, TransInfo::region, ARegion::regiontype, RGN_TYPE_WINDOW, setTransformViewMatrices(), TransInfo::snap_spatial, TransInfo::snap_spatial_precision, SPACE_VIEW3D, TransInfo::spacemtx, TransInfo::spacemtx_inv, TransInfo::spacetype, transform_input_update(), transform_snap_grid_init(), TransInfo::type, V3D_ORIENT_VIEW, TransInfo::viewinv, and TransInfo::zfac.
Referenced by blender::ed::transform::flushTransNodes(), transform_modal(), and view2d_edge_pan_loc_compensate().