Skip to content

Commit

Permalink
CameraProjectionType - #105
Browse files Browse the repository at this point in the history
  • Loading branch information
nem0 committed Dec 28, 2024
1 parent 4f9f52c commit 777268c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/ofbx.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -2457,6 +2457,9 @@ struct OptionalError<Object*> parseCamera(Scene& scene, const Element& element,
CameraImpl* camera = allocator.allocate<CameraImpl>(scene, element);

camera->projectionType = static_cast<Camera::ProjectionType>(resolveEnumProperty(*camera, "ProjectionType", (int)Camera::ProjectionType::PERSPECTIVE));
// try "CameraProjectionType" too, see https://github.com/nem0/OpenFBX/issues/105
camera->projectionType = static_cast<Camera::ProjectionType>(resolveEnumProperty(*camera, "CameraProjectionType", (int)camera->projectionType));

camera->apertureMode = static_cast<Camera::ApertureMode>(resolveEnumProperty(*camera, "ApertureMode", (int)Camera::ApertureMode::HORIZANDVERT));
camera->gateFit = static_cast<Camera::GateFit>(resolveEnumProperty(*camera, "GateFit", (int)Camera::GateFit::HORIZONTAL));

Expand Down

0 comments on commit 777268c

Please sign in to comment.