Kstars

matr.h
1/*
2 SPDX-FileCopyrightText: 2012 Andrew Stepanenko
3
4 Modified by Jasem Mutlaq <mutlaqja@ikarustech.com> for KStars:
5 SPDX-FileCopyrightText: 2012 Jasem Mutlaq <mutlaqja@ikarustech.com>
6
7 SPDX-License-Identifier: GPL-2.0-or-later
8*/
9
10#pragma once
11
12#include "vect.h"
13
14namespace GuiderUtils
15{
16class Matrix
17{
18 public:
19 double x[4][4];
20 Matrix();
21 explicit Matrix(double);
22 Matrix &operator+=(const Matrix &);
23 Matrix &operator-=(const Matrix &);
24 Matrix &operator*=(const Matrix &);
25 Matrix &operator*=(double);
26 Matrix &operator/=(double);
27 void Invert();
28 void Transpose();
29 friend Matrix operator+(const Matrix &, const Matrix &);
30 friend Matrix operator-(const Matrix &, const Matrix &);
31 friend Matrix operator*(const Matrix &, double);
32 friend Matrix operator*(const Matrix &, const Matrix &);
33 friend GuiderUtils::Vector operator*(const GuiderUtils::Vector &, const Matrix &);
34};
35
36Matrix Translate(const GuiderUtils::Vector &);
37Matrix Scale(const GuiderUtils::Vector &);
38Matrix RotateX(double);
39Matrix RotateY(double);
40Matrix RotateZ(double);
41Matrix Rotate(const GuiderUtils::Vector &v, double angle);
42Matrix Transform(const GuiderUtils::Vector &v1, const GuiderUtils::Vector &v2, const GuiderUtils::Vector &v3);
43Matrix MirrorX();
44Matrix MirrorY();
45Matrix MirrorZ();
46} // namespace GuiderUtils
47
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Tue Mar 26 2024 11:19:02 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006

KDE's Doxygen guidelines are available online.