mirror of
https://codeberg.org/unspeaker/tek.git
synced 2025-12-06 11:46:41 +01:00
wip: fixed piano
This commit is contained in:
parent
86188b59db
commit
1b82a957aa
9 changed files with 100 additions and 105 deletions
|
|
@ -54,10 +54,6 @@ pub trait Area<N: Coordinate>: From<[N;4]> + Debug + Copy {
|
|||
let [x, y, w, h] = self.xywh();
|
||||
[(x + w / 2.into()).minus(n / 2.into()), y + h / 2.into(), n, 1.into()]
|
||||
}
|
||||
#[inline] fn center_xw (&self, n: N, m: N) -> [N;4] {
|
||||
let [x, y, w, h] = self.xywh();
|
||||
[(x + w / 2.into()).minus(n / 2.into()), y + h / 2.into(), n, 1.into()]
|
||||
}
|
||||
#[inline] fn center_y (&self, n: N) -> [N;4] {
|
||||
let [x, y, w, h] = self.xywh();
|
||||
[x + w / 2.into(), (y + h / 2.into()).minus(n / 2.into()), 1.into(), n]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue