Class InterpolationUtil

java.lang.Object
kr.toxicity.model.api.util.InterpolationUtil

@Internal public final class InterpolationUtil extends Object
Interpolation util
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static interface 
     
  • Method Summary

    Modifier and Type
    Method
    Description
    static float
    alpha(float p0, float p1, float alpha)
     
    static @NotNull org.joml.Vector3f
    bezier(float time, float startTime, float endTime, @NotNull org.joml.Vector3f startValue, @NotNull org.joml.Vector3f endValue, @Nullable org.joml.Vector3f bezierLeftTime, @Nullable org.joml.Vector3f bezierLeftValue, @Nullable org.joml.Vector3f bezierRightTime, @Nullable org.joml.Vector3f bezierRightValue)
     
    static @NotNull @Unmodifiable List<AnimationMovement>
    buildAnimation(@NotNull List<VectorPoint> position, @NotNull List<VectorPoint> rotation, @NotNull List<VectorPoint> scale, @NotNull it.unimi.dsi.fastutil.floats.FloatSortedSet points)
     
    static @NotNull org.joml.Vector3f
    catmull_rom(@NotNull org.joml.Vector3f p0, @NotNull org.joml.Vector3f p1, @NotNull org.joml.Vector3f p2, @NotNull org.joml.Vector3f p3, float t)
     
    static float
    cubicBezier(float p0, float p1, float p2, float p3, float t)
     
    static float
    derivativeBezier(float p0, float p1, float p2, float p3, float t)
     
    static void
    insertLerpFrame(@NotNull it.unimi.dsi.fastutil.floats.FloatSortedSet frames)
     
    static void
    insertLerpFrame(@NotNull it.unimi.dsi.fastutil.floats.FloatSortedSet frames, float frame)
     
    interpolatorFor(@NotNull List<VectorPoint> vectors)
     
    static float
    lerp(float p0, float p1, float alpha)
     
    static @NotNull org.joml.Vector3f
    lerp(@NotNull org.joml.Vector3f p0, @NotNull org.joml.Vector3f p1, float alpha)
     
    static float
    roundTime(float time)
     
    static float
    solveBezierTForTime(float time, float t0, float h1, float h2, float t1)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Method Details

    • buildAnimation

      @NotNull public static @NotNull @Unmodifiable List<AnimationMovement> buildAnimation(@NotNull @NotNull List<VectorPoint> position, @NotNull @NotNull List<VectorPoint> rotation, @NotNull @NotNull List<VectorPoint> scale, @NotNull @NotNull it.unimi.dsi.fastutil.floats.FloatSortedSet points)
    • interpolatorFor

      @NotNull public static @NotNull InterpolationUtil.VectorPointBuilder interpolatorFor(@NotNull @NotNull List<VectorPoint> vectors)
    • insertLerpFrame

      public static void insertLerpFrame(@NotNull @NotNull it.unimi.dsi.fastutil.floats.FloatSortedSet frames)
    • roundTime

      public static float roundTime(float time)
    • insertLerpFrame

      public static void insertLerpFrame(@NotNull @NotNull it.unimi.dsi.fastutil.floats.FloatSortedSet frames, float frame)
    • alpha

      public static float alpha(float p0, float p1, float alpha)
    • lerp

      @NotNull public static @NotNull org.joml.Vector3f lerp(@NotNull @NotNull org.joml.Vector3f p0, @NotNull @NotNull org.joml.Vector3f p1, float alpha)
    • lerp

      public static float lerp(float p0, float p1, float alpha)
    • cubicBezier

      public static float cubicBezier(float p0, float p1, float p2, float p3, float t)
    • derivativeBezier

      public static float derivativeBezier(float p0, float p1, float p2, float p3, float t)
    • solveBezierTForTime

      public static float solveBezierTForTime(float time, float t0, float h1, float h2, float t1)
    • bezier

      @NotNull public static @NotNull org.joml.Vector3f bezier(float time, float startTime, float endTime, @NotNull @NotNull org.joml.Vector3f startValue, @NotNull @NotNull org.joml.Vector3f endValue, @Nullable @Nullable org.joml.Vector3f bezierLeftTime, @Nullable @Nullable org.joml.Vector3f bezierLeftValue, @Nullable @Nullable org.joml.Vector3f bezierRightTime, @Nullable @Nullable org.joml.Vector3f bezierRightValue)
    • catmull_rom

      @NotNull public static @NotNull org.joml.Vector3f catmull_rom(@NotNull @NotNull org.joml.Vector3f p0, @NotNull @NotNull org.joml.Vector3f p1, @NotNull @NotNull org.joml.Vector3f p2, @NotNull @NotNull org.joml.Vector3f p3, float t)