mirror of
https://bitbucket.org/smil3y/katie.git
synced 2025-02-25 11:22:58 +00:00
remove unused qt_blurImage() argument
Signed-off-by: Ivailo Monev <xakepa10@laimg.moc>
This commit is contained in:
parent
ebfc0dc2f5
commit
790b7eb42c
1 changed files with 25 additions and 43 deletions
|
@ -381,7 +381,7 @@ inline void qt_blurrow(QImage & im, int line, int alpha)
|
|||
* zR,zG,zB and zA in fp format 8.zprec
|
||||
*/
|
||||
template <int aprec, int zprec, bool alphaOnly>
|
||||
void expblur(QImage &img, qreal radius, bool improvedQuality = false, int transposed = 0)
|
||||
void expblur(QImage &img, qreal radius, bool improvedQuality = false)
|
||||
{
|
||||
// halve the radius if we're using two passes
|
||||
if (improvedQuality)
|
||||
|
@ -406,7 +406,6 @@ void expblur(QImage &img, qreal radius, bool improvedQuality = false, int transp
|
|||
}
|
||||
|
||||
QImage temp(img.height(), img.width(), img.format());
|
||||
if (transposed >= 0) {
|
||||
if (img.depth() == 8) {
|
||||
qt_memrotate270(reinterpret_cast<const quint8*>(img.bits()),
|
||||
img.width(), img.height(), img.bytesPerLine(),
|
||||
|
@ -418,19 +417,6 @@ void expblur(QImage &img, qreal radius, bool improvedQuality = false, int transp
|
|||
reinterpret_cast<quint32*>(temp.bits()),
|
||||
temp.bytesPerLine());
|
||||
}
|
||||
} else {
|
||||
if (img.depth() == 8) {
|
||||
qt_memrotate90(reinterpret_cast<const quint8*>(img.bits()),
|
||||
img.width(), img.height(), img.bytesPerLine(),
|
||||
reinterpret_cast<quint8*>(temp.bits()),
|
||||
temp.bytesPerLine());
|
||||
} else {
|
||||
qt_memrotate90(reinterpret_cast<const quint32*>(img.bits()),
|
||||
img.width(), img.height(), img.bytesPerLine(),
|
||||
reinterpret_cast<quint32*>(temp.bits()),
|
||||
temp.bytesPerLine());
|
||||
}
|
||||
}
|
||||
|
||||
img_height = temp.height();
|
||||
for (int row = 0; row < img_height; ++row) {
|
||||
|
@ -438,7 +424,6 @@ void expblur(QImage &img, qreal radius, bool improvedQuality = false, int transp
|
|||
qt_blurrow<aprec, zprec, alphaOnly>(temp, row, alpha);
|
||||
}
|
||||
|
||||
if (transposed == 0) {
|
||||
if (img.depth() == 8) {
|
||||
qt_memrotate90(reinterpret_cast<const quint8*>(temp.bits()),
|
||||
temp.width(), temp.height(), temp.bytesPerLine(),
|
||||
|
@ -450,9 +435,6 @@ void expblur(QImage &img, qreal radius, bool improvedQuality = false, int transp
|
|||
reinterpret_cast<quint32*>(img.bits()),
|
||||
img.bytesPerLine());
|
||||
}
|
||||
} else {
|
||||
img = temp;
|
||||
}
|
||||
}
|
||||
#define AVG(a,b) ( ((((a)^(b)) & 0xfefefefeUL) >> 1) + ((a)&(b)) )
|
||||
#define AVG16(a,b) ( ((((a)^(b)) & 0xf7deUL) >> 1) + ((a)&(b)) )
|
||||
|
@ -545,7 +527,7 @@ static QImage qt_halfScaled(const QImage &source)
|
|||
return dest;
|
||||
}
|
||||
|
||||
static void qt_blurImage(QPainter *p, QImage &blurImage, qreal radius, bool quality, bool alphaOnly, int transposed = 0)
|
||||
static void qt_blurImage(QPainter *p, QImage &blurImage, qreal radius, bool quality, bool alphaOnly)
|
||||
{
|
||||
if (blurImage.format() != QImage::Format_ARGB32_Premultiplied
|
||||
&& blurImage.format() != QImage::Format_RGB32)
|
||||
|
@ -561,9 +543,9 @@ static void qt_blurImage(QPainter *p, QImage &blurImage, qreal radius, bool qual
|
|||
}
|
||||
|
||||
if (alphaOnly)
|
||||
expblur<12, 10, true>(blurImage, radius, quality, transposed);
|
||||
expblur<12, 10, true>(blurImage, radius, quality);
|
||||
else
|
||||
expblur<12, 10, false>(blurImage, radius, quality, transposed);
|
||||
expblur<12, 10, false>(blurImage, radius, quality);
|
||||
|
||||
if (p) {
|
||||
p->scale(scale, scale);
|
||||
|
@ -571,12 +553,12 @@ static void qt_blurImage(QPainter *p, QImage &blurImage, qreal radius, bool qual
|
|||
}
|
||||
}
|
||||
|
||||
static void qt_blurImage(QImage &blurImage, qreal radius, bool quality, int transposed = 0)
|
||||
static void qt_blurImage(QImage &blurImage, qreal radius, bool quality)
|
||||
{
|
||||
if (blurImage.format() == QImage::Format_Indexed8)
|
||||
expblur<12, 10, true>(blurImage, radius, quality, transposed);
|
||||
expblur<12, 10, true>(blurImage, radius, quality);
|
||||
else
|
||||
expblur<12, 10, false>(blurImage, radius, quality, transposed);
|
||||
expblur<12, 10, false>(blurImage, radius, quality);
|
||||
}
|
||||
|
||||
Q_GUI_EXPORT bool qt_scaleForTransform(const QTransform &transform, qreal *scale);
|
||||
|
|
Loading…
Add table
Reference in a new issue