Wheel softness effect

A place to discuss everything related to Newton Dynamics.

Moderators: Sascha Willems, walaber

Wheel softness effect

Postby PJani » Thu Jun 24, 2010 8:06 pm

Hey i am working on multibodyvehicle wheels and i am trying to create something like as in my sketch which will simulate "constant" contact with the ground?

Any idea where to start?
Attachments
idea.PNG
idea.PNG (28.44 KiB) Viewed 3915 times
| i7-5930k@4.2Ghz, EVGA 980Ti FTW, 32GB RAM@3000 |
| Dell XPS 13 9370, i7-8550U, 16GB RAM |
| Ogre 1.7.4 | VC++ 9 | custom OgreNewt, Newton 300 |
| C/C++, C# |
User avatar
PJani
 
Posts: 448
Joined: Mon Feb 02, 2009 7:18 pm
Location: Slovenia

Re: Wheel softness effect

Postby Carli » Fri Jun 25, 2010 2:07 am

Raycasting could help ;)
Carli
 
Posts: 245
Joined: Fri Oct 02, 2009 5:28 am

Re: Wheel softness effect

Postby PJani » Fri Jun 25, 2010 9:56 am

I would like to avoid raycast, because i need to have this effect on edges slopes or uneven terrain. ;P
| i7-5930k@4.2Ghz, EVGA 980Ti FTW, 32GB RAM@3000 |
| Dell XPS 13 9370, i7-8550U, 16GB RAM |
| Ogre 1.7.4 | VC++ 9 | custom OgreNewt, Newton 300 |
| C/C++, C# |
User avatar
PJani
 
Posts: 448
Joined: Mon Feb 02, 2009 7:18 pm
Location: Slovenia

Re: Wheel softness effect

Postby JernejL » Fri Jun 25, 2010 11:40 am

i think what you want is soft body physics.. but that's not yet in newton, however you can simulate a tire continously in contact with convex casting..
Help improving the Newton Game Dynamics WIKI
User avatar
JernejL
 
Posts: 1587
Joined: Mon Dec 06, 2004 2:00 pm
Location: Slovenia

Re: Wheel softness effect

Postby PJani » Fri Jun 25, 2010 12:17 pm

Delfi wrote:i think what you want is soft body physics.. but that's not yet in newton, however you can simulate a tire continously in contact with convex casting..


convex casting is the thing i am looking for :D thank you.

edit: soft body physics would be overkill ;P
| i7-5930k@4.2Ghz, EVGA 980Ti FTW, 32GB RAM@3000 |
| Dell XPS 13 9370, i7-8550U, 16GB RAM |
| Ogre 1.7.4 | VC++ 9 | custom OgreNewt, Newton 300 |
| C/C++, C# |
User avatar
PJani
 
Posts: 448
Joined: Mon Feb 02, 2009 7:18 pm
Location: Slovenia

Re: Wheel softness effect

Postby PJani » Fri Jun 25, 2010 1:54 pm

am only one question how could i create fake contact?
| i7-5930k@4.2Ghz, EVGA 980Ti FTW, 32GB RAM@3000 |
| Dell XPS 13 9370, i7-8550U, 16GB RAM |
| Ogre 1.7.4 | VC++ 9 | custom OgreNewt, Newton 300 |
| C/C++, C# |
User avatar
PJani
 
Posts: 448
Joined: Mon Feb 02, 2009 7:18 pm
Location: Slovenia

Re: Wheel softness effect

Postby Julio Jerez » Fri Jun 25, 2010 2:46 pm

That's a good question? I never did that,

you could just find the contact joints form teh callback and manipulate the contacts.
Julio Jerez
Moderator
Moderator
 
Posts: 12426
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Wheel softness effect

Postby PJani » Fri Jun 25, 2010 3:13 pm

Hmm what if i want to make this?

is there any good way to make partial penetration of ground? :shock:
Attachments
idea2.PNG
idea2.PNG (7.15 KiB) Viewed 3887 times
| i7-5930k@4.2Ghz, EVGA 980Ti FTW, 32GB RAM@3000 |
| Dell XPS 13 9370, i7-8550U, 16GB RAM |
| Ogre 1.7.4 | VC++ 9 | custom OgreNewt, Newton 300 |
| C/C++, C# |
User avatar
PJani
 
Posts: 448
Joined: Mon Feb 02, 2009 7:18 pm
Location: Slovenia

Re: Wheel softness effect

Postby Julio Jerez » Fri Jun 25, 2010 4:45 pm

The only think I can think of is allowwing
void NewtonMaterialSetSurfaceThickness (const NewtonWorld* newtonWorld, int id0, int id1, dFloat thickness);

to take a negative value for thickness. that way the bodey will collide at soem penetartion depth.
I cannot say now, but I believe thickness is clamped to zero which is the default.
a positive value will collide similar to copmercial engine whe the requiere a skin thickness for collision to work properlly.
I will have to find out is is possible to allow thickness to be negative.

onothet solution would be using a collision shape smaller tha the visual mesh.
I have not follow this, but whey cannot you just make the shape smaller?
I am guessing you want a perpetual contact, which I think a negative thnickeness will guarantee.

another way will be to make a ContactCustomJoint, that is updated before the update I think with the collision system.
I think.
Julio Jerez
Moderator
Moderator
 
Posts: 12426
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Wheel softness effect

Postby PJani » Fri Jun 25, 2010 6:12 pm

I will look that thickness.

Julio Jerez wrote:onothet solution would be using a collision shape smaller tha the visual mesh.
I have not follow this, but whey cannot you just make the shape smaller?
I am guessing you want a perpetual contact, which I think a negative thnickeness will guarantee.


If i would like to make wheels visually "soft" i would do as you suggested jep i am looking for perpetual(i couldn't get that word in my head) contact, because wheels doesnt have real friction(i am thinking because they are loosing contact which doesnt happen on real tires). ;)

Edit: Jep it seems that is clamped to 0.0 :S.
| i7-5930k@4.2Ghz, EVGA 980Ti FTW, 32GB RAM@3000 |
| Dell XPS 13 9370, i7-8550U, 16GB RAM |
| Ogre 1.7.4 | VC++ 9 | custom OgreNewt, Newton 300 |
| C/C++, C# |
User avatar
PJani
 
Posts: 448
Joined: Mon Feb 02, 2009 7:18 pm
Location: Slovenia

Re: Wheel softness effect

Postby PJani » Sat Jun 26, 2010 6:46 am

It is possible to un clamp it?
| i7-5930k@4.2Ghz, EVGA 980Ti FTW, 32GB RAM@3000 |
| Dell XPS 13 9370, i7-8550U, 16GB RAM |
| Ogre 1.7.4 | VC++ 9 | custom OgreNewt, Newton 300 |
| C/C++, C# |
User avatar
PJani
 
Posts: 448
Joined: Mon Feb 02, 2009 7:18 pm
Location: Slovenia

Re: Wheel softness effect

Postby Julio Jerez » Sat Jun 26, 2010 9:49 am

I do not know, but I i will check it out, I beleive ther shoul be no problem.
did you try setting thickness to a negetive value and read it back?

It can not be left unclamped because if is is too large then it may even be bigget that the shape with.
Julio Jerez
Moderator
Moderator
 
Posts: 12426
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: Wheel softness effect

Postby PJani » Sat Jun 26, 2010 10:35 am

The problem is i dont know how to readit back. I just did set it to negative value -0.5f (in my units half a meter). And i didnt see any penetration so that why i assuming that is clamped to 0.0
| i7-5930k@4.2Ghz, EVGA 980Ti FTW, 32GB RAM@3000 |
| Dell XPS 13 9370, i7-8550U, 16GB RAM |
| Ogre 1.7.4 | VC++ 9 | custom OgreNewt, Newton 300 |
| C/C++, C# |
User avatar
PJani
 
Posts: 448
Joined: Mon Feb 02, 2009 7:18 pm
Location: Slovenia


Return to General Discussion

Who is online

Users browsing this forum: No registered users and 0 guests

cron