Class CubicRotationTransition
java.lang.Object
org.eclipse.nebula.effects.stw.Transition
org.eclipse.nebula.effects.stw.transitions.CubicRotationTransition
public class CubicRotationTransition extends Transition
A cubic rotation effect. Showing two sides of a cube, the cube rotates from one
side to the other side.
-
Field Summary
Fields inherited from class org.eclipse.nebula.effects.stw.Transition
_fps, _T, _transitionManager, DEFAULT_FPS, DEFAULT_T, DIR_DOWN, DIR_LEFT, DIR_RIGHT, DIR_UP, IS_LINUX_OS, IS_MAC_OS
-
Constructor Summary
Constructors Constructor Description CubicRotationTransition(TransitionManager transitionManager)
This constructor creates a CubicRotationTransition with number of frames per second ofTransition.DEFAULT_FPS
and total transition time ofTransition.DEFAULT_T
milliseconds.CubicRotationTransition(TransitionManager transitionManager, long fps, long T)
This constructor creates a CubicRotationTransition with number of frames per second offps
and total transition time ofT
milliseconds. -
Method Summary
Modifier and Type Method Description protected void
endTransition(org.eclipse.swt.graphics.Image from, org.eclipse.swt.graphics.Image to, org.eclipse.swt.graphics.GC gc, double direction)
double
getQuality()
Returns a percentage representing the quality of image slicingprotected void
initTransition(org.eclipse.swt.graphics.Image from, org.eclipse.swt.graphics.Image to, org.eclipse.swt.graphics.GC gc, double direction)
void
setQuality(double quality)
Sets the quality of image slicing as a percentage in the interval from 0 to 100 inclusiveprotected void
stepTransition(long t, org.eclipse.swt.graphics.Image from, org.eclipse.swt.graphics.Image to, org.eclipse.swt.graphics.GC gc, double direction)
Methods inherited from class org.eclipse.nebula.effects.stw.Transition
doEvents, getFPS, getTotalTransitionTime, setFPS, setTotalTransitionTime, start
-
Constructor Details
-
CubicRotationTransition
This constructor creates a CubicRotationTransition with number of frames per second ofTransition.DEFAULT_FPS
and total transition time ofTransition.DEFAULT_T
milliseconds. It is similar to new CubicRotationTransition(transitionManager,Transition.DEFAULT_FPS
,Transition.DEFAULT_T
)- Parameters:
transitionManager
- the transition manager to be used to manage transitions
-
CubicRotationTransition
This constructor creates a CubicRotationTransition with number of frames per second offps
and total transition time ofT
milliseconds.- Parameters:
transitionManager
- the transition manager to be used to manage transitionsfps
- number of frames per secondT
- the total time the transition effect will take in milliseconds
-
-
Method Details
-
initTransition
protected void initTransition(org.eclipse.swt.graphics.Image from, org.eclipse.swt.graphics.Image to, org.eclipse.swt.graphics.GC gc, double direction)- Specified by:
initTransition
in classTransition
-
stepTransition
protected void stepTransition(long t, org.eclipse.swt.graphics.Image from, org.eclipse.swt.graphics.Image to, org.eclipse.swt.graphics.GC gc, double direction)- Specified by:
stepTransition
in classTransition
-
endTransition
protected void endTransition(org.eclipse.swt.graphics.Image from, org.eclipse.swt.graphics.Image to, org.eclipse.swt.graphics.GC gc, double direction)- Specified by:
endTransition
in classTransition
-
setQuality
public void setQuality(double quality)Sets the quality of image slicing as a percentage in the interval from 0 to 100 inclusive- Parameters:
quality
- is a percentage from 0 to 100 inclusive
-
getQuality
public double getQuality()Returns a percentage representing the quality of image slicing- Returns:
- a percentage representing the quality of image slicing
-