diff options
author | Erich Eckner <git@eckner.net> | 2023-07-10 21:08:59 +0200 |
---|---|---|
committer | Erich Eckner <git@eckner.net> | 2023-07-10 21:08:59 +0200 |
commit | c28a90f1385d9dee0d42e19f45971b7ca3792999 (patch) | |
tree | 2303e733fac09ba4811a04ca1d74d5a3fdb16db0 | |
parent | 1df33a8f13e06ef27fbd095e511909904adeda24 (diff) | |
download | units-c28a90f1385d9dee0d42e19f45971b7ca3792999.tar.xz |
lowlevelunit.pas: Matrix * Vektor
-rw-r--r-- | lowlevelunit.pas | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/lowlevelunit.pas b/lowlevelunit.pas index 59bad32..37a6267 100644 --- a/lowlevelunit.pas +++ b/lowlevelunit.pas @@ -88,6 +88,7 @@ operator * (x1,x2: tIntPoint): int64; inline; operator * (x1,x2: tInt64Point): int64; inline; operator * (x1,x2: tExtPoint): extended; inline; operator * (x1,x2: tExt3dPoint): extended; inline; +operator * (m: t2x2Extended; x: tExtPoint): tExtPoint; inline; function round(x: tExtPoint): tInt64Point; overload; function symmetrischModulo(x,m: tInt64Point): tInt64Point; overload; @@ -415,6 +416,14 @@ begin result:=x1['x']*x2['x'] + x1['y']*x2['y']; end; +operator * (m: t2x2Extended; x: tExtPoint): tExtPoint; +begin + result:=extPoint( + m['x']['x'] * x['x'] + m['x']['y'] * x['y'], + m['y']['x'] * x['x'] + m['y']['y'] * x['y'] + ); +end; + // allgemeine Funktionen ******************************************************* function round(x: tExtPoint): tInt64Point; |