--- trunk/src/selection/SelectionEvaluator.cpp 2009/11/25 20:02:06 1390 +++ trunk/src/selection/SelectionEvaluator.cpp 2010/10/19 18:40:54 1513 @@ -51,7 +51,8 @@ namespace OpenMD { SelectionEvaluator::SelectionEvaluator(SimInfo* si) - : info(si), nameFinder(info), distanceFinder(info), indexFinder(info), + : info(si), nameFinder(info), distanceFinder(info), hullFinder(info), + indexFinder(info), isLoaded_(false){ nStuntDouble = info->getNGlobalAtoms() + info->getNGlobalRigidBodies(); } @@ -181,6 +182,9 @@ namespace OpenMD { case Token::within: withinInstruction(instruction, stack.top()); break; + case Token::hull: + stack.push(hull()); + break; //case Token::selected: // stack.push(getSelectionSet()); // break; @@ -273,6 +277,9 @@ namespace OpenMD { break; case Token::z: propertyValue = sd->getPos().z(); + break; + case Token::r: + propertyValue = sd->getPos().length(); break; default: unrecognizedAtomProperty(property); @@ -441,6 +448,16 @@ namespace OpenMD { } + OpenMDBitSet SelectionEvaluator::hull() { + OpenMDBitSet bs(nStuntDouble); + + bs = hullFinder.findHull(); + + return bs; + } + + + RealType SelectionEvaluator::getCharge(Atom* atom) { RealType charge =0.0; AtomType* atomType = atom->getAtomType();