Thread Previous • Date Previous • Date Next • Thread Next |
I don't get the relation with "reset" behaviour. The problem is not to load the value, but to save it. I see no way to synchronize the registered Real with the different threads values. I'm thinking a virtual member void Functor::sync() could be the solution, it could be called after the parallel sections in the dispatcher. It would synchronize things once per step. Other than that, I don't see any solution. Perhaps I'll just let energy be a temporary variable, always 0 in loaded scenes, and let users store it with python if they need.No, the accumulator is not serializable (and is not meant to be, it is just a special increment-only variable). You could, though add a private bool doReset, which would be an additional (optional) parameter to the ctor (True by default) which would prevent reset() from doing anything. That would be the easiest, I think.
Don't worry, I'm watching this. But for now taucs support is in the TODO list. Actually, I'm not sure it will change our situation when taucs will be supported. The fluid model is based on CGAL kernel, thus using taucs implies for now passing coordinates of points and vectors under the form of Real values. Using Eigen, it would need to convert CGAL::Vector to Eigen::Vector first, then use Eigen::taucs. It is exactly the same. So, I'm not sure integrating the layer Eigen bewteen taucs and CGAL would give any advantage.BTW2 regarding dropping Wm3 and moving to eigen: eigen has support for taucs solver with its sparse matrices, see http://eigen.tuxfamily.org/dox/TutorialSparse.html
Cheers. Bruno
Thread Previous • Date Previous • Date Next • Thread Next |