@Override
    public Object load(AssetInfo info) throws IOException {
        if (!(info.getKey() instanceof TextureKey)) {
            throw new IllegalArgumentException("Texture assets must be loaded using a TextureKey");
        }

        TextureKey textureKey = (TextureKey) info.getKey();
        try (InputStream stream = info.openStream()) {
            in = new LittleEndien(stream);
            loadHeader();
            if (texture3D) {
                textureKey.setTextureTypeHint(Texture.Type.ThreeDimensional);
            } else if (depth > 1) {
                textureKey.setTextureTypeHint(Texture.Type.CubeMap);
            }
            ArrayList<ByteBuffer> data = readData(textureKey.isFlipY());
            return new Image(pixelFormat, width, height, depth, data, sizes, ColorSpace.sRGB);
        }
    }
<code>DDSLoader</code> is an image loader that reads in a DirectX DDS file.
Supports DXT1, DXT3, DXT5, RGB, RGBA, Grayscale, Alpha pixel formats.
2D images, mipmapped 2D images, and cubemaps.

@author Gareth Jenkins-Jones
@author Kirill Vainer
@version $Id: DDSLoader.java,v 2.0 2008/8/15
jme3-core/src/plugins/java/com/jme3/texture/plugins/DDSLoader.java