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
 LayerMerge feature or bug?
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

yogiyang

India
725 Posts

Posted - May 12 2020 :  01:38:45  Show Profile  Reply
Hello,

It seems that there is a bug in LayerMerge (as per my understanding).

I tried it in the Layers_AllTypes demo.

Here is what I did:
 
Changed the line: ImageEnView1.LayerOptions := ImageEnView1.LayerOptions + [loAutoUndoChangesByuser, loAutoUndoChangesByCode];

to: ImageEnView1.LayerOptions := ImageEnView1.LayerOptions + [loAutoUndoChangesByuser, loAutoUndoChangesByCode, loAutoSelectMask];

Added a menu item and put this one line of code: ImageEnView1.LayersMerge();


What is happening is that all selected layers get merged. Except for the mask of the lower most layer.

Is this by design or is it a bug?

I am attaching a small video showing this behavior.

attach/yogiyang/202051213719_Video_2020-05-12_095123.zip
3627.18 KB

TIA




Yogi Yang

xequte

38198 Posts

Posted - May 12 2020 :  17:35:05  Show Profile  Reply
Thanks Yogi,

I can reproduce and will investigate.

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

yogiyang

India
725 Posts

Posted - May 13 2020 :  07:59:04  Show Profile  Reply
Hello Nigel,

Thanks for confirming.

While you are at it.

I also observed that when we pass LayersMerge an array in debug mode ImageEn givs error as follows after LayersMerge code is executed:
 
---------------------------
Debugger Exception Notification
---------------------------
Project Layers.exe raised exception class EListError with message 'List index out of bounds (-1)'.
---------------------------
Break Continue Help
---------------------------

I repeat this happens only when we are running the EXE in IDE. If we run the exe out side the IDE then there are no errors generated.

Please also look into this if possible.

I am using Delphi 10.3 Rio Update 3 and ImageEN 8.7.6.

TIA


Yogi Yang
Go to Top of Page

xequte

38198 Posts

Posted - May 13 2020 :  16:52:46  Show Profile  Reply
Hi Yogi

If you break the code at that point, what line/method is running? I suspect it is an outdated reference in TImageEnLayerMView that is caught by an exception handler (which in 9.0.0 does not raise an exception).

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