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
 TImageEnProc

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
Bernhard Posted - Feb 08 2021 : 06:21:37
Hi,

using Delphi, I can create an instance of TImageEnProc:
proc := TImageEnProc.CreateFromBitmap(bmp);
or
proc := TImageEnProc.create(nil);

How can I create an instance of TImageEnProc with C++? Everything I tried didn't work.

Thank you for any help
Bernhard
3   L A T E S T    R E P L I E S    (Newest First)
xequte Posted - Feb 10 2021 : 23:23:45
Hi Bernhard

My C++ is not great, but I would have thought you'd need to pass a TComponent class, e.g.

TImageEnProc *proc = new TImageEnProc(Self);

Nigel
Xequte Software
www.imageen.com
Bernhard Posted - Feb 09 2021 : 01:53:48
Hi Nigel,
Thanks for the prompt reply.
Of course I tried this line and the compiler aborted with the error message:
Delphi-style classes must be allocated with 'new'

Then I tried
TImageEnProc *proc = new TImageEnProc;
This works with TIEBitmap, for example, but not with TImageEnProc. The compiler aborted with:
no matching constructor for initialization of 'Imageenproc::TImageEnProc'

Next I tried:
TImageEnProc *proc = new TImageEnProc(NULL);
Compiler refused work and responded: call to constructor of 'Imageenproc::TImageEnProc' is ambiguous

Now I've tried something else:
TIEBitmap *Quelle = new TIEBitmap;
TImageEnProc *proc = new TImageEnProc(Quelle);
And so it finally worked!

Should that be mentioned in the help for the class?
xequte Posted - Feb 08 2021 : 18:46:21
Hi Bernhard

It should be the same:

TImageEnProc proc = TImageEnProc->create(NULL);

Nigel
Xequte Software
www.imageen.com