Commit Graph

52 Commits (28e68329b688b34279c5ff403a6f2b23994b452e)

Author SHA1 Message Date
Robert Adams eb0687f5af vh: update BulletSim (OpenSim/Region/Physics/BulletSPlugin
and DLL/SO) to ac6dcd35fb
(Mon May 6 21:10:02 2013 -0400) on top of 0.7.5-postfixes.
2013-05-08 06:02:12 -07:00
Robert Adams 80cee1b85a BulletSim: Fix single physical prim reporting its mass as zero.
Properly return root mass as mass of just the root prim rather
than the mass of the linkset. SOG has the logic to add the masses
together to get the linkset mass.
Update TODO list.
2012-12-24 08:56:02 -08:00
Robert Adams ae4d932e7f BulletSim: Move all the parameter variables, tables and get and fetch logic to a separate, static class for easier addition and to remove all that bulk from the BSScene class. 2012-12-21 13:35:44 -08:00
Robert Adams 2b8efa24dd BulletSim: add parameter to UpdateProperties call into the linkset so changes from the physics engine can be differentiated from changes made by the user. This eliminates a linkset rebuild loop. Also add logic to not rebuild or freak out when the object/linkset crosses a terrain boundry. 2012-12-16 21:19:13 -08:00
Robert Adams ace1f1e931 BulletSim: rip out old code for linkset child position fetching. BulletSim doesn't need to do that bookkeeping because SOG/SOP already does it. 2012-12-16 21:19:10 -08:00
Robert Adams 31d3952477 BulletSim: fix problem with continuious rebuilding of physical linksets. This caused movement problems and large prim vehicles to take up a LOT of simulation time. 2012-12-13 16:32:19 -08:00
Robert Adams 9df85eadf4 BulletSim: Fix crash on the destruction of physical linksets.
While fixing the above, add methods to physical body and shape pointer
wrapper so routines won't have to know that IntPtr.Zero means no
physical instance.
Fix problem with physical linksets failing after a few sits and
unsits by properly restoring child prom positions for compound
linksets after multiple selection and deselections.
2012-12-10 15:35:53 -08:00
Melanie 3b2caa63b0 Rename BulletSim's PhysicsShapeType to BSPhysicsShapeType because it
conflicts with PhysicsShape type defined in later libOMV
2012-11-22 14:45:41 +00:00
Robert Adams d6db0d5740 BulletSim: uplevel PhysicsShapeType out of ShapeData structure (since it is getting simplified out of existance someday) and update all the references to that enum. 2012-11-21 16:42:50 -08:00
Robert Adams 702fd1e094 BulletSim: only compute linkset mass when membership changes rather than everytime someone asks for it. 2012-11-06 18:16:00 -08:00
Robert Adams 1dc23b2b97 BulletSim: parameterize selection of linkset implementation 2012-11-03 21:15:39 -07:00
Robert Adams b0eccd5044 BulletSim: debugging of compound shape implementation of linksets.
Add compound shape creation and freeing in shape manager.
Add optional taint-time execution method and update code to use it.
Add API2 linkage for more compound shape methods (get num, get/remove by index, ...)
Modify perferred shape return so linkset children can have differet shapes than root.
Add Position and Orientation calls to linksets so children can be moved around by
    the linkset by its own calculation. Allows for very general linkset implementations.
2012-11-03 21:15:30 -07:00
Robert Adams f53b4e7a21 BulletSim: Add RawPosition and RawOrientation to BSPhysObject and rename MassRaw to RawMass. Fix BSShapeCollection to use Raw* for creating the body to eliminate exception from referencing the physical body before it has been created. 2012-11-03 21:15:22 -07:00
Robert Adams 39c02dcc8c BulletSim: Remove use of shapeData in ShapeCollection and rely on the available BSPhysObject varaiables. Fix line endings in BSLinksetCompound. 2012-11-03 21:15:14 -07:00
Robert Adams 364a7c3088 BulletSim: rename BSBody and BSShape to PhysBody and PhysShape. Add skeleton of BSLinksetCompound. 2012-11-03 21:15:06 -07:00
Robert Adams 52be581f71 BulletSim: remove center-of-mass setting for linksets because it causes the constraint calculation to pull the objects together. 2012-11-03 21:14:49 -07:00
Robert Adams 93fe384cce BulletSim: Use the PostTaints operation to build the linkset once before the next simulation step. This eliminates the management of children vs taintChildren and simplifies the constratin creation code. 2012-11-03 21:14:41 -07:00
Robert Adams 2f25f70316 BulletSim: remove unneeded parameter from Refresh(). 2012-11-03 21:13:44 -07:00
Robert Adams 2b75035aef BulletSim: add ForEachMember(action) call for linkset. 2012-11-03 21:13:11 -07:00
Robert Adams 804b332d45 BulletSim: Add banking and other new code to vechile dynamics. Add third party license and contributor in for for Aurora-Sim project for physics code. 2012-11-03 21:12:46 -07:00
Robert Adams 14eeb8b31b BulletSim: fix bug that caused error (and a crash on 32 bit Linux) when mesh assets weren't already in the cache. Comment cleanups. 2012-10-22 22:24:59 -07:00
Robert Adams a61f20ac74 BulletSim: Create LinkSet abstract class and sparate constraint based linksets into own subclass. Will eventually add manual movement linkset subclass. 2012-10-22 22:24:30 -07:00
Robert Adams 3a458e2a36 BulletSim: Use full linkset mass when computing vehicle gravity force. Add taint-time specification to new AddForce(). 2012-10-11 14:01:18 -07:00
Robert Adams a791620622 BulletSim: cosmetic changes (comments and renaming). Give mass to terrain to improve interactions. 2012-10-11 14:01:10 -07:00
Robert Adams 87825b0abe BulletSim: Fix crash when linking large physical linksets.
Properly remove and restore linkage constraints when upgrading
    a prim's mesh to a hull.
Lots more debug logging.
Definitions and use of Bullet structure dumping.
Centralize detail logging so a Flush() can be added for debugging.
2012-10-11 14:01:03 -07:00
Robert Adams ce97ebdc88 BulletSim: Fix linkset problem where delayed manipulations of child objects was using the child shape address at call time rather than the one created at taint time. 2012-10-02 11:13:57 -07:00
Robert Adams 5221f2421e BulletSim: remove warnings for unused variables. 2012-10-02 11:13:20 -07:00
Robert Adams 6f89975526 BulletSim: add separate runtime and taint-time linkset children lists to keep the creation of constraints separate from runtime. 2012-09-27 22:02:13 -07:00
Robert Adams 74dea4cfd5 BulletSim: rename some constraint variables to be consistant with other name use.
Added callbacks for shape and body changes in GetBodyAndShape() so the linkset
    constraints can be picked up and restored. A better design might be to have
    a "prim shape changed" event. Think about that.
Added constraint types to general constraint class.
2012-09-27 22:02:08 -07:00
Robert Adams 7b65985047 BulletSim: remove the trailing spaces from lines to make git happier 2012-09-27 22:02:03 -07:00
Robert Adams f82b903dee BulletSim: Fix linkset crash. Caused by the different body and shape
pointers at runtime and at taint-time. Now passes the body into the
    taint.
Vehicles zero inertia when active to eliminate Bullet's contribution
    to vehicle motion.
2012-09-27 22:01:52 -07:00
Robert Adams d016051fa0 BulletSim: renamed members of BulletShape, BulletSim and BulletBody
so the members case is consistant. Caused modifications everywhere.
New logic in BSShapeCollection to track use and sharing of shapes.
    I just reslized, though, that shapes cannot be shared because the
    shape's UserPointer is the localID of the prim and is required
    for tracking collisions. More changes coming.
Added DuplicateCollisionShape2() to API and changed BuildNativeShape2
    to take a ShapeData structure so don't have to pass so many parameters.
    This matches the latest version of BulletSim.dll.
Additions and removal of DetailLog() statements for debugging.
2012-09-27 22:01:37 -07:00
Robert Adams 91efccabdc BulletSim: Convert BSCharacter to use common BSPhysObject code and variables.
Fix avatar height calculation to properly account for the capsule ends.
Rearrange some locking in TerrainManager to eliminate possible race conditions.
Move DetailLog() definition into common BSPhysObject class.
Some variable renaming to make usage clearer (refactor.rename makes this so easy).
2012-09-27 22:01:16 -07:00
Robert Adams ee7cda261c BulletSim: move a bunch of common logic out of BSPrim and BSCharacter
and into the parent class BSPhysObject.
Rework collision logic to enable extra collision after done colliding.
Rename 'Scene' to 'PhysicsScene' to differentiate it from the simulator 'Scene'.
2012-09-27 22:01:11 -07:00
Robert Adams f0a098924e BulletSim: set all linkset objects center of mass to the whole linkset's center of mass 2012-09-15 15:31:49 -07:00
Robert Adams 7c347f4c5c BulletSim: Add calls to linkset class when object going static or dynamic.
Reset center of mass on an object when going dynamic.
2012-09-15 15:31:44 -07:00
Robert Adams 2c5ff93990 BulletSim: Way too many changes in one commit.
Many changes to BSDynamic for readability and commentary.
Linkset hacking for vehicles: don't over mass the root prim.
Add parameter for link constraint solver iterations.
Correct uses of timestep in timescale calculations for vehicles.
Reorganize code/logic for making objects static and dynamic for readability
    and use of API2.
Changed most calls in BSPrim to use API2 calls (the new way).
Avatars do not generate default Bullet collision events but do call up
    to the simulator for every avatar. Reduces overhead.
Objects added to collision list only if they are processing collisions.
    Reduces overhead especially for large numbers of avatars.
Generalize call for water height to GetWaterHeightAtXYZ().
Catch and correct exception getting terrain height when out of bounds.
Correct race condition in Terrain Manager where creation wasn't at taint-time.
Add API calls for constructing compound shapes.
Move NeedsMeshing() logic into object class.
Reorganize logic for object meshing to reduce rebuilding of meshs/hulls.
2012-09-15 15:31:29 -07:00
Robert Adams 126eae7100 BulletSim: Add Bullet body and shape to BSPhysObject and rename
'Body' to 'BSBody' for disambiguation when reading code.
Complete the API2 interface so nearly all methods on bullet
    classes are available to the managed code. The efficient
    single call simulation step is kept in place while all
    other creation/destruction/parameterization can be done
    in the managed code.
2012-09-07 16:05:28 -07:00
Robert Adams 3c097cb7a9 BulletSim: Add some comments (gasp) and log messages. 2012-09-07 16:05:22 -07:00
Robert Adams 7b6987ce83 BulletSim: unify physical objects under BSPhysObjects. Now BSScene and BSLinkset only know of BSPhysObject's and there is only one list to search in BSScene. 2012-08-31 11:41:12 -07:00
Robert Adams 03d76e9403 BulletSim: restore most of the Detail logging statements. Will have
no effect on non-logging running.
Capture region name that is passed to the physics engine and use
    it for detail logging file name prefix.
Fix problem with avatars dropping when flying across region boundries.
2012-08-17 13:34:22 -07:00
Robert Adams ccc69d66a1 BulletSim: add parameters and functionality to specify the mesh
level of detail for large meshes.
Remove parameter and code for DetailLog (conditional logging into
   regular log file).
2012-08-17 13:34:18 -07:00
Robert Adams 376441e550 BulletSim: make it so objects in a linkset do not generate collisions with each other. 2012-08-15 16:29:50 -07:00
Robert Adams 9efe7bf7ba BulletSim: add locking to constraintCollection and rename some of the public method variables to reduce confusion between a physics scene and the real scene. 2012-08-15 12:08:17 -07:00
Robert Adams 0c7ce4fc98 BulletSim: many, many detailed logging messages for physical linkset
debugging.
Linkset bugs fixed where accounting of children would get lost.
Moved scene based vehicle tracking logic from prim to the scene.
Added GetCollisionFlags2 method to BulletSimAPI.
Updated DLLs and SOs.
2012-08-10 16:22:44 -07:00
Robert Adams 3ca770cd2c BulletSim: Add module names to DetailLog output. Fix some problems with linksets that were caused by checking data structures that are changed regularly from taint time code -- resulted in linksets not being unlinked properly. 2012-08-10 08:33:09 -07:00
Robert Adams 320982cae3 BulletSim: add an identifier to the TaintObject call so exceptions that happen when the taint is invoked can be debugged 2012-08-09 15:17:19 -07:00
Robert Adams 38e79b80a8 BulletSim: separate out the constraints by type. The linksets use
6dof constraint but eventually others will be exposed so future
features can use all the Bullet capabilities.
Force children to generate a position update when unlinked.
2012-08-09 15:01:05 -07:00
Robert Adams 5ab151c2d6 BulletSim: add avatar code to keep avatars from ending up trapped under the terrain 2012-08-08 13:48:49 -07:00
Robert Adams 50dbb9ffe4 BulletSim: add parameters and API calls for setting ERP and CFM.
Set ERP and CFM in linkset constraints.
Reorder rebuilding of object bodies so they are not rebuilt everytime
   something is linked and unlinked.
2012-07-31 09:23:05 -07:00