Class TextureUtil

java.lang.Object
com.mojang.blaze3d.platform.TextureUtil

@Environment(CLIENT) public class TextureUtil extends Object
Mappings:
Namespace Name
named com/mojang/blaze3d/platform/TextureUtil
intermediary com/mojang/blaze3d/platform/TextureUtil
official com/mojang/blaze3d/platform/TextureUtil
  • Field Details

    • LOGGER

      private static final Logger LOGGER
    • MIN_MIPMAP_LEVEL

      public static final int MIN_MIPMAP_LEVEL
      See Also:
    • DEFAULT_IMAGE_BUFFER_SIZE

      private static final int DEFAULT_IMAGE_BUFFER_SIZE
      See Also:
  • Constructor Details

    • TextureUtil

      public TextureUtil()
  • Method Details

    • readResource

      public static ByteBuffer readResource(InputStream inputStream) throws IOException
      Throws:
      IOException
      Mappings:
      Namespace Name Mixin selector
      named readResource Lcom/mojang/blaze3d/platform/TextureUtil;readResource(Ljava/io/InputStream;)Ljava/nio/ByteBuffer;
      intermediary readResource Lcom/mojang/blaze3d/platform/TextureUtil;readResource(Ljava/io/InputStream;)Ljava/nio/ByteBuffer;
      official readResource Lcom/mojang/blaze3d/platform/TextureUtil;readResource(Ljava/io/InputStream;)Ljava/nio/ByteBuffer;
    • readResource

      private static ByteBuffer readResource(ReadableByteChannel channel, int bufSize) throws IOException
      Throws:
      IOException
      Mappings:
      Namespace Name Mixin selector
      named readResource Lcom/mojang/blaze3d/platform/TextureUtil;readResource(Ljava/nio/channels/ReadableByteChannel;I)Ljava/nio/ByteBuffer;
      intermediary readResource Lcom/mojang/blaze3d/platform/TextureUtil;readResource(Ljava/nio/channels/ReadableByteChannel;I)Ljava/nio/ByteBuffer;
      official readResource Lcom/mojang/blaze3d/platform/TextureUtil;readResource(Ljava/nio/channels/ReadableByteChannel;I)Ljava/nio/ByteBuffer;
    • writeAsPNG

      public static void writeAsPNG(Path directory, String prefix, GpuTexture texture, int scales, IntUnaryOperator colorFunction)
      Mappings:
      Namespace Name Mixin selector
      named writeAsPNG Lcom/mojang/blaze3d/platform/TextureUtil;writeAsPNG(Ljava/nio/file/Path;Ljava/lang/String;Lcom/mojang/blaze3d/textures/GpuTexture;ILjava/util/function/IntUnaryOperator;)V
      intermediary writeAsPNG Lcom/mojang/blaze3d/platform/TextureUtil;writeAsPNG(Ljava/nio/file/Path;Ljava/lang/String;Lcom/mojang/blaze3d/textures/GpuTexture;ILjava/util/function/IntUnaryOperator;)V
      official writeAsPNG Lcom/mojang/blaze3d/platform/TextureUtil;writeAsPNG(Ljava/nio/file/Path;Ljava/lang/String;Lcom/mojang/blaze3d/textures/GpuTexture;ILjava/util/function/IntUnaryOperator;)V
    • getDebugTexturePath

      public static Path getDebugTexturePath(Path path)
      Mappings:
      Namespace Name Mixin selector
      named getDebugTexturePath Lcom/mojang/blaze3d/platform/TextureUtil;getDebugTexturePath(Ljava/nio/file/Path;)Ljava/nio/file/Path;
      intermediary getDebugTexturePath Lcom/mojang/blaze3d/platform/TextureUtil;getDebugTexturePath(Ljava/nio/file/Path;)Ljava/nio/file/Path;
      official getDebugTexturePath Lcom/mojang/blaze3d/platform/TextureUtil;getDebugTexturePath(Ljava/nio/file/Path;)Ljava/nio/file/Path;
    • getDebugTexturePath

      public static Path getDebugTexturePath()