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
 apply .blackvalue and .whitevalue to a selection
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

JanSteevens

Netherlands
17 Posts

Posted - Nov 11 2014 :  09:04:47  Show Profile  Reply
Is there a way to apply .blackvalue (and .whitevalue) to a selection of a bitmap only?

xequte

38616 Posts

Posted - Nov 12 2014 :  12:43:27  Show Profile  Reply
Hi

I'm afraid there is not a function for that.



Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
Go to Top of Page

JanSteevens

Netherlands
17 Posts

Posted - Nov 14 2014 :  03:42:26  Show Profile  Reply
Nigel,

Thank you for a clear answer. Any chance the feature will be implemented sometime?

Jan
Go to Top of Page

xequte

38616 Posts

Posted - Dec 04 2014 :  13:13:50  Show Profile  Reply
Hi Jan

We have implemented this for v5.2.1.

Using the new TIEBitmap.AdjustmentsMask it is possible to specify a selection mask for BlackValue, WhiteValue, ChannelOffset, Contrast and layer blending operations.


Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
Go to Top of Page

JanSteevens

Netherlands
17 Posts

Posted - Dec 08 2014 :  02:56:26  Show Profile  Reply
Hi Nigel,

Wonderful! I'm deeply impressed.

Jan Steevens

Go to Top of Page

JanSteevens

Netherlands
17 Posts

Posted - Apr 02 2015 :  08:34:06  Show Profile  Reply
Just installed imageEn 6.xx.

The new TIEBitmap.AdjustmentsMask works very well (I'm using it to adjust black&white values), except I can't find a decent way to switch the mask off again and apply changes to the entire bitmap as before. Changing the selection using .select to extend the mask to include the entire bitmap did work in principle but that slowed down the operation too much with the large (> 50 Mb) bitmap I'm using to be practical.

Any hint would be appreciated.

regards,

Jan Steevens
Go to Top of Page

xequte

38616 Posts

Posted - Apr 04 2015 :  02:03:10  Show Profile  Reply
Hi Jan

I will improve the documentation.

To reset the mask (so adjustments are applied to the whole image) use AdjustmentsMask := nil;

Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
Go to Top of Page

JanSteevens

Netherlands
17 Posts

Posted - Apr 07 2015 :  10:09:40  Show Profile  Reply
Hi Nigel,

Thank you for the reply.

Maybe I don't understand.

I tried:

...
 if BlackWhiteSelectionOnly.checked then
    CurrMask := ImageEnViewCurr.SelectionMask
  else
    CurrMask := nil;

  ImageEnViewCurr.IEBitmap.AdjustmentsMask.Assign(CurrMask);

  ImageEnViewCurr.IEBitmap.BlackValue:= trackbar_black.position;
  ImageEnViewCurr.IEBitmap.WhiteValue:= trackbar_white.position;
  ImageEnViewCurr.Update;
...


Which results in the correct behaviour (black/white only applied to the selection) with BlackWhiteSelectionOnly.checked = true but no reaction on changing the trackbar position whatsoever when BlackWhiteSelectionOnly.checked = false.

Stated otherwise:
Switching off BlackWhiteSelectionOnly.checked results in the image remaining unchanged, switching it on makes the trackbars change a selection if present, but never the entire image.


Still puzzled,

Jan



Go to Top of Page

xequte

38616 Posts

Posted - Apr 21 2015 :  20:33:24  Show Profile  Reply
To reset the adjustments mask use:

ImageEnView1.IEBitmap.AdjustmentsMask.Empty();
ImageEnView1.Update();


Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
Go to Top of Page

JanSteevens

Netherlands
17 Posts

Posted - Apr 23 2015 :  04:46:47  Show Profile  Reply
Hi Nigel,

Black/white changes are applied to the entire image normally until the AdjustmentMask is assigned.
From then on .IEBitmap.AdjustmentsMask.Empty() does work to switch the mask off, except: the problem remains the same. The ImageEnView treated that way from then on refuses to react on a black/white change, except when a selection is made. Reloading an image does not help, the program must be restarted.

I tried (to start with):

In .. .BlackWhiteSelectionOnlyClick(..)

  if BlackWhiteSelectionOnly.Checked then
    begin
      ImageEnViewCurr.IEBitmap.AdjustmentsMask.Assign(ImageEnViewCurr.SelectionMask);
      ImageEnViewCurr.Update;
    end
  else
    begin
      ImageEnViewCurr.IEBitmap.AdjustmentsMask.Empty(); 
      ImageEnViewCurr.Update;
    end;

It looks as if the masking function, once set, remains active somehow.

Either I must be doing wrong something obvious or there is a flaw in the new function.

Any idea?

Regards,

Jan Steevens
Go to Top of Page

xequte

38616 Posts

Posted - Apr 23 2015 :  19:10:58  Show Profile  Reply
Hi Jan

We'll have a fix for this in v6.0.1.



Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
Go to Top of Page

JanSteevens

Netherlands
17 Posts

Posted - Apr 24 2015 :  02:52:46  Show Profile  Reply
Hi Nigel,

Thank you for looking into the problem. Avoids going on trying. Will I get a notification when 6.01 is released or will the update be announced somewhere?

Regards,

Jan Steevens

Go to Top of Page

xequte

38616 Posts

Posted - Apr 24 2015 :  03:18:57  Show Profile  Reply
Hi Jan

Subscribe to this post for release notifications:

http://www.imageen.com/ieforum/topic.asp?TOPIC_ID=215



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: