Native image.copyPixels + alphaImage fix

This commit is contained in:
Joshua Granick
2019-07-29 11:38:05 -07:00
parent c8120c20d5
commit ac44102aaf
2 changed files with 2 additions and 4 deletions

View File

@@ -420,13 +420,11 @@ class ImageDataUtil
}
else
{
if (alphaPoint == null) alphaPoint = new Vector2();
var alphaData = alphaImage.buffer.data;
var alphaFormat = alphaImage.buffer.format;
var alphaPosition, alphaPixel:RGBA;
var alphaView = new ImageDataView(alphaImage, new Rectangle(alphaPoint.x, alphaPoint.y, alphaImage.width, alphaImage.height));
var alphaView = new ImageDataView(alphaImage, new Rectangle(sourceView.x + (alphaPoint == null ? 0 : alphaPoint.x), sourceView.y + (alphaPoint == null ? 0 : alphaPoint.y), sourceView.width, sourceView.height));
destView.clip(Std.int(destPoint.x), Std.int(destPoint.y), alphaView.width, alphaView.height);