From the ImageMagick command line I can do composition using following commands.
composite displace_map.png image.png -displace 60x60 displace_out.png.
This is working. But how can I convert the following command to Magick.Net. I have tried this which did not work. string srcImage = @"image.png";
string srcDisplaceMap = @"displace_map.png";
using (var gradient = new MagickImage(srcDisplaceMap))
{
using (var flatImage = new MagickImage(srcImage))
{
flatImage.VirtualPixelMethod = VirtualPixelMethod.Gray;
flatImage.Composite(gradient, Gravity.Center, CompositeOperator.Displace, "60x60");
flatImage.Write(@"out.png");
}
}