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
 Problem with DoPreviews
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

robnic

Italy
7 Posts

Posted - Mar 01 2012 :  04:34:40  Show Profile  Reply
Hello,

first of all congratulations to Fabrizio for the improvements in the VLC. The new version seems to be even faster than the old one. I have just upgraded from V2 to V4

Unfortunately i have a problem with the DoPreviews method.
In a form i have a TimageEnMIO object linked to a TImageEnMView object.
After the image (moncromatic TIFF with faxccitt4 compression) has been acquired by a scanner the user can click in a button and asjust the colors. The code is sipmply theimageEnMIO.proc.DoPreviews(ppeColorAdjust) (it works)
Later the image is saved using the code theimageenMio.savefile(..)
The image is saved but the color adjust is missing.

Probably i miss something. Any hint ?

Thanks

Roberto

fab

1310 Posts

Posted - Mar 01 2012 :  04:51:52  Show Profile  Reply
Hello,
thank you Roberto.
pppeColorAdjust works with color images, so your need to save the image as RGB instead of BW:
ImageEnMView.MIO.Params[imageindex].SamplesPerPixel := 3;
ImageEnMView.MIO.Params[imageindex].BitsPerSample := 8;
ImageEnMView.MIO.Params[imageindex].TIFF_Compression := ioTIFF_JPEG; // or another compression
ImageEnMView.MIO.SaveToFile(...);

Hope this helps.
Go to Top of Page

robnic

Italy
7 Posts

Posted - Mar 01 2012 :  06:28:41  Show Profile  Reply
Ahhhh, thanks. Thats explain everything.

Another small thing.: Having a TImageEnMView and a TImageEnView what's the best way to show in the last one the image currently selected in the TImageEnMView ? Now i use the clipboard (copy in the Mview and past in the view)

thanks

Roberto
Go to Top of Page

fab

1310 Posts

Posted - Mar 01 2012 :  07:42:27  Show Profile  Reply
There are several ways. I prefer (used in demo: Multi\MultiView2):

ImageEnMView1.CopyToIEBitmap( idx, ImageEnView1.IEBitmap );
ImageEnView1.Update();
Go to Top of Page

robnic

Italy
7 Posts

Posted - Mar 01 2012 :  09:52:59  Show Profile  Reply
Perfect thanks.

Roberto
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: