[Closed] btHingeConstraint - Coordinate gone NULL (berserk)

papaonn
Posts: 41
Joined: Wed Nov 20, 2013 4:14 pm

[Closed] btHingeConstraint - Coordinate gone NULL (berserk)

Post by papaonn »

Hi all,

I couldn't understand how to visualize axis 1 and axis 2 in btHingeConstraint.

I used 2 boxes A & B.

in A, the pivot point is p(0, 5, 0), and the axis 1 is (0, 0, 1)
in B, the pivot point is p(0, 5, 0), and the axis 2 is (0, 0, 1)

it seems like the axis will tell the rotation of the object along the axis,
however if i change axis 2 into other orientation (1, 0, 0), the rotation of object is still the same just that the object B is attached to the pivot point in different facing direction. i.e, the movement rotation of object B is still the same (like a door).


Could someone help me in visualizing this axis 1 and axis 2 relationship?

Thank you very much :)

(This is resolved, however i met some new problems below)
Last edited by papaonn on Mon Dec 23, 2013 4:31 am, edited 4 times in total.
papaonn
Posts: 41
Joined: Wed Nov 20, 2013 4:14 pm

Re: hinge axis 1 and 2 problem

Post by papaonn »

Hi finally i managed to resolve the problem above,

however now i met another problem, which is that under some orientation, the entire system just gone wild and disappeared, when i trace for their coordinate it returned me NULL.

I managed to resolve some of the orientation by changing the distance of pivot points, i am wondering what has caused the system to gone berserk with my body gone disappear and coordinate becomes NULL ?

It should not be the pivot point problem since i have make sure that the pivot points are far enough from the boundary of the bodies themselves.

Anyone could help me in this ? Many Thanks. :oops:



Resolved : I figure out that it has to do with the collision itself, the berserk was caused by the collision of object, hence a correct repositioning of the objects are important before attaching constraint.