Re: Passing Bitmap as parameter to DLL
- From: "Peter Below (TeamB)" <none@xxxxxxxxxxxxx>
- Date: 27 Jul 2008 01:30:06 -0700
Andy wrote:
I have a Delphi DLL and I would like to pass a TBitmap as a
parameter. How do I go about doing this and especially how to create
and free it without problems? Any help is greatly appreciated.
To pass objects from a host application to a DLL you have to build both
projects with run-time packages, using the core rtl and vcl packages as
well as any others that contain classes you want to pass across the
module boundary. The objects you pass should always be created and
destroyed in the same module, if possible. But since packages also get
you a common memory manager it would be no problem to have the DLL
create and return a TBitmap and have the host exe destroy it, you just
have to make sure the responsibilities are clearly documented.
--
Peter Below (TeamB)
Don't be a vampire (http://slash7.com/pages/vampires),
use the newsgroup archives :
http://www.tamaracka.com/search.htm
http://groups.google.com
.
- References:
- Passing Bitmap as parameter to DLL
- From: Andy
- Passing Bitmap as parameter to DLL
- Prev by Date: Re: Writing CD/DVD
- Next by Date: Re: The Match : Elevate DB 2.0 VS Nexus DB
- Previous by thread: Re: Passing Bitmap as parameter to DLL
- Next by thread: Re: Passing Bitmap as parameter to DLL
- Index(es):
Relevant Pages
|