Skip to content

Add fast_normalize to Quat (and maybe other types) #540

@janhohenheim

Description

@janhohenheim

See this issue: bevyengine/bevy#14302 and the accompanying PR: bevyengine/bevy#14316 (comment) for context and an example implementation.

The motivating problem is this: operating multiple times on a normalized quaternion will accumulate small errors that will eventually result in it no longer being normalized. While the error is still small, a full .normalize() is not necessary; there are cheaper ways to get such a quaternion normalized again.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions