diff options
author | yinsimei | 2017-06-05 11:49:19 +0200 |
---|---|---|
committer | Eugene Sandulenko | 2017-07-13 18:27:45 +0200 |
commit | 10ff6994ae8a8f6ba1f49d8cf1590762b1ae1be8 (patch) | |
tree | 88ccaea220791535dd3f5629424338c80b0c8a3a /engines/sludge/thumbnail.cpp | |
parent | 414b3c47146ebcc684fb37bccbbb66ff2ac68e2d (diff) | |
download | scummvm-rg350-10ff6994ae8a8f6ba1f49d8cf1590762b1ae1be8.tar.gz scummvm-rg350-10ff6994ae8a8f6ba1f49d8cf1590762b1ae1be8.tar.bz2 scummvm-rg350-10ff6994ae8a8f6ba1f49d8cf1590762b1ae1be8.zip |
SLUDGE: format code and remove oneliners
Diffstat (limited to 'engines/sludge/thumbnail.cpp')
-rw-r--r-- | engines/sludge/thumbnail.cpp | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/engines/sludge/thumbnail.cpp b/engines/sludge/thumbnail.cpp index 5e77936fb6..63c7544fff 100644 --- a/engines/sludge/thumbnail.cpp +++ b/engines/sludge/thumbnail.cpp @@ -104,8 +104,8 @@ bool saveThumbnail(Common::WriteStream *stream) { GLuint *tmp = new GLuint [thumbWidth * thumbHeight]; if (! checkNew(image)) return false; glReadPixels(viewportOffsetX, viewportOffsetY, thumbWidth, thumbHeight, GL_RGBA, GL_UNSIGNED_BYTE, tmp); - for (int y = 0; y < thumbHeight; y ++) { - for (int x = 0; x < thumbWidth; x ++) { + for (int y = 0; y < thumbHeight; y++) { + for (int x = 0; x < thumbWidth; x++) { const GLuint a = tmp[y * thumbWidth + x]; image[y * thumbWidth + x] = ((a & 0x00f80000) >> (16 + 3)) | ((a & 0x0000fc00) >> (8 + 2 - 5)) | ((a & 0x000000f8) << (11 - 3)); } @@ -122,8 +122,8 @@ bool saveThumbnail(Common::WriteStream *stream) { #endif setPixelCoords(false); - for (int y = 0; y < thumbHeight; y ++) { - for (int x = 0; x < thumbWidth; x ++) { + for (int y = 0; y < thumbHeight; y++) { + for (int x = 0; x < thumbWidth; x++) { put2bytes((*(image + y * thumbWidth + x)), fp); } } @@ -167,7 +167,7 @@ void showThumbnail(char *filename, int atX, int atY) { int t1, t2; unsigned short c; GLubyte *target; - for (t2 = 0; t2 < fileHeight; t2 ++) { + for (t2 = 0; t2 < fileHeight; t2++) { t1 = 0; while (t1 < fileWidth) { c = (unsigned short) fp->readUint16BE(); |