Skip to content

Commit

Permalink
Use ARGB for the image
Browse files Browse the repository at this point in the history
  • Loading branch information
AlexProgrammerDE committed Feb 18, 2024
1 parent 3583308 commit c6bda88
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ public void setColor(int x, int y, byte color) {

public BufferedImage toBufferedImage() {
var image =
new BufferedImage(128, 128, BufferedImage.TYPE_4BYTE_ABGR);
new BufferedImage(128, 128, BufferedImage.TYPE_INT_ARGB);
for (var x = 0; x < 128; ++x) {
for (var y = 0; y < 128; ++y) {
image.setRGB(x, y, convertABGRToARGB(MapColor.getColorFromPackedId(getColor(x, y))));
Expand Down

0 comments on commit c6bda88

Please sign in to comment.