Commit Graph

22 Commits

Author SHA1 Message Date
Mikolaj Wielgus 44c30caafe chore(licensing): add REUSE license headers to `**.{rs,md,toml}` files
I ran the following command in Fish shell:

```
reuse annotate --skip-unrecognised --copyright="Topola contributors" --license="MIT" **.{rs,md,toml}
```

The choice of year 2024 in the copyright statements is intentional.
2024-12-29 22:47:00 +01:00
Alain Emilia Anna Zscheile ba41ff6837 refactor: get rid of unnecessary bounds on struct generics 2024-12-12 16:38:26 +01:00
Alain Emilia Anna Zscheile 8a724dc5d2 chore: fix deprecation warnings about geo::EuclideanDistance 2024-12-12 06:54:37 +00:00
Alain Emilia Anna Zscheile 9e0bdb5bc7 refactor: various further refactorings (#128)
These optimize out unnecessary code duplication, reserve vector capacity beforehand by leveraging `Iterator`s and avoid unnecessary double-lookups into HashMaps.

Reviewed-on: https://codeberg.org/topola/topola/pulls/128
Co-authored-by: Alain Emilia Anna Zscheile <fogti+devel@ytrizja.de>
Co-committed-by: Alain Emilia Anna Zscheile <fogti+devel@ytrizja.de>
2024-12-11 14:13:21 +00:00
Mikolaj Wielgus d4a310a5c0 graph: disambiguate naming of different kinds of indices
Disambiguate between node indices and (teir inner) petgraph indices.
Rename "band index" to "band first seg index", as we identify bands by
teir first segs. Rename "trianvertex index" and "navvertex index"
respectively to "trianvertex node index" and "navvertex node index", as
these point to nodes on the geometry graph and only indirectly to
vertices on the vertex graph.
2024-06-18 15:30:33 +02:00
Mikolaj Wielgus a80dfc10be autorouter,router: shorten and clarify terminology
Rename "triangulation vertex" to just "trianvertex".
Rename "navigation vertex" to just "navvertex".

The standalone word "vertex" was overused and in some cases confusing.
2024-06-03 12:46:27 +02:00
Mikolaj Wielgus 1c09483873 autorouter: implement simple undo (untested, not in GUI yet) 2024-05-14 14:22:47 +02:00
Mikolaj Wielgus 68df579308 overlay: minimize ratsnest edge lengths 2024-04-22 18:06:42 +02:00
Mikolaj Wielgus 44bbb20e62 triangulation: for refs consistently use structs instead of tuples 2024-04-22 01:31:02 +02:00
Mikolaj Wielgus 8d59242f3f overlay,egui: impl. incomplete ratsnest generation and drawing
For now only doing Delaunay triangulation, then applying minimum
spanning tree (without properly working edge ordering yet).
2024-04-21 19:51:47 +02:00
Mikolaj Wielgus 47b8616a40 triangulation: move out and make independent of layout and drawing 2024-04-20 14:50:17 +02:00
Mikolaj Wielgus df23ea8398 router: move top-level files to own `router` module 2024-04-14 20:25:01 +00:00
Mikolaj Wielgus 9feb32955c drawing,layout: move zones upwards, from drawing to layout
This generally largely drawings from groupings. We need this because it
will be easier to handle all groupings on the level of layout as
continents and bands, which are groupings too, are to be tracked there.

There's a lot of rough edges when it comes to typing and contracts.
2024-04-11 18:07:08 +00:00
Mikolaj Wielgus ef823c1c27 board,layout: rename "layout" to "drawing", "board" to "layout" 2024-03-22 23:23:31 +00:00
Mikolaj Wielgus d2ff1826a0 layout: attach `Rules` storing design rules to `Layout` 2024-02-02 23:58:23 +00:00
Mikolaj Wielgus 9f42991032 layout,geometry: move some code from `Layout` to new `Geometry` struct 2024-01-27 15:33:17 +00:00
Mikolaj Wielgus 0c6190e235 cleanup,layout: make connectivity and geometry private and clean up 2024-01-13 22:55:54 +00:00
Mikolaj Wielgus 1af5b96768 deps,graph: split out to new geometry and connectivity graph modules
The geometry graph is where the layout's dots, segs, and bends are
stored. The connectivity graph is where information about connected
components and relations between tem (e.g. which ones are connected with
bands) and information common to all band primitives are stored.

This removes dependency on the Slab library. We may go back to it
sometime in the future if we decide to phase out usage of Petgraph's
`StableDiGraph`.
2024-01-13 20:36:25 +00:00
Mikolaj Wielgus 84d5f9c49e layout: implement almost working reworked squeezing-under
I've temporarily removed collision/infringement detection in
`.move_dot()` because it was a lot of effort to get it right. We'll deal
with this later.

There's a panic due to mesh edges not being generated properly from
loose bends. But this commit is already very large, so I'm going to fix
this in the next one.

There's also some nomenclature changes.
2023-12-19 02:22:55 +00:00
Mikolaj Wielgus 9fe591d4dc mesh: Make bends vertices, too 2023-11-06 23:22:00 +00:00
Mikolaj Wielgus d6163d3d44 triangulation: Parameterize to make independent from `Mesh` 2023-11-05 20:19:18 +00:00
Mikolaj Wielgus 8379470bb1 mesh: Split out `Mesh` into a new `Triangulation` struct
It will be possible for the mesh to contain additional vertices that
aren't part of the Delaunay triangulation. `Mesh` is now a wrapper over
`Triangulation` that implements the same traits, and will be later
adding its own vertices in addition to the ones from triangulation.
2023-11-04 22:49:20 +00:00