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

8
LINES

< > BotCompany Repo | #1004986 // md5OfRGBImage

JavaX fragment (include)

static S md5OfRGBImage(RGBImage img) ctex {
  MessageDigest m = MessageDigest.getInstance("MD5");
  m.update(intToBytes(img.getWidth()));
  int[] pixels = img.getPixels();
  for (int i = 0; i < l(pixels); i++)
    m.update(intToBytes(pixels[i]));
  ret bytesToHex(m.digest());
}

Author comment

Began life as a copy of #1004629

download  show line numbers  debug dex  old transpilations   

Travelled to 15 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, ddnzoavkxhuk, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, onxytkatvevr, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt

No comments. add comment

Snippet ID: #1004986
Snippet name: md5OfRGBImage
Eternal ID of this version: #1004986/1
Text MD5: 1efc10c8115d5835ddb147c3575d2b6f
Author: stefan
Category: javax
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2016-09-20 23:18:05
Source code size: 285 bytes / 8 lines
Pitched / IR pitched: No / No
Views / Downloads: 579 / 872
Referenced in: #1006653 - rgbMD5 - synonym of md5OfRGBImage
#1006654 - Standard functions list 2 (LIVE, continuation of #761)
#1010160 - md5OfTransparentImage