Libraryless. Click here for Pure Java version (5338L/29K).
svoid setRGB(BufferedImage img, Pt p, RGB rgb) { img?.setRGB(p.x, p.y, rgb.asIntWithAlpha()); } svoid setRGB(BufferedImage img, int x, int y, RGB rgb) { img?.setRGB(x, y, rgb.asIntWithAlpha()); } svoid setRGB(BufferedImage img, int x, int y, Color color) { img?.setRGB(x, y, colorToIntOpaque(color)); }
Began life as a copy of #1031353
download show line numbers debug dex old transpilations
Travelled to 4 computer(s): bhatertpkbcr, mqqgnosmbjvj, pyentgdyhuwx, vouqrxazstgt
No comments. add comment
Snippet ID: | #1031377 |
Snippet name: | setRGB |
Eternal ID of this version: | #1031377/4 |
Text MD5: | 641bfe1ddd37e475b861e9d0d870df9d |
Transpilation MD5: | a6d2a9fe36fb333a36a29b0564e72f20 |
Author: | stefan |
Category: | javax / imaging |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2022-03-15 16:13:45 |
Source code size: | 320 bytes / 11 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 234 / 331 |
Version history: | 3 change(s) |
Referenced in: | #1006654 - Standard functions list 2 (LIVE, continuation of #761) |