Package com.jogamp.newt.event
Class PinchToZoomGesture.ZoomEvent
- java.lang.Object
-
- java.util.EventObject
-
- com.jogamp.newt.event.NEWTEvent
-
- com.jogamp.newt.event.InputEvent
-
- com.jogamp.newt.event.GestureHandler.GestureEvent
-
- com.jogamp.newt.event.PinchToZoomGesture.ZoomEvent
-
- All Implemented Interfaces:
Serializable
- Enclosing class:
- PinchToZoomGesture
public static class PinchToZoomGesture.ZoomEvent extends GestureHandler.GestureEvent
AGestureHandler.GestureEventdenominating zoom.- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.jogamp.newt.event.InputEvent
InputEvent.InputClass, InputEvent.InputType
-
-
Field Summary
-
Fields inherited from class com.jogamp.newt.event.GestureHandler.GestureEvent
EVENT_GESTURE_DETECTED
-
Fields inherited from class com.jogamp.newt.event.InputEvent
ALT_GRAPH_MASK, ALT_MASK, AUTOREPEAT_MASK, BUTTON1_MASK, BUTTON2_MASK, BUTTON3_MASK, BUTTON4_MASK, BUTTON5_MASK, BUTTON6_MASK, BUTTON7_MASK, BUTTON8_MASK, BUTTON9_MASK, BUTTONALL_MASK, BUTTONLAST_MASK, CONFINED_MASK, CTRL_MASK, INVISIBLE_MASK, META_MASK, SHIFT_MASK
-
Fields inherited from class com.jogamp.newt.event.NEWTEvent
consumedTag
-
-
Constructor Summary
Constructors Constructor Description ZoomEvent(Object source, long when, int modifiers, GestureHandler handler, MouseEvent pe, float zoom, float delta, float scale)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description floatgetDelta()Delta to last zoom value lies within [-1..1].floatgetScale()Returns the scale used to determine thezoomand hence it'sdeltavalue, which semantics depends on thepointer type'sMouseEvent.PointerClass.floatgetZoom()Zoom value lies within [0..2], with 1 as 1:1.StringtoString()-
Methods inherited from class com.jogamp.newt.event.GestureHandler.GestureEvent
getHandler, getTrigger
-
Methods inherited from class com.jogamp.newt.event.InputEvent
getButtonDownCount, getButtonMask, getButtonsDown, getModifiers, getModifiersString, isAltDown, isAltGraphDown, isAnyButtonDown, isAutoRepeat, isButtonDown, isConfined, isControlDown, isInvisible, isMetaDown, isShiftDown, toString
-
Methods inherited from class com.jogamp.newt.event.NEWTEvent
getAttachment, getEventType, getWhen, isConsumed, setAttachment, setConsumed, toHexString
-
Methods inherited from class java.util.EventObject
getSource
-
-
-
-
Constructor Detail
-
ZoomEvent
public ZoomEvent(Object source, long when, int modifiers, GestureHandler handler, MouseEvent pe, float zoom, float delta, float scale)
-
-
Method Detail
-
getZoom
public final float getZoom()
Zoom value lies within [0..2], with 1 as 1:1.
-
getDelta
public final float getDelta()
Delta to last zoom value lies within [-1..1].
-
getScale
public final float getScale()
Returns the scale used to determine thezoomand hence it'sdeltavalue, which semantics depends on thepointer type'sMouseEvent.PointerClass.For
MouseEvent.PointerClass.Offscreen, the scale is usually1.0fand denominates an abstract value without association to a physical value.For
MouseEvent.PointerClass.Onscreen, the scale varies and denominates the divisor of the distance the finger[s] have moved on the screen. Hencescale * deltareproduces the screen distance in pixels the finger[s] have moved.
-
toString
public final String toString()
- Overrides:
toStringin classGestureHandler.GestureEvent
-
-