stepSimulation fn

anshul.bhardwaj
Posts: 28
Joined: Mon Aug 29, 2011 11:02 am

stepSimulation fn

Post by anshul.bhardwaj »

Hi,
I am using step simulation function in the following way...

Code: Select all

step(et,steps,btScalar(1.0/60));
where et is the time between two frames, steps = 10. and what i am getting the observation is

Code: Select all

Profiling: Root (total running time: 144.838 ms) ---
0 -- stepSimulation (99.99 %) :: 144.821 ms / frame (1 calls)
Unaccounted: (0.012 %) :: 0.017 ms
...----------------------------------
...Profiling: stepSimulation (total running time: 144.821 ms) ---
...0 -- synchronizeMotionStates (0.52 %) :: 0.746 ms / frame (10 calls)
...1 -- internalSingleStepSimulation (99.43 %) :: 143.993 ms / frame (10 calls)
...Unaccounted: (0.057 %) :: 0.082 ms
......----------------------------------
......Profiling: internalSingleStepSimulation (total running time: 143.993 ms) ---
......0 -- updateActivationState (0.03 %) :: 0.048 ms / frame (10 calls)
......1 -- updateActions (83.19 %) :: 119.785 ms / frame (10 calls)
......2 -- integrateTransforms (0.57 %) :: 0.821 ms / frame (10 calls)
......3 -- solveConstraints (0.87 %) :: 1.258 ms / frame (10 calls)
......4 -- calculateSimulationIslands (0.09 %) :: 0.125 ms / frame (10 calls)
......5 -- addSpeculativeContacts (0.29 %) :: 0.422 ms / frame (10 calls)
......6 -- performDiscreteCollisionDetection (14.36 %) :: 20.682 ms / frame (10 calls)
......7 -- predictUnconstraintMotion (0.38 %) :: 0.543 ms / frame (10 calls)
......Unaccounted: (0.215 %) :: 0.309 ms
.........----------------------------------
.........Profiling: solveConstraints (total running time: 1.258 ms) ---
.........0 -- solveGroup (27.74 %) :: 0.349 ms / frame (10 calls)
.........1 -- processIslands (39.43 %) :: 0.496 ms / frame (10 calls)
.........2 -- islandUnionFindAndQuickSort (13.75 %) :: 0.173 ms / frame (10 calls)
.........Unaccounted: (19.078 %) :: 0.240 ms
............----------------------------------
............Profiling: solveGroup (total running time: 0.349 ms) ---
............0 -- solveGroupCacheFriendlyIterations (13.18 %) :: 0.046 ms / frame (10 calls)
............1 -- solveGroupCacheFriendlySetup (42.12 %) :: 0.147 ms / frame (10 calls)
............Unaccounted: (44.699 %) :: 0.156 ms
.........----------------------------------
.........Profiling: performDiscreteCollisionDetection (total running time: 20.682 ms) ---
.........0 -- dispatchAllCollisionPairs (82.05 %) :: 16.969 ms / frame (10 calls)
.........1 -- calculateOverlappingPairs (1.45 %) :: 0.299 ms / frame (10 calls)
.........2 -- updateAabbs (15.97 %) :: 3.303 ms / frame (10 calls)
.........Unaccounted: (0.537 %) :: 0.111 ms
My application has minimum of 20 fps then how its completing in 10 calls, it should complete in 3 to 4 calls.
Or i am getting step simulation in wrong way?