nargil
09-02-2009 11:11:03
for a certain actor/body ?
actor->clearBodyFlag(NX_BF_VISUALIZATION);
doesn't work. I want the debug visualization to work with my objects, but disable it for the terrain which is an overkill for the gpu rendering.
this is how i turn it on.
it couts the name of the terrain i want to disable debug rendering for, but it's still being rendered
actor->clearBodyFlag(NX_BF_VISUALIZATION);
doesn't work. I want the debug visualization to work with my objects, but disable it for the terrain which is an overkill for the gpu rendering.
this is how i turn it on.
this->mWorld->createDebugRenderer(this->getSceneMgrRW());
this->mWorld->getPhysXDriver()->setVisualisationActorAxesEnabled(false);
this->mWorld->getPhysXDriver()->setVisualisationBodyAngularVelocityEnabled(false);
this->mWorld->getPhysXDriver()->setVisualisationBodyAxesEnabled(false);
this->mWorld->getPhysXDriver()->setVisualisationBodyJointGroupsEnabled(false);
this->mWorld->getPhysXDriver()->setVisualisationBodyLinearVelocityEnabled(false);
this->mWorld->getPhysXDriver()->setVisualisationBodyMassAxesEnabled(false);
//this->mWorld->getPhysXDriver()->setVisualisationBodyMassAxesEnabled(true);
this->mWorld->getPhysXDriver()->setVisualisationWorldAxesEnabled(false);
this->mWorld->getPhysXDriver()->setVisualisationCollisionAABBsEnabled(false);
this->mWorld->getPhysXDriver()->setVisualisationCollisionAxesEnabled(false);
this->mWorld->getPhysXDriver()->setVisualisationCollisionCCDEnabled(false);
this->mWorld->getPhysXDriver()->setVisualisationCollisionCompoundsEnabled(false);
this->mWorld->getPhysXDriver()->setVisualisationCollisionDynamicEnabled(false);
this->mWorld->getPhysXDriver()->setVisualisationCollisionEdgesEnabled(false);
this->mWorld->getPhysXDriver()->setVisualisationCollisionFaceNormalsEnabled(false);
this->mWorld->getPhysXDriver()->setVisualisationCollisionSpheresEnabled(false);
NxOgre::Actors* act = this->mScene->getActors();
for(NxOgre::Actor* a = act->begin(); a = act->next();)
{
if(static_cast<MyAbstractActor*>(a)->getType()==12346)
{
std::cout << a->getName() << std::endl;
a->clearBodyFlag(NX_BF_VISUALIZATION);
}
}
it couts the name of the terrain i want to disable debug rendering for, but it's still being rendered