# HG changeset patch # User spq@33b003aa-7bff-0310-803a-e67f0ece8222 # Date 1215822026 0 # Node ID d66538926e781b83882cf7f3b890a59510187a5c # Parent 112fc4af772d56435f5a9607a8b3ea75149d1c6f fix getPixelRGBA - it should return r g b and not r b g... why did everyone use the wrong order instead of fixing the reason? :) diff -r 112fc4af772d -r d66538926e78 engine/core/video/image.cpp --- a/engine/core/video/image.cpp Fri Jul 11 15:42:54 2008 +0000 +++ b/engine/core/video/image.cpp Sat Jul 12 00:20:26 2008 +0000 @@ -136,7 +136,7 @@ case 4: pixel = *(Uint32 *)p; } - SDL_GetRGBA(pixel, m_surface->format, r, b, g, a); + SDL_GetRGBA(pixel, m_surface->format, r, g, b, a); } void Image::render(const Rect& rect, unsigned char alpha) { diff -r 112fc4af772d -r d66538926e78 engine/core/view/camera.cpp --- a/engine/core/view/camera.cpp Fri Jul 11 15:42:54 2008 +0000 +++ b/engine/core/view/camera.cpp Sat Jul 12 00:20:26 2008 +0000 @@ -314,7 +314,7 @@ x = static_cast(round(fx / fsw * fow)); y = static_cast(round(fy / fsh * foh)); } - vc.image->getPixelRGBA(x, y, &r, &b, &g, &a); + vc.image->getPixelRGBA(x, y, &r, &g, &b, &a); // instance is hit with mouse if not totally transparent if (a != 0) { instances.push_back(i); @@ -349,7 +349,7 @@ x = static_cast(round(fx / fsw * fow)); y = static_cast(round(fy / fsh * foh)); } - vc.image->getPixelRGBA(x, y, &r, &b, &g, &a); + vc.image->getPixelRGBA(x, y, &r, &g, &b, &a); // instance is hit with mouse if not totally transparent if (a != 0) { instances.push_back(i);