com.threerings.opengl.model.tools
Class ModelViewer
java.lang.Object
com.threerings.expr.DynamicScope
com.threerings.opengl.GlApp
com.threerings.opengl.GlCanvasApp
com.threerings.opengl.GlCanvasTool
com.threerings.opengl.model.tools.ModelTool
com.threerings.opengl.model.tools.ModelViewer
- All Implemented Interfaces:
- ConfigUpdateListener<ModelConfig>, EditorContext, Scope, ScopeUpdateListener, AlContext, Enqueueable, AnimationObserver, ModelObserver, GlContext, ActionListener, EventListener, ChangeListener
public class ModelViewer
- extends ModelTool
- implements ChangeListener, ConfigUpdateListener<ModelConfig>, ModelObserver
A simple model viewer application.
| Fields inherited from interface com.threerings.expr.Scope |
EPOCH, NOW |
|
Constructor Summary |
ModelViewer(String model)
Creates the model viewer with (optionally) the path to a model to load. |
| Methods inherited from class com.threerings.opengl.GlApp |
createSnapshot, enqueue, getApp, getCameraHandler, getClipProvider, getColorPository, getCompatibilityMode, getCompositor, getConfigManager, getImageCache, getMessageManager, getRenderEffects, getRenderer, getRenderScheme, getResourceManager, getScope, getShaderCache, getSoundManager, getStreamGain, setCameraHandler, setCompatibilityMode, setRenderEffects, setRenderer, setRenderScheme, xlate |
| Methods inherited from class com.threerings.expr.DynamicScope |
addListener, dispose, endCompoundUpdate, get, getParentScope, getScopeName, put, remove, removeListener, scopeUpdated, setParentScope, startCompoundUpdate, wasUpdated |
ModelViewer
public ModelViewer(String model)
- Creates the model viewer with (optionally) the path to a model to load.
main
public static void main(String[] args)
- The program entry point.
stateChanged
public void stateChanged(ChangeEvent event)
- Specified by:
stateChanged in interface ChangeListener
configUpdated
public void configUpdated(ConfigEvent<ModelConfig> event)
- Description copied from interface:
ConfigUpdateListener
- Called when a configuration has been updated.
- Specified by:
configUpdated in interface ConfigUpdateListener<ModelConfig>
animationStarted
public boolean animationStarted(Animation animation)
- Description copied from interface:
AnimationObserver
- Notes that an animation has started.
- Specified by:
animationStarted in interface AnimationObserver
- Returns:
- true to keep the observer in the list, false to remove it.
animationStopped
public boolean animationStopped(Animation animation,
boolean completed)
- Description copied from interface:
AnimationObserver
- Notifies the observer that the animation has stopped.
- Specified by:
animationStopped in interface AnimationObserver
completed - whether or not the animation ran to completion (as opposed to being
cancelled).
- Returns:
- true to keep the observer in the list, false to remove it.
modelCompleted
public boolean modelCompleted(Model model)
- Description copied from interface:
ModelObserver
- Notes that a model (such as a transient effect) has completed.
- Specified by:
modelCompleted in interface ModelObserver
- Returns:
- true to keep the observer in the list, false to remove it.
actionPerformed
public void actionPerformed(ActionEvent event)
- Specified by:
actionPerformed in interface ActionListener- Overrides:
actionPerformed in class ModelTool
Copyright © 2011. All Rights Reserved.