ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
Forum membership is Free!  Click Join to sign-up
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 Need to change TIFF resolution
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

aclement

India
9 Posts

Posted - May 20 2015 :  10:02:25  Show Profile  Reply
Hi,
I need to change the TIFF file resolution and compress. The reason was the customer had scanned the files and the size if it in database is big.
Can you please provide me a way to do that. I tried the below but not working as expected and causing AV error

for i := 0 to imgScanFile.MIO.ParamsCount do
begin
//imgScanFile.MIO.TwainParams.XResolution.CurrentValue := 200;
//imgScanFile.MIO.TwainParams.YResolution.CurrentValue := 200;
//imgScanFile.MIO.Acquire;
imgScanFile.MIO.Params[i].DpiX := 200;
imgScanFile.MIO.Params[i].DpiY := 200;
end;
end;
imgScanFile.MIO.SaveToFileTIFF(imgScanFile.MIO.ExecuteSaveDialog);

xequte

38514 Posts

Posted - May 21 2015 :  01:07:10  Show Profile  Reply
Hi

The DPI settings of an image are simply an instruction on how to print/display an image. Setting them won't actually change the image, so you also need to call for each image in the MIO:

imgScanFile.Proc.Resample( .. );

http://www.imageen.com/help/TImageEnProc.Resample.html

Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: