2
* This file is part of Krita
4
* Copyright (c) 2006 Cyrille Berger <cberger@cberger.net>
5
* Copyright (c) 2010 Marc Pegon <pe.marc@free.fr>
7
* This program is free software; you can redistribute it and/or modify
8
* it under the terms of the GNU Lesser General Public License as published by
9
* the Free Software Foundation; version 2 of the License.
11
* This program is distributed in the hope that it will be useful,
12
* but WITHOUT ANY WARRANTY; without even the implied warranty of
13
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14
* GNU General Public License for more details.
16
* You should have received a copy of the GNU Lesser General Public License
17
* along with this program; if not, write to the Free Software
18
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
21
#ifndef KIS_PERSPECTIVETRANSFORM_WORKER_H
22
#define KIS_PERSPECTIVETRANSFORM_WORKER_H
24
#include "kis_types.h"
25
#include "krita_export.h"
30
#include <KoUpdater.h>
31
typedef QPointer<KoUpdater> KoUpdaterPtr;
33
class KRITAIMAGE_EXPORT KisPerspectiveTransformWorker : public QObject
39
KisPerspectiveTransformWorker(KisPaintDeviceSP dev, KisSelectionSP selection, const QPointF& topLeft, const QPointF& topRight, const QPointF& bottomLeft, const QPointF& bottomRight, KoUpdaterPtr progress);
40
KisPerspectiveTransformWorker(KisPaintDeviceSP dev, QRect r, QPointF center, double aX, double aY, double distance, KoUpdaterPtr progress);
42
~KisPerspectiveTransformWorker();
46
qint32 m_progressTotalSteps;
47
qint32 m_lastProgressReport;
48
qint32 m_progressStep;
49
double m_xcenter, m_ycenter, m_p, m_q;
50
QTransform m_transform;
51
KisPaintDeviceSP m_dev;
52
KoUpdaterPtr m_progress;
53
KisSelectionSP m_selection;
54
double m_matrix[3][3];