static RGBImage mergeImagesVertically(RGBImage... images) { ret mergeImagesVertically(toList(images)); } static RGBImage mergeImagesVertically(L<RGBImage> images, O... _) { optPar int spacing = imageMergeSpacing(); RGB spaceColor = optPar spaceColor(_, RGB(0.9f)); int h = intSum(images, "height")+(l(images)-1)*spacing, w = intMax(images, "width"); RGBImage out = new RGBImage(w, h, spaceColor); int y = 0; for i over images: { RGBImage img = images.get(i); int x = (w-img.w())/2; copyRGBImage(img, 0, 0, out, x, y); y += img.h() + spacing; } ret out; }
Began life as a copy of #1006078
download show line numbers debug dex old transpilations
Travelled to 14 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, sawdedvomwva, tslmcundralx, tvejysmllsmz, vouqrxazstgt
No comments. add comment
Snippet ID: | #1006081 |
Snippet name: | mergeImagesVertically [with spacing] |
Eternal ID of this version: | #1006081/3 |
Text MD5: | 69f3a3f533dee36ee0cd73250be90dae |
Author: | stefan |
Category: | javax / imaging |
Type: | JavaX fragment (include) |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2019-08-24 00:48:45 |
Source code size: | 606 bytes / 18 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 520 / 547 |
Version history: | 2 change(s) |
Referenced in: | #1006374 - mergeImagesHorizontally [with spacing] #1006654 - Standard functions list 2 (LIVE, continuation of #761) #1018775 - mergeBWImagesVertically [with spacing] #1019192 - mergeBufferedImagesVertically [with spacing] |