Commit Graph

28 Commits

Author SHA1 Message Date
Mikolaj Wielgus 087d1deea0 router: Don't try to route around target dot
This was causing a panic, as it's not possible to route from *around* a
dot *into* the same dot.
2023-10-17 03:55:21 +00:00
Mikolaj Wielgus bfbad933e2 debug: Create and use `before_probe` observer for search visualization
Also changed `as_*`s to `into_*`s.
2023-10-13 04:00:01 +00:00
Mikolaj Wielgus 4e8e9298e6 astar: Probe neighbors before adding tem to queue 2023-10-12 00:19:38 +00:00
Mikolaj Wielgus af61a6b120 router: Rename `Route` to `Tracer` and simplify related code 2023-10-11 22:23:18 +00:00
Mikolaj Wielgus cc3b537b5c debug: Visualize A* running during interactive routing 2023-10-10 21:09:21 +00:00
Mikolaj Wielgus 7a06a9b02d router: Implement basic cursor following 2023-10-06 22:41:59 +00:00
Mikolaj Wielgus 5f37ff7616 Unroute path whose routing failed in the middle 2023-09-05 02:03:32 +02:00
Mikolaj Wielgus 7d76051cbf Route to goal immediately if a straight path exists at any vertex 2023-09-03 05:43:08 +02:00
Mikolaj Wielgus 73a831ba6d Visualize every routing search step 2023-09-03 01:56:46 +02:00
Mikolaj Wielgus c492bd1dda Parametrize routing using `RouteStrategy` trait 2023-09-02 06:05:13 +02:00
Mikolaj Wielgus bea6d84878 Implement `AstarStrategy` trait to not borrow A* context multiple times 2023-09-02 01:44:35 +02:00
Mikolaj Wielgus b5f9a5957a Route with A* step by step instead of only after A* 2023-09-01 01:35:48 +02:00
Mikolaj Wielgus cd5365c26f Pass `width` as an argument instead of holding it in `Route` 2023-08-31 21:17:25 +02:00
Mikolaj Wielgus e5ba7401c1 Move routing methods to the `Route` struct
Commented out shove/squeeze features for now.
2023-08-31 20:33:34 +02:00
Mikolaj Wielgus 9f201d2c3d Make `Head`, `Segbend`, `Bow` copyable
Having to move or borrow tem, especially `Head`, makes it really
difficult to appease the borrow checker.
2023-08-31 07:27:42 +02:00
Mikolaj Wielgus 1d5b428bf9 Split out drawing routines from `Router` into `Draw` 2023-08-30 06:34:56 +02:00
Mikolaj Wielgus 247b78087c Add methods to unroute or undraw segbends 2023-08-29 21:11:03 +02:00
Mikolaj Wielgus f2346eedb8 Run `cargo fix`
This hasn't cleaned up all the unused import, but it's a good start.
2023-08-29 05:02:45 +02:00
Mikolaj Wielgus ceef3a7fb7 Take `&impl Interior` argument in path removal method 2023-08-29 01:59:11 +02:00
Mikolaj Wielgus 47aadfcdd3 Introduce `Segbend`, a seg-dot-bend triple 2023-08-29 01:49:37 +02:00
Mikolaj Wielgus 79a26cb324 Split `Walk` trait into `Interior` and `Ends` traits 2023-08-28 22:54:03 +02:00
Mikolaj Wielgus 84a7f5d873 Make `Bow` don't borrow the graph 2023-08-28 19:17:57 +02:00
Mikolaj Wielgus 47b3ffba08 Some small improvements to iteration in graph and layout code 2023-08-28 04:12:25 +02:00
Mikolaj Wielgus 14f6b9f870 Implement basic A* routing 2023-08-27 21:14:42 +02:00
Mikolaj Wielgus 9196d95546 Triangulate only after drawing finishes
Otherwise we'll end up with the (not yet implemented) pathfinding
algorithm trying to route traces with themselves.
2023-08-26 22:25:01 +02:00
Mikolaj Wielgus a1afd19fcb Implement Petgraph's graph traits on a Spade's triangulation 2023-08-25 23:39:44 +02:00
Mikolaj Wielgus 658bb112c2 Move Delaunay triangulation to a new `Mesh` struct 2023-08-24 21:23:37 +02:00
Mikolaj Wielgus 8456259b38 Rename `Layout` to `Router`, `Mesh` to `Layout` 2023-08-24 03:32:50 +02:00