From d855e721982a2fe02fd41aeb154f37cfd389dee3 Mon Sep 17 00:00:00 2001 From: Sam Hocevar Date: Sun, 8 Apr 2012 14:55:08 +0000 Subject: [PATCH] win32: the GDI+ byte swapping was wrong; fix that. --- src/image/codec/gdiplus-image.cpp | 9 ++++----- win32/mrpigeon.vcxproj | 12 ++++++++++++ 2 files changed, 16 insertions(+), 5 deletions(-) diff --git a/src/image/codec/gdiplus-image.cpp b/src/image/codec/gdiplus-image.cpp index 2fa74d64..2f581d8f 100644 --- a/src/image/codec/gdiplus-image.cpp +++ b/src/image/codec/gdiplus-image.cpp @@ -102,11 +102,10 @@ bool GdiPlusImageData::Open(char const *path) for (int y = 0; y < size.y; y++) for (int x = 0; x < size.x; x++) { - uint8_t tmp = p[0]; - *p++ = p[1]; - *p++ = p[1]; - *p++ = p[1]; - *p++ = tmp; + uint8_t tmp = p[2]; + p[2] = p[0]; + p[0] = tmp; + p += 4; } return true; diff --git a/win32/mrpigeon.vcxproj b/win32/mrpigeon.vcxproj index 590b41d6..7fd7ca28 100644 --- a/win32/mrpigeon.vcxproj +++ b/win32/mrpigeon.vcxproj @@ -18,12 +18,24 @@ Xbox 360 + + + + + + + + + + + + {9e62f2fe-3408-4eae-8238-fd84238ceeda}