summaryrefslogtreecommitdiffstats
path: root/src/gui/image
diff options
context:
space:
mode:
authorFrederik Gladhorn <frederik.gladhorn@digia.com>2013-06-20 16:45:12 +0200
committerFrederik Gladhorn <frederik.gladhorn@digia.com>2013-06-20 16:45:12 +0200
commit6213b8145772d3dc584907a544f6c46b8cef74e2 (patch)
tree4c1902793bb78511e63c09cbe92f9eda6b3d7237 /src/gui/image
parent75e9c7d6bc662e62e9ce8b641588183992c1e8bf (diff)
parent25739bebba0343a8b35775a073c49f0fba080762 (diff)
Merge remote-tracking branch 'origin/stable' into dev
Conflicts: src/plugins/platforms/cocoa/qcocoafiledialoghelper.mm src/plugins/platforms/qnx/qqnxrasterbackingstore.cpp tools/configure/configureapp.cpp Change-Id: I3092bd3276af14304b7ab3ae1e1cc05d11cdede0
Diffstat (limited to 'src/gui/image')
-rw-r--r--src/gui/image/qbmphandler.cpp12
-rw-r--r--src/gui/image/qimage.cpp10
-rw-r--r--src/gui/image/qppmhandler.cpp2
-rw-r--r--src/gui/image/qxbmhandler.cpp4
4 files changed, 14 insertions, 14 deletions
diff --git a/src/gui/image/qbmphandler.cpp b/src/gui/image/qbmphandler.cpp
index 6abde5e420..cb4e45f1d0 100644
--- a/src/gui/image/qbmphandler.cpp
+++ b/src/gui/image/qbmphandler.cpp
@@ -53,7 +53,7 @@ static void swapPixel01(QImage *image) // 1-bpp: swap 0 and 1 pixels
{
int i;
if (image->depth() == 1 && image->colorCount() == 2) {
- register uint *p = (uint *)image->bits();
+ uint *p = (uint *)image->bits();
int nbytes = image->byteCount();
for (i=0; i<nbytes/4; i++) {
*p = ~*p;
@@ -368,7 +368,7 @@ static bool read_dib_body(QDataStream &s, const BMP_INFOHDR &bi, int offset, int
if (comp == BMP_RLE4) { // run length compression
int x=0, y=0, c, i;
quint8 b;
- register uchar *p = data + (h-1)*bpl;
+ uchar *p = data + (h-1)*bpl;
const uchar *endp = p + w;
while (y < h) {
if (!d->getChar((char *)&b))
@@ -440,7 +440,7 @@ static bool read_dib_body(QDataStream &s, const BMP_INFOHDR &bi, int offset, int
while (--h >= 0) {
if (d->read((char*)buf,buflen) != buflen)
break;
- register uchar *p = data + h*bpl;
+ uchar *p = data + h*bpl;
uchar *b = buf;
for (int i=0; i<w/2; i++) { // convert nibbles to bytes
*p++ = *b >> 4;
@@ -457,7 +457,7 @@ static bool read_dib_body(QDataStream &s, const BMP_INFOHDR &bi, int offset, int
if (comp == BMP_RLE8) { // run length compression
int x=0, y=0;
quint8 b;
- register uchar *p = data + (h-1)*bpl;
+ uchar *p = data + (h-1)*bpl;
const uchar *endp = p + w;
while (y < h) {
if (!d->getChar((char *)&b))
@@ -520,7 +520,7 @@ static bool read_dib_body(QDataStream &s, const BMP_INFOHDR &bi, int offset, int
}
else if (nbits == 16 || nbits == 24 || nbits == 32) { // 16,24,32 bit BMP image
- register QRgb *p;
+ QRgb *p;
QRgb *end;
uchar *buf24 = new uchar[bpl];
int bpl24 = ((w*nbits+31)/32)*4;
@@ -632,7 +632,7 @@ bool qt_write_dib(QDataStream &s, QImage image)
uchar *buf = new uchar[bpl_bmp];
uchar *b, *end;
- register const uchar *p;
+ const uchar *p;
memset(buf, 0, bpl_bmp);
for (y=image.height()-1; y>=0; y--) { // write the image bits
diff --git a/src/gui/image/qimage.cpp b/src/gui/image/qimage.cpp
index 0efb9c2646..98f3aeeeb9 100644
--- a/src/gui/image/qimage.cpp
+++ b/src/gui/image/qimage.cpp
@@ -2270,7 +2270,7 @@ static void dither_to_Mono(QImageData *dst, const QImageData *src,
int *b1, *b2;
int wbytes = w * (d/8);
- register const uchar *p = src->data;
+ const uchar *p = src->data;
const uchar *end = p + wbytes;
b2 = line2;
if (use_gray) { // 8 bit image
@@ -2830,7 +2830,7 @@ static void convert_Mono_to_X32(QImageData *dest, const QImageData *src, Qt::Ima
uchar *dest_data = dest->data;
if (src->format == QImage::Format_Mono) {
for (int y = 0; y < dest->height; y++) {
- register uint *p = (uint *)dest_data;
+ uint *p = (uint *)dest_data;
for (int x = 0; x < dest->width; x++)
*p++ = colorTable.at((src_data[x>>3] >> (7 - (x & 7))) & 1);
@@ -2839,7 +2839,7 @@ static void convert_Mono_to_X32(QImageData *dest, const QImageData *src, Qt::Ima
}
} else {
for (int y = 0; y < dest->height; y++) {
- register uint *p = (uint *)dest_data;
+ uint *p = (uint *)dest_data;
for (int x = 0; x < dest->width; x++)
*p++ = colorTable.at((src_data[x>>3] >> (x & 7)) & 1);
@@ -2873,7 +2873,7 @@ static void convert_Mono_to_Indexed8(QImageData *dest, const QImageData *src, Qt
uchar *dest_data = dest->data;
if (src->format == QImage::Format_Mono) {
for (int y = 0; y < dest->height; y++) {
- register uchar *p = dest_data;
+ uchar *p = dest_data;
for (int x = 0; x < dest->width; x++)
*p++ = (src_data[x>>3] >> (7 - (x & 7))) & 1;
src_data += src->bytes_per_line;
@@ -2881,7 +2881,7 @@ static void convert_Mono_to_Indexed8(QImageData *dest, const QImageData *src, Qt
}
} else {
for (int y = 0; y < dest->height; y++) {
- register uchar *p = dest_data;
+ uchar *p = dest_data;
for (int x = 0; x < dest->width; x++)
*p++ = (src_data[x>>3] >> (x & 7)) & 1;
src_data += src->bytes_per_line;
diff --git a/src/gui/image/qppmhandler.cpp b/src/gui/image/qppmhandler.cpp
index e425eca521..6fc41df77c 100644
--- a/src/gui/image/qppmhandler.cpp
+++ b/src/gui/image/qppmhandler.cpp
@@ -188,7 +188,7 @@ static bool read_pbm_body(QIODevice *device, char type, int w, int h, int mcc, Q
}
}
} else { // read ascii data
- register uchar *p;
+ uchar *p;
int n;
for (y=0; y<h; y++) {
p = outImage->scanLine(y);
diff --git a/src/gui/image/qxbmhandler.cpp b/src/gui/image/qxbmhandler.cpp
index 498f6ce767..aceb6623ea 100644
--- a/src/gui/image/qxbmhandler.cpp
+++ b/src/gui/image/qxbmhandler.cpp
@@ -57,7 +57,7 @@ QT_BEGIN_NAMESPACE
X bitmap image read/write functions
*****************************************************************************/
-static inline int hex2byte(register char *p)
+static inline int hex2byte(char *p)
{
return ((isdigit((uchar) *p) ? *p - '0' : toupper((uchar) *p) - 'A' + 10) << 4) |
(isdigit((uchar) *(p+1)) ? *(p+1) - '0' : toupper((uchar) *(p+1)) - 'A' + 10);
@@ -215,7 +215,7 @@ static bool write_xbm_image(const QImage &sourceImage, QIODevice *device, const
}
}
int bcnt = 0;
- register char *p = buf;
+ char *p = buf;
int bpl = (w+7)/8;
for (int y = 0; y < h; ++y) {
uchar *b = image.scanLine(y);