|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.metalev.multitouch.controller.MultiTouchController.PointInfo
public static class MultiTouchController.PointInfo
A class that packages up all MotionEvent information with all derived multitouch information (if available)
Constructor Summary | |
---|---|
MultiTouchController.PointInfo()
|
Method Summary | |
---|---|
int |
getAction()
|
long |
getEventTime()
|
float |
getMultiTouchAngle()
Calculate the angle of a multitouch event, and cache it. |
float |
getMultiTouchDiameter()
Calculate the diameter of the multitouch event, and cache it. |
float |
getMultiTouchDiameterSq()
Calculate the squared diameter of the multitouch event, and cache it. |
float |
getMultiTouchHeight()
Difference between y coords of touchpoint 0 and 1. |
float |
getMultiTouchWidth()
Difference between x coords of touchpoint 0 and 1. |
int |
getNumTouchPoints()
Return the total number of touch points |
int[] |
getPointerIds()
Return the array of pointer ids -- only the first getNumTouchPoints() of these is defined. |
float |
getPressure()
Return the pressure the first touch point if there's only one, or the average pressure of first and second touch points if two or more. |
float[] |
getPressures()
Return the array of pressures -- only the first getNumTouchPoints() of these is defined. |
float |
getX()
Return the X coord of the first touch point if there's only one, or the midpoint between first and second touch points if two or more. |
float[] |
getXs()
Return the array of X coords -- only the first getNumTouchPoints() of these is defined. |
float |
getY()
Return the X coord of the first touch point if there's only one, or the midpoint between first and second touch points if two or more. |
float[] |
getYs()
Return the array of Y coords -- only the first getNumTouchPoints() of these is defined. |
boolean |
isDown()
|
boolean |
isMultiTouch()
True if number of touch points >= 2. |
void |
set(MultiTouchController.PointInfo other)
Copy all fields from one PointInfo class to another. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public MultiTouchController.PointInfo()
Method Detail |
---|
public void set(MultiTouchController.PointInfo other)
public boolean isMultiTouch()
public float getMultiTouchWidth()
public float getMultiTouchHeight()
public float getMultiTouchDiameterSq()
public float getMultiTouchDiameter()
public float getMultiTouchAngle()
public int getNumTouchPoints()
public float getX()
public float[] getXs()
public float getY()
public float[] getYs()
public int[] getPointerIds()
public float getPressure()
public float[] getPressures()
public boolean isDown()
public int getAction()
public long getEventTime()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |