Commit graph

187 commits

Author SHA1 Message Date
Seth Alves
e14b4c6ad4 cleanups 2015-04-27 11:01:48 -07:00
Andrew Meadows
e3d29d74af name changes and preparation for more cleanup 2015-04-26 15:24:30 -07:00
Seth Alves
6e6793cbcc remove debugging prints 2015-04-24 15:18:02 -07:00
Andrew Meadows
3ecf959b3e removed cached copies of damping and restitution 2015-04-24 14:50:37 -07:00
Seth Alves
e7c6ee597a sync 2015-04-24 14:36:05 -07:00
Seth Alves
ea250c037a sync 2015-04-24 14:27:32 -07:00
Seth Alves
6b53fefebe sync 2015-04-24 14:21:59 -07:00
Andrew Meadows
c4395e75bb cleanup and comments 2015-04-24 13:26:26 -07:00
Seth Alves
6d151ee3ed try a different way of identifying when to claim simulation ownership of a moving entity 2015-04-24 09:29:05 -07:00
Seth Alves
cf0499e671 various physics-related experiments 2015-04-23 21:07:04 -07:00
Seth Alves
2ca592de8b fix logic with infectious simulation ownership 2015-04-23 10:02:29 -07:00
Seth Alves
10e5378396 fix mangled if 2015-04-23 09:13:18 -07:00
Seth Alves
9e96026c52 move _accelerationNearlyGravityCount and _shouldClaimSimulationOwnership from EntityItem to EntityMotionState 2015-04-22 21:36:36 -07:00
Seth Alves
4ca076ed94 put PhysicsEngine::bump back in. some things get missed if we just set the one thing active 2015-04-22 18:53:49 -07:00
Seth Alves
5a7f8a2f5a git rid of unneeded bump code. re-indent billiards.js and rez in balls with some y velocity so they fall to the table 2015-04-22 17:06:21 -07:00
Seth Alves
864f8cb3b3 fix comment 2015-04-22 16:10:25 -07:00
Seth Alves
96b4517e6e when removing something from bullet, attempt to wake up anything that was touching it 2015-04-22 16:05:31 -07:00
Seth Alves
07a848c9ce added bump call in physics engine for when an entity is deleted and may have something resting on top of it 2015-04-22 15:50:39 -07:00
Seth Alves
3450597d70 remove some debugging prints 2015-04-22 15:03:23 -07:00
Seth Alves
c30d742f7d experimenting 2015-04-22 14:22:09 -07:00
Seth Alves
36dbbd0c9d experimenting 2015-04-22 14:14:12 -07:00
Seth Alves
cd3ee39fcc experimenting 2015-04-22 13:42:04 -07:00
Seth Alves
ee000f91ae experimenting 2015-04-22 13:27:19 -07:00
Seth Alves
27ed0c4a98 experimenting 2015-04-22 13:21:06 -07:00
Seth Alves
7382b0b19f experimenting 2015-04-22 13:17:20 -07:00
Seth Alves
32673efc80 compute collision events inside lock to avoid a rare crash 2015-04-22 10:51:45 -07:00
Andrew Meadows
65825a4501 Merge pull request #4659 from ericrius1/collision
Filtering triggering of collisions with contact type of "continue"
2015-04-22 09:33:40 -07:00
Seth Alves
23f1767634 cleanup 2015-04-20 16:13:28 -07:00
Seth Alves
d6c8bd94cf clean up some debugging prints 2015-04-20 15:59:33 -07:00
Seth Alves
08d300afcd use a flag to indicate that simulation ownership should be grabbed 2015-04-20 11:49:10 -07:00
Seth Alves
88f289f3c1 small cleanup and some debugging prints 2015-04-20 11:19:48 -07:00
Seth Alves
fbff3627dc attempt to claim simulation ownership of entities the avatar crashes with 2015-04-20 11:13:51 -07:00
Eric Levin
2b4d894ab3 moved the type computation inside the while loop so it is correctly computed each iteration 2015-04-17 08:17:58 -07:00
Eric Levin
096f69961a Filtering triggering of collisions with contact type of "continue" 2015-04-16 16:42:28 -07:00
Andrew Meadows
619d1ba191 rename to measureAcceleration 2015-04-16 14:09:33 -07:00
Andrew Meadows
5180e7e715 measure linear velocity of moving objects 2015-04-16 13:44:17 -07:00
Andrew Meadows
abb40ca080 cleanup: split stats dump out of stepSimulation 2015-04-14 09:00:36 -07:00
Andrew Meadows
40c94fa00e merge upstream/master into andrew/isentropic 2015-04-07 16:23:38 -07:00
Seth Alves
55bab2efd6 put physics into its own logging group 2015-04-06 18:09:45 -07:00
Andrew Meadows
435ce106eb Add DynamicCharacterController prototype 2015-04-06 16:03:13 -07:00
Andrew Meadows
27d6d9f720 add Bullet profiling hooks for physics simulation 2015-04-02 15:20:16 -07:00
Andrew Meadows
94c1cf12f5 deleting _dynamicsWorld doesn't crash on shutdown 2015-03-30 17:12:19 -07:00
Philip Rosedale
f116ac131d Merge pull request #4532 from AndrewMeadows/inertia
fix crash in PhysicsEngine on shutdown
2015-03-30 16:31:34 -07:00
Andrew Meadows
c6b34df06c unlock after character is properly updated 2015-03-30 16:07:56 -07:00
Seth Alves
ee7247a5b4 fix a couple of crashes 2015-03-30 15:56:01 -07:00
Andrew Meadows
9b13f186e3 remove character from PhysicsEngine on shutdown 2015-03-30 15:51:58 -07:00
Seth Alves
7137b41375 free these so it's easier to see other leaks in valgrind 2015-03-30 09:30:37 -07:00
Andrew Meadows
430158c109 updateShapeIfNecessary() is a more correct name 2015-03-24 23:35:09 -07:00
Andrew Meadows
44eca08fa4 PhysicsEngine doesn't need AvatarData
MyAvatar now owns its CharacterController
fix for bug of phantom collision obj when avatar's physics are disabled
2015-03-24 17:38:35 -07:00
Andrew Meadows
6454149536 formatting and comments 2015-03-20 12:45:29 -07:00
Andrew Meadows
90a8844738 merge upstream/master into andrew/bispinor
Conflicts:
	libraries/physics/src/PhysicsEngine.cpp
2015-03-19 16:18:52 -07:00
Brad Davis
91906d619f Removing unmatched QReadWriteLock::unlock() call 2015-03-18 22:32:06 -07:00
Andrew Meadows
c032b29633 proper shape management for ConvexHull shapes 2015-03-18 16:29:57 -07:00
Seth Alves
dd97b54e52 quiet physics log spam 2015-03-18 13:22:29 -07:00
Seth Alves
2dd75fef2c remove some unneeded Q_OBJECT macros, diff minimization 2015-03-17 19:12:26 -07:00
Seth Alves
b76103edb0 clean up debugging spew 2015-03-16 16:44:29 -07:00
Andrew Meadows
78b614f855 move avatar details into CharacterController 2015-03-16 16:24:32 -07:00
Seth Alves
59e4efa651 debugging prints around a deadlock 2015-03-15 07:10:43 -07:00
Seth Alves
250567e315 formatting, diff minimization 2015-03-14 12:09:23 -07:00
Seth Alves
b815c365eb formatting 2015-03-13 18:57:27 -07:00
Seth Alves
87cc710efc more merge madness, calculate 2nd PhysicsEngine hash with qChecksum if url is set 2015-03-13 18:43:24 -07:00
Seth Alves
50798398ff merge from upstream 2015-03-13 18:04:55 -07:00
Seth Alves
2368e6e5b7 collision with a hull sort of works. there is a new memory corruption problem 2015-03-13 15:41:57 -07:00
Andrew Meadows
99e2d799c5 correct math for capsule halfHeight 2015-03-13 09:40:32 -07:00
Seth Alves
89b58e2681 trying to get loaded callback for model hooked up to PhysicsEngine 2015-03-13 09:11:15 -07:00
Seth Alves
a945421d9d still trying to make PhysicsEngine::addEntityInternal be async 2015-03-12 16:38:55 -07:00
Andrew Meadows
a1a12465da able to update avatar controller in PhysicsEngine 2015-03-12 16:36:41 -07:00
Seth Alves
2cf0e1ab25 break PhysicsEngine::addEntityInternal in half, making the 2nd part asynch. This is to allow a ModelEntityItem time to download its collision hull before the 2nd part runs 2015-03-12 15:58:09 -07:00
Andrew Meadows
3d531e8304 add f at end of float literal 2015-03-10 14:24:49 -07:00
Andrew Meadows
fd76eda383 slightly better hardcoded size for avatar capsule
we'll be measuring avatar dimensions more correctly soon
2015-03-09 17:59:45 -07:00
Andrew Meadows
3c05d685d7 avoid assert for zero-length character velocity 2015-03-09 17:37:34 -07:00
Seth Alves
ab8784f1b4 add comment about character capsule being hard-coded 2015-03-09 13:51:08 -07:00
Seth Alves
b2cfed8bca removed unused blob of code 2015-03-08 09:04:00 -07:00
Seth Alves
ac0c4e8512 cap max speed at MAX_WALKING_SPEED 2015-03-04 19:57:06 -08:00
Seth Alves
a8b688d540 move _velocity into base class. walking on a cube works 2015-03-04 15:26:02 -08:00
Seth Alves
b4998e9c53 falling onto an object works 2015-03-04 08:48:48 -08:00
Seth Alves
8eec66c066 merge upstream, avatar can now fall onto a cube 2015-03-03 18:37:16 -08:00
Seth Alves
7e4b597ca3 keep physics specific code in PhysicsEngine 2015-03-03 15:45:10 -08:00
Andrew Meadows
5776df1012 load dynamic obj as inactive when not moving 2015-02-25 12:07:19 -08:00
Andrew Meadows
b4da2ddd52 fix physics crash on disconnect from domainserver 2015-02-05 09:13:32 -08:00
Andrew Meadows
23bd3f90d9 Bullet-style rotation integration for kinematics
and for dead reckoning after wire-transfer
2015-01-27 17:27:15 -08:00
Andrew Meadows
d5c0c200de optimization for when physics engine doesn't step 2015-01-27 15:54:32 -08:00
Andrew Meadows
1ad5f9c7db merge upstream/master into andrew/isentropic
Conflicts:
	libraries/physics/src/ObjectMotionState.cpp
2015-01-23 14:04:26 -08:00
Andrew Meadows
b34189115d Merge branch andrew/isentropic 2015-01-23 13:21:45 -08:00
Andrew Meadows
f2bcdfa2b4 update _lastSimulated for kinematic motion 2015-01-23 13:10:41 -08:00
Andrew Meadows
d173afaa70 add support for non-physical kinematic movement 2015-01-23 11:01:46 -08:00
Andrew Meadows
3997b916c1 remove ground collision hack for physics testing 2015-01-22 09:17:51 -08:00
Andrew Meadows
77c4362991 fix typo 2015-01-21 18:14:24 -08:00
Andrew Meadows
b2e79a0157 don't process results when no simulation 2015-01-21 18:06:19 -08:00
Andrew Meadows
2751fab2c3 don't send collision events for inactive pairs
also throttle collision events to 30/sec
2015-01-21 18:02:13 -08:00
Andrew Meadows
1c38b08e8f remane emitEntityCollision... to entityCollision... 2015-01-21 14:07:23 -08:00
Andrew Meadows
6840daa0b5 removing tabs from formatting 2015-01-21 11:55:28 -08:00
Andrew Meadows
e49c76656f merge upstream/master into andrew/isentropic
Conflicts:
	libraries/physics/src/PhysicsEngine.cpp
2015-01-21 11:35:36 -08:00
Andrew Meadows
86583f3f3f physics collisions emit script collision events 2015-01-21 11:27:32 -08:00
Andrew Meadows
790d07d346 track known contacts and generate collision events 2015-01-20 14:18:10 -08:00
Andrew Meadows
5da38834e2 introduce notion of NumSteps vs NumSubsteps 2015-01-20 11:16:40 -08:00
Andrew Meadows
0154c613d0 change FrameCount to NumSubsteps for more accuracy 2015-01-20 11:02:48 -08:00
Andrew Meadows
549e3fac5f store backpointer to MotionState in btRigidBody 2015-01-20 10:45:58 -08:00
Andrew Meadows
e4f29412d5 cheaper failure adding entity to physics engine 2015-01-19 18:11:14 -08:00
Andrew Meadows
171fead347 remove log about failure to add to physics engine 2015-01-19 15:55:53 -08:00