Quantcast
Channel: magick Discussions Rss Feed
Viewing all articles
Browse latest Browse all 3693

New Post: How join the images processed by tilecrop ?

$
0
0
There is no method that does the reverse but you can recreate the image with the help of the Page property of MagickImage. Below is a simple example:
using (MagickImage image = new MagickImage("gradient:yellow-purple", 200, 200))
{
  using (MagickImage result = new MagickImage("xc:black", 200, 200))
  {
    foreach (MagickImage tile in image.CropToTiles(50, 50))
    {
      // Store the position because some methods will change the value.
      MagickGeometry offset = tile.Page;

      // Perform operations on the image
      tile.Rotate(90);

      // Draw the result on the black canvas at the stored offset
      result.Composite(tile, offset);

      // Don't forget to dispose the tile
      tile.Dispose();
    }
    result.Write("result.png");
  }
}

Viewing all articles
Browse latest Browse all 3693

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>