Commit Graph

95 Commits

Author SHA1 Message Date
Mikolaj Wielgus ea854abfc7 Revert "egui: perform routing in separate thread or task"
This reverts commit 4144ee361f.

Instead of mutexing the autorouter, we'll mutex the layout.
2024-05-04 15:03:36 +02:00
Mikolaj Wielgus 4144ee361f egui: perform routing in separate thread or task 2024-05-03 19:50:38 +02:00
Mikolaj Wielgus 682f179cad egui: draw bounding boxes 2024-05-03 02:42:42 +02:00
Mikolaj Wielgus 531bc6d22c autorouter: as a starter, route the endpoints of only the first ratline 2024-05-03 01:36:04 +02:00
Mikolaj Wielgus 9c332bdde3 egui: add "Autoroute" button
Not functional yet as I still haven't implemented
`Autorouter::autoroute()`
2024-05-02 18:53:43 +02:00
Mikolaj Wielgus ea22ba705c layout: create `Zone` struct for accessing zone properties 2024-05-01 20:57:49 +02:00
Mikolaj Wielgus c74e69a5e9 autorouter: move ratsnest to `Autorouter`, move overlay to egui module 2024-04-27 01:12:01 +02:00
Mikolaj Wielgus 81f9f82f40 overlay: move overlay to new autorouter module 2024-04-26 02:34:25 +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 8a6b0724e9 egui: highlight selected zones 2024-04-18 16:35:10 +02:00
Mikolaj Wielgus 43f1248a76 geometry: have a common `Shape` object for both primitives and compounds 2024-04-18 15:41:01 +02:00
Mikolaj Wielgus f2569c5167 layout: alias `Node` to not require generic parameters 2024-04-17 21:06:55 +02:00
Mikolaj Wielgus 4a9322d694 overlay: new module, impl. basic mouse selection of primitives
Only check for intersection of the AABB as a starter.
2024-04-16 00:21:18 +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 6932a698f6 geometry: rename `Shape*` to `PrimitiveShape*` 2024-04-10 01:34:18 +00:00
Mikolaj Wielgus 2d5998547a egui: paint zones (only convex ones work for now) 2024-04-08 21:52:15 +00:00
Mikolaj Wielgus 1362058db5 sdl2-demo: fix painting of zones
The Y coordinate was not inverted, and the zone polygon would not get
closed.
2024-04-06 01:55:58 +00:00
Mikolaj Wielgus 36e029012f sdl2-demo: implement painting of zones (untested) 2024-04-04 13:58:29 +00:00
Mikolaj Wielgus 3a812d5621 geometry: implement incomplete interface for manipulation of groupings 2024-03-26 20:24:15 +00:00
Mikolaj Wielgus e23f7de07e drawing: use `None` instead of negative values to denote no net 2024-03-24 16:34:50 +00:00
Mikolaj Wielgus ef823c1c27 board,layout: rename "layout" to "drawing", "board" to "layout" 2024-03-22 23:23:31 +00:00
Mikolaj Wielgus d58bff85fe dsn: don't flip y coord on import, do so when rendering 2024-03-17 13:58:29 +00:00
Mikolaj Wielgus 74d10f4a9e layout,sdl2-demo,egui: basic support for displaying two layers 2024-03-14 21:51:29 +00:00
Mikolaj Wielgus d8e128e81a egui: actually load and display the layout 2024-03-09 17:03:05 +00:00
Tomasz Cichoń b661047ca8 sdl2-demo: fix envelope/mesh sizes 2024-03-08 13:07:46 +01:00
Tomasz Cichoń 12574712a4 dsn: remove temporary scaling factor
The binary targets have zooming and no longer need it for display.
2024-03-08 10:12:31 +01:00
Tomasz Cichoń 23fe001647 tests: add export of prerouted_lm317_breakout
The file can now be parsed and partially loaded into Layout.
2024-03-08 09:09:38 +01:00
Tomasz Cichoń fb6922a5e5 sdl2-demo: add zooming/panning 2024-03-08 08:55:30 +01:00
Tomasz Cichoń 6bbbc368c6 dsn: refactor the parser/serializer to allow enums
This cleans up and defines new types in structure.rs as well.
2024-03-08 05:06:00 +01:00
Mikolaj Wielgus 8a56a16528 egui: implement zooming in/out to a point 2024-03-05 20:02:16 +00:00
Mikolaj Wielgus 4959f3512b egui: implement moving the canvas horizontally and vertically 2024-03-05 18:51:17 +00:00
Mikolaj Wielgus b43111030e egui: implement basic interactive zooming 2024-03-05 12:56:44 +00:00
Mikolaj Wielgus e50fb26bdd egui: make the WASM port actually work 2024-03-02 16:09:01 +00:00
Mikolaj Wielgus fd4eb0b4dd egui: implement basic input file selection from dialog
Imported layout is not displayed yet.
2024-03-02 06:54:12 +00:00
Mikolaj Wielgus d5d26cdaeb tests: add prerouted LM317 breakout board project for testing
Will add some tests for it in later commits.
2024-03-01 11:13:04 +00:00
Mikolaj Wielgus 2f6b40410c board: make layout private
Also add board/ directory, as I forgot to add it in the previous commit.
2024-02-29 02:28:15 +00:00
Mikolaj Wielgus 8d55fbc837 layout: move connectivity to new superordinate `Board` struct
This is very rudimentary (merely compiles and doesn't panic). Routing is
unlikely to work at the moment. I'll be fixing all this in subsequent
commits.
2024-02-28 09:24:49 +00:00
Tomasz Cichoń b53dc62df3 rules: implement `RulesTrait` for rules imported from DSN 2024-02-28 04:17:59 +01:00
Mikolaj Wielgus 7f69ffddf9 geometry: move geometry module to from layout to root
As we'll be creating a deeper hierarchy of modules subordinate to
layout, we need to keep the module full paths short to prevent tem from
growing uncontrollably.
2024-02-26 19:16:40 +00:00
Tomasz Cichoń 2014be1004 dsn: add loading of simple images containing pins 2024-02-23 03:52:07 +01:00
Mikolaj Wielgus 473a877845 dsn: encapsulate DSN structure in new `DsnDesign` struct
Using a placeholder instead of rules and disabled routing for now. Also
did some formatting corrections.
2024-02-22 04:49:55 +00:00
Tomasz Cichoń 3f6bad2ed6 dsn, sdl2-demo: replace hardcoded layout with basic .dsn file 2024-02-21 19:22:05 +01:00
Mikolaj Wielgus 08c03a0e77 egui: implement painting of shapes 2024-02-21 16:29:58 +00:00
Mikolaj Wielgus f10f7b7ab4 cargo: rename topola-gui to topola-egui, minor refactoring 2024-02-20 04:18:19 +00:00
Mikolaj Wielgus f2c2dca4be cargo: introduce topola-gui binary crate 2024-02-19 03:17:38 +00:00