ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 AddLayers ielkImage seems to have different size compared to another layer

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

View 
UserName:
Password:
Format  Bold Italicized Underline  Align Left Centered Align Right  Horizontal Rule  Insert Hyperlink   Browse for an image to attach to your post Browse for a zip to attach to your post Insert Code  Insert Quote Insert List
   
Message 

 

Emoji
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Black Eye [B)]
Frown [:(] Shocked [:0] Angry [:(!] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
AdrianKnowles Posted - Sep 21 2023 : 00:27:43
Hi,
I have two .png files containing the same icon just rotated. Both are 44x44 pixels

I add each of these into separate layers using the following code

LineTestImageEnView.LayersAdd( ielkImage, GrabTopx, GrabTopY, 50, 50 );
LineTestImageEnView.IO.LoadFromFile(ExtractFilePath(Application.ExeName) + 'UpDown2.png');

LineTestImageEnView.LayersAdd( ielkImage, GrabBotx, GrabBotY, 50, 50 );
LineTestImageEnView.IO.LoadFromFile(ExtractFilePath(Application.ExeName) + 'LeftRight.png');

However they appear to be different sizes. See attached image showing the two round icons

Am I doing something wrong?

Kind regards,
Adrian


2   L A T E S T    R E P L I E S    (Newest First)
AdrianKnowles Posted - Sep 21 2023 : 07:44:50
Hi,
I recreated both .png's in photoshop and now seems ok. Previously one was created in Affinity designer and one in Photoshop (I couldnt see any differences in the header though, weird)

Kind regards,
Adrian
xequte Posted - Sep 21 2023 : 02:06:50
Hi Adrian

I cannot reproduce that. Can you give me more information:

procedure Tfmain.Button1Click(Sender: TObject);
const
  GrabTopx = 100;
  GrabTopY = 100;
  GrabBotX = 100;
  GrabBotY = 200;
begin
  ImageEnView1.LayersAdd( ielkImage, GrabTopx, GrabTopY, 50, 50 );
  ImageEnView1.IO.LoadFromFile( 'D:\UpDown2.png');

  ImageEnView1.LayersAdd( ielkImage, GrabBotx, GrabBotY, 50, 50 );
  ImageEnView1.IO.LoadFromFile( 'D:\LeftRight.png');
end;


Nigel
Xequte Software
www.imageen.com