edu.dhbw.andar
Class ARObject
java.lang.Object
edu.dhbw.andar.ARObject
- Direct Known Subclasses:
- CustomObject
public abstract class ARObject
- extends java.lang.Object
- Author:
- tobi
Constructor Summary |
ARObject(java.lang.String name,
java.lang.String patternName,
double markerWidth,
double[] markerCenter)
Create a new AR object. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ARObject
public ARObject(java.lang.String name,
java.lang.String patternName,
double markerWidth,
double[] markerCenter)
- Create a new AR object.
- Parameters:
name
- the name of the the object, an arbitrary stringpatternName
- the file name of the pattern(the file must reside in the res/raw folder)markerWidth
- markerCenter
-
getMarkerWidth
public double getMarkerWidth()
getCenter
public double[] getCenter()
getId
public int getId()
getPatternName
public java.lang.String getPatternName()
isVisible
public boolean isVisible()
- Returns:
- Is this object visible? -> is the marker belonging to this object visible?
getTransMatrix
public double[] getTransMatrix()
- Get the current translation matrix.
- Returns:
draw
public void draw(GL10 gl)
- Do OpenGL stuff.
Everything draw here will be drawn directly onto the marker.
TODO replace wrap by real floatbuffer
- Parameters:
gl
-
init
public abstract void init(GL10 gl)