Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/transform/transform.c
- This file is larger than 256 KB, so syntax highlighting is disabled by default.
| Show All 36 Lines | |||||
| #include "DNA_movieclip_types.h" | #include "DNA_movieclip_types.h" | ||||
| #include "DNA_scene_types.h" /* PET modes */ | #include "DNA_scene_types.h" /* PET modes */ | ||||
| #include "DNA_workspace_types.h" | #include "DNA_workspace_types.h" | ||||
| #include "DNA_gpencil_types.h" | #include "DNA_gpencil_types.h" | ||||
| #include "BLI_alloca.h" | #include "BLI_alloca.h" | ||||
| #include "BLI_utildefines.h" | #include "BLI_utildefines.h" | ||||
| #include "BLI_math.h" | #include "BLI_math.h" | ||||
| #include "BLI_math_bits.h" | |||||
| #include "BLI_rect.h" | #include "BLI_rect.h" | ||||
| #include "BLI_listbase.h" | #include "BLI_listbase.h" | ||||
| #include "BLI_string.h" | #include "BLI_string.h" | ||||
| #include "BLI_ghash.h" | #include "BLI_ghash.h" | ||||
| #include "BLI_utildefines_stack.h" | #include "BLI_utildefines_stack.h" | ||||
| #include "BLI_memarena.h" | #include "BLI_memarena.h" | ||||
| #include "BKE_nla.h" | #include "BKE_nla.h" | ||||
| Show All 20 Lines | |||||
| #include "ED_keyframing.h" | #include "ED_keyframing.h" | ||||
| #include "ED_screen.h" | #include "ED_screen.h" | ||||
| #include "ED_space_api.h" | #include "ED_space_api.h" | ||||
| #include "ED_markers.h" | #include "ED_markers.h" | ||||
| #include "ED_view3d.h" | #include "ED_view3d.h" | ||||
| #include "ED_mesh.h" | #include "ED_mesh.h" | ||||
| #include "ED_clip.h" | #include "ED_clip.h" | ||||
| #include "ED_node.h" | #include "ED_node.h" | ||||
| #include "ED_gizmo_library.h" | |||||
| #include "ED_gpencil.h" | #include "ED_gpencil.h" | ||||
| #include "WM_types.h" | #include "WM_types.h" | ||||
| #include "WM_api.h" | #include "WM_api.h" | ||||
| #include "UI_view2d.h" | #include "UI_view2d.h" | ||||
| #include "UI_interface.h" | #include "UI_interface.h" | ||||
| #include "UI_interface_icons.h" | #include "UI_interface_icons.h" | ||||
| ▲ Show 20 Lines • Show All 1,980 Lines • ▼ Show 20 Lines | if ((U.autokey_flag & AUTOKEY_FLAG_NOWARNING) == 0) { | ||||
| if (ar == t->ar) { | if (ar == t->ar) { | ||||
| if (t->flag & (T_OBJECT | T_POSE)) { | if (t->flag & (T_OBJECT | T_POSE)) { | ||||
| if (ob && autokeyframe_cfra_can_key(scene, &ob->id)) { | if (ob && autokeyframe_cfra_can_key(scene, &ob->id)) { | ||||
| drawAutoKeyWarning(t, ar); | drawAutoKeyWarning(t, ar); | ||||
| } | } | ||||
| } | } | ||||
| } | } | ||||
| } | } | ||||
| if (t->tsnap.status & POINT_INIT) { | |||||
| float screen_co[2]; | |||||
| if (ED_view3d_project_float_ex( | |||||
| t->ar, t->persmat, false, t->tsnap.snapPoint, screen_co, V3D_PROJ_TEST_NOP) == | |||||
| V3D_PROJ_RET_OK) { | |||||
| unsigned char activeCol[4]; | |||||
| UI_GetThemeColor3ubv(TH_ACTIVE, activeCol); | |||||
| short elem_type = count_bits_i((int)scene->toolsettings->snap_mode) > 1 ? | |||||
| t->tsnap.elem_type : | |||||
| 0; | |||||
| ED_gizmo_draw_preset_snap_elem(NULL, screen_co, activeCol, elem_type); | |||||
| } | |||||
| } | |||||
| } | } | ||||
| } | } | ||||
| /** | /** | ||||
| * \see #initTransform which reads values from the operator. | * \see #initTransform which reads values from the operator. | ||||
| */ | */ | ||||
| void saveTransform(bContext *C, TransInfo *t, wmOperator *op) | void saveTransform(bContext *C, TransInfo *t, wmOperator *op) | ||||
| { | { | ||||
| ▲ Show 20 Lines • Show All 7,797 Lines • Show Last 20 Lines | |||||