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
 Selection
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

brm121966

USA
64 Posts

Posted - Feb 10 2024 :  18:13:21  Show Profile  Reply
Hello.
13th version.
Got the situation.
If you clear ImageEnView - ClearAll; Blank();
Load an image and select it using the Rectangle method.
Hover the cursor over the marks to narrow the selection area - the cursor does not change and changes are not possible.
But if you click on the right side of the picture, the selection will be reset.
Then select the area again using the Rectangle method.
Change the area to become available.
Tell me how to correctly work with methods for selecting areas that can be changed?

Thank you.
Rudolf

xequte

38608 Posts

Posted - Feb 12 2024 :  20:01:23  Show Profile  Reply
Hi Rudolf

So i started a new application and added a TImageEnView and Button.

I added this code to the button click event:

  ImageEnView1.ClearAll();
  ImageEnView1.Blank();
  ImageEnView1.IO.LoadFromFile( 'D:\im.jpg' );
  ImageEnView1.MouseInteractGeneral := [miSelect];

I created a selection and was able to size it as expected.

Can you give me more information?

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

brm121966

USA
64 Posts

Posted - Feb 13 2024 :  23:01:14  Show Profile  Reply
Hi Nigel.
It looks like the problem is in the maximum selected area.
I select an area inside the image and expand the left area to the maximum left side of the image.
After this manipulation, it is impossible to change the left size of the selected area.
The same applies to other sides of the selected area.
Thanks.

Rudolf
Go to Top of Page

xequte

38608 Posts

Posted - Feb 14 2024 :  22:37:11  Show Profile  Reply
Hi Rudolf

I'm not seeing that. Can you create a small demo that shows it and the steps I need to take.

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

brm121966

USA
64 Posts

Posted - Mar 03 2024 :  11:16:06  Show Profile  Reply
Hi Nigel.
I have a problem with drawing the selected area (see picture).
Given: A layer with a selected area of the entire layer in the center of the image. property set
let's start

    with ImageEnView do begin
      LayersAdd( ielkShape,600, 600, 300, 300 );
      TIEShapeLayer(CurrentLayer).Shape := iesRoundRect;
      with CurrentLayer do begin
        BorderColor  := clBlack;
        BorderWidth  := 2;
        FillColor    := $00F0F0F0; //clBlack;
        FillColor2   := clWhite;
        FillGradient := gpgDiagCenter2; //gpgVertical;
        Opacity := 0.2;
        Cropped := true;
      end;
      Soft_Shadow(CurrentLayer,40);
    end;

After going beyond the main image contour.
Resizes the selected area of the moved layer.
See attached image.



Rudolf

Go to Top of Page

xequte

38608 Posts

Posted - Mar 03 2024 :  17:28:53  Show Profile  Reply
Hi Rudolf

What is your Soft_Shadow() code?

Did you call ImageEnView.Update() after setting the soft shadow?

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

brm121966

USA
64 Posts

Posted - Mar 07 2024 :  22:57:06  Show Profile  Reply
Hi Nigel
The code was adjusted, but the effect remained.

    with IEV_Load do begin
      LayersAdd( ielkImage,500, 500, 250, 2500 );
      IO.LoadFromFileAuto(ImageEnMView.SelectedFilename);
      with CurrentLayer do begin
        BorderColor := clBlack;
        BorderWidth := 0;
        Cropped := true;
      end;
      Soft_Shadow(CurrentLayer,40);
      Update();
    end;

procedure Soft_Shadow(o_pCL:TIELayer;n_pR:Integer);
begin
  with o_pCL.SoftShadow do begin
    Enabled := True;
    OffsetX := 0;
    OffsetY := 0;
    ShadowColor := TColor2TRGB( clWhite );
    Radius  := n_pR;
  end;
end;


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