Class DynamicCubemapTexture
java.lang.Object
net.minecraft.client.renderer.texture.AbstractTexture
foundry.veil.api.client.render.texture.CubemapTexture
foundry.veil.api.client.render.texture.DynamicCubemapTexture
- All Implemented Interfaces:
AutoCloseable
Dynamic implementation of
CubemapTexture. Must call init(int, int) before it can be used.-
Field Summary
Fields inherited from class net.minecraft.client.renderer.texture.AbstractTexture
blur, id, mipmap, NOT_ASSIGNED -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidinit(int width, int height) Initializes each face to the same size white texture.voidload(net.minecraft.server.packs.resources.ResourceManager resourceManager) voidupload(int face, com.mojang.blaze3d.platform.NativeImage image) Uploads the specified image to the specified face.voidupload(com.mojang.blaze3d.platform.NativeImage image) Uploads the same image to all faces of the cubemap.voidupload(net.minecraft.core.Direction face, com.mojang.blaze3d.platform.NativeImage image) Uploads the specified image to the specified face.Methods inherited from class foundry.veil.api.client.render.texture.CubemapTexture
bind, getGlFace, getId, setFilterMethods inherited from class net.minecraft.client.renderer.texture.AbstractTexture
close, releaseId, reset
-
Constructor Details
-
DynamicCubemapTexture
public DynamicCubemapTexture()
-
-
Method Details
-
init
public void init(int width, int height) Initializes each face to the same size white texture.- Parameters:
width- The width of each faceheight- The height of each face
-
upload
public void upload(com.mojang.blaze3d.platform.NativeImage image) Uploads the same image to all faces of the cubemap.- Parameters:
image- The image to upload
-
upload
public void upload(net.minecraft.core.Direction face, com.mojang.blaze3d.platform.NativeImage image) Uploads the specified image to the specified face.- Parameters:
face- The face to upload toimage- The image to upload
-
upload
public void upload(int face, com.mojang.blaze3d.platform.NativeImage image) Uploads the specified image to the specified face.- Parameters:
face- The face to upload toimage- The image to upload
-
load
public void load(net.minecraft.server.packs.resources.ResourceManager resourceManager) throws IOException - Specified by:
loadin classnet.minecraft.client.renderer.texture.AbstractTexture- Throws:
IOException
-