Created
April 3, 2018 10:51
-
-
Save ilkerkesen/8b181d55aaae4772b82e5f897f5189cf to your computer and use it in GitHub Desktop.
Revisions
-
ilkerkesen created this gist
Apr 3, 2018 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,23 @@ using Luxor function make_frame(W, H, images, captions, title="title", fn="drawing.png") @assert length(images) == length(captions) nimg = length(images) + 1 width = W*nimg; height = H*nimg Drawing(width, height, fn) tiles = Tiler(W,H,1,nimg) origin() background("white") for (i, img, cap) in zip(1:nimg-1, images, captions) @layer begin sc = 0.01 image = readpng(img) w, h = image.width, image.height w *= 0.2; h *= 0.2 x, y = tiles[i][1].x, tiles[i][1].y placeimage(image, x, y, .5; centered=true) scale(sc,sc) end end finish() end