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

10
LINES

< > BotCompany Repo | #1033649 // bitMatrixToQuadTree

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

Transpiled version (5815L) is out of date.

static QuadTreeBitMatrix bitMatrixToQuadTree(BitMatrix m) {
  int w = m.getWidth(), h = m.getHeight();
  QuadTreeBitMatrix qt = new(w, h);

  for y to h:
    for x to w:
      if (m.get(x, y))
        qt.set(x, y);
  ret qt;
}

Author comment

Began life as a copy of #1033642

download  show line numbers  debug dex  old transpilations   

Travelled to 4 computer(s): bhatertpkbcr, ekrmjmnbrukm, mowyntqkapby, mqqgnosmbjvj

No comments. add comment

Snippet ID: #1033649
Snippet name: bitMatrixToQuadTree
Eternal ID of this version: #1033649/5
Text MD5: 24910f1d7081610f6ae3a22a4ec75e67
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2021-12-25 22:59:07
Source code size: 235 bytes / 10 lines
Pitched / IR pitched: No / No
Views / Downloads: 69 / 122
Version history: 4 change(s)
Referenced in: [show references]