Skip to main content
March 20, 2008
Question

Memory Release in RenderSuite

  • March 20, 2008
  • 2 replies
  • 1720 views
Howdy,

I've had problems with releasing used memory using RenderSuite2.

In the plugin I call AEGP_RenderAndCheckoutFrame to get a receipt for the pixels, and AEGP_GetReceiptWorld to get the raw pixels. After tweaking the pixels i call AEGP_CheckInFrame to release the pixels. I do not dispose the world i get.

For some reason, i see that AEGP_CheckInFrame does not release the pixels, and that the memory is only being released when closing the project/AE program.

Any idea why it happens?

Thanks,
Eran Kalmanson
This topic has been closed for replies.

2 replies

March 23, 2008
Thanks for the quick answer.

It doesn't seem that the AE frees the memory it uses. When rendering a ~40 sec comp (480x360), and handling each and every one of the frames (and specifically when getting the receipt for the frame) in the comp the AE process takes approximately 1GB of physical memory (which naturally is alot). It seems that the grabbed frames are not being released properly for some reason. Only when closing the project and then AE the memory is released.

attached is the code I've written:

// get the reciept for the frame ERR(suites.RenderSuite2()->AEGP_RenderAndCheckoutFrame(roH, NULL, NULL, &receipt));

if (receipt){
AEGP_WorldH frameH = NULL;
PF_Pixel8 *pixelBase;
unsigned char *srcRow, *dstRow, *frameBase;
A_u_long rowBytes;

ERR(suites.RenderSuite2()->AEGP_GetReceiptWorld(receipt, &frameH));
ERR(suites.WorldSuite2()->AEGP_GetBaseAddr8(frameH, &pixelBase)); ERR(suites.WorldSuite2()->AEGP_GetRowBytes(frameH, &rowBytes));

// frame handling

// frame release
ERR(suites.RenderSuite2()->AEGP_CheckinFrame(receipt));
}
Bruce Bullis
Community Manager
Community Manager
March 21, 2008
Your release of the memory lets AE re-use it, if it wants to; it doesn't force AE to re-use the memory. Try a RAM preview after releasing the memory; you should see it get re-used.
Participant
November 1, 2021

Has an API to reuse this memory ?