mirror of https://codeberg.org/topola/topola.git
fix(autorouter/ratline): Don't count ratlines with shared endpoint as intersecting
This commit is contained in:
parent
eb0ee25565
commit
b49aa9e1b7
|
|
@ -28,6 +28,7 @@ allowed_scopes = [
|
||||||
"autorouter/place_via",
|
"autorouter/place_via",
|
||||||
"autorouter/pointroute",
|
"autorouter/pointroute",
|
||||||
"autorouter/ratsnest",
|
"autorouter/ratsnest",
|
||||||
|
"autorouter/ratline",
|
||||||
"autorouter/remove_bands",
|
"autorouter/remove_bands",
|
||||||
"autorouter/selection",
|
"autorouter/selection",
|
||||||
"drawing/band",
|
"drawing/band",
|
||||||
|
|
|
||||||
|
|
@ -81,6 +81,25 @@ impl<'a, M: AccessMesadata> RatlineRef<'a, M> {
|
||||||
.ratsnest()
|
.ratsnest()
|
||||||
.graph()
|
.graph()
|
||||||
.edge_indices()
|
.edge_indices()
|
||||||
|
.filter(move |other| {
|
||||||
|
let (self_source, self_target) = self
|
||||||
|
.autorouter
|
||||||
|
.ratsnest
|
||||||
|
.graph()
|
||||||
|
.edge_endpoints(self.index)
|
||||||
|
.unwrap();
|
||||||
|
let (other_source, other_target) = self
|
||||||
|
.autorouter
|
||||||
|
.ratsnest
|
||||||
|
.graph()
|
||||||
|
.edge_endpoints(*other)
|
||||||
|
.unwrap();
|
||||||
|
|
||||||
|
self_source != other_source
|
||||||
|
&& self_source != other_target
|
||||||
|
&& self_target != other_source
|
||||||
|
&& self_target != other_target
|
||||||
|
})
|
||||||
.filter(move |other| {
|
.filter(move |other| {
|
||||||
let other_line = other.ref_(self.autorouter).line();
|
let other_line = other.ref_(self.autorouter).line();
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue