Record Class ColoringVertexConsumer
java.lang.Object
java.lang.Record
net.createmod.catnip.impl.client.render.ColoringVertexConsumer
- All Implemented Interfaces:
com.mojang.blaze3d.vertex.VertexConsumer,net.neoforged.neoforge.client.extensions.IVertexConsumerExtension
public record ColoringVertexConsumer(com.mojang.blaze3d.vertex.VertexConsumer delegate, float red, float green, float blue, float alpha)
extends Record
implements com.mojang.blaze3d.vertex.VertexConsumer
-
Constructor Summary
ConstructorsConstructorDescriptionColoringVertexConsumer(com.mojang.blaze3d.vertex.VertexConsumer delegate, float red, float green, float blue, float alpha) Creates an instance of aColoringVertexConsumerrecord class. -
Method Summary
Modifier and TypeMethodDescriptioncom.mojang.blaze3d.vertex.VertexConsumeraddVertex(float x, float y, float z) floatalpha()Returns the value of thealpharecord component.floatblue()Returns the value of thebluerecord component.com.mojang.blaze3d.vertex.VertexConsumerdelegate()Returns the value of thedelegaterecord component.final booleanIndicates whether some other object is "equal to" this one.floatgreen()Returns the value of thegreenrecord component.final inthashCode()Returns a hash code value for this object.floatred()Returns the value of theredrecord component.com.mojang.blaze3d.vertex.VertexConsumersetColor(int r, int g, int b, int a) com.mojang.blaze3d.vertex.VertexConsumersetNormal(float x, float y, float z) com.mojang.blaze3d.vertex.VertexConsumersetUv(float u, float v) com.mojang.blaze3d.vertex.VertexConsumersetUv1(int u, int v) com.mojang.blaze3d.vertex.VertexConsumersetUv2(int u, int v) final StringtoString()Returns a string representation of this record class.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface net.neoforged.neoforge.client.extensions.IVertexConsumerExtension
applyBakedLighting, applyBakedNormals, misc, putBulkDataMethods inherited from interface com.mojang.blaze3d.vertex.VertexConsumer
addVertex, addVertex, addVertex, addVertex, addVertex, putBulkData, putBulkData, setColor, setColor, setLight, setNormal, setOverlay, setWhiteAlpha
-
Constructor Details
-
ColoringVertexConsumer
public ColoringVertexConsumer(com.mojang.blaze3d.vertex.VertexConsumer delegate, float red, float green, float blue, float alpha) Creates an instance of aColoringVertexConsumerrecord class.- Parameters:
delegate- the value for thedelegaterecord componentred- the value for theredrecord componentgreen- the value for thegreenrecord componentblue- the value for thebluerecord componentalpha- the value for thealpharecord component
-
-
Method Details
-
addVertex
public com.mojang.blaze3d.vertex.VertexConsumer addVertex(float x, float y, float z) - Specified by:
addVertexin interfacecom.mojang.blaze3d.vertex.VertexConsumer
-
setColor
public com.mojang.blaze3d.vertex.VertexConsumer setColor(int r, int g, int b, int a) - Specified by:
setColorin interfacecom.mojang.blaze3d.vertex.VertexConsumer
-
setUv
public com.mojang.blaze3d.vertex.VertexConsumer setUv(float u, float v) - Specified by:
setUvin interfacecom.mojang.blaze3d.vertex.VertexConsumer
-
setUv1
public com.mojang.blaze3d.vertex.VertexConsumer setUv1(int u, int v) - Specified by:
setUv1in interfacecom.mojang.blaze3d.vertex.VertexConsumer
-
setUv2
public com.mojang.blaze3d.vertex.VertexConsumer setUv2(int u, int v) - Specified by:
setUv2in interfacecom.mojang.blaze3d.vertex.VertexConsumer
-
setNormal
public com.mojang.blaze3d.vertex.VertexConsumer setNormal(float x, float y, float z) - Specified by:
setNormalin interfacecom.mojang.blaze3d.vertex.VertexConsumer
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
delegate
public com.mojang.blaze3d.vertex.VertexConsumer delegate()Returns the value of thedelegaterecord component.- Returns:
- the value of the
delegaterecord component
-
red
public float red()Returns the value of theredrecord component.- Returns:
- the value of the
redrecord component
-
green
public float green()Returns the value of thegreenrecord component.- Returns:
- the value of the
greenrecord component
-
blue
public float blue()Returns the value of thebluerecord component.- Returns:
- the value of the
bluerecord component
-
alpha
public float alpha()Returns the value of thealpharecord component.- Returns:
- the value of the
alpharecord component
-