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

7
LINES

< > BotCompany Repo | #1035002 // drawPixelChessboard

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

Transpiled version (164L) is out of date.

// draw faint one times one pixel chess board to indicate how big a pixel is
svoid drawPixelChessboard(BufferedImage image) {
  int w = image.getWidth(), h = image.getHeight();
  for y to h:
    for x to w:
      setPixel(image, x, y, even(x+y) ? Color.lightGray : Color.white);
}

Author comment

Began life as a copy of #1035000

download  show line numbers  debug dex  old transpilations   

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

No comments. add comment

Snippet ID: #1035002
Snippet name: drawPixelChessboard
Eternal ID of this version: #1035002/2
Text MD5: 938afd33f539dd13582deb286e90e35d
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2022-03-22 18:26:21
Source code size: 286 bytes / 7 lines
Pitched / IR pitched: No / No
Views / Downloads: 151 / 209
Version history: 1 change(s)
Referenced in: [show references]