irrBullet 0.1.8 - Bullet physics wrapper
Re: irrBullet 0.1.71 - Bullet physics wrapper
Hi everyone. I want to apologize for the lack of author support and updates to irrBullet. I haven't had time to help with problems or work on irrBullet and I'm not sure when I will have time.
I did have some time to check up on things, however, and I decided to let everyone know that irrBullet has not been abandoned. To show my appreciation to all of the irrBullet users, I made this small flag chart with 45 of the most popular user countries of 2011. Flag size represents the user mass of a country.
- Josiah
I did have some time to check up on things, however, and I decided to let everyone know that irrBullet has not been abandoned. To show my appreciation to all of the irrBullet users, I made this small flag chart with 45 of the most popular user countries of 2011. Flag size represents the user mass of a country.
- Josiah
Re: irrBullet 0.1.71 - Bullet physics wrapper
Hi, I was wondering if anyone could help me. I think I have problem with rigidbody/animated node.
I have an animated node which when hit falls down, now what happens is when hit the node animates and goes down but I dont think the rigidbody updates beacuse if I fire where the node started ie standing up, the bullet still collides with something.
Code for the animated node and rigidbody:
Code for when the target is hit:
Sorry if this has been asked before, I couldn't find anything and thanks.
I have an animated node which when hit falls down, now what happens is when hit the node animates and goes down but I dont think the rigidbody updates beacuse if I fire where the node started ie standing up, the bullet still collides with something.
Code for the animated node and rigidbody:
Code: Select all
IAnimatedMeshSceneNode* targetNode = (IAnimatedMeshSceneNode*)(device->getSceneManager()->getSceneNodeFromName("target"));
targetNode ->setCurrentFrame(0);
targetNode ->setAnimationSpeed(0);
ICollisionShape *targetShape = new IGImpactMeshShape(targetNode , device->getSceneManager()->getMesh("../../media/target.b3d"), 0);
IRigidBody *targetBody = world->addRigidBody(targetShape,COL_WORLD_OBJECT,worldObjectCollidesWith);
targetBody ->getAttributes()->addBool("target", true);
Code: Select all
obj1->getAttributes()->setAttribute("target", false);
targetNode ->setFrameLoop(1,31);
targetNode ->setAnimationSpeed(10);
targetNode ->setLoopMode(false);
"Hey Baby Wobbling Wobbling"
-Russell Peters
-Russell Peters
Re: irrBullet 0.1.71 - Bullet physics wrapper
right now i have an odd issue with irrbullet a strange windows apear in the middle of my screen and i can't interact with my program i'll post screen shot and code implying irrbullet
Re: irrBullet 0.1.71 - Bullet physics wrapper
Granyte:
Is it Irrlicht's color-select dialog? What version of Irrlicht are you using? I've had this happen to me before but updating Irrlicht stopped the problem. I think 1.7 caused it.
Ravi08:
The rigidbody does not automatically scale with the bounding box of a scene node. You'll have to figure out a way to do that yourself because it's too specific to your game.
Is it Irrlicht's color-select dialog? What version of Irrlicht are you using? I've had this happen to me before but updating Irrlicht stopped the problem. I think 1.7 caused it.
Ravi08:
The rigidbody does not automatically scale with the bounding box of a scene node. You'll have to figure out a way to do that yourself because it's too specific to your game.
Re: irrBullet 0.1.71 - Bullet physics wrapper
i was using irrlicht 1.8.0 svn
i switched to usong bullet directly because i need colision with the terrain mesh but i'm now facing newer issues
i switched to usong bullet directly because i need colision with the terrain mesh but i'm now facing newer issues
irrBullet and ITerrainSceneNode
Hey everyone.
I played with irrBullet quite a while ago and now it's time to fully integrate it into my project.
Similar to quite some users I'm facing a problem with adding my terrain scene node to the physics simulation. The scene node is correctly added to the sim world but other objects still pass through it.
Here's my approach:
From the terrain scene node's nature, it's not possible to get its standard IMesh but a mesh buffer from an arbitrary LOD. Hence I extended ITriangleMeshShape's functionality to also accept IMeshBuffers as a parameter as ITMS basically works on the mesh buffers of IMesh.
On my side of the action, I use the following code to add terrain to the physics simulation:
Obviously, it fills a MeshBuffer object with data for a given LOD step which is then used to create bullet's representation of it.
Note that debugging shows the correct (similar) values as for verts- and triangle count.
Hence the questions are:
- Am I doing smth wrong?
- Am I missing smth?
All the other stuff collides as it should so I'm quite sure the sim is correctly set up.
Help greatly appreciated,
p.
I played with irrBullet quite a while ago and now it's time to fully integrate it into my project.
Similar to quite some users I'm facing a problem with adding my terrain scene node to the physics simulation. The scene node is correctly added to the sim world but other objects still pass through it.
Here's my approach:
From the terrain scene node's nature, it's not possible to get its standard IMesh but a mesh buffer from an arbitrary LOD. Hence I extended ITriangleMeshShape's functionality to also accept IMeshBuffers as a parameter as ITMS basically works on the mesh buffers of IMesh.
Code: Select all
void IBvhTriangleMeshShape::createShape(IMeshBuffer *meshBuffer)
{
btBvhTriangleMeshShape* bvhShape = new btBvhTriangleMeshShape(getTriangleMeshFromBuffer(meshBuffer), false, true);
shape = bvhShape;
calculateLocalInertia(getMass(), vector3df(0.0f,0.0f,0.0f));
}
Code: Select all
void OFLPhysics::addTerrain(scene::ITerrainSceneNode* terrain)
{
OFLPhysics* inst = getInstance();
scene::CDynamicMeshBuffer buf(irr::video::EVT_STANDARD,irr::video::EIT_16BIT);
terrain->getMeshBufferForLOD(buf, 0);
ICollisionShape* terrShape = new IBvhTriangleMeshShape(terrain, &buf, 0.f);
terrShape->setMargin(.5f);
IRigidBody* terrBody = inst->bWorld->addRigidBody(terrShape);
terrBody->setCollisionFlags(ECF_STATIC_OBJECT);
}
Note that debugging shows the correct (similar) values as for verts- and triangle count.
Hence the questions are:
- Am I doing smth wrong?
- Am I missing smth?
All the other stuff collides as it should so I'm quite sure the sim is correctly set up.
Help greatly appreciated,
p.
beer->setMotivationCallback(this);
Re: irrBullet 0.1.71 - Bullet physics wrapper
@polylux: are you trying to collide multiple IBvhTriangleMesh shapes? If so, that's the problem.
Working on game: Marrbles (Currently stopped).
Re: irrBullet 0.1.71 - Bullet physics wrapper
Thanks serengeor,serengeor wrote:@polylux: are you trying to collide multiple IBvhTriangleMesh shapes? If so, that's the problem.
no, currently I only collide a cube with my terrain - so just one IBTM for the moment. Also, the terrain seems to be correctly handled as it starts to drift downwards as i assign mass to it.
Just to avoid problems in the future, what do you mean by 'collide multiple IBTMs'? Mean if there is more than one IBTM present or IBTMs that collide with each other?
p.
beer->setMotivationCallback(this);
Re: irrBullet 0.1.71 - Bullet physics wrapper
Well it seams they are only intended to be for static usage (static level geometry) and nothing else. For example if you would drop one IBvhTriangleMeshShape onto another one it would simply just go trough it. So I think that applying mass to it would't be a good idea.
Working on game: Marrbles (Currently stopped).
Re: irrBullet 0.1.71 - Bullet physics wrapper
thanks! never intended to anyways.serengeor wrote:Well it seams they are only intended to be for static usage (static level geometry) and nothing else. For example if you would drop one IBvhTriangleMeshShape onto another one it would simply just go trough it. So I think that applying mass to it would't be a good idea.
but still the problem remains. is there probably some mesh size constraint from bullet?
beer->setMotivationCallback(this);
Re: irrBullet 0.1.71 - Bullet physics wrapper
I don't know if I understand you correctly, but here's a link where I think you could read up on that: http://www.bulletphysics.org/mediawiki- ... _The_Worldpolylux wrote:is there probably some mesh size constraint from bullet?
Working on game: Marrbles (Currently stopped).
Re: irrBullet 0.1.71 - Bullet physics wrapper
Thanks again serengeor,
I am pretty sure it's no tunneling problem as the cube is sufficiently big (edge len: 3 units), falls down slowly and collides nicely with all other objects. Might need to debug further with the debug draw funcs. Will report back then.
p.
I am pretty sure it's no tunneling problem as the cube is sufficiently big (edge len: 3 units), falls down slowly and collides nicely with all other objects. Might need to debug further with the debug draw funcs. Will report back then.
p.
beer->setMotivationCallback(this);
Re: irrBullet 0.1.71 - Bullet physics wrapper
Well, seemingly it's the wrong way to create a triangle collision mesh from your terrain as with a sufficiently sized terrain the simulation pretty fast slows down to a slide show. Bullet offers the btHeightfieldTerrainShape (Link) for such things. I am currently very tempted to extend irrBullet's functionality by this - as long as no one else has done it already.
If so, just tell me please.
p.
If so, just tell me please.
p.
beer->setMotivationCallback(this);
Re: irrBullet 0.1.71 - Bullet physics wrapper
How big was your terrain (how much vertices)?polylux wrote:Well, seemingly it's the wrong way to create a triangle collision mesh from your terrain as with a sufficiently sized terrain the simulation pretty fast slows down to a slide show. Bullet offers the btHeightfieldTerrainShape (Link) for such things. I am currently very tempted to extend irrBullet's functionality by this - as long as no one else has done it already.
If so, just tell me please.
p.
Working on game: Marrbles (Currently stopped).
Re: irrBullet 0.1.71 - Bullet physics wrapper
roughly 350k of verteces at LOD 0serengeor wrote:How big was your terrain (how much vertices)?polylux wrote:Well, seemingly it's the wrong way to create a triangle collision mesh from your terrain as with a sufficiently sized terrain the simulation pretty fast slows down to a slide show. Bullet offers the btHeightfieldTerrainShape (Link) for such things. I am currently very tempted to extend irrBullet's functionality by this - as long as no one else has done it already.
If so, just tell me please.
p.
beer->setMotivationCallback(this);