public static boolean supports(Collection<Caps> caps, Texture tex) {
        if (tex.getType() == Texture.Type.TwoDimensionalArray
                && !caps.contains(Caps.TextureArray)) {
            return false;
        }

        Image img = tex.getImage();
        if (img == null) {
            return true;
        }

        Format fmt = img.getFormat();
        switch (fmt) {
            case Depth24Stencil8:
                return caps.contains(Caps.PackedDepthStencilBuffer);
            case Depth32F:
                return caps.contains(Caps.FloatDepthBuffer);
            case RGB16F_to_RGB111110F:
            case RGB111110F:
                return caps.contains(Caps.PackedFloatTexture);
            case RGB16F_to_RGB9E5:
            case RGB9E5:
                return caps.contains(Caps.SharedExponentTexture);
            default:
                if (fmt.isFloatingPont()) {
                    return caps.contains(Caps.FloatTexture);
                }

                return true;
        }
    }
Returns true if given the renderer capabilities, the texture
can be supported by the renderer.

<p>This only checks the format of the texture, non-power-of-2
textures are scaled automatically inside the renderer
if are not supported natively.

@param caps The collection of renderer capabilities {@link Renderer#getCaps() }.
@param tex The texture to check
@return True if it is supported, false otherwise.
jme3-core/src/main/java/com/jme3/renderer/Caps.java