Fix fillRect behaviour when using alpha on neko/cpp

see #759 and #631
This commit is contained in:
azrafe7
2015-12-24 11:28:56 +01:00
parent f387b7eefc
commit 8a76e2d58a
2 changed files with 5 additions and 2 deletions

View File

@@ -253,13 +253,15 @@ namespace lime {
int row;
RGBA fillColor (color);
if (premultiplied) fillColor.MultiplyAlpha ();
for (int y = 0; y < dataView.height; y++) {
row = dataView.Row (y);
for (int x = 0; x < dataView.width; x++) {
fillColor.WriteUInt8 (data, row + (x * 4), format, premultiplied);
fillColor.WriteUInt8 (data, row + (x * 4), format, false);
}