Class B3DModel.Parser
- java.lang.Object
-
- net.minecraftforge.client.model.b3d.B3DModel.Parser
-
- Enclosing class:
- B3DModel
public static class B3DModel.Parser extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description private java.util.Deque<com.google.common.collect.Table<java.lang.Integer,java.util.Optional<B3DModel.Node<?>>,B3DModel.Key>>animationsprivate java.util.List<B3DModel.Brush>brushesprivate java.nio.ByteBufferbufprivate java.lang.Stringdumpprivate intlengthprivate java.util.Deque<java.lang.Integer>limitStackprivate com.google.common.collect.ImmutableMap.Builder<java.lang.String,B3DModel.Node<B3DModel.Mesh>>meshesprivate B3DModelresprivate byte[]tagprivate java.util.List<B3DModel.Texture>texturesprivate static intversionprivate java.util.List<B3DModel.Vertex>vertices
-
Constructor Summary
Constructors Constructor Description Parser(java.io.InputStream in)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private org.apache.commons.lang3.tuple.Triple<java.lang.Integer,java.lang.Integer,java.lang.Float>anim()private B3DModelbb3d()private java.util.List<org.apache.commons.lang3.tuple.Pair<B3DModel.Vertex,java.lang.Float>>bone()private java.util.List<B3DModel.Brush>brus()private voidchunk(java.lang.String tag)private voiddump(java.lang.String str)private B3DModel.BrushgetBrush(int brush)private B3DModel.TexturegetTexture(int texture)private B3DModel.VertexgetVertex(int vertex)private booleanisChunk(java.lang.String tag)private java.util.Map<java.lang.Integer,B3DModel.Key>keys()private org.apache.commons.lang3.tuple.Pair<B3DModel.Brush,java.util.List<B3DModel.Face>>mesh()private B3DModel.Node<?>node()B3DModelparse()private voidpopLimit()private voidpushLimit()private voidreadHeader()private QuaternionreadQuat()private java.lang.StringreadString()private voidskip()private java.util.List<B3DModel.Texture>texs()private java.util.List<B3DModel.Face>tris()private java.util.List<B3DModel.Vertex>vrts()
-
-
-
Field Detail
-
version
private static final int version
- See Also:
- Constant Field Values
-
buf
private final java.nio.ByteBuffer buf
-
tag
private byte[] tag
-
length
private int length
-
dump
private java.lang.String dump
-
res
private B3DModel res
-
textures
private final java.util.List<B3DModel.Texture> textures
-
brushes
private final java.util.List<B3DModel.Brush> brushes
-
vertices
private final java.util.List<B3DModel.Vertex> vertices
-
meshes
private final com.google.common.collect.ImmutableMap.Builder<java.lang.String,B3DModel.Node<B3DModel.Mesh>> meshes
-
limitStack
private java.util.Deque<java.lang.Integer> limitStack
-
animations
private final java.util.Deque<com.google.common.collect.Table<java.lang.Integer,java.util.Optional<B3DModel.Node<?>>,B3DModel.Key>> animations
-
-
Method Detail
-
dump
private void dump(java.lang.String str)
-
parse
public B3DModel parse() throws java.io.IOException
- Throws:
java.io.IOException
-
getTexture
private B3DModel.Texture getTexture(int texture)
-
getBrush
@Nullable private B3DModel.Brush getBrush(int brush) throws java.io.IOException
- Throws:
java.io.IOException
-
getVertex
private B3DModel.Vertex getVertex(int vertex) throws java.io.IOException
- Throws:
java.io.IOException
-
readHeader
private void readHeader() throws java.io.IOException- Throws:
java.io.IOException
-
isChunk
private boolean isChunk(java.lang.String tag) throws java.io.IOException- Throws:
java.io.IOException
-
chunk
private void chunk(java.lang.String tag) throws java.io.IOException- Throws:
java.io.IOException
-
readString
private java.lang.String readString() throws java.io.IOException- Throws:
java.io.IOException
-
pushLimit
private void pushLimit()
-
popLimit
private void popLimit()
-
bb3d
private B3DModel bb3d() throws java.io.IOException
- Throws:
java.io.IOException
-
texs
private java.util.List<B3DModel.Texture> texs() throws java.io.IOException
- Throws:
java.io.IOException
-
brus
private java.util.List<B3DModel.Brush> brus() throws java.io.IOException
- Throws:
java.io.IOException
-
vrts
private java.util.List<B3DModel.Vertex> vrts() throws java.io.IOException
- Throws:
java.io.IOException
-
tris
private java.util.List<B3DModel.Face> tris() throws java.io.IOException
- Throws:
java.io.IOException
-
mesh
private org.apache.commons.lang3.tuple.Pair<B3DModel.Brush,java.util.List<B3DModel.Face>> mesh() throws java.io.IOException
- Throws:
java.io.IOException
-
bone
private java.util.List<org.apache.commons.lang3.tuple.Pair<B3DModel.Vertex,java.lang.Float>> bone() throws java.io.IOException
- Throws:
java.io.IOException
-
keys
private java.util.Map<java.lang.Integer,B3DModel.Key> keys() throws java.io.IOException
- Throws:
java.io.IOException
-
anim
private org.apache.commons.lang3.tuple.Triple<java.lang.Integer,java.lang.Integer,java.lang.Float> anim() throws java.io.IOException- Throws:
java.io.IOException
-
node
private B3DModel.Node<?> node() throws java.io.IOException
- Throws:
java.io.IOException
-
readQuat
private Quaternion readQuat()
-
skip
private void skip()
-
-