diff options
-rw-r--r-- | source/blender/editors/space_view3d/view3d_camera_control.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/editors/space_view3d/view3d_camera_control.c b/source/blender/editors/space_view3d/view3d_camera_control.c index bce0e49d60a..11643960595 100644 --- a/source/blender/editors/space_view3d/view3d_camera_control.c +++ b/source/blender/editors/space_view3d/view3d_camera_control.c @@ -138,7 +138,8 @@ struct View3DCameraControl *ED_view3d_cameracontrol_acquire(Depsgraph *depsgraph vctrl->ctx_v3d = v3d; vctrl->ctx_rv3d = rv3d; - vctrl->use_parent_root = v3d->camera->transflag & OB_TRANSFORM_ADJUST_ROOT_PARENT_FOR_VIEW_LOCK; + vctrl->use_parent_root = v3d->camera != NULL && + v3d->camera->transflag & OB_TRANSFORM_ADJUST_ROOT_PARENT_FOR_VIEW_LOCK; vctrl->persp_backup = rv3d->persp; vctrl->dist_backup = rv3d->dist; |