java.lang.Object
net.ixdarklord.folios.internal.compat.Compat

public final class Compat extends Object
  • Method Summary

    Modifier and Type
    Method
    Description
    static com.mojang.blaze3d.vertex.PoseStack.Pose
    copy(com.mojang.blaze3d.vertex.PoseStack.Pose pose)
    PoseStack.Pose.copy: a pose of its own, holding the same matrices.
    static <T> com.mojang.serialization.Codec<List<T>>
    listOf(com.mojang.serialization.Codec<T> codec, int min, int max)
    Codec.listOf(min, max): a list of at least min and at most max elements.
    static void
    mulPose(com.mojang.blaze3d.vertex.PoseStack pose, org.joml.Matrix4f matrix)
    PoseStack.mulPose(Matrix4f): the matrix, its rotation turning the normals too.
    static void
    scale(com.mojang.blaze3d.vertex.PoseStack pose, float x, float y, float z)
    PoseStack.scale as later versions do it.
    static org.joml.Vector3f
    transformNormal(com.mojang.blaze3d.vertex.PoseStack.Pose pose, float x, float y, float z, org.joml.Vector3f out)
    PoseStack.Pose.transformNormal: a direction turned by the pose, normalized.

    Methods inherited from class java.lang.Object

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

    • listOf

      public static <T> com.mojang.serialization.Codec<List<T>> listOf(com.mojang.serialization.Codec<T> codec, int min, int max)
      Codec.listOf(min, max): a list of at least min and at most max elements.
    • mulPose

      public static void mulPose(com.mojang.blaze3d.vertex.PoseStack pose, org.joml.Matrix4f matrix)
      PoseStack.mulPose(Matrix4f): the matrix, its rotation turning the normals too.
    • scale

      public static void scale(com.mojang.blaze3d.vertex.PoseStack pose, float x, float y, float z)
      PoseStack.scale as later versions do it. 1.20.1's takes a cube root by a trick that breaks on a negative product, so mirroring one axis (y, to turn page pixels upright) left the normals garbage and every face lit at the ambient floor.
    • transformNormal

      public static org.joml.Vector3f transformNormal(com.mojang.blaze3d.vertex.PoseStack.Pose pose, float x, float y, float z, org.joml.Vector3f out)
      PoseStack.Pose.transformNormal: a direction turned by the pose, normalized.
    • copy

      public static com.mojang.blaze3d.vertex.PoseStack.Pose copy(com.mojang.blaze3d.vertex.PoseStack.Pose pose)
      PoseStack.Pose.copy: a pose of its own, holding the same matrices.