Libraryless. Click here for Pure Java version (11494L/64K).
1 | static int binaryImagePixelDifference_sameSize(Image2B img1, Image2B img2) {
|
2 | assertSameSize(img1, img2); |
3 | ret countDifferingBits(img1.pixels, img2.pixels); |
4 | } |
5 | |
6 | static int binaryImagePixelDifference_sameSize(Image2BAsInts img1, Image2BAsInts img2) {
|
7 | assertSameSize(img1, img2); |
8 | ret countDifferingBits(img1.pixels, img2.pixels); |
9 | } |
10 | |
11 | static int binaryImagePixelDifference_sameSize(Image2BAsLongs img1, Image2BAsLongs img2) {
|
12 | assertSameSize(img1, img2); |
13 | ret countDifferingBits(img1.pixels, img2.pixels); |
14 | } |
download show line numbers debug dex old transpilations
Travelled to 3 computer(s): elmgxqgtpvxh, mqqgnosmbjvj, wnsclhtenguj
No comments. add comment
| Snippet ID: | #1035863 |
| Snippet name: | binaryImagePixelDifference_sameSize - number of differing pixels |
| Eternal ID of this version: | #1035863/7 |
| Text MD5: | c9ef8ae28e29d66d222050610be8cdcf |
| Transpilation MD5: | 3e47dbe0c2012b3ec0a2ce1558282dca |
| Author: | stefan |
| Category: | javax / imaging |
| Type: | JavaX fragment (include) |
| Public (visible to everyone): | Yes |
| Archived (hidden from active list): | No |
| Created/modified: | 2022-09-03 01:42:17 |
| Source code size: | 523 bytes / 14 lines |
| Pitched / IR pitched: | No / No |
| Views / Downloads: | 384 / 517 |
| Version history: | 6 change(s) |
| Referenced in: | [show references] |