//-------------------------------------------------------------- void Kepler::draw() { pushAll(); ramBeginCamera(); mKeplerDynamics.draw(); ramEndCamera(); popAll(); }
LinkedElements (IT elements) : head_(0) { try { pushAll(elements); } catch(...) { WARN (progress, "Failure while populating LinkedElements list. " "All elements will be discarded"); clear(); throw; } }
//-------------------------------------------------------------- void Kepler::drawActor(ramActor &actor) { pushAll(); glEnable(GL_DEPTH_TEST); glDisable(GL_LIGHTING); for (int i=0; i<actor.getNumNode(); i++) { ramNode &node = actor.getNode(i); float jointSize = (i==ramActor::JOINT_HEAD) ? 6.0 : 3.0; node.beginTransform(); ofSetColor(ramColor::BLUE_LIGHT); ofNoFill(); ofBox(jointSize); if (i==mNodeA || i==mNodeB) { ofSetColor(ramColor::RED_LIGHT); ofBox(jointSize*1.5f); } node.endTransform(); if (node.hasParent()) { ofSetColor(ramColor::RED_LIGHT); ofLine(node, *node.getParent()); } } const ofVec3f lhp = actor.getNode(mNodeA).getGlobalPosition(); const ofVec3f rhp = actor.getNode(mNodeB).getGlobalPosition(); mPickerA.updatePosition(btVector3(lhp.x, lhp.y, lhp.z)); mPickerB.updatePosition(btVector3(rhp.x, rhp.y, rhp.z)); popAll(); }
/** @return the next smallest number */ int next() { TreeNode *cur = myStack.top(); myStack.pop(); pushAll(cur->right); return cur->val; }
BSTIterator(TreeNode *root) { pushAll(root); }
/** @return the next smallest number */ int next() { TreeNode * top = s.top(); s.pop(); pushAll(top -> right); return top -> val; }
/** @return the next smallest number */ int next() { TreeNode *tmpNode = myStack.top(); myStack.pop(); pushAll(tmpNode->right); return tmpNode->val; }