org.mt4j.components.interfaces
Interface IMTComponent

All Known Subinterfaces:
IdragClusterable, IMTComponent3D
All Known Implementing Classes:
AbstractShape, AbstractVisibleComponent, BitmapFontCharacter, Cluster, MTBackgroundImage, MTCanvas, MTClipRectangle, MTClipRoundRect, MTColorPicker, MTComponent, MTCube, MTEllipse, MTImage, MTImageButton, MTKey, MTKeyboard, MTLine, MTList, MTListCell, MTMovieClip, MTOverlayContainer, MTPolygon, MTProgressBar, MTRectangle, MTRoundRectangle, MTSceneMenu, MTSceneTexture, MTSceneWindow, MTSlider, MTSphere, MTStencilPolygon, MTSvg, MTSvgButton, MTTextArea, MTTextField, MTTextKeyboard, MTTriangleMesh, MTWindow, PhysicsCircle, PhysicsPolygon, PhysicsRectangle, PhysicsSphere, TouchTailComponent, VectorFontCharacter

public interface IMTComponent

The Interface IMTComponent.

Author:
Christopher Ruff

Method Summary
 boolean containsPointGlobal(Vector3D testPoint)
          Checks whether this, or this component's children contains the specified point.
 void drawComponent(processing.core.PGraphics g)
          Draws this component.
 int getID()
          Gets the iD.
 java.lang.String getName()
          Gets the name.
 processing.core.PApplet getRenderer()
          Gets the renderer.
 boolean isEnabled()
          Checks if the component is enabled.
 boolean isGestureAllowed(java.lang.Class c)
          Checks if the gesture is allowed on this component.
 boolean isVisible()
          Checks if the component is visible.
 boolean processInputEvent(MTInputEvent inEvt)
          Processes the input event.
 void rotateZGlobal(Vector3D rotationPoint, float degree)
          Rotates the component around its z-axis and the rotation point (in world coordiantes).
 void scaleGlobal(float factorX, float factorY, float factorZ, Vector3D scalingPoint)
          Scales the component in world from the scalingpoint (in world coordiantes) in the 3 axis.
 void setEnabled(boolean enabled)
          Sets the component enabled.
 void setName(java.lang.String name)
          Sets the name of the component.
 void setVisible(boolean visible)
          Sets the visibility.
 void translateGlobal(Vector3D directionVect)
          Translates the object in the given direction relative to the global world coordinate frame.
 void updateComponent(long timeDelta)
          Updates the component.
 

Method Detail

rotateZGlobal

void rotateZGlobal(Vector3D rotationPoint,
                   float degree)
Rotates the component around its z-axis and the rotation point (in world coordiantes).

Parameters:
rotationPoint - the rotation point
degree - the degree

translateGlobal

void translateGlobal(Vector3D directionVect)
Translates the object in the given direction relative to the global world coordinate frame.

Parameters:
directionVect - the direction vect

scaleGlobal

void scaleGlobal(float factorX,
                 float factorY,
                 float factorZ,
                 Vector3D scalingPoint)
Scales the component in world from the scalingpoint (in world coordiantes) in the 3 axis.

Parameters:
factorX - the factor x
factorY - the factor y
factorZ - the factor z
scalingPoint - the scaling point

drawComponent

void drawComponent(processing.core.PGraphics g)
Draws this component. (Not its children)

Parameters:
g - the g

updateComponent

void updateComponent(long timeDelta)
Updates the component.

Parameters:
timeDelta - the time delta

getID

int getID()
Gets the iD.

Returns:
the iD

getName

java.lang.String getName()
Gets the name.

Returns:
the name the name of this component

setName

void setName(java.lang.String name)
Sets the name of the component.

Parameters:
name - the new name

getRenderer

processing.core.PApplet getRenderer()
Gets the renderer.

Returns:
the renderer

isEnabled

boolean isEnabled()
Checks if the component is enabled.

Returns:
true, if is enabled

setEnabled

void setEnabled(boolean enabled)
Sets the component enabled. If enabled, the component will process input events.

Parameters:
enabled - the new enabled

isVisible

boolean isVisible()
Checks if the component is visible.

Returns:
true, if is visible

setVisible

void setVisible(boolean visible)
Sets the visibility.

Parameters:
visible - the new visible

containsPointGlobal

boolean containsPointGlobal(Vector3D testPoint)
Checks whether this, or this component's children contains the specified point. The point is assumed to be in global space coordinates.

Parameters:
testPoint - the test point
Returns:
true, if successful

isGestureAllowed

boolean isGestureAllowed(java.lang.Class c)
Checks if the gesture is allowed on this component.

Parameters:
c - The Class of the InputAnalyzer (Gesture Analyzer)
Returns:
true, if this gesture is allowed

processInputEvent

boolean processInputEvent(MTInputEvent inEvt)
Processes the input event.

Parameters:
inEvt - the in evt
Returns:
true, if successful