|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--roboplayer.core.memory.VisualInfo
This class represents visual memory. It not only read information from sensors, but it can be used to store information and estimate position for objects out of the view
Constructor Summary | |
VisualInfo(Body body,
Params params,
char side,
java.lang.String team)
|
Method Summary | |
ObjectInfo |
getBall()
|
double |
getDirection()
|
Polar |
getLandmark(java.lang.String name)
|
Polar |
getMyGoalPos()
|
ObjectInfo |
getNearestPlayer(Polar pos)
|
ObjectInfo |
getNearestTeammate(Polar pos)
This function looks for nearest player to specified position. |
Polar |
getOpponentGoalPos()
|
ObjectInfo |
getOpponentPlayer(double dir)
|
java.util.Enumeration |
getPlayers()
Return all players |
Polar |
getPolar(Vector2d pos)
This function returns polar coordinates of specified point |
Vector2d |
getPosition()
|
double |
getTurnAngle()
|
void |
onSee(java.lang.String info)
see message will be send to this function |
Vector2d |
positionFromPolar(Polar p)
This function calculates position from polar coordinates |
void |
updateSee()
This function updates state from old state. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public VisualInfo(Body body, Params params, char side, java.lang.String team)
Method Detail |
public void onSee(java.lang.String info)
SeeListener
onSee
in interface SeeListener
info
- see infopublic void updateSee()
updateSee
in interface SeeListener
public double getDirection()
public Vector2d getPosition()
public ObjectInfo getBall()
public Polar getOpponentGoalPos()
public Polar getMyGoalPos()
public java.util.Enumeration getPlayers()
public Vector2d positionFromPolar(Polar p)
public ObjectInfo getNearestPlayer(Polar pos)
public ObjectInfo getNearestTeammate(Polar pos)
pos
- Distance is calculated from this position
public ObjectInfo getOpponentPlayer(double dir)
public Polar getLandmark(java.lang.String name)
public double getTurnAngle()
public Polar getPolar(Vector2d pos)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |