A place to discuss everything related to Newton Dynamics.
Moderators: Sascha Willems, walaber
by Julio Jerez » Sun Nov 09, 2008 11:13 am
It cannot be that complicated
do you have a test demo?
-
Julio Jerez
- Moderator
![Moderator Moderator](./images/ranks/newtonstrip.png)
-
- Posts: 12249
- Joined: Sun Sep 14, 2003 2:18 pm
- Location: Los Angeles
-
by Kapitan » Sun Nov 09, 2008 1:06 pm
Yes i have a test, but textures and mesh are big,
i'll try to shink. But it really seems it's problem
in trasform matrix and torque.
Maybe in my .exe.
-
Kapitan
-
- Posts: 37
- Joined: Thu Apr 17, 2008 6:07 pm
by Kapitan » Tue Nov 11, 2008 9:24 am
Too huge my scene (and it's a .irr file) so i cannot do
a fast shrink for a demo.
I've tried to use a NewtonCreateBox instead of ConvexHull
for my dice and it works...i can apply force or torque as
usual without collision "explosion".
So it can be a problem related to ConvexHull collision
and trasformation matrix, if you want i can try
to send you my dice mesh only to debug.
Bye.
-
Kapitan
-
- Posts: 37
- Joined: Thu Apr 17, 2008 6:07 pm
by ep1stle » Tue Nov 11, 2008 12:30 pm
Kapitan wrote:I don't Believe it!!!
Was the NewtonSetWorldSize!!!
It seems to me that something was missing.
Thanks guys.
Hey Kapitan, I have the same problem you had. Some of my bodies are freezed, although they shouldn't. I can't find a mistake in my code?
How did you fixed your problem with the movement? Just added NewtonSetWorldSize()? I call this function and I have no clue what might be wrong, especially because this problem only occurrs on one special map
![Sad :(](./images/smilies/icon_sad.gif)
-
ep1stle
-
- Posts: 10
- Joined: Mon Nov 27, 2006 12:38 pm
- Location: GERMANY
-
by Kapitan » Tue Nov 11, 2008 3:41 pm
Yes, my objects were out of bounds
![Very Happy :D](./images/smilies/icon_biggrin.gif)
.
So i 've set the right size and all works.
My bounds are the green box in the photo,
taken from table mesh plus padding on the y
axis (height axis).
-
Kapitan
-
- Posts: 37
- Joined: Thu Apr 17, 2008 6:07 pm
by Kapitan » Fri Nov 21, 2008 3:22 am
Maybe i've found a way to solve... but i always think something is wrong
in the convexhull trasformation matrix.
Instead of apply the initial trasform directly from newton to irrlicht,
i insert in the convex hull creation scaled vertices (take the scale
from irrlick getScale()). Then i take the trasform matrix from irrlicht
and divide the main diagonal with x,y,z scale. So now
i have a pure traslation and rotation matrix to apply to newton
(with NewtonBodySetMatrix).
See next for code and a video of the old "bug".
-
Kapitan
-
- Posts: 37
- Joined: Thu Apr 17, 2008 6:07 pm
by Julio Jerez » Sat Nov 22, 2008 10:09 am
I saw teh video, bu I still do no ud=ndertanbd why you are makin teh collision shape so big.
why no just making it the size of eth visual objects?
-
Julio Jerez
- Moderator
![Moderator Moderator](./images/ranks/newtonstrip.png)
-
- Posts: 12249
- Joined: Sun Sep 14, 2003 2:18 pm
- Location: Los Angeles
-
by Kapitan » Sat Nov 22, 2008 5:59 pm
But the problem is there...i'm not making the collision bigger,
i only apply an Omega to the body, and this is the result,
the scale (that first was set to 0.3 on my dice) is changed
to 1.0 in some way by Newton...
-
Kapitan
-
- Posts: 37
- Joined: Thu Apr 17, 2008 6:07 pm
Return to General Discussion
Who is online
Users browsing this forum: No registered users and 26 guests