NewtonWorldConvexCast and penetration value

A place to discuss everything related to Newton Dynamics.

Moderators: Sascha Willems, walaber

NewtonWorldConvexCast and penetration value

Postby pHySiQuE » Mon Dec 05, 2016 1:13 am

Shouldn't NewtonWorldConvexCast give penetration values of 0 for each contact? I am reworking my character controller to use a swept collision approach and it's working well, but I am having trouble calculating the exact position of the player at the time of the collision. The fact that the penetration value isn't zero means there is a small inaccuracy in the player position. How can I calculate the correct position at the time of impact?
pHySiQuE
 
Posts: 608
Joined: Fri Sep 02, 2011 9:54 pm

Re: NewtonWorldConvexCast and penetration value

Postby Julio Jerez » Mon Dec 05, 2016 8:34 am

it should return 0 if the start position is disjointed, else it will be the penetration thet shape are on the start of the cast.

there in one thing in newton that has the potential of been inconsistent. and that is convex vs polygon collision. and is this.
All collision use the same routine to calculate collision between tow shapes, expect pair involving a polygon vs a convex shape.
when this is the case, the and the shape can be projected onto the center of the polygon, the collision is so trivial, that is worth having a dedicate function for that.

this open the possibility that when collision with a large face, while in the middle of the face the collision produce different result that when going across the edge.

The way I calibrate it in the pass is by calculation the Convex vs convex against phase vs convex and see If the result are identical. I has not done that yet.

But please before you do anything, see if you can link your sand box demo to a newton DLL and provide me with a repro case so that I can tune the rest of the collision.
Julio Jerez
Moderator
Moderator
 
Posts: 12249
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles


Return to General Discussion

Who is online

Users browsing this forum: No registered users and 15 guests