GetData multiple times
-
On 08/04/2014 at 09:40, xxxxxxxx wrote:
If you call GetData multiple times from the same location from different functions will you get the same data?
Does calling GetData clear out what is in that memory location?
example:
def Message(self, op, type, data) : #op is the tag
if type==c4d.MSG_DESCRIPTION_POSTSETPARAMETER:
startJoint = d.GetData(FINAL_LINK)def Execute(self, tag, doc, op, bt, priority, flags) :
self.final_cd = data.GetData(FINAL_LINK)do startJoint and self.final_cd have the same data?
Jimmy
-
On 08/04/2014 at 14:00, xxxxxxxx wrote:
Look at the documentation of BaseContainer::GetData(). You can also easily verify this with
a short example.But to answer your question, not it does not clear the data. GetData() would be a very inappropriate
name if it would. They will get the same data unless something else was able to access and modify
the specified entry.We assume, of course, that "d" in Message() and "data" in Execute() refer to the same object.
-Niklas