FileDocCategorySizeDatePackage
Texture_Info.javaAPI DocExample1897Fri Dec 10 13:25:42 GMT 1999com.tornadolabs.j3dtree

Texture_Info.java

/*
//*****************************************************************************
/*
*	@(#) Texture_Info.java
*
*	Project:		Java3dTree
*	Client:		Java 3D Community
*
*	Project Information:
*		dselman@tornadolabs.com
*		http://www.tornadolabs.com
*	
*	@author Daniel Selman: dselman@tornadolabs.com
*/
//*****************************************************************************

package com.tornadolabs.j3dtree;
import javax.media.j3d.*;
import javax.vecmath.Color4f;

public class Texture_Info extends ObjectInfo
{

	private static final int[] 		m_kCapabilityArray = 
												{
													Texture.ALLOW_BOUNDARY_COLOR_READ,
													Texture.ALLOW_BOUNDARY_MODE_READ,
													Texture.ALLOW_ENABLE_READ,
													Texture.ALLOW_FILTER_READ,
													Texture.ALLOW_IMAGE_READ,
													Texture.ALLOW_MIPMAP_MODE_READ
												};

	public Texture_Info()
	{
	}
	
	java.util.Enumeration getChildren( Object obj )
	{
		return super.getChildren( obj );
	}
	
	public int[] getCapabilityBits()
	{
		return createCompoundArray( m_kCapabilityArray, super.getCapabilityBits() );
	}
	
	public String getInfo( Object obj )
	{
		String szText = super.getInfo( obj );

		szText = insertSectionBreak( szText );
		szText += "Texture\r\n";
		
		Texture texture = (Texture) obj;
		
		Color4f color = new Color4f();
		texture.getBoundaryColor( color );
				
		szText += "Boundary Color: " + color + "\r\n";
		szText += "Boundary Mode S: " + texture.getBoundaryModeS() + "\r\n";
		szText += "Boundary Mode T: " + texture.getBoundaryModeT() + "\r\n";
		szText += "Enable: " + texture.getEnable() + "\r\n";
		szText += "Mag Filter: " + texture.getMagFilter() + "\r\n";
		szText += "Min Filter: " + texture.getMinFilter() + "\r\n";
		szText += "MipMap Mode: " + texture.getMipMapMode() + "\r\n";
		
		return szText;
	}
}