Fork me
BeyondAR
Augmented Reality Framework for Android
 All Classes Functions Variables
com.beyondar.android.view.OnTouchBeyondarViewListener Interface Reference

On touch listener to detect when a BeyondarObject has been touched on the BeyondarGLSurfaceView. More...

Public Member Functions

void onTouchBeyondarView (MotionEvent event, BeyondarGLSurfaceView beyondarView)
 Use BeyondarGLSurfaceView#getBeyondarObjectsOnScreenCoordinates(float, float, java.util.ArrayList) to get the object touched:
More...
 

Detailed Description

On touch listener to detect when a BeyondarObject has been touched on the BeyondarGLSurfaceView.

Member Function Documentation

void com.beyondar.android.view.OnTouchBeyondarViewListener.onTouchBeyondarView ( MotionEvent  event,
BeyondarGLSurfaceView  beyondarView 
)

Use BeyondarGLSurfaceView#getBeyondarObjectsOnScreenCoordinates(float, float, java.util.ArrayList) to get the object touched:

float x = event.getX();
float y = event.getY();
ArrayList<BeyondarObject> geoObjects = new ArrayList<BeyondarObject>();
beyondarView.getARObjectOnScreenCoordinates(x, y, geoObjects);
...
Now we iterate the ArrayList. The first element will be the closest one to the user
...
Parameters
event
beyondarView

The documentation for this interface was generated from the following file: