void* lockHost(int bufferID)
A pointer to the memory block allocated by the host application.
Retrieves a pointer to a memory block allocated by the host application with the allocHost function. Since some graphics programs like Photoshop manage memory themselves, you might want to use this in preference to the C-language system memory functions like malloc.
int bufferID = allocHost(100); if (bufferID == NULL) { Warn("Could not allocate memory"); } else { char* memptr = lockHost(bufferID); sprintf(memptr, "Message goes here!"); Info(memptr); freeHost(bufferID); }