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

13
LINES

< > BotCompany Repo | #1019199 // markedFaces_scaledToWidth

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

Libraryless. Click here for Pure Java version (7034L/46K).

1  
static L<RGBImageAndRect> markedFaces_scaledToWidth(int width, O... _) {
2  
  optPar bool withNoFace;
3  
  new L<RGBImageAndRect> images;
4  
  for (File f : listImageFilesByDateDesc(ai_markedFacesDir())) {
5  
    BufferedImage img = loadImage2(f);
6  
    Rect face = unstructAndCast(Rect, getFileInfoField(f, "Face position"));
7  
    if (face == null && !withNoFace) continue;
8  
    BufferedImage img2 = scaleImageToWidth(img, width);
9  
    Rect face2 = rescaleRect_imageToImage(face, img, img2);
10  
    images.add(RGBImageAndRect(RGBImage(img2, f), face2));
11  
  }
12  
  ret images;
13  
}

download  show line numbers  debug dex  old transpilations   

Travelled to 12 computer(s): bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, irmadwmeruwu, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tvejysmllsmz, vouqrxazstgt

No comments. add comment

Snippet ID: #1019199
Snippet name: markedFaces_scaledToWidth
Eternal ID of this version: #1019199/8
Text MD5: 21d156be9c0f3c0559104dfc5e404333
Transpilation MD5: 49c8c3c8d3da2cbe32d3cd0e77f14ee4
Author: stefan
Category: javax / image recognition
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2019-05-05 19:16:23
Source code size: 566 bytes / 13 lines
Pitched / IR pitched: No / No
Views / Downloads: 418 / 501
Version history: 7 change(s)
Referenced in: [show references]