57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
|
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
|
+
+
+
+
-
-
-
+
-
-
-
|
qreal paintedHeight() const;
public slots:
/// Set the source image.
void setSource(BaseImage* source);
protected slots:
/// Set the result image.
void setImage(const QImage& image);
signals:
/// The source image has been changed.
void sourceChanged();
/// The image is about to be changed.
void imageChanging();
/// The image has been changed.
void imageChanged();
void paintedSizeChanged();
void startTransform(const QImage& image);
protected:
/// Called to apply this image's transformation to `image`.
///
/// This method may be called asynchronously.
virtual QImage transform(const QImage& image) = 0;
protected slots:
/// Called to trigger a new transformation when the source image had been changed.
void updateImage();
virtual void updateImage();
private slots:
void finishTransform(const QImage& image);
private:
struct Data;
QScopedPointer<Data> d;
friend class BaseImageTransformWorker;
};
|