Qt 6.x
The Qt SDK
Loading...
Searching...
No Matches
qimagescale.cpp File Reference
#include <private/qimagescale_p.h>
#include <private/qdrawhelper_p.h>
#include <private/qimage_p.h>
#include "qimage.h"
#include "qcolor.h"
#include "qrgba64_p.h"
#include "qrgbafloat.h"
+ Include dependency graph for qimagescale.cpp:

Go to the source code of this file.

Namespaces

namespace  QImageScale
 

Functions

static const unsigned int ** QImageScale::qimageCalcYPoints (const unsigned int *src, int sw, int sh, int dh)
 
static int * QImageScale::qimageCalcXPoints (int sw, int dw)
 
static int * QImageScale::qimageCalcApoints (int s, int d, int up)
 
static QImageScaleInfoQImageScale::qimageFreeScaleInfo (QImageScaleInfo *isi)
 
static QImageScaleInfoQImageScale::qimageCalcScaleInfo (const QImage &img, int sw, int sh, int dw, int dh, char aa)
 
static void qt_qimageScaleAARGBA_up_x_down_y (QImageScaleInfo *isi, unsigned int *dest, int dw, int dh, int dow, int sow)
 
static void qt_qimageScaleAARGBA_down_x_up_y (QImageScaleInfo *isi, unsigned int *dest, int dw, int dh, int dow, int sow)
 
static void qt_qimageScaleAARGBA_down_xy (QImageScaleInfo *isi, unsigned int *dest, int dw, int dh, int dow, int sow)
 
template<typename T >
static void multithread_pixels_function (QImageScaleInfo *isi, int dh, const T &scaleSection)
 
static void qt_qimageScaleAARGBA_up_xy (QImageScaleInfo *isi, unsigned int *dest, int dw, int dh, int dow, int sow)
 
static void qt_qimageScaleAARGBA (QImageScaleInfo *isi, unsigned int *dest, int dw, int dh, int dow, int sow)
 
static void qt_qimageScaleAARGBA_helper (const unsigned int *pix, int xyap, int Cxy, int step, int &r, int &g, int &b, int &a)
 
static void qt_qimageScaleAARGB_up_x_down_y (QImageScaleInfo *isi, unsigned int *dest, int dw, int dh, int dow, int sow)
 
static void qt_qimageScaleAARGB_down_x_up_y (QImageScaleInfo *isi, unsigned int *dest, int dw, int dh, int dow, int sow)
 
static void qt_qimageScaleAARGB_down_xy (QImageScaleInfo *isi, unsigned int *dest, int dw, int dh, int dow, int sow)
 
static void qt_qimageScaleAARGB (QImageScaleInfo *isi, unsigned int *dest, int dw, int dh, int dow, int sow)
 
static void qt_qimageScaleAARGB_helper (const unsigned int *pix, int xyap, int Cxy, int step, int &r, int &g, int &b)
 
QImage qSmoothScaleImage (const QImage &src, int dw, int dh)
 

Function Documentation

◆ multithread_pixels_function()

template<typename T >
static void multithread_pixels_function ( QImageScaleInfo isi,
int  dh,
const T &  scaleSection 
)
inlinestatic

Definition at line 272 of file qimagescale.cpp.

References QSemaphore::acquire(), QThreadPool::contains(), QThread::currentThread(), i, Q_UNUSED, QThreadPoolPrivate::qtGuiInstance(), QSemaphore::release(), QImageScale::QImageScaleInfo::sh, QThreadPool::start(), and QImageScale::QImageScaleInfo::sw.

Referenced by qt_qimageScaleAARGB_down_x_up_y(), qt_qimageScaleAARGB_down_xy(), qt_qimageScaleAARGB_up_x_down_y(), qt_qimageScaleAARGBA_down_x_up_y(), qt_qimageScaleAARGBA_down_xy(), qt_qimageScaleAARGBA_up_x_down_y(), and qt_qimageScaleAARGBA_up_xy().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ qSmoothScaleImage()

QImage qSmoothScaleImage ( const QImage src,
int  dw,
int  dh 
)

Definition at line 1179 of file qimagescale.cpp.

References QImageScale::qimageCalcScaleInfo(), QImageScale::qimageFreeScaleInfo(), qt_fpColorPrecision(), qt_qimageScaleAARGB(), qt_qimageScaleAARGBA(), and qWarning.

Referenced by QImage::smoothScaled().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ qt_qimageScaleAARGB()

static void qt_qimageScaleAARGB ( QImageScaleInfo isi,
unsigned int *  dest,
int  dw,
int  dh,
int  dow,
int  sow 
)
static

Definition at line 984 of file qimagescale.cpp.

References qCpuHasFeature, qt_qimageScaleAARGB_down_x_up_y(), qt_qimageScaleAARGB_down_xy(), qt_qimageScaleAARGB_up_x_down_y(), qt_qimageScaleAARGBA_up_xy(), and QImageScale::QImageScaleInfo::xup_yup.

Referenced by qSmoothScaleImage().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ qt_qimageScaleAARGB_down_x_up_y()

static void qt_qimageScaleAARGB_down_x_up_y ( QImageScaleInfo isi,
unsigned int *  dest,
int  dw,
int  dh,
int  dow,
int  sow 
)
static

Definition at line 1090 of file qimagescale.cpp.

References multithread_pixels_function(), qRgb(), qt_qimageScaleAARGB_helper(), QImageScale::QImageScaleInfo::xapoints, QImageScale::QImageScaleInfo::xpoints, QImageScale::QImageScaleInfo::yapoints, and QImageScale::QImageScaleInfo::ypoints.

Referenced by qt_qimageScaleAARGB().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ qt_qimageScaleAARGB_down_xy()

static void qt_qimageScaleAARGB_down_xy ( QImageScaleInfo isi,
unsigned int *  dest,
int  dw,
int  dh,
int  dow,
int  sow 
)
static

Definition at line 1129 of file qimagescale.cpp.

References j, multithread_pixels_function(), qRgb(), qt_qimageScaleAARGB_helper(), rx(), QImageScale::QImageScaleInfo::xapoints, QImageScale::QImageScaleInfo::xpoints, QImageScale::QImageScaleInfo::yapoints, and QImageScale::QImageScaleInfo::ypoints.

Referenced by qt_qimageScaleAARGB().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ qt_qimageScaleAARGB_helper()

static void qt_qimageScaleAARGB_helper ( const unsigned int *  pix,
int  xyap,
int  Cxy,
int  step,
int &  r,
int &  g,
int &  b 
)
inlinestatic

Definition at line 1033 of file qimagescale.cpp.

References j, pix, qBlue(), qGreen(), and qRed().

Referenced by qt_qimageScaleAARGB_down_x_up_y(), qt_qimageScaleAARGB_down_xy(), and qt_qimageScaleAARGB_up_x_down_y().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ qt_qimageScaleAARGB_up_x_down_y()

static void qt_qimageScaleAARGB_up_x_down_y ( QImageScaleInfo isi,
unsigned int *  dest,
int  dw,
int  dh,
int  dow,
int  sow 
)
static

Definition at line 1051 of file qimagescale.cpp.

References multithread_pixels_function(), qRgb(), qt_qimageScaleAARGB_helper(), QImageScale::QImageScaleInfo::xapoints, QImageScale::QImageScaleInfo::xpoints, QImageScale::QImageScaleInfo::yapoints, and QImageScale::QImageScaleInfo::ypoints.

Referenced by qt_qimageScaleAARGB().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ qt_qimageScaleAARGBA()

static void qt_qimageScaleAARGBA ( QImageScaleInfo isi,
unsigned int *  dest,
int  dw,
int  dh,
int  dow,
int  sow 
)
static

Definition at line 340 of file qimagescale.cpp.

References qCpuHasFeature, qt_qimageScaleAARGBA_down_x_up_y(), qt_qimageScaleAARGBA_down_xy(), qt_qimageScaleAARGBA_up_x_down_y(), qt_qimageScaleAARGBA_up_xy(), and QImageScale::QImageScaleInfo::xup_yup.

Referenced by qSmoothScaleImage().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ qt_qimageScaleAARGBA_down_x_up_y()

static void qt_qimageScaleAARGBA_down_x_up_y ( QImageScaleInfo isi,
unsigned int *  dest,
int  dw,
int  dh,
int  dow,
int  sow 
)
static

Definition at line 450 of file qimagescale.cpp.

References multithread_pixels_function(), qRgba(), qt_qimageScaleAARGBA_helper(), QImageScale::QImageScaleInfo::xapoints, QImageScale::QImageScaleInfo::xpoints, QImageScale::QImageScaleInfo::yapoints, and QImageScale::QImageScaleInfo::ypoints.

Referenced by qt_qimageScaleAARGBA().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ qt_qimageScaleAARGBA_down_xy()

static void qt_qimageScaleAARGBA_down_xy ( QImageScaleInfo isi,
unsigned int *  dest,
int  dw,
int  dh,
int  dow,
int  sow 
)
static

Definition at line 492 of file qimagescale.cpp.

References j, multithread_pixels_function(), qRgba(), qt_qimageScaleAARGBA_helper(), rx(), QImageScale::QImageScaleInfo::xapoints, QImageScale::QImageScaleInfo::xpoints, QImageScale::QImageScaleInfo::yapoints, and QImageScale::QImageScaleInfo::ypoints.

Referenced by qt_qimageScaleAARGBA().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ qt_qimageScaleAARGBA_helper()

static void qt_qimageScaleAARGBA_helper ( const unsigned int *  pix,
int  xyap,
int  Cxy,
int  step,
int &  r,
int &  g,
int &  b,
int &  a 
)
inlinestatic

Definition at line 388 of file qimagescale.cpp.

References j, pix, qAlpha(), qBlue(), qGreen(), and qRed().

Referenced by qt_qimageScaleAARGBA_down_x_up_y(), qt_qimageScaleAARGBA_down_xy(), and qt_qimageScaleAARGBA_up_x_down_y().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ qt_qimageScaleAARGBA_up_x_down_y()

static void qt_qimageScaleAARGBA_up_x_down_y ( QImageScaleInfo isi,
unsigned int *  dest,
int  dw,
int  dh,
int  dow,
int  sow 
)
static

Definition at line 409 of file qimagescale.cpp.

References multithread_pixels_function(), qRgba(), qt_qimageScaleAARGBA_helper(), QImageScale::QImageScaleInfo::xapoints, QImageScale::QImageScaleInfo::xpoints, QImageScale::QImageScaleInfo::yapoints, and QImageScale::QImageScaleInfo::ypoints.

Referenced by qt_qimageScaleAARGBA().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ qt_qimageScaleAARGBA_up_xy()

static void qt_qimageScaleAARGBA_up_xy ( QImageScaleInfo isi,
unsigned int *  dest,
int  dw,
int  dh,
int  dow,
int  sow 
)
static

Definition at line 298 of file qimagescale.cpp.

References interpolate_4_pixels(), INTERPOLATE_PIXEL_256(), multithread_pixels_function(), pix, QImageScale::QImageScaleInfo::xapoints, QImageScale::QImageScaleInfo::xpoints, QImageScale::QImageScaleInfo::yapoints, and QImageScale::QImageScaleInfo::ypoints.

Referenced by qt_qimageScaleAARGB(), and qt_qimageScaleAARGBA().

+ Here is the call graph for this function:
+ Here is the caller graph for this function: