comparison engine/core/video/image.cpp @ 162:c3418554467f

Sorry. Last fix/bug was brought to you by pure unadulterated stupitity.
author phoku@33b003aa-7bff-0310-803a-e67f0ece8222
date Tue, 14 Oct 2008 20:40:02 +0000
parents e62122d12727
children 3804348fe3fb
comparison
equal deleted inserted replaced
161:e62122d12727 162:c3418554467f
106 void Image::setYShift(int yshift) { 106 void Image::setYShift(int yshift) {
107 m_yshift = yshift; 107 m_yshift = yshift;
108 } 108 }
109 109
110 void Image::getPixelRGBA(int x, int y, uint8_t* r, uint8_t* g, uint8_t* b, uint8_t* a) { 110 void Image::getPixelRGBA(int x, int y, uint8_t* r, uint8_t* g, uint8_t* b, uint8_t* a) {
111 if ((x < 0) || (x > m_surface->w) || (y < 0) || (y > m_surface->h)) { 111 if ((x < 0) || (x >= m_surface->w) || (y < 0) || (y >= m_surface->h)) {
112 r = 0; 112 r = 0;
113 g = 0; 113 g = 0;
114 b = 0; 114 b = 0;
115 a = 0; 115 a = 0;
116 return; 116 return;