Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Always pre-transform vertices while reading with Assimp. #6959

Merged
merged 2 commits into from
Sep 13, 2024

Conversation

ssheorey
Copy link
Member

Type

  • Bug fix (non-breaking change which fixes an issue): Fixes #
  • New feature (non-breaking change which adds functionality). Resolves #
  • Breaking change (fix or feature that would cause existing functionality to not work as expected) Resolves #

Motivation and Context

While reading glb files with bone transforms (especially scaling) and a single mesh, the transform is ignored if post_process is not enabled. This can cause reading a mesh with incorrect scale factor.

e.g.: 03d693e178e54766af2905e90cbc1f03.glb file from Objaverse

Checklist:

  • I have run python util/check_style.py --apply to apply Open3D code style
    to my code.
  • This PR changes Open3D behavior or adds new functionality.
    • Both C++ (Doxygen) and Python (Sphinx / Google style) documentation is
      updated accordingly.
    • I have added or updated C++ and / or Python unit tests OR included test
      results
      (e.g. screenshots or numbers) here.
  • I will follow up and update the code if CI fails.
  • For fork PRs, I have selected Allow edits from maintainers.

Description

This PR adds the PreTransformVertices option to the Assimp backend call by default, so that all transforms are always applied.

Also improves error messages when reading / writing fails.

Copy link

update-docs bot commented Sep 10, 2024

Thanks for submitting this pull request! The maintainers of this repository would appreciate if you could update the CHANGELOG.md based on your changes.

Copy link
Contributor

@benjaminum benjaminum left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

Copy link

@RachithP RachithP left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good!
Not sure if the failing checks are something that needs to be addressed before merging.

@ssheorey ssheorey merged commit dbb3c7d into main Sep 13, 2024
33 of 44 checks passed
@ssheorey ssheorey deleted the ss/assimp-pretransform branch September 13, 2024 00:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants