Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/editors/space_view3d/view3d_walk.c')
-rw-r--r--source/blender/editors/space_view3d/view3d_walk.c20
1 files changed, 6 insertions, 14 deletions
diff --git a/source/blender/editors/space_view3d/view3d_walk.c b/source/blender/editors/space_view3d/view3d_walk.c
index 50fa573423a..64167b83655 100644
--- a/source/blender/editors/space_view3d/view3d_walk.c
+++ b/source/blender/editors/space_view3d/view3d_walk.c
@@ -16,6 +16,11 @@
/** \file
* \ingroup spview3d
+ *
+ * Interactive walk navigation modal operator
+ * (similar to walking around in a first person game).
+ *
+ * \note Similar logic to `view3d_fly.c` changes here may apply there too.
*/
/* defines VIEW3D_OT_navigate - walk modal operator */
@@ -620,7 +625,7 @@ static int walkEnd(bContext *C, WalkInfo *walk)
if (walk->state == WALK_RUNNING) {
return OPERATOR_RUNNING_MODAL;
}
- else if (walk->state == WALK_CONFIRM) {
+ if (walk->state == WALK_CONFIRM) {
/* Needed for auto_keyframe. */
#ifdef WITH_INPUT_NDOF
if (walk->ndof) {
@@ -1295,19 +1300,6 @@ static int walkApply(bContext *C, WalkInfo *walk, bool is_confirm)
sub_v3_v3v3(dvec, cur_loc, new_loc);
}
- if (rv3d->persp == RV3D_CAMOB) {
- Object *lock_ob = ED_view3d_cameracontrol_object_get(walk->v3d_camera_control);
- if (lock_ob->protectflag & OB_LOCK_LOCX) {
- dvec[0] = 0.0f;
- }
- if (lock_ob->protectflag & OB_LOCK_LOCY) {
- dvec[1] = 0.0f;
- }
- if (lock_ob->protectflag & OB_LOCK_LOCZ) {
- dvec[2] = 0.0f;
- }
- }
-
/* scale the movement to the scene size */
mul_v3_v3fl(dvec_tmp, dvec, walk->grid);
add_v3_v3(rv3d->ofs, dvec_tmp);