Class ObjGeometry
java.lang.Object
net.neoforged.neoforge.client.model.obj.ObjGeometry
- All Implemented Interfaces:
UnbakedGeometry,UnbakedGeometryExtension,ExtendedUnbakedGeometry
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionclassprivate classclassstatic final record -
Field Summary
FieldsModifier and TypeFieldDescriptionfinal booleanprivate static final Vector4fprivate static final Vec2[]final booleanfinal booleanfinal ResourceLocationfinal @Nullable Stringprivate final Multimap<String, ObjGeometry.ModelGroup> final booleanFields inherited from interface net.minecraft.client.resources.model.UnbakedGeometry
EMPTY -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbake(TextureSlots textureSlots, ModelBaker baker, ModelState state, ModelDebugName debugName, ContextMap additionalProperties) Version ofUnbakedGeometry.bake(TextureSlots, ModelBaker, ModelState, ModelDebugName)that also receives additional properties sourced fromUnbakedModelExtension.fillAdditionalProperties(net.minecraft.util.context.ContextMap.Builder).makeQuad(int[][] indices, int tintIndex, Vector4f colorTint, Vector4f ambientColor, TextureAtlasSprite texture, Transformation transform) static ObjGeometryparse(ObjTokenizer tokenizer, ObjGeometry.Settings settings) private static Vec2parseVector2(String[] line) private static Vector3fparseVector3(String[] line) (package private) static Vector4fparseVector4(String[] line) private static Vector3fparseVector4To3(String[] line) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.neoforged.neoforge.client.model.ExtendedUnbakedGeometry
bake
-
Field Details
-
COLOR_WHITE
-
DEFAULT_COORDS
-
parts
-
positions
-
texCoords
-
normals
-
colors
-
automaticCulling
public final boolean automaticCulling -
shadeQuads
public final boolean shadeQuads -
flipV
public final boolean flipV -
emissiveAmbient
public final boolean emissiveAmbient -
mtlOverride
-
modelLocation
-
-
Constructor Details
-
ObjGeometry
-
-
Method Details
-
parse
public static ObjGeometry parse(ObjTokenizer tokenizer, ObjGeometry.Settings settings) throws IOException - Throws:
IOException
-
parseVector4To3
-
parseVector2
-
parseVector3
-
parseVector4
-
bake
public QuadCollection bake(TextureSlots textureSlots, ModelBaker baker, ModelState state, ModelDebugName debugName, ContextMap additionalProperties) Description copied from interface:UnbakedGeometryExtensionVersion ofUnbakedGeometry.bake(TextureSlots, ModelBaker, ModelState, ModelDebugName)that also receives additional properties sourced fromUnbakedModelExtension.fillAdditionalProperties(net.minecraft.util.context.ContextMap.Builder).- Specified by:
bakein interfaceExtendedUnbakedGeometry- Specified by:
bakein interfaceUnbakedGeometryExtension
-
makeQuad
private org.apache.commons.lang3.tuple.Pair<BakedQuad,Direction> makeQuad(int[][] indices, int tintIndex, Vector4f colorTint, Vector4f ambientColor, TextureAtlasSprite texture, Transformation transform)
-