colecody27 / Graph-Lab

https://graph-lab.vercel.app
0 stars 0 forks source link

Get or set vertice positions #23

Closed colecody27 closed 5 months ago

colecody27 commented 5 months ago

Currently the graph positions the vertices at random. Each vertice is already generated with an x and y position and the heuristic cost is generated using the the straight line distance from each vertice to the goal. In order to have an accurate heuristic costs, the vertices need to be positioned at the provided x and y coordinates.

OR

Once the graph visualization is generated, get the coordinates and calculate the heuristic cost based on them.

https://js.cytoscape.org/#collection/position--dimensions