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

19
LINES

< > BotCompany Repo | #1019586 // Screen Lens with rect of changing pixels

JavaX source code (desktop) [tags: use-pretranspiled] - run with: x30.jar

Download Jar. Uses 3874K of libraries. Click here for Pure Java version (10886L/80K).

!7

static ScreenLens lens;
static RGBImage lastImage;
static Rect diffRect;

p-noconsole {
  lens = new ScreenLens;
  lens.postProcess = func(BufferedImage img) {
    RGBImage rgb = new(img);
    if (lastImage != null) {
      diffRect = or(rectOfDifferentPixels(lastImage, rgb), diffRect);
      drawBox(img, diffRect, Color.red, 0.8f);
    }
    lastImage = rgb;
    ret img;
  };
  lens.start();
}

Author comment

Began life as a copy of #1006557

download  show line numbers  debug dex  old transpilations   

Travelled to 12 computer(s): bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, irmadwmeruwu, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt

No comments. add comment

Snippet ID: #1019586
Snippet name: Screen Lens with rect of changing pixels
Eternal ID of this version: #1019586/4
Text MD5: 62bac6d3800755a6513a9ccebbbd2377
Transpilation MD5: 5c4bc02a9cb4456954611d40c0fdee31
Author: stefan
Category: javax / gui / ocr
Type: JavaX source code (desktop)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2018-11-27 23:10:36
Source code size: 419 bytes / 19 lines
Pitched / IR pitched: No / No
Views / Downloads: 393 / 1073
Version history: 3 change(s)
Referenced in: [show references]