Looking at PhotoshopSDK.h I see that STL headers for vectors and strings are there. Does using these containers work OK with the special requirements for getting and releasing memory in plugins? Looking at PIUNew.h, there is a comment which says that one should ''Use the buffer procs for large image requests'' which implies one should be restrained in how much one allocates with that version of new. I am suspecting that the same consideration would apply with STL containers. Is this right? What is a safe upper limit on the amount of memory one could use before going to buffer procs?
Mike
Using STL in Plugins?
As long as you free all of the items correctly in the plugin, and don't try to allocate a LOT of memory using them - it should be fine.
The upper limit depends a lot on the Photoshop preferences, and how your plugin will allocate those little bits (lately, we face address space fragmentation sooner than really running out of RAM).
Subscribe to:
Post Comments
(Atom)
No comments:
Post a Comment