com.jme3.texture.plugins
Class TGALoader

java.lang.Object
  extended by com.jme3.texture.plugins.TGALoader
All Implemented Interfaces:
AssetLoader

public final class TGALoader
extends java.lang.Object
implements AssetLoader

TextureManager provides static methods for building a Texture object. Typically, the information supplied is the filename and the texture properties.


Field Summary
static int TYPE_BLACKANDWHITE
           
static int TYPE_BLACKANDWHITE_RLE
           
static int TYPE_COLORMAPPED
           
static int TYPE_COLORMAPPED_RLE
           
static int TYPE_NO_IMAGE
           
static int TYPE_TRUECOLOR
           
static int TYPE_TRUECOLOR_RLE
           
 
Constructor Summary
TGALoader()
           
 
Method Summary
 java.lang.Object load(AssetInfo info)
          Loads asset from the given input stream, parsing it into an application-usable object.
static Image load(java.io.InputStream in, boolean flip)
          loadImage is a manual image loader which is entirely independent of AWT.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TYPE_NO_IMAGE

public static final int TYPE_NO_IMAGE
See Also:
Constant Field Values

TYPE_COLORMAPPED

public static final int TYPE_COLORMAPPED
See Also:
Constant Field Values

TYPE_TRUECOLOR

public static final int TYPE_TRUECOLOR
See Also:
Constant Field Values

TYPE_BLACKANDWHITE

public static final int TYPE_BLACKANDWHITE
See Also:
Constant Field Values

TYPE_COLORMAPPED_RLE

public static final int TYPE_COLORMAPPED_RLE
See Also:
Constant Field Values

TYPE_TRUECOLOR_RLE

public static final int TYPE_TRUECOLOR_RLE
See Also:
Constant Field Values

TYPE_BLACKANDWHITE_RLE

public static final int TYPE_BLACKANDWHITE_RLE
See Also:
Constant Field Values
Constructor Detail

TGALoader

public TGALoader()
Method Detail

load

public java.lang.Object load(AssetInfo info)
                      throws java.io.IOException
Description copied from interface: AssetLoader
Loads asset from the given input stream, parsing it into an application-usable object.

Specified by:
load in interface AssetLoader
Returns:
An object representing the resource.
Throws:
java.io.IOException - If an I/O error occurs while loading

load

public static Image load(java.io.InputStream in,
                         boolean flip)
                  throws java.io.IOException
loadImage is a manual image loader which is entirely independent of AWT. OUT: RGB888 or RGBA8888 Image object

Parameters:
in - InputStream of an uncompressed 24b RGB or 32b RGBA TGA
flip - Flip the image vertically
Returns:
Image object that contains the image, either as a RGB888 or RGBA8888
Throws:
java.io.IOException