Class StbImageLoader

java.lang.Object
com.jme3.texture.plugins.StbImageLoader
All Implemented Interfaces:
com.jme3.asset.AssetLoader

public class StbImageLoader extends Object implements com.jme3.asset.AssetLoader
  • Constructor Details

    • StbImageLoader

      public StbImageLoader()
  • Method Details

    • load

      public com.jme3.texture.Image load(InputStream in, boolean flipY) throws IOException
      Loads an image from an InputStream with optional vertical flip.
      Parameters:
      in - the input stream containing the encoded image data (e.g. PNG, JPEG)
      flipY - true to flip the image vertically on load
      Returns:
      the decoded Image
      Throws:
      IOException - if the stream cannot be read or the image format is unsupported
    • load

      public com.jme3.texture.Image load(byte[] data, boolean flipY) throws IOException
      Loads an image from a byte array with optional vertical flip.
      Parameters:
      data - the raw encoded image data (e.g. PNG, JPEG)
      flipY - true to flip the image vertically on load
      Returns:
      the decoded Image
      Throws:
      IOException - if the image data cannot be decoded or the format is unsupported
    • load

      public Object load(com.jme3.asset.AssetInfo assetInfo) throws IOException
      Specified by:
      load in interface com.jme3.asset.AssetLoader
      Throws:
      IOException