Class TransformationStackImpl
java.lang.Object
org.scilab.forge.scirenderer.tranformations.TransformationStackImpl
- All Implemented Interfaces:
TransformationStack
- Author:
- Pierre Lando
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.scilab.forge.scirenderer.tranformations.TransformationStack
TransformationStack.TransformationStackEvent
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
addListener
(TransformationStackListener listener) Add a listener.void
clear()
Pop all matrix on the stack except identity.protected void
Fire a change event.peek()
Return the top transformation.pop()
Pop one matrix on the stack.void
push
(Transformation transformation) Push the given transformation on the stack.void
pushLeftMultiply
(Transformation transformation) Push the given transformation left time the peek on the stack.void
pushRightMultiply
(Transformation transformation) Push the given transformation right time the peek on the stack.void
removeListener
(TransformationStackListener listener) Remove a listener.
-
Constructor Details
-
TransformationStackImpl
public TransformationStackImpl()
-
-
Method Details
-
addListener
Description copied from interface:TransformationStack
Add a listener.- Specified by:
addListener
in interfaceTransformationStack
- Parameters:
listener
- added listener.
-
removeListener
Description copied from interface:TransformationStack
Remove a listener.- Specified by:
removeListener
in interfaceTransformationStack
- Parameters:
listener
- removed listener.
-
peek
Description copied from interface:TransformationStack
Return the top transformation.- Specified by:
peek
in interfaceTransformationStack
- Returns:
- the top transformation.
-
push
Description copied from interface:TransformationStack
Push the given transformation on the stack.- Specified by:
push
in interfaceTransformationStack
- Parameters:
transformation
- the given transformation.
-
pushRightMultiply
Description copied from interface:TransformationStack
Push the given transformation right time the peek on the stack.- Specified by:
pushRightMultiply
in interfaceTransformationStack
- Parameters:
transformation
- the given transformation.
-
pushLeftMultiply
Description copied from interface:TransformationStack
Push the given transformation left time the peek on the stack.- Specified by:
pushLeftMultiply
in interfaceTransformationStack
- Parameters:
transformation
- the given transformation.
-
pop
Description copied from interface:TransformationStack
Pop one matrix on the stack.- Specified by:
pop
in interfaceTransformationStack
- Returns:
- the popped matrix.
-
clear
public void clear()Description copied from interface:TransformationStack
Pop all matrix on the stack except identity.- Specified by:
clear
in interfaceTransformationStack
-
fireChanged
Fire a change event.- Parameters:
event
- the event.top
- the new top transformation.
-