using (Document pdf = new Document(sourcePath))
{
Parallel.For(data.start_page, data.end_page + 1, x =>
{
var width = (pdf.Pages[x].GetPageRect(true).Width * percentage).ToInt();
var height = (pdf.Pages[x].GetPageRe…...ToInt(); JpegDevice jpg = new JpegDevice(width, height...resolution), data.quality); jpg.Process(pdf.Pages[x], $“{imgSavePath}{x}...