Class ModelBlockRenderer.AmbientOcclusionFace
java.lang.Object
net.minecraft.client.renderer.block.ModelBlockRenderer.AmbientOcclusionFace
- Enclosing class:
ModelBlockRenderer
-
Field Summary
FieldsModifier and TypeFieldDescription(package private) final float[]
(package private) final int[]
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate int
blend
(int lightColor0, int lightColor1, int lightColor2, int lightColor3) private int
blend
(int brightness0, int brightness1, int brightness2, int brightness3, float weight0, float weight1, float weight2, float weight3) void
calculate
(BlockAndTintGetter level, BlockState state, BlockPos pos, Direction direction, float[] shape, BitSet shapeFlags, boolean shade)
-
Field Details
-
brightness
final float[] brightness -
lightmap
final int[] lightmap
-
-
Constructor Details
-
AmbientOcclusionFace
public AmbientOcclusionFace()
-
-
Method Details
-
calculate
public void calculate(BlockAndTintGetter level, BlockState state, BlockPos pos, Direction direction, float[] shape, BitSet shapeFlags, boolean shade) - Parameters:
shape
- the array, of length 12, containing the shape boundsshapeFlags
- the bit set to store the shape flags in. The first bit will betrue
if the face should be offset, and the second if the face is less than a block in width and height.
-
blend
private int blend(int lightColor0, int lightColor1, int lightColor2, int lightColor3) - Returns:
- the ambient occlusion light color
-
blend
private int blend(int brightness0, int brightness1, int brightness2, int brightness3, float weight0, float weight1, float weight2, float weight3)
-