Improved performance of ImageData:getPixel and ImageData:mapPixel

This commit is contained in:
Alex Szpakowski
2013-04-09 18:12:03 -03:00
parent b59b967f6b
commit 9abfb9e23b
-2
View File
@@ -80,8 +80,6 @@ pixel ImageData::getPixel(int x, int y)
if (!inside(x, y))
throw love::Exception("Attempt to get out-of-range pixel!");
Lock lock(mutex);
pixel *pixels = (pixel *)getData();
return pixels[y*getWidth()+x];
}