diff options
author | Hugo Locurcio <hugo.locurcio@hugo.pro> | 2021-05-23 19:50:53 +0200 |
---|---|---|
committer | Hugo Locurcio <hugo.locurcio@hugo.pro> | 2021-05-23 19:50:53 +0200 |
commit | 21807f8d883a3a276bea990c9349e0417caf46f6 (patch) | |
tree | 0ad28384d2a164a24d6de3a86a4b0b2ed181c04b /editor/plugins | |
parent | 809948f977294c8bb61a6e46dfa132ea6e0478d8 (diff) |
Fix editor constantly redrawing when freelook is active with still camera
The editor only needs to redraw when the camera is moving.
This helps preserver battery life on laptops when using freelook,
especially with the toggle mode (Shift + F).
Diffstat (limited to 'editor/plugins')
-rw-r--r-- | editor/plugins/node_3d_editor_plugin.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/editor/plugins/node_3d_editor_plugin.cpp b/editor/plugins/node_3d_editor_plugin.cpp index ba39ce3aed..10dfb65c45 100644 --- a/editor/plugins/node_3d_editor_plugin.cpp +++ b/editor/plugins/node_3d_editor_plugin.cpp @@ -344,7 +344,7 @@ void Node3DEditorViewport::_update_camera(float p_interp_delta) { equal = false; } - if (!equal || p_interp_delta == 0 || is_freelook_active() || is_orthogonal != orthogonal) { + if (!equal || p_interp_delta == 0 || is_orthogonal != orthogonal) { camera->set_global_transform(to_camera_transform(camera_cursor)); if (orthogonal) { |