Class TextureAtlas
java.lang.Object
net.minecraft.client.renderer.texture.AbstractTexture
net.minecraft.client.renderer.texture.TextureAtlas
- All Implemented Interfaces:
AutoCloseable, Dumpable, TickableTexture
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate List<SpriteContents.AnimationState> private intprivate final Identifierstatic final IdentifierDeprecated.static final IdentifierDeprecated.static final IdentifierDeprecated.private static final org.slf4j.Loggerprivate intprivate final intprivate intprivate GpuTextureView[]private @Nullable TextureAtlasSpriteprivate List<TextureAtlasSprite> private @Nullable GpuBufferprivate Map<Identifier, TextureAtlasSprite> private intFields inherited from class AbstractTexture
sampler, texture, textureView -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidclose()private voidcreateTexture(int newWidth, int newHeight, int newMipLevel) voidvoiddumpContents(Identifier selfId, Path dir) private static voiddumpSpriteNames(Path dir, String outputId, Map<Identifier, TextureAtlasSprite> regions) (package private) intgetSprite(Identifier location) (package private) intgetWidth()location()intvoidtick()voidupload(SpriteLoader.Preparations preparations) private voidprivate voidMethods inherited from class AbstractTexture
getSampler, getTexture, getTextureView
-
Field Details
-
LOGGER
private static final org.slf4j.Logger LOGGER -
LOCATION_BLOCKS
Deprecated. -
LOCATION_ITEMS
Deprecated. -
LOCATION_PARTICLES
Deprecated. -
sprites
-
animatedTexturesStates
-
texturesByName
-
missingSprite
-
location
-
maxSupportedTextureSize
private final int maxSupportedTextureSize -
width
private int width -
height
private int height -
maxMipLevel
private int maxMipLevel -
mipLevelCount
private int mipLevelCount -
mipViews
-
spriteUbos
-
-
Constructor Details
-
TextureAtlas
-
-
Method Details
-
createTexture
private void createTexture(int newWidth, int newHeight, int newMipLevel) -
upload
-
uploadInitialContents
private void uploadInitialContents() -
dumpContents
- Specified by:
dumpContentsin interfaceDumpable- Throws:
IOException
-
dumpSpriteNames
private static void dumpSpriteNames(Path dir, String outputId, Map<Identifier, TextureAtlasSprite> regions) -
cycleAnimationFrames
public void cycleAnimationFrames() -
uploadAnimationFrames
private void uploadAnimationFrames() -
tick
public void tick()- Specified by:
tickin interfaceTickableTexture
-
getSprite
-
missingSprite
-
clearTextureData
public void clearTextureData() -
close
public void close()- Specified by:
closein interfaceAutoCloseable- Overrides:
closein classAbstractTexture
-
location
-
maxSupportedTextureSize
public int maxSupportedTextureSize() -
getWidth
int getWidth() -
getHeight
int getHeight() -
getTextures
-