yade-dev team mailing list archive
-
yade-dev team
-
Mailing list archive
-
Message #05445
[Bug 607836] Re: b.dynamic and b->isDynamic() out of synchro in case of save/load
** Attachment added: "Script"
http://launchpadlibrarian.net/52215350/TestRotBlockedDOF.py
--
b.dynamic and b->isDynamic() out of synchro in case of save/load
https://bugs.launchpad.net/bugs/607836
You received this bug notification because you are a member of Yade
developers, which is subscribed to Yade.
Status in Yet Another Dynamic Engine: New
Bug description:
The attached script will illustrate the title.
It is about a sphere which is created as dynamic=False, then updated to dynamic=True, in order to let rotate it with NewtonIntegrator.
Directly with the script as it is joined, you will observe that the orientation of the sphere is unfortunately not at all modified.
But, "hokus pokus", (magic expression) comment l.27-28 about the save/load, re-run and you will have the orientation which evolves...
The reason is in b->isDynamic() (in C++). In the first case (with save/load), you will have b->isDynamic()=0 (in C++), even if b.dynamic=True (in python)
Whereas, in the second case, things are as they should : b->isDynamic() = b.dynamic = True
You can easily check this with logs from NewtonIntegrator.cpp (I could not attach the file with cout typed I used : no more than one attachment it seems)
References