##################################################################

Appearance3DChooser v1.1

Copyright (C) 2009 Frederic Roudaut


This program is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
General Public License for more details.

###################################################################

com.appearance3Dchooser
Class Appearance3DChooser

java.lang.Object
  extended by java.awt.Component
      extended by java.awt.Container
          extended by java.awt.Window
              extended by java.awt.Frame
                  extended by javax.swing.JFrame
                      extended by com.appearance3Dchooser.Appearance3DChooser
All Implemented Interfaces:
java.awt.event.ActionListener, java.awt.event.WindowListener, java.awt.image.ImageObserver, java.awt.MenuContainer, java.io.Serializable, java.util.EventListener, javax.accessibility.Accessible, javax.swing.RootPaneContainer, javax.swing.WindowConstants

public class Appearance3DChooser
extends javax.swing.JFrame
implements java.awt.event.ActionListener, java.awt.event.WindowListener

Appearance3DChooser Class.
This is perhaps the Class you want to use for updating your objects appearances. It includes :


An instance of this object fire a Property Event when a dedicated parameter is modified. If Cancel is clicked, all parameters are reseted and associated Property Events are also fired. It distinguishes the following events :

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class javax.swing.JFrame
javax.swing.JFrame.AccessibleJFrame
 
Nested classes/interfaces inherited from class java.awt.Frame
java.awt.Frame.AccessibleAWTFrame
 
Nested classes/interfaces inherited from class java.awt.Window
java.awt.Window.AccessibleAWTWindow
 
Nested classes/interfaces inherited from class java.awt.Container
java.awt.Container.AccessibleAWTContainer
 
Nested classes/interfaces inherited from class java.awt.Component
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BaselineResizeBehavior, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy
 
Field Summary
protected  javax.swing.JMenuItem aboutMenuItem
           
static java.lang.String AMBIENT
           
protected  float[] ambientColor
           
protected  float[] ambientColorInit
           
private  Appearance3DChooserPanel appearance3DPan
           
protected  java.beans.PropertyChangeSupport boundSupport
           
protected  javax.swing.JButton cancel
           
protected  int colorTarget
           
static java.lang.String COLORTARGET
           
protected  int colorTargetInit
           
static java.lang.String DIFFUSE
           
protected  float[] diffuseColor
           
protected  float[] diffuseColorInit
           
static java.lang.String EMISSIVE
           
protected  float[] emissiveColor
           
protected  float[] emissiveColorInit
           
protected  javax.swing.JMenuItem helpMenuItem
           
protected  javax.swing.JMenuItem info3DMenuItem
           
protected  javax.swing.JMenuItem infoJavaMenuItem
           
protected  javax.swing.JMenuItem infoParametersMenuItem
           
protected  javax.swing.JMenuItem infoSystemMenuItem
           
protected  javax.swing.JMenuItem infoUserMenuItem
           
protected  boolean lighting
           
static java.lang.String LIGHTING
           
protected  boolean lightingInit
           
protected  javax.swing.JButton ok
           
protected  javax.swing.JButton reset
           
private static long serialVersionUID
           
protected  float shininess
           
static java.lang.String SHININESS
           
protected  float shininessInit
           
static java.lang.String SPECULAR
           
protected  float[] specularColor
           
protected  float[] specularColorInit
           
static java.lang.String TEXTURE_BLEND
           
static java.lang.String TEXTURE_COMBINE_ALPHA_FUNCTION
           
static java.lang.String TEXTURE_COMBINE_ALPHA_MODE
           
static java.lang.String TEXTURE_COMBINE_ALPHA_SCALE
           
static java.lang.String TEXTURE_COMBINE_ALPHA_SOURCE
           
static java.lang.String TEXTURE_COMBINE_RGB_FUNCTION
           
static java.lang.String TEXTURE_COMBINE_RGB_MODE
           
static java.lang.String TEXTURE_COMBINE_RGB_SCALE
           
static java.lang.String TEXTURE_COMBINE_RGB_SOURCE
           
static java.lang.String TEXTURE_FILE
           
static java.lang.String TEXTURE_MODE
           
static java.lang.String TEXTURE_PERSPECTIVE_CORRECTION_MODE
           
static java.lang.String TEXTURE_TRANSFORM
           
static java.lang.String TEXTURE_USE
           
protected  float[] textureBlendColor
           
protected  float[] textureBlendColorInit
           
protected  int[] textureCombineAlphaFunction
           
protected  int[] textureCombineAlphaFunctionInit
           
protected  int textureCombineAlphaMode
           
protected  int textureCombineAlphaModeInit
           
protected  int textureCombineAlphaScale
           
protected  int textureCombineAlphaScaleInit
           
protected  int[] textureCombineAlphaSource
           
protected  int[] textureCombineAlphaSourceInit
           
protected  int[] textureCombineRGBFunction
           
protected  int[] textureCombineRGBFunctionInit
           
protected  int textureCombineRGBMode
           
protected  int textureCombineRGBModeInit
           
protected  int textureCombineRGBScale
           
protected  int textureCombineRGBScaleInit
           
protected  int[] textureCombineRGBSource
           
protected  int[] textureCombineRGBSourceInit
           
protected  java.net.URL textureFile
           
protected  java.net.URL textureFileInit
           
protected  int textureMode
           
protected  int textureModeInit
           
protected  int texturePerspectiveCorrectionMode
           
protected  int texturePerspectiveCorrectionModeInit
           
protected  javax.media.j3d.Transform3D textureTransform
           
protected  javax.media.j3d.Transform3D textureTransformInit
           
protected  boolean textureUse
           
protected  boolean textureUseInit
           
protected  float transparency
           
static java.lang.String TRANSPARENCY
           
static java.lang.String TRANSPARENCY_DST_BLEND_FUNCTION
           
static java.lang.String TRANSPARENCY_MODE
           
static java.lang.String TRANSPARENCY_SRC_BLEND_FUNCTION
           
protected  int transparencyDstBlendFunction
           
protected  int transparencyDstBlendFunctionInit
           
protected  float transparencyInit
           
protected  int transparencyMode
           
protected  int transparencyModeInit
           
protected  int transparencySrcBlendFunction
           
protected  int transparencySrcBlendFunctionInit
           
 
Fields inherited from class javax.swing.JFrame
accessibleContext, EXIT_ON_CLOSE, rootPane, rootPaneCheckingEnabled
 
Fields inherited from class java.awt.Frame
CROSSHAIR_CURSOR, DEFAULT_CURSOR, E_RESIZE_CURSOR, HAND_CURSOR, ICONIFIED, MAXIMIZED_BOTH, MAXIMIZED_HORIZ, MAXIMIZED_VERT, MOVE_CURSOR, N_RESIZE_CURSOR, NE_RESIZE_CURSOR, NORMAL, NW_RESIZE_CURSOR, S_RESIZE_CURSOR, SE_RESIZE_CURSOR, SW_RESIZE_CURSOR, TEXT_CURSOR, W_RESIZE_CURSOR, WAIT_CURSOR
 
Fields inherited from class java.awt.Component
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT
 
Fields inherited from interface javax.swing.WindowConstants
DISPOSE_ON_CLOSE, DO_NOTHING_ON_CLOSE, HIDE_ON_CLOSE
 
Fields inherited from interface java.awt.image.ImageObserver
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH
 
Constructor Summary
Appearance3DChooser(java.lang.String title, boolean showMaterial, boolean showTransparency, boolean showTexture, boolean showRendering)
          Main Appearance3DChooser constructor.
Appearance3DChooser(java.lang.String title, boolean showMaterial, boolean showTransparency, boolean showTexture, boolean showRendering, boolean show)
          Main Appearance3DChooser constructor.
 
Method Summary
 void actionPerformed(java.awt.event.ActionEvent e)
          Called when an action is performed : the OK/CANCEL/RESET button is clicked or a menu is choosen in the menu bar
 void addPropertyChangeListener(java.beans.PropertyChangeListener l)
          Add a Property Change Listener.
 void addPropertyChangeListener(java.lang.String s, java.beans.PropertyChangeListener l)
          Add a Property Change Listener.
 float[] getAmbientColor()
          Return the Ambient Color.
 int getColorTarget()
          Return the Color Target.
 float[] getDiffuseColor()
          Return the Diffuse Color.
 float[] getEmissiveColor()
          Return the Emissive Color.
 boolean getLighting()
          Return the Lighting mode.
private  Appearance3DChooserPanel getPickerPan()
          Return the Apparence3DChooser Panel.
 float getShininess()
          Return the Shininess.
 float[] getSpecularColor()
          Return the Specular Color.
 float[] getTextureBlendColor()
          Return the Texture Blend Color.
 int[] getTextureCombineAlphaFunction()
          Return the Texture Combine Alpha Function.
 int getTextureCombineAlphaMode()
          Return the Texture Combine Alpha Mode.
 int getTextureCombineAlphaScale()
          Return the Texture Combine Alpha Scale.
 int[] getTextureCombineAlphaSource()
          Return the Texture Combine Alpha Source.
 int[] getTextureCombineRGBFunction()
          Return the Texture Combine RGB Function.
 int getTextureCombineRGBMode()
          Return the Texture Combine RGB Mode.
 int getTextureCombineRGBScale()
          Return the Texture Combine RGB Scale.
 int[] getTextureCombineRGBSource()
          Return the Texture Combine RGB Source.
 java.net.URL getTextureFile()
          Return the Texture File URL.
 int getTextureMode()
          Return the Texture Mode.
 int getTexturePerspectiveCorrectionMode()
          Return the Texture Perspective Correction Mode.
 javax.media.j3d.Transform3D getTextureTransform()
          Return the Texture Transform.
 float getTextureTransformRotZ()
          Return the Texture Transform Rotation on Z axis.
 float getTextureTransformScaleX()
          Return the Texture Transform Scale on X axis.
 float getTextureTransformScaleY()
          Return the Texture Transform Scale on Y axis.
 float getTextureTransformTranslatX()
          Return the Texture Transform Translation on X axis.
 float getTextureTransformTranslatY()
          Return the Texture Transform Translation on Y axis.
 float getTransparency()
          Return the transparency value.
 int getTransparencyDstBlendFunction()
          Return the transparency Destination Blend Function.
 int getTransparencyMode()
          Return the transparency Mode.
 int getTransparencySrcBlendFunction()
          Return the transparency Source Blend Function.
 boolean isTextureSet()
          Return the Texture Setting.
static void main(java.lang.String[] args)
          A Main Exemple.
 void removePropertyChangeListener(java.beans.PropertyChangeListener l)
          Remove a Property Change Listener.
 void runListeners()
          Must be called before listening any Property change.
 void setAmbientColor(float r, float g, float b, boolean init)
          Set the Ambient Color.
 void setColorTarget(int c, boolean init)
          Set the Color Target.
 void setDiffuseColor(float r, float g, float b, boolean init)
          Set the Diffuse Color
 void setEmissiveColor(float r, float g, float b, boolean init)
          Set the Emissive Color.
 void setInitParameters()
          Set all the parameters to their init value.
 void setLighting(boolean l, boolean init)
          Set the Lighting mode.
 void setShininess(float s, boolean init)
          Set the Shininess.
 void setSpecularColor(float r, float g, float b, boolean init)
          Set the Specular Color.
 void setTextureBlendColor(float r, float g, float b, float a, boolean init)
          Set the Texture Blend Color.
 void setTextureCombineAlphaFunction(int c0, int c1, int c2, boolean init)
          Set the Texture Combine Alpha Function.
 void setTextureCombineAlphaMode(int m, boolean init)
          Set the Texture Combine Alpha Mode/
 void setTextureCombineAlphaScale(int s, boolean init)
          Set the Texture Combine Alpha Scale .
 void setTextureCombineAlphaSource(int c0, int c1, int c2, boolean init)
          Set the Texture Combine Alpha Source.
 void setTextureCombineRGBFunction(int c0, int c1, int c2, boolean init)
          Set the Texture Combine RGB Function.
 void setTextureCombineRGBMode(int m, boolean init)
          Set the Texture Combine RGB Mode
 void setTextureCombineRGBScale(int s, boolean init)
          Set the Texture Combine RGB Scale.
 void setTextureCombineRGBSource(int c0, int c1, int c2, boolean init)
          Set the Texture Combine RGB Source.
 void setTextureFile(java.net.URL f, boolean init)
          Set the Texture File URL.
 void setTextureMode(int m, boolean init)
          Set the Texture Mode.
 void setTexturePerspectiveCorrectionMode(int m, boolean init)
          Set the Texture Perspective Correction Mode.
 void setTextureTransform(javax.media.j3d.Transform3D t, boolean init)
          Set the Texture Transform.
 void setTextureTransformRotZ(float v, boolean init)
          Set the Texture Transform Rotation on Z axis.
 void setTextureTransformScaleX(float v, boolean init)
          Set the Texture Transform Scale on X axis.
 void setTextureTransformScaleY(float v, boolean init)
          Set the Texture Transform Scale on Y axis.
 void setTextureTransformTranslatX(float v, boolean init)
          Set the Texture Transform Translation on X axis.
 void setTextureTransformTranslatY(float v, boolean init)
          Set the Texture Transform Translation on Y axis.
 void setTextureUse(boolean b, boolean init)
          Set the Texture Setting.
 void setTransparency(float t, boolean init)
          Set the transparency value.
 void setTransparencyDstBlendFunction(int f, boolean init)
          Set the transparency Destination Blend Function.
 void setTransparencyMode(int m, boolean init)
          Set the transparency Mode.
 void setTransparencySrcBlendFunction(int f, boolean init)
          Set the transparency Source Blend Function.
 void showWindow(boolean on)
          Show or Hide the Windows.
private  void updateAmbientColor(float[] c)
          Internal update of the Ambient Color Parameters and fire of an associated property.
private  void updateColorTarget(int c)
          Internal update of the Color Target Parameters and fire of an associated property.
private  void updateDiffuseColor(float[] c)
          Internal update of the Diffuse Color Parameters and fire of an associated property.
private  void updateEmissiveColor(float[] c)
          Internal update of the Emissive Color Parameters and fire of an associated property.
private  void updateLighting(boolean l)
          Internal update of the Lighting mode Parameters and fire of an associated property.
private  void updateShininess(float s)
          Internal update of the Shininess Parameters and fire of an associated property.
private  void updateSpecularColor(float[] c)
          Internal update of the Specular Color Parameters and fire of an associated property.
private  void updateTextureBlendColor(float[] b)
          Internal update of the Texture Blend Color Parameters and fire of an associated property.
private  void updateTextureCombineAlphaFunction(int[] s)
          Internal update of the Texture Combine Alpha Function Parameters and fire of an associated property.
private  void updateTextureCombineAlphaMode(int m)
          Internal update of the Texture Combine Alpha Mode Parameters and fire of an associated property.
private  void updateTextureCombineAlphaScale(int s)
          Internal update of the Texture Combine Alpha Scale Parameters and fire of an associated property.
private  void updateTextureCombineAlphaSource(int[] s)
          Internal update of the Texture Combine Alpha Source Parameters and fire of an associated property.
private  void updateTextureCombineRGBFunction(int[] s)
          Internal update of the Texture Combine RGB Function Parameters and fire of an associated property.
private  void updateTextureCombineRGBMode(int m)
          Internal update of the Texture Combine RGB Mode Parameters and fire of an associated property.
private  void updateTextureCombineRGBScale(int s)
          Internal update of the Texture Combine RGB Scale Parameters and fire of an associated property.
private  void updateTextureCombineRGBSource(int[] s)
          Internal update of the Texture Combine RGB Source Parameters and fire of an associated property.
private  void updateTextureFile(java.net.URL f)
          Internal update of the Texture File URL Parameters and fire of an associated property.
private  void updateTextureMode(int m)
          Internal update of the Texture Mode Parameters and fire of an associated property.
private  void updateTexturePerspectiveCorrectionMode(int m)
          Internal update of the Texture Perspective Correction Mode Parameters and fire of an associated property.
private  void updateTextureTransform(javax.media.j3d.Transform3D t)
          Internal update of the Texture Transform Parameters and fire of an associated property.
private  void updateTextureUse(boolean b)
          Internal update of the Texture Setting Parameters and fire of an associated property.
private  void updateTransparency(float f)
          Internal update of the transparency value Parameters and fire of an associated property.
private  void updateTransparencyDstBlendFunction(int f)
          Internal update of the transparency Destination Blend Function Parameters and fire of an associated property.
private  void updateTransparencyMode(int m)
          Internal update of the transparency Mode Parameters and fire of an associated property.
private  void updateTransparencySrcBlendFunction(int f)
          Internal update of the transparency Source Blend Function Parameters and fire of an associated property.
 void windowActivated(java.awt.event.WindowEvent w)
          Called when user Activates the Main JFrame.
 void windowClosed(java.awt.event.WindowEvent w)
          Called when the Main JFrame is closed.
 void windowClosing(java.awt.event.WindowEvent w)
          Called when the Main JFrame is in the process of being closed.
 void windowDeactivated(java.awt.event.WindowEvent w)
          Called when user Deactivates the Main JFrame.
 void windowDeiconified(java.awt.event.WindowEvent w)
          Called when user Deiconifies the Main JFrame.
 void windowIconified(java.awt.event.WindowEvent w)
          Called when user iconifies the Main JFrame.
 void windowOpened(java.awt.event.WindowEvent w)
          Called when the Main JFrame has been opened.
 
Methods inherited from class javax.swing.JFrame
addImpl, createRootPane, frameInit, getAccessibleContext, getContentPane, getDefaultCloseOperation, getGlassPane, getGraphics, getJMenuBar, getLayeredPane, getRootPane, getTransferHandler, isDefaultLookAndFeelDecorated, isRootPaneCheckingEnabled, paramString, processWindowEvent, remove, repaint, setContentPane, setDefaultCloseOperation, setDefaultLookAndFeelDecorated, setGlassPane, setIconImage, setJMenuBar, setLayeredPane, setLayout, setRootPane, setRootPaneCheckingEnabled, setTransferHandler, update
 
Methods inherited from class java.awt.Frame
addNotify, getCursorType, getExtendedState, getFrames, getIconImage, getMaximizedBounds, getMenuBar, getState, getTitle, isResizable, isUndecorated, remove, removeNotify, setCursor, setExtendedState, setMaximizedBounds, setMenuBar, setResizable, setState, setTitle, setUndecorated
 
Methods inherited from class java.awt.Window
addWindowFocusListener, addWindowListener, addWindowStateListener, applyResourceBundle, applyResourceBundle, createBufferStrategy, createBufferStrategy, dispose, getBufferStrategy, getFocusableWindowState, getFocusCycleRootAncestor, getFocusOwner, getFocusTraversalKeys, getGraphicsConfiguration, getIconImages, getInputContext, getListeners, getLocale, getModalExclusionType, getMostRecentFocusOwner, getOwnedWindows, getOwner, getOwnerlessWindows, getToolkit, getWarningString, getWindowFocusListeners, getWindowListeners, getWindows, getWindowStateListeners, hide, isActive, isAlwaysOnTop, isAlwaysOnTopSupported, isFocusableWindow, isFocusCycleRoot, isFocused, isLocationByPlatform, isShowing, pack, postEvent, processEvent, processWindowFocusEvent, processWindowStateEvent, removeWindowFocusListener, removeWindowListener, removeWindowStateListener, reshape, setAlwaysOnTop, setBounds, setBounds, setCursor, setFocusableWindowState, setFocusCycleRoot, setIconImages, setLocationByPlatform, setLocationRelativeTo, setMinimumSize, setModalExclusionType, setSize, setSize, setVisible, show, toBack, toFront
 
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalPolicy, getInsets, getLayout, getMaximumSize, getMinimumSize, getMousePosition, getPreferredSize, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paint, paintComponents, preferredSize, print, printComponents, processContainerEvent, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusTraversalKeys, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setFont, transferFocusBackward, transferFocusDownCycle, validate, validateTree
 
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, contains, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBaseline, getBaselineResizeBehavior, getBounds, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getFontMetrics, getForeground, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocation, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isOpaque, isPreferredSizeSet, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, processMouseWheelEvent, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resize, resize, setBackground, setComponentOrientation, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeysEnabled, setForeground, setIgnoreRepaint, setLocale, setLocation, setLocation, setMaximumSize, setName, setPreferredSize, show, size, toString, transferFocus, transferFocusUpCycle
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface java.awt.MenuContainer
getFont, postEvent
 

Field Detail

serialVersionUID

private static final long serialVersionUID
See Also:
Constant Field Values

appearance3DPan

private Appearance3DChooserPanel appearance3DPan

ok

protected javax.swing.JButton ok

cancel

protected javax.swing.JButton cancel

reset

protected javax.swing.JButton reset

info3DMenuItem

protected javax.swing.JMenuItem info3DMenuItem

aboutMenuItem

protected javax.swing.JMenuItem aboutMenuItem

helpMenuItem

protected javax.swing.JMenuItem helpMenuItem

infoUserMenuItem

protected javax.swing.JMenuItem infoUserMenuItem

infoSystemMenuItem

protected javax.swing.JMenuItem infoSystemMenuItem

infoJavaMenuItem

protected javax.swing.JMenuItem infoJavaMenuItem

infoParametersMenuItem

protected javax.swing.JMenuItem infoParametersMenuItem

emissiveColorInit

protected float[] emissiveColorInit

specularColorInit

protected float[] specularColorInit

ambientColorInit

protected float[] ambientColorInit

diffuseColorInit

protected float[] diffuseColorInit

shininessInit

protected float shininessInit

colorTargetInit

protected int colorTargetInit

lightingInit

protected boolean lightingInit

transparencyInit

protected float transparencyInit

transparencyModeInit

protected int transparencyModeInit

transparencySrcBlendFunctionInit

protected int transparencySrcBlendFunctionInit

transparencyDstBlendFunctionInit

protected int transparencyDstBlendFunctionInit

textureTransformInit

protected javax.media.j3d.Transform3D textureTransformInit

textureUseInit

protected boolean textureUseInit

textureFileInit

protected java.net.URL textureFileInit

texturePerspectiveCorrectionModeInit

protected int texturePerspectiveCorrectionModeInit

textureModeInit

protected int textureModeInit

textureBlendColorInit

protected float[] textureBlendColorInit

textureCombineRGBModeInit

protected int textureCombineRGBModeInit

textureCombineRGBSourceInit

protected int[] textureCombineRGBSourceInit

textureCombineRGBFunctionInit

protected int[] textureCombineRGBFunctionInit

textureCombineRGBScaleInit

protected int textureCombineRGBScaleInit

textureCombineAlphaModeInit

protected int textureCombineAlphaModeInit

textureCombineAlphaSourceInit

protected int[] textureCombineAlphaSourceInit

textureCombineAlphaFunctionInit

protected int[] textureCombineAlphaFunctionInit

textureCombineAlphaScaleInit

protected int textureCombineAlphaScaleInit

emissiveColor

protected float[] emissiveColor

specularColor

protected float[] specularColor

ambientColor

protected float[] ambientColor

diffuseColor

protected float[] diffuseColor

shininess

protected float shininess

colorTarget

protected int colorTarget

lighting

protected boolean lighting

transparency

protected float transparency

transparencyMode

protected int transparencyMode

transparencySrcBlendFunction

protected int transparencySrcBlendFunction

transparencyDstBlendFunction

protected int transparencyDstBlendFunction

textureTransform

protected javax.media.j3d.Transform3D textureTransform

textureUse

protected boolean textureUse

textureFile

protected java.net.URL textureFile

texturePerspectiveCorrectionMode

protected int texturePerspectiveCorrectionMode

textureMode

protected int textureMode

textureBlendColor

protected float[] textureBlendColor

textureCombineRGBMode

protected int textureCombineRGBMode

textureCombineRGBSource

protected int[] textureCombineRGBSource

textureCombineRGBFunction

protected int[] textureCombineRGBFunction

textureCombineRGBScale

protected int textureCombineRGBScale

textureCombineAlphaMode

protected int textureCombineAlphaMode

textureCombineAlphaSource

protected int[] textureCombineAlphaSource

textureCombineAlphaFunction

protected int[] textureCombineAlphaFunction

textureCombineAlphaScale

protected int textureCombineAlphaScale

SPECULAR

public static final java.lang.String SPECULAR
See Also:
Constant Field Values

AMBIENT

public static final java.lang.String AMBIENT
See Also:
Constant Field Values

EMISSIVE

public static final java.lang.String EMISSIVE
See Also:
Constant Field Values

DIFFUSE

public static final java.lang.String DIFFUSE
See Also:
Constant Field Values

COLORTARGET

public static final java.lang.String COLORTARGET
See Also:
Constant Field Values

SHININESS

public static final java.lang.String SHININESS
See Also:
Constant Field Values

LIGHTING

public static final java.lang.String LIGHTING
See Also:
Constant Field Values

TRANSPARENCY

public static final java.lang.String TRANSPARENCY
See Also:
Constant Field Values

TRANSPARENCY_MODE

public static final java.lang.String TRANSPARENCY_MODE
See Also:
Constant Field Values

TRANSPARENCY_SRC_BLEND_FUNCTION

public static final java.lang.String TRANSPARENCY_SRC_BLEND_FUNCTION
See Also:
Constant Field Values

TRANSPARENCY_DST_BLEND_FUNCTION

public static final java.lang.String TRANSPARENCY_DST_BLEND_FUNCTION
See Also:
Constant Field Values

TEXTURE_USE

public static final java.lang.String TEXTURE_USE
See Also:
Constant Field Values

TEXTURE_FILE

public static final java.lang.String TEXTURE_FILE
See Also:
Constant Field Values

TEXTURE_TRANSFORM

public static final java.lang.String TEXTURE_TRANSFORM
See Also:
Constant Field Values

TEXTURE_PERSPECTIVE_CORRECTION_MODE

public static final java.lang.String TEXTURE_PERSPECTIVE_CORRECTION_MODE
See Also:
Constant Field Values

TEXTURE_MODE

public static final java.lang.String TEXTURE_MODE
See Also:
Constant Field Values

TEXTURE_BLEND

public static final java.lang.String TEXTURE_BLEND
See Also:
Constant Field Values

TEXTURE_COMBINE_RGB_MODE

public static final java.lang.String TEXTURE_COMBINE_RGB_MODE
See Also:
Constant Field Values

TEXTURE_COMBINE_RGB_SOURCE

public static final java.lang.String TEXTURE_COMBINE_RGB_SOURCE
See Also:
Constant Field Values

TEXTURE_COMBINE_RGB_FUNCTION

public static final java.lang.String TEXTURE_COMBINE_RGB_FUNCTION
See Also:
Constant Field Values

TEXTURE_COMBINE_RGB_SCALE

public static final java.lang.String TEXTURE_COMBINE_RGB_SCALE
See Also:
Constant Field Values

TEXTURE_COMBINE_ALPHA_MODE

public static final java.lang.String TEXTURE_COMBINE_ALPHA_MODE
See Also:
Constant Field Values

TEXTURE_COMBINE_ALPHA_SOURCE

public static final java.lang.String TEXTURE_COMBINE_ALPHA_SOURCE
See Also:
Constant Field Values

TEXTURE_COMBINE_ALPHA_FUNCTION

public static final java.lang.String TEXTURE_COMBINE_ALPHA_FUNCTION
See Also:
Constant Field Values

TEXTURE_COMBINE_ALPHA_SCALE

public static final java.lang.String TEXTURE_COMBINE_ALPHA_SCALE
See Also:
Constant Field Values

boundSupport

protected java.beans.PropertyChangeSupport boundSupport
Constructor Detail

Appearance3DChooser

public Appearance3DChooser(java.lang.String title,
                           boolean showMaterial,
                           boolean showTransparency,
                           boolean showTexture,
                           boolean showRendering)
Main Appearance3DChooser constructor. Generate a Frame with all the Panes associated to control some of the JAVA 3D Appearance attributes.

Parameters:
title - Title for the frame.
showMaterial - set it to true if you want to see the Material Panel.
showTransparency - set it to true if you want to see the Transparency Panel.
showTexture - set it to true if you want to see the Texture Panel.
showRendering - set it to true if you want to see the Rendering Panel.

Appearance3DChooser

public Appearance3DChooser(java.lang.String title,
                           boolean showMaterial,
                           boolean showTransparency,
                           boolean showTexture,
                           boolean showRendering,
                           boolean show)
Main Appearance3DChooser constructor. Generate a Frame with all the Panes associated to control some of the JAVA 3D Appearance attributes.

Parameters:
title - Title for the frame.
showMaterial - set it to true if you want to see the Material Panel.
showTransparency - set it to true if you want to see the Transparency Panel.
showTexture - set it to true if you want to see the Texture Panel.
showRendering - set it to true if you want to see the Rendering Panel.
Method Detail

showWindow

public void showWindow(boolean on)
Show or Hide the Windows.

Parameters:
on - true if the windows has to be shown, falsed otherwise.

setInitParameters

public void setInitParameters()
Set all the parameters to their init value.


actionPerformed

public void actionPerformed(java.awt.event.ActionEvent e)
Called when an action is performed : the OK/CANCEL/RESET button is clicked or a menu is choosen in the menu bar

Specified by:
actionPerformed in interface java.awt.event.ActionListener
Parameters:
e - the related action.

windowClosing

public void windowClosing(java.awt.event.WindowEvent w)
Called when the Main JFrame is in the process of being closed.

Specified by:
windowClosing in interface java.awt.event.WindowListener
Parameters:
w - the related event.

windowDeactivated

public void windowDeactivated(java.awt.event.WindowEvent w)
Called when user Deactivates the Main JFrame.

Specified by:
windowDeactivated in interface java.awt.event.WindowListener
Parameters:
w - the related event.

windowActivated

public void windowActivated(java.awt.event.WindowEvent w)
Called when user Activates the Main JFrame.

Specified by:
windowActivated in interface java.awt.event.WindowListener
Parameters:
w - the related event.

windowDeiconified

public void windowDeiconified(java.awt.event.WindowEvent w)
Called when user Deiconifies the Main JFrame.

Specified by:
windowDeiconified in interface java.awt.event.WindowListener
Parameters:
w - the related event.

windowIconified

public void windowIconified(java.awt.event.WindowEvent w)
Called when user iconifies the Main JFrame.

Specified by:
windowIconified in interface java.awt.event.WindowListener
Parameters:
w - the related event.

windowClosed

public void windowClosed(java.awt.event.WindowEvent w)
Called when the Main JFrame is closed.

Specified by:
windowClosed in interface java.awt.event.WindowListener
Parameters:
w - the related event.

windowOpened

public void windowOpened(java.awt.event.WindowEvent w)
Called when the Main JFrame has been opened.

Specified by:
windowOpened in interface java.awt.event.WindowListener
Parameters:
w - the related event.

runListeners

public void runListeners()
Must be called before listening any Property change.


addPropertyChangeListener

public void addPropertyChangeListener(java.lang.String s,
                                      java.beans.PropertyChangeListener l)
Add a Property Change Listener.

Overrides:
addPropertyChangeListener in class java.awt.Window
Parameters:
s - the string describing it.
l - the Property Change Listener.

addPropertyChangeListener

public void addPropertyChangeListener(java.beans.PropertyChangeListener l)
Add a Property Change Listener.

Overrides:
addPropertyChangeListener in class java.awt.Window
Parameters:
l - the Property Change Listener.

removePropertyChangeListener

public void removePropertyChangeListener(java.beans.PropertyChangeListener l)
Remove a Property Change Listener.

Overrides:
removePropertyChangeListener in class java.awt.Component
Parameters:
l - the Property Change Listener.

getPickerPan

private Appearance3DChooserPanel getPickerPan()
Return the Apparence3DChooser Panel.

Returns:
the Apparence3DChooser Panel.

getSpecularColor

public float[] getSpecularColor()
Return the Specular Color.

Returns:
the Specular Color in (R,G,B).

setSpecularColor

public void setSpecularColor(float r,
                             float g,
                             float b,
                             boolean init)
Set the Specular Color.

Parameters:
r - the Specular Color in R.
g - the Specular Color in G.
b - the Specular Color in B.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateSpecularColor

private void updateSpecularColor(float[] c)
Internal update of the Specular Color Parameters and fire of an associated property.

Parameters:
c - the Specular Color in (R,G,B).

getAmbientColor

public float[] getAmbientColor()
Return the Ambient Color.

Returns:
the Ambient Color in (R,G,B).

setAmbientColor

public void setAmbientColor(float r,
                            float g,
                            float b,
                            boolean init)
Set the Ambient Color.

Parameters:
r - the Ambient Color in R.
g - the Ambient Color in G.
b - the Ambient Color in B.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateAmbientColor

private void updateAmbientColor(float[] c)
Internal update of the Ambient Color Parameters and fire of an associated property.

Parameters:
c - the Ambient Color in (R,G,B).

getDiffuseColor

public float[] getDiffuseColor()
Return the Diffuse Color.

Returns:
the Diffuse Color in (R,G,B).

setDiffuseColor

public void setDiffuseColor(float r,
                            float g,
                            float b,
                            boolean init)
Set the Diffuse Color

Parameters:
r - the Diffuse Color in R.
g - the Diffuse Color in G.
b - the Diffuse Color in B.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateDiffuseColor

private void updateDiffuseColor(float[] c)
Internal update of the Diffuse Color Parameters and fire of an associated property.

Parameters:
c - the Diffuse Color in (R,G,B).

getEmissiveColor

public float[] getEmissiveColor()
Return the Emissive Color.

Returns:
the Emissive Color in (R,G,B).

setEmissiveColor

public void setEmissiveColor(float r,
                             float g,
                             float b,
                             boolean init)
Set the Emissive Color.

Parameters:
r - the Emissive Color in R.
g - the Emissive Color in G.
b - the Emissive Color in B.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateEmissiveColor

private void updateEmissiveColor(float[] c)
Internal update of the Emissive Color Parameters and fire of an associated property.

Parameters:
c - the Emissive Color in (R,G,B).

getColorTarget

public int getColorTarget()
Return the Color Target.

Returns:
the Color Target. One of: Material.AMBIENT, Material.EMISSIVE, Material.DIFFUSE, Material.SPECULAR, or Material.AMBIENT_AND_DIFFUSE.

setColorTarget

public void setColorTarget(int c,
                           boolean init)
Set the Color Target.

Parameters:
c - the Color Target. One of: Material.AMBIENT, Material.EMISSIVE, Material.DIFFUSE, Material.SPECULAR, or Material.AMBIENT_AND_DIFFUSE.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateColorTarget

private void updateColorTarget(int c)
Internal update of the Color Target Parameters and fire of an associated property.

Parameters:
c - the Color Target. One of: Material.AMBIENT, Material.EMISSIVE, Material.DIFFUSE, Material.SPECULAR, or Material.AMBIENT_AND_DIFFUSE.

getShininess

public float getShininess()
Return the Shininess.

Returns:
the Shininess in the range [1.0, 128.0] with 1.0 being not shiny and 128.0 being very shiny.

setShininess

public void setShininess(float s,
                         boolean init)
Set the Shininess.

Parameters:
s - the Shininess in the range [1.0, 128.0] with 1.0 being not shiny and 128.0 being very shiny.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateShininess

private void updateShininess(float s)
Internal update of the Shininess Parameters and fire of an associated property.

Parameters:
s - the Shininess in the range [1.0, 128.0] with 1.0 being not shiny and 128.0 being very shiny.

getLighting

public boolean getLighting()
Return the Lighting mode.

Returns:
true if lighting is enabled for the object, false otherwise.

setLighting

public void setLighting(boolean l,
                        boolean init)
Set the Lighting mode.

Parameters:
l - true lighting is enabled for the object, false otherwise.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateLighting

private void updateLighting(boolean l)
Internal update of the Lighting mode Parameters and fire of an associated property.

Parameters:
l - true lighting is enabled for the object, false otherwise.

getTransparency

public float getTransparency()
Return the transparency value.

Returns:
the amount of transparency to be applied to the Appearance component object. The transparency values are in the range [0.0, 1.0], with 0.0 being fully opaque and 1.0 being fully transparent.

setTransparency

public void setTransparency(float t,
                            boolean init)
Set the transparency value.

Parameters:
t - the amount of transparency to be applied to the Appearance component object. The transparency values are in the range [0.0, 1.0], with 0.0 being fully opaque and 1.0 being fully transparent.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateTransparency

private void updateTransparency(float f)
Internal update of the transparency value Parameters and fire of an associated property.

Parameters:
f - the amount of transparency to be applied to the Appearance component object. The transparency values are in the range [0.0, 1.0], with 0.0 being fully opaque and 1.0 being fully transparent.

getTransparencyMode

public int getTransparencyMode()
Return the transparency Mode.

Returns:
the transparency Mode between TransparencyAttributes.FASTEST, TransparencyAttributes.NICEST, TransparencyAttributes.SCREEN_DOOR, TransparencyAttributes.BLENDED, TransparencyAttributes.NONE

setTransparencyMode

public void setTransparencyMode(int m,
                                boolean init)
Set the transparency Mode.

Parameters:
m - the transparency Mode between TransparencyAttributes.FASTEST, TransparencyAttributes.NICEST, TransparencyAttributes.SCREEN_DOOR, TransparencyAttributes.BLENDED, TransparencyAttributes.NONE
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateTransparencyMode

private void updateTransparencyMode(int m)
Internal update of the transparency Mode Parameters and fire of an associated property.

Parameters:
m - the transparency Mode between TransparencyAttributes.FASTEST, TransparencyAttributes.NICEST, TransparencyAttributes.SCREEN_DOOR, TransparencyAttributes.BLENDED, TransparencyAttributes.NONE

getTransparencySrcBlendFunction

public int getTransparencySrcBlendFunction()
Return the transparency Source Blend Function.

Returns:
the transparency Source Blend Function between TransparencyAttributes.BLEND_ZERO, TransparencyAttributes.BLEND_ONE, TransparencyAttributes.BLEND_SRC_ALPHA, TransparencyAttributes.BLEND_ONE_MINUS_SRC_ALPHA, TransparencyAttributes.BLEND_DST_COLOR, TransparencyAttributes.BLEND_ONE_MINUS_DST_COLOR.

setTransparencySrcBlendFunction

public void setTransparencySrcBlendFunction(int f,
                                            boolean init)
Set the transparency Source Blend Function.

Parameters:
f - the transparency Source Blend Function between TransparencyAttributes.BLEND_ZERO, TransparencyAttributes.BLEND_ONE, TransparencyAttributes.BLEND_SRC_ALPHA, TransparencyAttributes.BLEND_ONE_MINUS_SRC_ALPHA, TransparencyAttributes.BLEND_DST_COLOR, TransparencyAttributes.BLEND_ONE_MINUS_DST_COLOR.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateTransparencySrcBlendFunction

private void updateTransparencySrcBlendFunction(int f)
Internal update of the transparency Source Blend Function Parameters and fire of an associated property.

Parameters:
f - the transparency Source Blend Function between TransparencyAttributes.BLEND_ZERO, TransparencyAttributes.BLEND_ONE, TransparencyAttributes.BLEND_SRC_ALPHA, TransparencyAttributes.BLEND_ONE_MINUS_SRC_ALPHA, TransparencyAttributes.BLEND_DST_COLOR, TransparencyAttributes.BLEND_ONE_MINUS_DST_COLOR.

getTransparencyDstBlendFunction

public int getTransparencyDstBlendFunction()
Return the transparency Destination Blend Function.

Returns:
the transparency Destination Blend Function between TransparencyAttributes.BLEND_ZERO, TransparencyAttributes.BLEND_ONE, TransparencyAttributes.BLEND_SRC_ALPHA, TransparencyAttributes.BLEND_ONE_MINUS_SRC_ALPHA, TransparencyAttributes.BLEND_SRC_COLOR, TransparencyAttributes.BLEND_ONE_MINUS_SRC_COLOR.

setTransparencyDstBlendFunction

public void setTransparencyDstBlendFunction(int f,
                                            boolean init)
Set the transparency Destination Blend Function.

Parameters:
f - the transparency Destination Blend Function between TransparencyAttributes.BLEND_ZERO, TransparencyAttributes.BLEND_ONE, TransparencyAttributes.BLEND_SRC_ALPHA, TransparencyAttributes.BLEND_ONE_MINUS_SRC_ALPHA, TransparencyAttributes.BLEND_SRC_COLOR, TransparencyAttributes.BLEND_ONE_MINUS_SRC_COLOR.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateTransparencyDstBlendFunction

private void updateTransparencyDstBlendFunction(int f)
Internal update of the transparency Destination Blend Function Parameters and fire of an associated property.

Parameters:
f - the transparency Destination Blend Function between TransparencyAttributes.BLEND_ZERO, TransparencyAttributes.BLEND_ONE, TransparencyAttributes.BLEND_SRC_ALPHA, TransparencyAttributes.BLEND_ONE_MINUS_SRC_ALPHA, TransparencyAttributes.BLEND_SRC_COLOR, TransparencyAttributes.BLEND_ONE_MINUS_SRC_COLOR.

getTextureTransform

public javax.media.j3d.Transform3D getTextureTransform()
Return the Texture Transform.

Returns:
the Texture Transform.

setTextureTransform

public void setTextureTransform(javax.media.j3d.Transform3D t,
                                boolean init)
Set the Texture Transform.

Parameters:
t - the Texture Transform.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateTextureTransform

private void updateTextureTransform(javax.media.j3d.Transform3D t)
Internal update of the Texture Transform Parameters and fire of an associated property.

Parameters:
t - the Texture Transform.

getTextureTransformScaleX

public float getTextureTransformScaleX()
Return the Texture Transform Scale on X axis.

Returns:
the Texture Transform Scale on X axis.

setTextureTransformScaleX

public void setTextureTransformScaleX(float v,
                                      boolean init)
Set the Texture Transform Scale on X axis.

Parameters:
v - the Texture Transform Scale on X axis.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

getTextureTransformScaleY

public float getTextureTransformScaleY()
Return the Texture Transform Scale on Y axis.

Returns:
the Texture Transform Scale on Y axis.

setTextureTransformScaleY

public void setTextureTransformScaleY(float v,
                                      boolean init)
Set the Texture Transform Scale on Y axis.

Parameters:
v - the Texture Transform Scale on Y axis.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

getTextureTransformTranslatX

public float getTextureTransformTranslatX()
Return the Texture Transform Translation on X axis.

Returns:
the Texture Transform Translation on X axis.

setTextureTransformTranslatX

public void setTextureTransformTranslatX(float v,
                                         boolean init)
Set the Texture Transform Translation on X axis.

Parameters:
v - the Texture Transform Translation on X axis.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

getTextureTransformTranslatY

public float getTextureTransformTranslatY()
Return the Texture Transform Translation on Y axis.

Returns:
the Texture Transform Translation on Y axis.

setTextureTransformTranslatY

public void setTextureTransformTranslatY(float v,
                                         boolean init)
Set the Texture Transform Translation on Y axis.

Parameters:
v - the Texture Transform Translation on Y axis.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

getTextureTransformRotZ

public float getTextureTransformRotZ()
Return the Texture Transform Rotation on Z axis.

Returns:
the Texture Transform Rotation on Z axis.

setTextureTransformRotZ

public void setTextureTransformRotZ(float v,
                                    boolean init)
Set the Texture Transform Rotation on Z axis.

Parameters:
v - the Texture Transform Rotation on Z axis.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

getTextureFile

public java.net.URL getTextureFile()
Return the Texture File URL.

Returns:
the Texture File URL.

setTextureFile

public void setTextureFile(java.net.URL f,
                           boolean init)
Set the Texture File URL.

Parameters:
f - the Texture File URL.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateTextureFile

private void updateTextureFile(java.net.URL f)
Internal update of the Texture File URL Parameters and fire of an associated property.

Parameters:
f - the Texture File URL.

getTextureMode

public int getTextureMode()
Return the Texture Mode.

Returns:
the Texture Mode between TextureAttributes.MODULATE, TextureAttributes.DECAL, TextureAttributes.BLEND, TextureAttributes.REPLACE, TextureAttributes.COMBINE.

setTextureMode

public void setTextureMode(int m,
                           boolean init)
Set the Texture Mode.

Parameters:
m - the Texture Mode between TextureAttributes.MODULATE, TextureAttributes.DECAL, TextureAttributes.BLEND, TextureAttributes.REPLACE, TextureAttributes.COMBINE.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateTextureMode

private void updateTextureMode(int m)
Internal update of the Texture Mode Parameters and fire of an associated property.

Parameters:
m - the Texture Mode between TextureAttributes.MODULATE, TextureAttributes.DECAL, TextureAttributes.BLEND, TextureAttributes.REPLACE, TextureAttributes.COMBINE.

getTextureBlendColor

public float[] getTextureBlendColor()
Return the Texture Blend Color.

Returns:
the Texture Blend Color in (R,G,B,A).

setTextureBlendColor

public void setTextureBlendColor(float r,
                                 float g,
                                 float b,
                                 float a,
                                 boolean init)
Set the Texture Blend Color.

Parameters:
r - the Texture Blend Color in R.
g - the Texture Blend Color in G.
b - the Texture Blend Color in B.
a - the Texture Blend Color in A.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateTextureBlendColor

private void updateTextureBlendColor(float[] b)
Internal update of the Texture Blend Color Parameters and fire of an associated property.

Parameters:
b - the Texture Blend Color in (R,G,B,A).

getTexturePerspectiveCorrectionMode

public int getTexturePerspectiveCorrectionMode()
Return the Texture Perspective Correction Mode.

Returns:
the Texture Perspective Correction Mode between TextureAttributes.NICEST, TextureAttributes.FASTEST.

setTexturePerspectiveCorrectionMode

public void setTexturePerspectiveCorrectionMode(int m,
                                                boolean init)
Set the Texture Perspective Correction Mode.

Parameters:
m - the Texture Perspective Correction Mode between TextureAttributes.NICEST, TextureAttributes.FASTEST.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateTexturePerspectiveCorrectionMode

private void updateTexturePerspectiveCorrectionMode(int m)
Internal update of the Texture Perspective Correction Mode Parameters and fire of an associated property.

Parameters:
m - the Texture Perspective Correction Mode between TextureAttributes.NICEST, TextureAttributes.FASTEST.

getTextureCombineRGBMode

public int getTextureCombineRGBMode()
Return the Texture Combine RGB Mode.

Returns:
the Texture Combine RGB Mode between TextureAttributes.COMBINE_REPLACE, TextureAttributes.COMBINE_MODULATE, TextureAttributes.COMBINE_ADD, TextureAttributes.COMBINE_ADD_SIGNED, TextureAttributes.COMBINE_SUBTRACT, TextureAttributes.COMBINE_INTERPOLATE, TextureAttributes.COMBINE_DOT3.

setTextureCombineRGBMode

public void setTextureCombineRGBMode(int m,
                                     boolean init)
Set the Texture Combine RGB Mode

Parameters:
m - the Texture Combine RGB Mode between TextureAttributes.COMBINE_REPLACE, TextureAttributes.COMBINE_MODULATE, TextureAttributes.COMBINE_ADD, TextureAttributes.COMBINE_ADD_SIGNED, TextureAttributes.COMBINE_SUBTRACT, TextureAttributes.COMBINE_INTERPOLATE, TextureAttributes.COMBINE_DOT3.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateTextureCombineRGBMode

private void updateTextureCombineRGBMode(int m)
Internal update of the Texture Combine RGB Mode Parameters and fire of an associated property.

Parameters:
m - the Texture Combine RGB Mode between TextureAttributes.COMBINE_REPLACE, TextureAttributes.COMBINE_MODULATE, TextureAttributes.COMBINE_ADD, TextureAttributes.COMBINE_ADD_SIGNED, TextureAttributes.COMBINE_SUBTRACT, TextureAttributes.COMBINE_INTERPOLATE, TextureAttributes.COMBINE_DOT3.

getTextureCombineRGBSource

public int[] getTextureCombineRGBSource()
Return the Texture Combine RGB Source.

Returns:
the Texture Combine RGB Source between TextureAttributes.COMBINE_OBJECT_COLOR, TextureAttributes.COMBINE_TEXTURE_COLOR, TextureAttributes.COMBINE_CONSTANT_COLOR, TextureAttributes.COMBINE_PREVIOUS_TEXTURE_UNIT_STATE.

setTextureCombineRGBSource

public void setTextureCombineRGBSource(int c0,
                                       int c1,
                                       int c2,
                                       boolean init)
Set the Texture Combine RGB Source.

Parameters:
c0 - the Texture Combine RGB Source C0 between TextureAttributes.COMBINE_OBJECT_COLOR, TextureAttributes.COMBINE_TEXTURE_COLOR, TextureAttributes.COMBINE_CONSTANT_COLOR, TextureAttributes.COMBINE_PREVIOUS_TEXTURE_UNIT_STATE.
c1 - the Texture Combine RGB Source C1 between TextureAttributes.COMBINE_OBJECT_COLOR, TextureAttributes.COMBINE_TEXTURE_COLOR, TextureAttributes.COMBINE_CONSTANT_COLOR, TextureAttributes.COMBINE_PREVIOUS_TEXTURE_UNIT_STATE.
c2 - the Texture Combine RGB Source C2 between TextureAttributes.COMBINE_OBJECT_COLOR, TextureAttributes.COMBINE_TEXTURE_COLOR, TextureAttributes.COMBINE_CONSTANT_COLOR, TextureAttributes.COMBINE_PREVIOUS_TEXTURE_UNIT_STATE.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateTextureCombineRGBSource

private void updateTextureCombineRGBSource(int[] s)
Internal update of the Texture Combine RGB Source Parameters and fire of an associated property.

Parameters:
s - the Texture Combine RGB Source (C0,C1,C2) between TextureAttributes.COMBINE_OBJECT_COLOR, TextureAttributes.COMBINE_TEXTURE_COLOR, TextureAttributes.COMBINE_CONSTANT_COLOR, TextureAttributes.COMBINE_PREVIOUS_TEXTURE_UNIT_STATE.

getTextureCombineRGBFunction

public int[] getTextureCombineRGBFunction()
Return the Texture Combine RGB Function.

Returns:
the Texture Combine RGB Function between TextureAttributes.COMBINE_SRC_COLOR, TextureAttributes.COMBINE_ONE_MINUS_SRC_COLOR, TextureAttributes.COMBINE_SRC_ALPHA, TextureAttributes.COMBINE_ONE_MINUS_SRC_ALPHA.

setTextureCombineRGBFunction

public void setTextureCombineRGBFunction(int c0,
                                         int c1,
                                         int c2,
                                         boolean init)
Set the Texture Combine RGB Function.

Parameters:
c0 - the Texture Combine RGB Function C0 between TextureAttributes.COMBINE_SRC_COLOR, TextureAttributes.COMBINE_ONE_MINUS_SRC_COLOR, TextureAttributes.COMBINE_SRC_ALPHA, TextureAttributes.COMBINE_ONE_MINUS_SRC_ALPHA.
c1 - the Texture Combine RGB Function C1 between TextureAttributes.COMBINE_SRC_COLOR, TextureAttributes.COMBINE_ONE_MINUS_SRC_COLOR, TextureAttributes.COMBINE_SRC_ALPHA, TextureAttributes.COMBINE_ONE_MINUS_SRC_ALPHA.
c2 - the Texture Combine RGB Function C2 between TextureAttributes.COMBINE_SRC_COLOR, TextureAttributes.COMBINE_ONE_MINUS_SRC_COLOR, TextureAttributes.COMBINE_SRC_ALPHA, TextureAttributes.COMBINE_ONE_MINUS_SRC_ALPHA.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateTextureCombineRGBFunction

private void updateTextureCombineRGBFunction(int[] s)
Internal update of the Texture Combine RGB Function Parameters and fire of an associated property.

Parameters:
s - the Texture Combine RGB Function (C0,C1,C2) between TextureAttributes.COMBINE_SRC_COLOR, TextureAttributes.COMBINE_ONE_MINUS_SRC_COLOR, TextureAttributes.COMBINE_SRC_ALPHA, TextureAttributes.COMBINE_ONE_MINUS_SRC_ALPHA.

getTextureCombineRGBScale

public int getTextureCombineRGBScale()
Return the Texture Combine RGB Scale.

Returns:
the Texture Combine RGB Scale.

setTextureCombineRGBScale

public void setTextureCombineRGBScale(int s,
                                      boolean init)
Set the Texture Combine RGB Scale.

Parameters:
s - the Texture Combine RGB Scale.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateTextureCombineRGBScale

private void updateTextureCombineRGBScale(int s)
Internal update of the Texture Combine RGB Scale Parameters and fire of an associated property.

Parameters:
s - the Texture Combine RGB Scale.

getTextureCombineAlphaMode

public int getTextureCombineAlphaMode()
Return the Texture Combine Alpha Mode.

Returns:
the Texture Combine Alpha Mode between TextureAttributes.COMBINE_REPLACE, TextureAttributes.COMBINE_MODULATE, TextureAttributes.COMBINE_ADD, TextureAttributes.COMBINE_ADD_SIGNED, TextureAttributes.COMBINE_SUBTRACT, TextureAttributes.COMBINE_INTERPOLATE, TextureAttributes.COMBINE_DOT3.

setTextureCombineAlphaMode

public void setTextureCombineAlphaMode(int m,
                                       boolean init)
Set the Texture Combine Alpha Mode/

Parameters:
m - the Texture Combine Alpha Mode between TextureAttributes.COMBINE_REPLACE, TextureAttributes.COMBINE_MODULATE, TextureAttributes.COMBINE_ADD, TextureAttributes.COMBINE_ADD_SIGNED, TextureAttributes.COMBINE_SUBTRACT, TextureAttributes.COMBINE_INTERPOLATE, TextureAttributes.COMBINE_DOT3.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateTextureCombineAlphaMode

private void updateTextureCombineAlphaMode(int m)
Internal update of the Texture Combine Alpha Mode Parameters and fire of an associated property.

Parameters:
m - the Texture Combine Alpha Mode between TextureAttributes.COMBINE_REPLACE, TextureAttributes.COMBINE_MODULATE, TextureAttributes.COMBINE_ADD, TextureAttributes.COMBINE_ADD_SIGNED, TextureAttributes.COMBINE_SUBTRACT, TextureAttributes.COMBINE_INTERPOLATE, TextureAttributes.COMBINE_DOT3.

getTextureCombineAlphaSource

public int[] getTextureCombineAlphaSource()
Return the Texture Combine Alpha Source.

Returns:
the Texture Combine Alpha Source between TextureAttributes.COMBINE_OBJECT_COLOR, TextureAttributes.COMBINE_TEXTURE_COLOR, TextureAttributes.COMBINE_CONSTANT_COLOR, TextureAttributes.COMBINE_PREVIOUS_TEXTURE_UNIT_STATE.

setTextureCombineAlphaSource

public void setTextureCombineAlphaSource(int c0,
                                         int c1,
                                         int c2,
                                         boolean init)
Set the Texture Combine Alpha Source.

Parameters:
c0 - the Texture Combine Alpha Source C0 between TextureAttributes.COMBINE_OBJECT_COLOR, TextureAttributes.COMBINE_TEXTURE_COLOR, TextureAttributes.COMBINE_CONSTANT_COLOR, TextureAttributes.COMBINE_PREVIOUS_TEXTURE_UNIT_STATE.
c1 - the Texture Combine Alpha Source C1 between TextureAttributes.COMBINE_OBJECT_COLOR, TextureAttributes.COMBINE_TEXTURE_COLOR, TextureAttributes.COMBINE_CONSTANT_COLOR, TextureAttributes.COMBINE_PREVIOUS_TEXTURE_UNIT_STATE.
c2 - the Texture Combine Alpha Source C2 between TextureAttributes.COMBINE_OBJECT_COLOR, TextureAttributes.COMBINE_TEXTURE_COLOR, TextureAttributes.COMBINE_CONSTANT_COLOR, TextureAttributes.COMBINE_PREVIOUS_TEXTURE_UNIT_STATE.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateTextureCombineAlphaSource

private void updateTextureCombineAlphaSource(int[] s)
Internal update of the Texture Combine Alpha Source Parameters and fire of an associated property.

Parameters:
s - the Texture Combine Alpha Source (C0,C1,C2) between TextureAttributes.COMBINE_OBJECT_COLOR, TextureAttributes.COMBINE_TEXTURE_COLOR, TextureAttributes.COMBINE_CONSTANT_COLOR, TextureAttributes.COMBINE_PREVIOUS_TEXTURE_UNIT_STATE.

getTextureCombineAlphaFunction

public int[] getTextureCombineAlphaFunction()
Return the Texture Combine Alpha Function.

Returns:
the Texture Combine Alpha Function between TextureAttributes.COMBINE_SRC_ALPHA, TextureAttributes.COMBINE_ONE_MINUS_SRC_ALPHA.

setTextureCombineAlphaFunction

public void setTextureCombineAlphaFunction(int c0,
                                           int c1,
                                           int c2,
                                           boolean init)
Set the Texture Combine Alpha Function.

Parameters:
c0 - the Texture Combine Alpha Function C0 between TextureAttributes.COMBINE_SRC_ALPHA, TextureAttributes.COMBINE_ONE_MINUS_SRC_ALPHA.
c1 - the Texture Combine Alpha Function C1 between TextureAttributes.COMBINE_SRC_ALPHA, TextureAttributes.COMBINE_ONE_MINUS_SRC_ALPHA.
c2 - the Texture Combine Alpha Function C2 between TextureAttributes.COMBINE_SRC_ALPHA, TextureAttributes.COMBINE_ONE_MINUS_SRC_ALPHA.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateTextureCombineAlphaFunction

private void updateTextureCombineAlphaFunction(int[] s)
Internal update of the Texture Combine Alpha Function Parameters and fire of an associated property.

Parameters:
s - the Texture Combine Alpha Function (C0,C1,C2) between TextureAttributes.COMBINE_SRC_ALPHA, TextureAttributes.COMBINE_ONE_MINUS_SRC_ALPHA.

getTextureCombineAlphaScale

public int getTextureCombineAlphaScale()
Return the Texture Combine Alpha Scale.

Returns:
the Texture Combine Alpha Scale.

setTextureCombineAlphaScale

public void setTextureCombineAlphaScale(int s,
                                        boolean init)
Set the Texture Combine Alpha Scale .

Parameters:
s - the Texture Combine Alpha Scale.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateTextureCombineAlphaScale

private void updateTextureCombineAlphaScale(int s)
Internal update of the Texture Combine Alpha Scale Parameters and fire of an associated property.

Parameters:
s - the Texture Combine Alpha Scale.

isTextureSet

public boolean isTextureSet()
Return the Texture Setting.

Returns:
true if the texture is used, false otherwise.

setTextureUse

public void setTextureUse(boolean b,
                          boolean init)
Set the Texture Setting.

Parameters:
b - true if the texture is used, false otherwise.
init - set to true if it replaces the init value. Ie the CANCEL button will set it to this value.

updateTextureUse

private void updateTextureUse(boolean b)
Internal update of the Texture Setting Parameters and fire of an associated property.

Parameters:
b - true if the texture is used, false otherwise.

main

public static void main(java.lang.String[] args)
A Main Exemple.



##################################################################

Appearance3DChooser v1.1

Copyright (C) 2009 Frederic Roudaut


This program is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful, but
WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
General Public License for more details.

###################################################################