Revision: 52521 http://brlcad.svn.sourceforge.net/brlcad/?rev=52521&view=rev Author: Abhi2011 Date: 2012-09-24 14:38:26 +0000 (Mon, 24 Sep 2012) Log Message: ----------- Removed all the logging lines.
Modified Paths: -------------- brlcad/trunk/src/libged/simulate/simphysics.cpp brlcad/trunk/src/libged/simulate/simulate.c Modified: brlcad/trunk/src/libged/simulate/simphysics.cpp =================================================================== --- brlcad/trunk/src/libged/simulate/simphysics.cpp 2012-09-24 14:20:21 UTC (rev 52520) +++ brlcad/trunk/src/libged/simulate/simphysics.cpp 2012-09-24 14:38:26 UTC (rev 52521) @@ -235,7 +235,7 @@ btDefaultMotionState* bb_MotionState = (btDefaultMotionState*)bb_RigidBody->getMotionState(); bb_MotionState->m_graphicsWorldTrans.getOpenGLMatrix(m); - bu_log("Position : %f, %f, %f\n", m[12], m[13], m[14]); + //bu_log("Position : %f, %f, %f\n", m[12], m[13], m[14]); struct rigid_body *current_node = (struct rigid_body *)bb_RigidBody->getUserPointer(); @@ -272,9 +272,9 @@ v = bb_RigidBody->getLinearVelocity(); VMOVE(current_node->linear_velocity, v); - bu_log("Got linear velocity as : %f, %f, %f", current_node->linear_velocity[0], + /*bu_log("Got linear velocity as : %f, %f, %f", current_node->linear_velocity[0], current_node->linear_velocity[1], - current_node->linear_velocity[2]); + current_node->linear_velocity[2]);*/ v = bb_RigidBody->getAngularVelocity(); VMOVE(current_node->angular_velocity, v); @@ -536,8 +536,6 @@ //Add the rigid bodies to the world, including the ground plane add_rigid_bodies(dynamicsWorld, collision_shapes); - bu_log("After add_rigid_bodies()\n"); - //Add a broadphase callback to hook to the AABB detection algos /* btOverlapFilterCallback * filterCallback = new broadphase_callback(); dynamicsWorld->getPairCache()->setOverlapFilterCallback(filterCallback); @@ -553,18 +551,12 @@ //Step the physics the required number of times step_physics(dynamicsWorld); - bu_log("After step_physics()\n"); - //Get the world transforms back into the simulation params struct get_transforms(dynamicsWorld); - bu_log("After get_transforms()\n"); - //Clean and free memory used by physics objects cleanup(dynamicsWorld, collision_shapes); - bu_log("After cleanup()\n"); - //Clean up stuff in here //delete filterCallback; delete solver; Modified: brlcad/trunk/src/libged/simulate/simulate.c =================================================================== --- brlcad/trunk/src/libged/simulate/simulate.c 2012-09-24 14:20:21 UTC (rev 52520) +++ brlcad/trunk/src/libged/simulate/simulate.c 2012-09-24 14:38:26 UTC (rev 52521) @@ -92,19 +92,20 @@ for (dp = gedp->ged_wdbp->dbip->dbi_Head[i]; dp != RT_DIR_NULL; dp = dp->d_forw) { if ((dp->d_flags & RT_DIR_HIDDEN) || /* check for hidden comb/prim */ !(dp->d_flags & RT_DIR_REGION) /* check if region */ - ) - continue; + ) { + continue; + } if (strstr(dp->d_namep, prefix)) { - bu_vls_printf(gedp->ged_result_str, "add_regions: Skipping \"%s\" due to \"%s\" in name\n", + bu_vls_printf(gedp->ged_result_str, "add_regions: Skipping \"%s\" due to \"%s\" in name\n", dp->d_namep, prefix); - continue; + continue; } if (BU_STR_EMPTY(dp->d_namep)) { bu_vls_printf(gedp->ged_result_str, "add_regions: Skipping \"%s\" due to empty name\n", dp->d_namep); - continue; + continue; } /* Duplicate the region */ @@ -252,8 +253,6 @@ return GED_ERROR; } - bu_log("After 1"); - /* Apply inverse rotation with no translation to undo previous iteration's rotation */ MAT_COPY(m, current_node->m_prev); m[12] = 0; @@ -267,8 +266,6 @@ return GED_ERROR; } - bu_log("After 2"); - /*---------------------- Now apply current transformation -------------------------*/ /* Apply rotation with no translation*/ @@ -284,8 +281,6 @@ return GED_ERROR; } - bu_log("After 3"); - /* Translate again without any rotation, to apply final position */ MAT_IDN(m); m[12] = current_node->m[12]; @@ -300,8 +295,6 @@ return GED_ERROR; } - bu_log("After 4"); - /* Write the modified solid to the db so it can be redrawn at the new position & orientation by Mged */ if (rt_db_put_internal(current_node->dp, gedp->ged_wdbp->dbip, &intern, &rt_uniresource) < 0) { bu_vls_printf(gedp->ged_result_str, "apply_transforms: ERROR Database write error for '%s', aborting\n", @@ -309,8 +302,6 @@ return GED_ERROR; } - bu_log("After 5"); - /* Store this world transformation to undo it before next world transformation */ MAT_COPY(current_node->m_prev, current_node->m); @@ -336,8 +327,6 @@ { struct rigid_body *current_node; - printf("recreate_sim_comb: enter "); - if (sim_kill(gedp, sim_params->sim_comb_name) != GED_OK) { bu_log("sim_kill_copy: ERROR Could not delete existing \"%s\"\n", sim_params->sim_comb_name); return GED_ERROR; @@ -345,11 +334,9 @@ for (current_node = sim_params->head_node; current_node != NULL; current_node = current_node->next) { - add_to_comb(gedp, sim_params->sim_comb_name, current_node->rb_namep); + add_to_comb(gedp, sim_params->sim_comb_name, current_node->rb_namep); } - printf("recreate_sim_comb: exit "); - return GED_OK; } @@ -460,8 +447,6 @@ /* Recreate sim.c to clear AABBs and manifold regions from previous iteration */ recreate_sim_comb(gedp, &sim_params); - bu_log("After recreate_sim_comb()"); - /* Run the physics simulation */ sim_params.iter = i; rv = run_simulation(&sim_params); @@ -470,8 +455,6 @@ return GED_ERROR; } - bu_log("After run_simulation()"); - /* Apply transforms on the participating objects, also shades objects */ rv = apply_transforms(gedp, &sim_params); if (rv != GED_OK) { @@ -479,8 +462,6 @@ return GED_ERROR; } - bu_log("After apply_transforms()"); - /* free the raytrace instance */ rt_free_rti(sim_params.rtip); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ BRL-CAD Source Commits mailing list brlcad-commits@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/brlcad-commits