Thread Previous • Date Previous • Date Next • Thread Next |
Le 04/06/2010 11:05, Václav Šmilauer a écrit :
Thanks for this remark. But in fact these lines will probably disappear because their goal was to identify which contact law is used. And now it is a functor, it can not anymore be done by looping over engines. I have to focus on interactions now, but I'll have to think what's the best (loop over all interactions ? pick one ?)- vector<shared_ptr<Engine> >::iterator itFirst = scene->engines.begin(); - vector<shared_ptr<Engine> >::iterator itLast = scene->engines.end(); - for ( ;itFirst!=itLast; ++itFirst ) - {Use FOREACH(const shared_ptr<Engine>& e, scene->engines){...} that will make your code a lot more readable.
Thread Previous • Date Previous • Date Next • Thread Next |