Class StbImageLoader
java.lang.Object
com.jme3.texture.plugins.StbImageLoader
- All Implemented Interfaces:
com.jme3.asset.AssetLoader
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncom.jme3.texture.Imageload(byte[] data, boolean flipY) Loads an image from a byte array with optional vertical flip.load(com.jme3.asset.AssetInfo assetInfo) com.jme3.texture.Imageload(InputStream in, boolean flipY) Loads an image from anInputStreamwith optional vertical flip.
-
Constructor Details
-
StbImageLoader
public StbImageLoader()
-
-
Method Details
-
load
Loads an image from anInputStreamwith optional vertical flip.- Parameters:
in- the input stream containing the encoded image data (e.g. PNG, JPEG)flipY-trueto 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
Loads an image from a byte array with optional vertical flip.- Parameters:
data- the raw encoded image data (e.g. PNG, JPEG)flipY-trueto 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
- Specified by:
loadin interfacecom.jme3.asset.AssetLoader- Throws:
IOException
-