1 | static BitSet used332Colors(BufferedImage img) {
|
2 | ret used332Colors(RGBImage(img)); |
3 | } |
4 | |
5 | static BitSet used332Colors(RGBImage img) {
|
6 | int w = img.w(), h = img.h(); |
7 | new BitSet bs; |
8 | for y to h: for x to w: |
9 | setBit(bs, ubyteToInt(to332(img.getInt(x, y)))); |
10 | ret bs; |
11 | } |
Began life as a copy of #1019830
download show line numbers debug dex old transpilations
Travelled to 8 computer(s): bhatertpkbcr, cfunsshuasjs, gwrvuhgaqvyk, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt
No comments. add comment
| Snippet ID: | #1020585 |
| Snippet name: | used332Colors - return bitset of used 3-3-2 colors in image |
| Eternal ID of this version: | #1020585/1 |
| Text MD5: | 3e2a24135fecb29933e583e8632613d0 |
| Author: | stefan |
| Category: | javax / image analysis |
| Type: | JavaX fragment (include) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2018-12-27 17:33:12 |
| Source code size: | 281 bytes / 11 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 501 / 512 |
| Referenced in: | [show references] |