Skip to content

joml enable approximations #10092

@NeumimTo

Description

@NeumimTo

Is your feature request related to a problem?

from javadocs

Contains fast approximations of some Math operations.
By default, Math methods will be used by all other JOML classes. In order to use the approximations in this class, start the JVM with the parameter -Djoml.fastmath.
There are two algorithms for approximating sin/cos:
arithmetic polynomial approximation contributed by roquendm
theagentd's linear interpolation variant of Riven's algorithm from http://www.java-gaming.org/
By default, the first algorithm is being used. In order to use the second one, start the JVM with -Djoml.sinLookup. The lookup table bit length of the second algorithm can also be adjusted for improved accuracy via -Djoml.sinLookup.bits=, where is the number of bits of the lookup table.

Describe the solution you'd like.

set system property -Djoml.fastmath and -Djoml.sinLookup.bits during paper startup

Describe alternatives you've considered.

Provide another math library with paper thats better than java math, for example on sponge platform we have access to https://github.com/SpongePowered/math without need to do any kind of shading.

Other

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    resolution: won't fixIssue will not be resolved or feature not added.status: unlikelyUnlikely to ever be worked on due to complexity or risktype: featureRequest for a new Feature.
    No fields configured for Feature.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions