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

PixAndMore

Germany
7 Posts

Posted - Jul 06 2018 :  03:24:22  Show Profile  Reply
Hello...

with v8 I have problems to generate thumbnails from the original large images... until v7.5 I used that code


Destination.Allocate(dstWidth, dstHeight);

Source.RenderToTIEBitmapEx(Destination,
  0, 0, dstWidth, dstHeight,
  srcX, srcY, srcWidth, srcHeight,
  False, 255, Resample
);


this proceduces with v8 this output:



when i replace RenderToTIEBitmapEx with CopyRectTo

Source.CopyRectTo(Destination,
  0, 0, 0, 0, dstWidth, dstHeight
);

it works, but it is not the same as what i wanted



Regards, Kai

xequte

38219 Posts

Posted - Jul 06 2018 :  06:40:10  Show Profile  Reply
Hi Kai

Can you please give me the full method/code to reproduce the issue?



Nigel
Xequte Software
www.imageen.com
Go to Top of Page

xequte

38219 Posts

Posted - Jul 06 2018 :  22:37:24  Show Profile  Reply
Hi Kai

I tried to reproduce as follows, but it works in my tests (Delphi 10.1 Berlin):

procedure TForm1.Button1Click(Sender: TObject);
const
  srcX = 10;
  srcY = 10;
  dstWidth  = 300;
  dstHeight = 300;
  srcWidth  = 200;
  srcHeight = 200;
  Resample = rfWICLinear;
begin
  ImageEnView2.IEBitmap.Allocate(dstWidth, dstHeight);

  ImageEnView1.IEBitmap.RenderToTIEBitmapEx(ImageEnView2.IEBitmap,
    0, 0, dstWidth, dstHeight,
    srcX, srcY, srcWidth, srcHeight,
    False, 255, Resample );

  ImageEnView2.Update();
end;


Nigel
Xequte Software
www.imageen.com
Go to Top of Page

PixAndMore

Germany
7 Posts

Posted - Jul 09 2018 :  02:10:42  Show Profile  Reply
Hello Nigel,

i have made some more tests, this happens only when I use rfFastLiniar as resample mode. My app uses rfNone, rfFastLinear und rfLanczos3 (None, Fast, HQ) in the user interface. rfNone and rfLanczos3 works as in v7.5 and your rfWICLinear works also...

which resample filter is a good replacemant for rfFastLiniear?



Regards, Kai
Go to Top of Page

xequte

38219 Posts

Posted - Jul 09 2018 :  05:36:41  Show Profile  Reply
Thanks Kai

We will have a fix for this in 8.0.1 tomorrow.



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