[Insight-users] Image Memory Management
Luis Ibanez
luis.ibanez@kitware.com
Wed, 11 Dec 2002 13:57:32 -0500
Hi David,
Thanks for trying this code for us.
I'm glad to hear that the changes
worked fine for your purpose.
I already made the modifications on
the CVS repository.
We anticipate a release to be done by
late january. However, the repository
is in a quite stable state at this
point if you feel like risking to use
the CVS version.
Please let me know if you have any
questions
Thanks
Luis
----------------------------------------------
David Holmes wrote:
> Luis-
>
> As expected, your modifications worked like a gem. I
> am very pleased. The specific steps that I took were:
>
> (1) Add the three macro functions and a #define
> DRH_HACK to the importimagecontainer.h
>
> (2) In my code, I put
>
> T* out;
> #ifdef DRH_HACK
> in->GetPixelContainer()->SetContainerManageMemory(false)
> out =in->GetPixelContainer()->GetImportPointer()
> #else
> out= (T*) malloc(W*H*D)
> out = memcpy(out, (T *)in->GetBufferPointer(),W*H*D);
>
> #endif
> return out;
>
>
> Like I said, it works just as I want it and if I
> distribute my code to other that don't have it, it
> should also work.
>
> But, that gets me to a more important question. If
> this is useful to other and it is added to the source,
> then I would expect to see it in the development
> version soon, however, when is the next scheduled
> release of the static version that would possibly have
> this?
>
> Thanks
>
> david
>
>
>