moved filters in CcdConstructionInfo

This commit is contained in:
ejcoumans 2006-06-25 21:03:10 +00:00
parent 71dfed4c52
commit 7a0a0941f9
3 changed files with 20 additions and 15 deletions

View File

@ -246,8 +246,8 @@ int main(int argc,char** argv)
ccdObjectCi.m_mass = shapeProps.m_mass;
ccdObjectCi.m_collisionFlags = CollisionObject::isStatic;
ccdObjectCi.m_collisionFilterGroup = CollisionFilterGroups::Static;
ccdObjectCi.m_collisionFilterMask = CollisionFilterGroups::All ^ CollisionFilterGroups::Static;
ccdObjectCi.m_collisionFilterGroup = CcdConstructionInfo::StaticFilter;
ccdObjectCi.m_collisionFilterMask = CcdConstructionInfo::AllFilter ^ CcdConstructionInfo::StaticFilter;
}
else
{

View File

@ -39,20 +39,24 @@ extern bool gDisableDeactivation;
class CcdPhysicsEnvironment;
///CollisionFilterGroups provides some optional usage of basic collision filtering
///this is done during broadphase, so very early in the pipeline
///more advanced collision filtering should be done in CollisionDispatcher::NeedsCollision
enum CollisionFilterGroups
{
Default = 1,
Static = 2,
Kinematic = 4,
Debris = 8,
All = Default | Static | Kinematic | Debris,
};
struct CcdConstructionInfo
{
///CollisionFilterGroups provides some optional usage of basic collision filtering
///this is done during broadphase, so very early in the pipeline
///more advanced collision filtering should be done in CollisionDispatcher::NeedsCollision
enum CollisionFilterGroups
{
DefaultFilter = 1,
StaticFilter = 2,
KinematicFilter = 4,
DebrisFilter = 8,
AllFilter = DefaultFilter | StaticFilter | KinematicFilter | DebrisFilter,
};
CcdConstructionInfo()
: m_gravity(0,0,0),
m_scaling(1.f,1.f,1.f),
@ -62,8 +66,8 @@ struct CcdConstructionInfo
m_linearDamping(0.1f),
m_angularDamping(0.1f),
m_collisionFlags(0),
m_collisionFilterGroup(CollisionFilterGroups::Default),
m_collisionFilterMask(CollisionFilterGroups::All),
m_collisionFilterGroup(DefaultFilter),
m_collisionFilterMask(AllFilter),
m_MotionState(0),
m_physicsEnv(0),
m_inertiaFactor(1.f)

View File

@ -79,6 +79,7 @@ END -%]
AdditionalDependencies="[% compose('libs', [], ' ') %]"
IgnoreImportLibrary="TRUE"
SuppressStartupBanner="TRUE"
GenerateManifest="false"
AdditionalLibraryDirectories="[% composedirs('libdirs', []) %]"
ProgramDatabaseFile="[% workbuild([my.doc.rawtarget.0,'.pdb']) %]"
TargetMachine="1"/>