void ramBaseApp::draw(ofEventArgs &args) { glPushAttrib(GL_ALL_ATTRIB_BITS); glEnable(GL_DEPTH_TEST); ramBeginCamera(); if (draw_floor_auto) drawFloor(); getActorManager().draw(); bool enable_physics = ramGetEnablePhysicsPrimitive(); ramEnablePhysicsPrimitive(false); glPushAttrib(GL_ALL_ATTRIB_BITS); glPushMatrix(); ofPushStyle(); if (ramShadowEnabled()) { // shadow ramBeginShadow(); drawNodeArrays(); ramEndShadow(); } ofPopStyle(); glPopMatrix(); glPopAttrib(); ramEnablePhysicsPrimitive(enable_physics); glPushAttrib(GL_ALL_ATTRIB_BITS); glPushMatrix(); ofPushStyle(); if (drawModel) { // entities drawNodeArrays(); } ofPopStyle(); glPopMatrix(); glPopAttrib(); ramEndCamera(); glPopAttrib(); }
void ramBaseApp::draw(ofEventArgs &args) { glPushAttrib(GL_ALL_ATTRIB_BITS); glEnable(GL_DEPTH_TEST); ramBeginCamera(); if (draw_floor_auto) drawFloor(); getActorManager().draw(); bool enable_physics = ramGetEnablePhysicsPrimitive(); ramEnablePhysicsPrimitive(false); if (ramShadowEnabled()) { // shadow ramBeginShadow(); drawNodeArrays(); ramEndShadow(); } ramEnablePhysicsPrimitive(enable_physics); if (drawModel) { // entities drawNodeArrays(); } ramEndCamera(); glPopAttrib(); getCommunicationManager().draw(); draw(); // calling testApp(or ofApp)::draw() }