summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorK. S. Ernest (iFire) Lee <ernest.lee@chibifire.com>2019-11-21 07:52:18 -0800
committerK. S. Ernest (iFire) Lee <ernest.lee@chibifire.com>2019-11-21 07:52:18 -0800
commitd0de3738843ed4e4f4a2864208782b3568effe71 (patch)
treebcc9cfbd352d0d92ade813fdc83fce5e692f7c23
parent37b230fe3af3c7e20a6f938d03b61a79b117d354 (diff)
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;