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
 Select a layer through the transparent areas
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

nwscomps

185 Posts

Posted - Oct 30 2018 :  11:14:24  Show Profile  Reply
Is it possible to select a layer by clicking into it through the transparent parts of another layer that is on top of it?
Does Imageen support this kind of selection?
If yes which option do I have to set-up?
I can only select layers by their order, that is if a layer is on top and I click on it, even though on transparent parts of the layer, I cannot select the other layer that is at the bottom of it.
Thanks

Francesco Savastano
Add-ons for the ImageEn Library
web: http://www.fssoft.it/delphicomps.html

w2m

USA
1990 Posts

Posted - Oct 30 2018 :  11:46:54  Show Profile  Reply
I do not think there is a option to do this, but you might be able to determine if the current layers IEBitmap pixel is transparent, then set the ImageEnView.LayersCurrent to the layer underneath the clicked layer. I am not sure if this will work however.

Bill Miller
Adirondack Software & Graphics
Email: w2m@hughes.net
EBook: http://www.imageen.com/ebook/
Custom Commercial ImageEn Development
Go to Top of Page

xequte

38311 Posts

Posted - Oct 30 2018 :  15:27:36  Show Profile  Reply
Hi Francesco

If iesoSelectTranspLayers is not enabled in TImageEnView.SelectionOptions then you can select layers by clicking through transparency:

https://www.imageen.com/help/TImageEnView.SelectionOptions.html

However, for performance reasons, this will not happen with non-image layers unless you have enabled Layer caching:

https://www.imageen.com/help/TImageEnView.TImageEnView.LayersCaching.html


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

nwscomps

185 Posts

Posted - Oct 31 2018 :  03:46:50  Show Profile  Reply
Hi Nigel,
I have set iesoSelectTranspLAyers = true and Layerscaching = -1 but I still cannot select through layers. IT always picks the foremost one, even though I am clicking on transparent parts. I tested this with image and with text layers.

Francesco Savastano
Add-ons for the ImageEn Library
web: http://www.fssoft.it/delphicomps.html
Go to Top of Page

nwscomps

185 Posts

Posted - Oct 31 2018 :  04:03:42  Show Profile  Reply
Update: I was able to select the underlaying layer through the alpha channel, this without any special option. What I did is to remove part of the alpha channel with my eraser tool and then click through it and the underlaying layer was selected.
This works for image layers, but not with text layers.

Francesco Savastano
Add-ons for the ImageEn Library
web: http://www.fssoft.it/delphicomps.html
Go to Top of Page

nwscomps

185 Posts

Posted - Oct 31 2018 :  04:35:12  Show Profile  Reply
Other update: with layerscaching = -1 I am able to select through text layers as well. I had wrongly understood your statement about iesoSelectTranspLAyers and I had set it to true rather than false..


Francesco Savastano
Add-ons for the ImageEn Library
web: http://www.fssoft.it/delphicomps.html
Go to Top of Page

yogiyang

India
726 Posts

Posted - Nov 01 2018 :  09:00:01  Show Profile  Reply
Hello Nigel,
 
However, for performance reasons, this will not happen with non-image layers unless you have enabled Layer caching:

In case of files with many layers (in our case some files has around 60 layers average) will ImageEn handle memory if the layer cache does not fit in memory or we are responsible for managing it?

TIA


Yogi Yang
Go to Top of Page

xequte

38311 Posts

Posted - Nov 01 2018 :  15:55:25  Show Profile  Reply
Hi Yogi

ImageEn will handle the memory (caching to file if necessary), but realistically memory problems due to layer caching should not be common because it only affects non-image layers (obviously image layers are always "cached") which are typically not large.

E.g. even 60 cached 1000x1000 pixel shape layers will only take as much memory as four 16MP photos.



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