diff options
author | Campbell Barton <ideasman42@gmail.com> | 2015-08-26 08:13:19 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2015-08-26 08:13:19 +0300 |
commit | 1d34f0feede65460d564e4f0cf17f73007e102f2 (patch) | |
tree | 219b957467d9f6f0646fd5cb839131bfa840e5c3 /source/blender/editors/space_view3d/view3d_edit.c | |
parent | cc60f35a18041d7dd364cba223b46dbcbd036e43 (diff) |
Smooth-view: Ignored camera-viewpoint on exit to user-view
Diffstat (limited to 'source/blender/editors/space_view3d/view3d_edit.c')
-rw-r--r-- | source/blender/editors/space_view3d/view3d_edit.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/source/blender/editors/space_view3d/view3d_edit.c b/source/blender/editors/space_view3d/view3d_edit.c index dd82e66cb97..3fc415ed21b 100644 --- a/source/blender/editors/space_view3d/view3d_edit.c +++ b/source/blender/editors/space_view3d/view3d_edit.c @@ -3815,8 +3815,16 @@ static void axis_set_view(bContext *C, View3D *v3d, ARegion *ar, smooth_viewtx); } else { + float ofs[3], dist; + + copy_v3_v3(ofs, rv3d->ofs); + dist = rv3d->dist; + + /* so we animate _from_ the camera location */ + ED_view3d_from_object(v3d->camera, rv3d->ofs, NULL, &rv3d->dist, NULL); + ED_view3d_smooth_view(C, v3d, ar, NULL, NULL, - NULL, quat, NULL, NULL, + ofs, quat, &dist, NULL, smooth_viewtx); } |