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

24
LINES

< > BotCompany Repo | #1031375 // newImage - synonym of whiteImage

JavaX fragment (include) [tags: use-pretranspiled]

Libraryless. Click here for Pure Java version (5507L/30K).

1  
static BufferedImage newImage(int w, int h) {
2  
  ret whiteImage(w, h);
3  
}
4  
5  
static BufferedImage newImage(int w, int h default w, Color color) {
6  
  ret bufferedImage(w, h, color);
7  
}
8  
9  
10  
static BufferedImage newImage(int size) {
11  
  ret whiteImage(size);
12  
}
13  
14  
static BufferedImage newImage(Pt size) {
15  
  ret whiteImage(size.x, size.y);
16  
}
17  
18  
static BufferedImage newImage(WidthAndHeight size) {
19  
  ret whiteImage(size.w(), size.h());
20  
}
21  
22  
static BufferedImage newImage(Dimension size) {
23  
  ret whiteImage(size.width, size.height);
24  
}

download  show line numbers  debug dex  old transpilations   

Travelled to 5 computer(s): bhatertpkbcr, mowyntqkapby, mqqgnosmbjvj, pyentgdyhuwx, vouqrxazstgt

No comments. add comment

Snippet ID: #1031375
Snippet name: newImage - synonym of whiteImage
Eternal ID of this version: #1031375/8
Text MD5: 50ec09ad88abefd13d9f43868d563085
Transpilation MD5: f5ff1903c94cf45fe36da9394cf7047d
Author: stefan
Category:
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2022-02-07 18:25:49
Source code size: 538 bytes / 24 lines
Pitched / IR pitched: No / No
Views / Downloads: 291 / 400
Version history: 7 change(s)
Referenced in: [show references]