summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2019-11-21 22:08:03 +0100
committerGitHub <noreply@github.com>2019-11-21 22:08:03 +0100
commit1dc110fe7bb574f771ce19560d14a44b5550ac80 (patch)
tree9e58f0d599211c1b764d8de29d1ff30eef4f5cd9
parentc352e6f841de3f1e3b415b28425fe03d4e8407f4 (diff)
parentd0de3738843ed4e4f4a2864208782b3568effe71 (diff)
Merge pull request #33793 from fire/33756
33756 gltf2 importer should use zfar
-rw-r--r--editor/import/editor_scene_importer_gltf.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/editor/import/editor_scene_importer_gltf.cpp b/editor/import/editor_scene_importer_gltf.cpp
index 30e2aae020..bb4f950674 100644
--- a/editor/import/editor_scene_importer_gltf.cpp
+++ b/editor/import/editor_scene_importer_gltf.cpp
@@ -2494,9 +2494,9 @@ Camera *EditorSceneImporterGLTF::_generate_camera(GLTFState &state, Node *scene_
const GLTFCamera &c = state.cameras[gltf_node->camera];
if (c.perspective) {
- camera->set_perspective(c.fov_size, c.znear, c.znear);
+ camera->set_perspective(c.fov_size, c.znear, c.zfar);
} else {
- camera->set_orthogonal(c.fov_size, c.znear, c.znear);
+ camera->set_orthogonal(c.fov_size, c.znear, c.zfar);
}
return camera;