~smartboyhw/ubuntu/raring/calligra/2.6.0-0ubuntu1

« back to all changes in this revision

Viewing changes to krita/ui/canvas/kis_image_pyramid.h

  • Committer: Package Import Robot
  • Author(s): Philip Muškovac
  • Date: 2012-10-23 21:09:16 UTC
  • mfrom: (1.1.13)
  • Revision ID: package-import@ubuntu.com-20121023210916-m82w6zxnxhaxz7va
Tags: 1:2.5.90-0ubuntu1
* New upstream alpha release (LP: #1070436)
  - Add libkactivities-dev and libopenimageio-dev to build-depends
  - Add kubuntu_build_calligraactive.diff to build calligraactive by default
  - Add package for calligraauthor and move files that are shared between
    calligrawords and calligraauthor to calligrawords-common
* Document the patches
* Remove numbers from patches so they follow the same naming scheme as
  the rest of our patches.
* calligra-data breaks replaces krita-data (<< 1:2.5.3) (LP: #1071686)

Show diffs side-by-side

added added

removed removed

Lines of Context:
21
21
 
22
22
#include <QImage>
23
23
#include <QVector>
24
 
#include <QThreadPool>
 
24
#include <QThreadStorage>
25
25
 
26
26
#include <KoColorSpace.h>
27
27
#include <kis_image.h>
28
28
#include <kis_paint_device.h>
29
29
#include "kis_projection_backend.h"
30
30
 
 
31
class KisDisplayFilter;
 
32
 
31
33
class KisImagePyramid : QObject, public KisProjectionBackend
32
34
{
33
35
    Q_OBJECT
38
40
 
39
41
    void setImage(KisImageWSP newImage);
40
42
    void setImageSize(qint32 w, qint32 h);
41
 
    void setMonitorProfile(const KoColorProfile* monitorProfile);
 
43
    void setMonitorProfile(const KoColorProfile* monitorProfile, KoColorConversionTransformation::Intent renderingIntent, KoColorConversionTransformation::ConversionFlags conversionFlags);
 
44
 
 
45
    /// we don't own the display filter, it's the docker that owns it!
 
46
    void setDisplayFilter(KisDisplayFilter *displayFilter);
42
47
    void updateCache(const QRect &dirtyImageRect);
43
48
    void recalculateCache(KisPPUpdateInfoSP info);
44
49
 
47
52
 
48
53
    /**
49
54
     * Render the projection onto a QImage.
50
 
     * Color profiling accurs here
 
55
     * Color profiling occurs here
51
56
     */
52
57
    QImage convertToQImage(qreal scale,
53
58
                           const QRect& unscaledRect,
71
76
    void alignSourceRect(QRect& rect, qreal scale);
72
77
 
73
78
private:
74
 
    QVector<KisPaintDeviceSP> m_pyramid;
75
 
    //QThreadPool m_pyramidUpdater;
76
 
    KisImageWSP  m_originalImage;
77
 
    const KoColorProfile* m_monitorProfile;
78
 
    const KoColorSpace* m_monitorColorSpace;
79
 
    KoColorConversionTransformation::Intent m_renderingIntent;
80
 
 
81
 
    /**
82
 
     * Number of planes inside pyramid
83
 
     */
84
 
    qint32 m_pyramidHeight;
85
 
 
86
 
private:
 
79
 
87
80
    void retrieveImageData(const QRect &rect);
88
81
    void rebuildPyramid();
89
82
    void clearPyramid();
117
110
     */
118
111
    QImage convertToQImageFast(KisPaintDeviceSP paintDevice,
119
112
                               const QRect& unscaledRect);
 
113
 
 
114
private:
 
115
 
 
116
    QVector<KisPaintDeviceSP> m_pyramid;
 
117
    KisImageWSP  m_originalImage;
 
118
 
 
119
    const KoColorProfile* m_monitorProfile;
 
120
    const KoColorSpace* m_monitorColorSpace;
 
121
 
 
122
    KisDisplayFilter *m_displayFilter;
 
123
 
 
124
    KoColorConversionTransformation::Intent m_renderingIntent;
 
125
    KoColorConversionTransformation::ConversionFlags m_conversionFlags;
 
126
 
 
127
 
 
128
    /**
 
129
     * Number of planes inside pyramid
 
130
     */
 
131
    qint32 m_pyramidHeight;
 
132
 
120
133
};
121
134
 
122
135
#endif /* __KIS_IMAGE_PYRAMID */