Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

13
LINES

< > BotCompany Repo | #1034532 // bufferedImageWithoutAlpha - synonym of intArrayToBufferedImageWithoutAlpha

JavaX fragment (include)

// from: https://stackoverflow.com/questions/14416107/int-array-to-bufferedimage
// pixels are RGB pixels
static BufferedImage bufferedImageWithoutAlpha(int[] pixels, int w, int h) {
  ret intArrayToBufferedImageWithoutAlpha(pixels, w, h);
}

static BufferedImage bufferedImageWithoutAlpha(int w, int h, int[] pixels) {
  ret intArrayToBufferedImageWithoutAlpha(pixels, w, h);
}

static BufferedImage bufferedImageWithoutAlpha(int w, int h, Color color) {
  ret bufferedImageWithoutAlpha(w, h, repIntAsArray(w*h, colorToInt(color)));
}

download  show line numbers  debug dex  old transpilations   

Travelled to 3 computer(s): bhatertpkbcr, mowyntqkapby, mqqgnosmbjvj

No comments. add comment

Snippet ID: #1034532
Snippet name: bufferedImageWithoutAlpha - synonym of intArrayToBufferedImageWithoutAlpha
Eternal ID of this version: #1034532/3
Text MD5: a9a04453a9d0816bcdf65fb676398110
Author: someone
Category:
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2022-02-20 19:12:35
Source code size: 547 bytes / 13 lines
Pitched / IR pitched: No / No
Views / Downloads: 183 / 209
Version history: 2 change(s)
Referenced in: #1006654 - Standard functions list 2 (LIVE, continuation of #761)