1 | static void cycleSegmentedComponents(final BufferedImage img, final L<ConnectedComponent> components) { |
2 | final new Var<ImageSurface> is; |
3 | final Var<int> iComponent = new(0); |
4 | |
5 | Runnable nextImage = r { |
6 | is.set(packFrameInTopRightCorner(showZoomedImage(is!, |
7 | cutOutPixelSet(img, components.get(iComponent!)), "Cut out " + (iComponent!+1) + "/" + l(components))); |
8 | iComponent.set(mod(iComponent!+1, l(components)); |
9 | }; |
10 | |
11 | callF(nextImage); |
12 | packInTopRightCorner(addToWindow(is!, jcenteredbutton("Next", nextImage))); |
13 | } |
download show line numbers debug dex old transpilations
Travelled to 13 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1010170 |
Snippet name: | cycleSegmentedComponents |
Eternal ID of this version: | #1010170/5 |
Text MD5: | 7b9307742ad28e19f3e17e56717e275b |
Author: | stefan |
Category: | javax / gui |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2017-09-05 19:58:57 |
Source code size: | 547 bytes / 13 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 433 / 458 |
Version history: | 4 change(s) |
Referenced in: | [show references] |