collision and scale :(
3 posters
collision and scale :(
Hello
I have problems
If i scaled object then collision is don't working. If scale of object = 1 then all is great!
tutorial 9
Why
Please, help
Thanks!
I have problems
If i scaled object then collision is don't working. If scale of object = 1 then all is great!
tutorial 9
Why
Please, help
Thanks!
Last edited by sakrist on Tue May 19, 2009 6:23 am; edited 1 time in total
Re: collision and scale :(
Bullet doesn't support scaled matrices... and watch the video tutorial06_1 I talk about that in details...
Re: collision and scale :(
you can remove the physic attribute and then add the physic attribute after you scale the object
sw- Posts : 73
Join date : 2008-10-12
Re: collision and scale :(
sw wrote:you can remove the physic attribute and then add the physic attribute after you scale the object
how to do it?
please
- Code:
SIO2object *object = ( SIO2object * )sio2ResourceGet( sio2->_SIO2resource,
SIO2_OBJECT,
objectName );
sio2PhysicRemoveObject( sio2->_SIO2physic, object );
object->_SIO2transform->scl->x = 0.5;
object->_SIO2transform->scl->y = 0.5;
object->_SIO2transform->scl->z = 0.5;
sio2PhysicAddObject( sio2->_SIO2physic, object );
this code don't work
Re: collision and scale :(
sio2PhysicRemoveObject( sio2->_SIO2physic, object );
object->_SIO2transform->scl->x = 0.5;
object->_SIO2transform->scl->y = 0.5;
object->_SIO2transform->scl->z = 0.5;
object->dim->x = object->dim->x * 0.5f;
object->dim->y = object->dim->y * 0.5f;
object->dim->z = object->dim->z * 0.5f;
sio2PhysicAddObject( sio2->_SIO2physic, object );
object->_SIO2transform->scl->x = 0.5;
object->_SIO2transform->scl->y = 0.5;
object->_SIO2transform->scl->z = 0.5;
object->dim->x = object->dim->x * 0.5f;
object->dim->y = object->dim->y * 0.5f;
object->dim->z = object->dim->z * 0.5f;
sio2PhysicAddObject( sio2->_SIO2physic, object );
sw- Posts : 73
Join date : 2008-10-12
Re: collision and scale :(
sw wrote:sio2PhysicRemoveObject( sio2->_SIO2physic, object );
object->_SIO2transform->scl->x = 0.5;
object->_SIO2transform->scl->y = 0.5;
object->_SIO2transform->scl->z = 0.5;
object->dim->x = object->dim->x * 0.5f;
object->dim->y = object->dim->y * 0.5f;
object->dim->z = object->dim->z * 0.5f;
sio2PhysicAddObject( sio2->_SIO2physic, object );
thanks
camera is work , but not collision
what me doing
Last edited by sakrist on Tue May 19, 2009 6:23 am; edited 1 time in total
Re: collision and scale :(
sio2interactive wrote:Bullet doesn't support scaled matrices... and watch the video tutorial06_1 I talk about that in details...
Which of the video?
Last edited by sakrist on Tue May 19, 2009 6:23 am; edited 1 time in total
Re: collision and scale :(
You need to adjust the origin of the collision objectsakrist wrote:sw wrote:sio2PhysicRemoveObject( sio2->_SIO2physic, object );
object->_SIO2transform->scl->x = 0.5;
object->_SIO2transform->scl->y = 0.5;
object->_SIO2transform->scl->z = 0.5;
object->dim->x = object->dim->x * 0.5f;
object->dim->y = object->dim->y * 0.5f;
object->dim->z = object->dim->z * 0.5f;
sio2PhysicAddObject( sio2->_SIO2physic, object );
thanks
camera is work , but not collision
what me doing
sw- Posts : 73
Join date : 2008-10-12
Similar topics
» Reposition a static physics object
» Best Way to Scale an SIO2Widget
» Collision Detection
» Collision Again
» Use object only for collision
» Best Way to Scale an SIO2Widget
» Collision Detection
» Collision Again
» Use object only for collision
Permissions in this forum:
You cannot reply to topics in this forum