Class BakedQuadFactory
java.lang.Object
net.minecraft.client.render.model.BakedQuadFactory
@Environment(CLIENT) public class BakedQuadFactory extends Object
-
Field Summary
-
Constructor Summary
Constructors Constructor Description BakedQuadFactory()
-
Method Summary
Modifier and Type Method Description BakedQuad
bake(Vec3f from, Vec3f to, ModelElementFace face, Sprite texture, Direction side, ModelBakeSettings settings, ModelRotation rotation, boolean shade, Identifier modelId)
static Direction
decodeDirection(int[] rotationMatrix)
private void
encodeDirection(int[] rotationMatrix, Direction direction)
private float[]
getPositionMatrix(Vec3f from, Vec3f to)
private void
packVertexData(int[] vertices, int cornerIndex, Direction direction, ModelElementTexture texture, float[] positionMatrix, Sprite sprite, AffineTransformation orientation, ModelRotation rotation, boolean shaded)
private void
packVertexData(int[] vertices, int cornerIndex, Vec3f position, Sprite sprite, ModelElementTexture modelElementTexture)
private int[]
packVertexData(ModelElementTexture texture, Sprite sprite, Direction direction, float[] positionMatrix, AffineTransformation orientation, ModelRotation rotation, boolean shaded)
private void
rotateVertex(Vec3f vector, ModelRotation rotation)
void
transformVertex(Vec3f vertex, AffineTransformation transformation)
private void
transformVertex(Vec3f vertex, Vec3f origin, Matrix4f transformationMatrix, Vec3f scale)
static ModelElementTexture
uvLock(ModelElementTexture texture, Direction orientation, AffineTransformation rotation, Identifier modelId)
-
Field Details
-
MIN_SCALE
private static final float MIN_SCALE -
MAX_SCALE
private static final float MAX_SCALE
-
-
Constructor Details
-
BakedQuadFactory
public BakedQuadFactory()
-
-
Method Details
-
bake
public BakedQuad bake(Vec3f from, Vec3f to, ModelElementFace face, Sprite texture, Direction side, ModelBakeSettings settings, @Nullable ModelRotation rotation, boolean shade, Identifier modelId) -
uvLock
public static ModelElementTexture uvLock(ModelElementTexture texture, Direction orientation, AffineTransformation rotation, Identifier modelId) -
packVertexData
private int[] packVertexData(ModelElementTexture texture, Sprite sprite, Direction direction, float[] positionMatrix, AffineTransformation orientation, @Nullable ModelRotation rotation, boolean shaded) -
getPositionMatrix
-
packVertexData
private void packVertexData(int[] vertices, int cornerIndex, Direction direction, ModelElementTexture texture, float[] positionMatrix, Sprite sprite, AffineTransformation orientation, @Nullable ModelRotation rotation, boolean shaded) -
packVertexData
private void packVertexData(int[] vertices, int cornerIndex, Vec3f position, Sprite sprite, ModelElementTexture modelElementTexture) -
rotateVertex
-
transformVertex
-
transformVertex
-
decodeDirection
-
encodeDirection
-