diff options
author | RĂ©mi Verschelde <remi@verschelde.fr> | 2021-07-20 22:19:06 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-07-20 22:19:06 +0200 |
commit | c82daaed483e7ab7df7e44c2d01a906154801905 (patch) | |
tree | 43d175b117dc6431f82b426e75ba71839fc48ddc /editor/plugins | |
parent | 693f9b4e20f76d56ead91f8a8cad204516d2d953 (diff) | |
parent | 879f84d8f8e7d9467bb9049b445d576916c847c0 (diff) |
Merge pull request #38317 from verdog/get-cam-2d-4.0
add viewport.get_camera_2d()
Diffstat (limited to 'editor/plugins')
-rw-r--r-- | editor/plugins/node_3d_editor_plugin.cpp | 2 | ||||
-rw-r--r-- | editor/plugins/node_3d_editor_plugin.h | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/editor/plugins/node_3d_editor_plugin.cpp b/editor/plugins/node_3d_editor_plugin.cpp index 0764a4c46c..a0884a81cd 100644 --- a/editor/plugins/node_3d_editor_plugin.cpp +++ b/editor/plugins/node_3d_editor_plugin.cpp @@ -2438,7 +2438,7 @@ void Node3DEditorViewport::_notification(int p_what) { Node *scene_root = editor->get_scene_tree_dock()->get_editor_data()->get_edited_scene_root(); if (previewing_cinema && scene_root != nullptr) { - Camera3D *cam = scene_root->get_viewport()->get_camera(); + Camera3D *cam = scene_root->get_viewport()->get_camera_3d(); if (cam != nullptr && cam != previewing) { //then switch the viewport's camera to the scene's viewport camera if (previewing != nullptr) { diff --git a/editor/plugins/node_3d_editor_plugin.h b/editor/plugins/node_3d_editor_plugin.h index fa0f4e950f..cc65cb53ca 100644 --- a/editor/plugins/node_3d_editor_plugin.h +++ b/editor/plugins/node_3d_editor_plugin.h @@ -494,7 +494,7 @@ public: AcceptDialog *p_accept); SubViewport *get_viewport_node() { return viewport; } - Camera3D *get_camera() { return camera; } // return the default camera object. + Camera3D *get_camera_3d() { return camera; } // return the default camera object. Node3DEditorViewport(Node3DEditor *p_spatial_editor, EditorNode *p_editor, int p_index); ~Node3DEditorViewport(); |