Group Abstract Group Abstract

Message Boards Message Boards

Must be an easy question - 4 pictures in a grid - without unwanted borders

Posted 10 years ago
4 Replies

3 lines as material to work with:

rr = Plot[Sin[x], {x, 0, 10}, Background -> Brown]
ar = Table[rr, {3}, {3}];
gr = Grid[ar, Frame -> All, FrameStyle -> Directive[{Thickness[3], Red}], Spacings -> {0, 0}]

Evaluate

Export["pic.gif", gr, "GIF"]
Export["pic.png", gr, "PNG"]
Export["pic.svg", gr, "SVG"]

enter image description here

A normal export without any cloud involved shows already the artifact. If a setting of Background->Brown is used in the Export is shows:

enter image description here

There is a way to remove the stitching error.

as = ImagePad[ImageAssemble[ar],2,Red]
CloudExport[as, "GIF"]

The picture is now stitched with ImageAssemble and a border is added with ImagePad. The result is a perfect picture.

Note: I was under the impression that CloudDeploy didn't produce the stitching artifacts but it also does when grid with pictures is mixed.

the ImageAssembled picture is 1 big picture while the Grid solution contains 9 individual pictures. So my question is if it is possible to mix Grid and Images without stitching errors or is it impossible to mix. Do I gain load time of the page with this?

POSTED BY: David Reiss

David, your picture has the white line at the top.

enter image description here

The white line is in the picture. I checked by downloading in firefox, IE and chrome. In firefox it is easy to see because of the black background. MMA 10.3 win 8.1 64

Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard