You can easily resize the image which you get from
page.DrawBitmap(dpi);
.
Here is a quick example for you:
public static Bitmap ResizeImage(Image image, int width, int height)
{
Bitmap result = new Bitmap(width, height);
using (Graphics graphics = Graphics.FromImage(result))
{
graphics.SmoothingMode = Drawing2D.SmoothingMode.HighQuality;
graphics.CompositingQuality = Drawing2D.CompositingQuality.HighQuality;
graphics.InterpolationMode = Drawing2D.InterpolationMode.HighQualityBicubic;
graphics.DrawImage(image, 0, 0, result.Width, result.Height);
}
return result;
}
Just past the image and desired dimensions(width and height) to this function. It will return a resized image for you. :)
I hope this helps. :)
Regards