projects
/
ses.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8d676cb
)
__ses_setc_xy()
author
yu.dongliang
<18588496441@163.com>
Tue, 31 Oct 2023 08:28:41 +0000
(16:28 +0800)
committer
yu.dongliang
<18588496441@163.com>
Tue, 31 Oct 2023 08:28:41 +0000
(16:28 +0800)
ses_layout.c
patch
|
blob
|
blame
|
history
diff --git
a/ses_layout.c
b/ses_layout.c
index 4d22bd84ea1184c59f16ca3d462aa5b3ffbd957d..db8603403b57b2b113260f78fc2635093a69f593 100644
(file)
--- a/
ses_layout.c
+++ b/
ses_layout.c
@@
-854,12
+854,19
@@
static void __ses_setc_xy(ScfEfunction* f, int d)
c->y = (p0->y + p1->y) / 2;
p0->x = c->x;
- p1->x = c->x;
- for (j = 2; j < c->n_pins; j++) {
+ if (2 == c->n_pins) {
+ p1->x = c->x;
+ continue;
+ }
+
+ for (j = 1; j < c->n_pins; j++) {
p0 = c->pins[j];
- p0->x = (p0->x + 3 * c->x) / 4;
+ if (j & 0x1)
+ p0->x = c->x - d / 3;
+ else
+ p0->x = c->x + d / 3;
}
}
}