Class TextureUtil

java.lang.Object
net.minecraft.client.texture.TextureUtil

@Environment(CLIENT)
public class TextureUtil
extends Object
  • Field Details

    • LOGGER

      private static final Logger LOGGER
  • Constructor Details

    • TextureUtil

      public TextureUtil()
  • Method Details

    • generateId

      public static int generateId()
    • deleteId

      public static void deleteId​(int id)
    • allocate

      public static void allocate​(int id, int width, int height)
    • allocate

      public static void allocate​(NativeImage.GLFormat internalFormat, int id, int width, int height)
    • allocate

      public static void allocate​(int id, int maxLevel, int width, int height)
    • allocate

      public static void allocate​(NativeImage.GLFormat internalFormat, int id, int maxLevel, int width, int height)
      Allocate uninitialized backing memory for maxLevel+1 mip levels to texture id.
    • bind

      private static void bind​(int id)
    • readAllToByteBuffer

      public static ByteBuffer readAllToByteBuffer​(InputStream inputStream) throws IOException
      Throws:
      IOException
    • readAllToString

      public static String readAllToString​(InputStream inputStream)
    • uploadImage

      public static void uploadImage​(IntBuffer imageData, int width, int height)
      Uploads imageData to the bound texture. Each integer is interpreted as 0xAARRGGBB.