diff --git a/libs/image/kis_vec.h b/libs/image/kis_vec.h index f7c34750a8..624e031ff8 100644 --- a/libs/image/kis_vec.h +++ b/libs/image/kis_vec.h @@ -1,61 +1,46 @@ /* * kis_vec.h - part of KImageShop * * Copyright (c) 1999 Matthias Elter * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ #ifndef __kis_vec_h__ #define __kis_vec_h__ #include #include #include typedef Eigen::Matrix KisVector2D; -typedef Eigen::Matrix KisVector3D; inline KisVector2D toKisVector2D(const QPointF& p) { return KisVector2D(p.x(), p.y()); } inline KisVector2D toKisVector2D(const QPoint& p) { return KisVector2D(p.x(), p.y()); } template inline QPointF toQPointF(const ExpressionType& expr) { return QPointF(expr.x(), expr.y()); } -template -inline QVector2D toQVector2D(const ExpressionType& expr){ - return QVector2D(expr.x(), expr.y()); -} - -inline KisVector2D nullKisVector2D() -{ - KisVector2D v; - v(0) = 0.0; - v(1) = 0.0; - return v; -} - - #endif diff --git a/libs/image/tests/kis_vec_test.cpp b/libs/image/tests/kis_vec_test.cpp index 8dfc4b3d74..588059c3d0 100644 --- a/libs/image/tests/kis_vec_test.cpp +++ b/libs/image/tests/kis_vec_test.cpp @@ -1,47 +1,32 @@ /* * Copyright (c) 2007 Boudewijn Rempt boud@valdyas.org * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ #include "kis_vec_test.h" #include #include "kis_vec.h" void KisVecTest::testCreation() { KisVector2D v2d = KisVector2D::Zero(); QVERIFY(v2d.x() == 0.0); QVERIFY(v2d.y() == 0.0); - - KisVector3D v3d = KisVector3D::Zero(); - QVERIFY(v3d.x() == 0.0); - QVERIFY(v3d.y() == 0.0); - QVERIFY(v3d.z() == 0.0); -} - - -void KisVecTest::testVec2D() -{ -} - - -void KisVecTest::testVec3D() -{ } QTEST_MAIN(KisVecTest) diff --git a/libs/image/tests/kis_vec_test.h b/libs/image/tests/kis_vec_test.h index 714e14582b..19f0388122 100644 --- a/libs/image/tests/kis_vec_test.h +++ b/libs/image/tests/kis_vec_test.h @@ -1,35 +1,33 @@ /* * Copyright (c) 2007 Boudewijn Rempt boud@valdyas.org * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. */ #ifndef KIS_VEC_TEST_H #define KIS_VEC_TEST_H #include class KisVecTest : public QObject { Q_OBJECT private Q_SLOTS: void testCreation(); - void testVec2D(); - void testVec3D(); }; #endif