MeshDefinition .java

net.minecraft.client.model.geom.builders.MeshDefinition (class, 33 lines): members: transformed, getRoot, root, apply. imports: PartPose.

net.minecraft.client.model.geom.buildersclass33 linesclient834 B

API Surface (3)

PartDefinition getRoot()
MeshDefinition transformed(final UnaryOperator<PartPose> function)
MeshDefinition apply(final MeshTransformer transformer)

Fields & Constants (1)

root

Code Graph: Dependencies (3)

Edges (calls / imports / inherits / references) resolved by graphify from the AST. Every chip opens the class source.

Full Source

MeshDefinition.java33 lines · Minecraft 26.3 · verbatim
1
package net.minecraft.client.model.geom.builders;
2
3
import com.google.common.collect.ImmutableList;
4
import java.util.function.UnaryOperator;
5
import net.fabricmc.api.EnvType;
6
import net.fabricmc.api.Environment;
7
import net.minecraft.client.model.geom.PartPose;
8
9
@Environment(EnvType.CLIENT)
10
public class MeshDefinition {
11
	private final PartDefinition root;
12
13
	public MeshDefinition() {
14
		this(new PartDefinition(ImmutableList.of(), PartPose.ZERO));
15
	}
16
17
	private MeshDefinition(final PartDefinition root) {
18
		this.root = root;
19
	}
20
21
	public PartDefinition getRoot() {
22
		return this.root;
23
	}
24
25
	public MeshDefinition transformed(final UnaryOperator<PartPose> function) {
26
		return new MeshDefinition(this.root.transformed(function));
27
	}
28
29
	public MeshDefinition apply(final MeshTransformer transformer) {
30
		return transformer.apply(this);
31
	}
32
}
33

Decompiled Minecraft 26.3 source of MeshDefinition (net/minecraft/client/model/geom/builders/MeshDefinition.java) with Mojang official mappings, stored verbatim on the site.