Cropping to PDF

Feb 19, 2015 at 5:05 PM
I'm using the following code to crop a region of interest in an image, then save only the cropped section to a new file:
Dim g As New ImageMagick.MagickGeometry(rect)
image.Crop(g)
image.RePage()
image.Write(fileName)
It works great when saving as an image (.png, .jpg, etc.). However, when the output is PDF, the result is a blank PDF document. If I comment out the image.RePage() line, the crop works as expected... it's just the repage that's not working. Is this a known issue? Are there any workarounds?

I'm using Magick.NET-Q8-x86 Version 7.0.0.0009.

Thanks!
Coordinator
Feb 21, 2015 at 10:19 AM
This was an unknown issue and it will be fixed in the next release of Magick.NET.
Mar 6, 2015 at 4:49 PM
dlemstra,

Thank you so much! The latest release seems to fix the issue for me.

eer3