This browser does not have a Java Plug-in.
Get the latest Java Plug-in here.

A-star / A* search

binarymillenium June 2008


The red dot is the goal, the green dot is the start, and the blue dot is the square currently being visited. Lighter blue small boxes show position that are queued for future visiting. The think green line is the current shortest route to the goal, if any. The thinning lines are alternate searched routes, which will terminate where the estimated cost to the goal plus the accumulated cost exceed the cost of the route that has already been found. Black boxes are impassable, while darker grey boxes on the grid are more costly than ligher grey or white boxes. Open the java console to see updates about the current best found path.

colormode(RGB,1.0) is broken with applet export, use the 0-255 int color mode instead.

Reload to see a new random cost map and start and goal points (TBD detect a mouse click to reinitialize).

more discussion

Source code: astar

Built with Processing