kinetic friction decremental

A place to discuss everything related to Newton Dynamics.

Moderators: Sascha Willems, walaber

kinetic friction decremental

Postby Overhertz » Fri Apr 13, 2012 5:30 pm

Is it possible to have dynamic traction, as an object slides faster, the traction should become lower. E.g.

Code: Select all
  NewtonMaterialSetDefaultFriction(ge_NewtonWorld, MaterialA, MaterialB, 1, 1.25);


lets say it starts like this, but as the objects velocity becomes higher, i want the kinetic friction to become lower, is this possible?

Thanks in advance.
Ziron Programming Language
Download the Assembler HERE
User avatar
Overhertz
 
Posts: 112
Joined: Mon Jul 06, 2009 11:19 am

Re: kinetic friction decremental

Postby Julio Jerez » Fri Apr 13, 2012 10:18 pm

Overhertz wrote:lets say it starts like this, but as the objects velocity becomes higher, i want the kinetic friction to become lower, is this possible?


Kenetic friction is contant regarless of the speed of the objects. That is wha teh engine solver model.
if you want velocity depended frictions you need to add drag in the force and torque callback.
Julio Jerez
Moderator
Moderator
 
Posts: 12426
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: kinetic friction decremental

Postby Overhertz » Sun Apr 15, 2012 8:38 am

i'm not sure i could do this via the callback, the problem is, i've created a multi body car, if i set the friction high, it grips and accelerates good, but if turning at high velocity, i don't want the friction any longer, since the car should drift or slide, not roll over at 20 kph :)

any ideas how else i could solve this problem?
Ziron Programming Language
Download the Assembler HERE
User avatar
Overhertz
 
Posts: 112
Joined: Mon Jul 06, 2009 11:19 am

Re: kinetic friction decremental

Postby Julio Jerez » Sun Apr 15, 2012 10:34 am

If you look at the SDK demos in core 300. you will see that I am started to bring back the car.
I had to stops because ther are missing element that I have to complete first.
In core 300 I am bringing back the car of core 1.00 with some improvements

I tried to take shortcut in core 200 to make a faster car for both, mutibody and the raycast, and the result was a bad in both cases.
if you give me a week or so I will have the car back working, and believe me the car will cover all different type of vehicles:
realistic to the point that the user one, to arcaide. tracked, wheeled, and any other combination.

I made the test unit, but I had not time finish yet.
I needed the the convex cast working, but that cascaded in to the collision instance, and so on.
now I have everything, so if you give that some time I beleive you will be please with the result.
Julio Jerez
Moderator
Moderator
 
Posts: 12426
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: kinetic friction decremental

Postby Sweenie » Sun Apr 15, 2012 11:19 am

if you give me a week or so I will have the car back working


:mrgreen:
I'm waiting for this like a kid waiting for Santa on Christmas. :D
Sweenie
 
Posts: 503
Joined: Mon Jan 24, 2005 7:59 am
Location: Sweden

Re: kinetic friction decremental

Postby Overhertz » Sun Apr 15, 2012 1:55 pm

Julio Jerez thank you for that news, it is like music to my ears, in that case i will wait and work on other elements :))))
Ziron Programming Language
Download the Assembler HERE
User avatar
Overhertz
 
Posts: 112
Joined: Mon Jul 06, 2009 11:19 am

Re: kinetic friction decremental

Postby Julio Jerez » Mon Apr 16, 2012 9:35 am

The feature I am adding now is serialization on all element of the engine.

I just completed teh serialization of collision (pending scene, and softbody collision with are incomplete still)
I am adding world serialization, Bopdy seralization and Joint serilazation.

wit thsi options, teh cline application can for get stuff straing form teh SDK demo and pate into they code.

say for example I complete the car, the I call
NewtonSerializeBody (...)
NewtonSerializeJoint (...)

and this will save the dat to a pice of memory, or a file all determened by the end client.
then in theo applicationb the application can call the derialization founstion for that feature, and
badabin badabum, the feature will be imported into the game. all teh application have to do is set up a cople of pointer for teh use data, and the callbacks.

this is sthe glue code for serialization of an entire world
Code: Select all
//static char* MAGIC_NUMBER = "serialize data";
static void SerializeFile (void* const serializeHandle, const void* const buffer, int size)
{
   // check that each chunk is a multiple of 4 bytes, this is useful for easy little to big Indian conversion
   _ASSERTE ((size & 0x03) == 0);
   fwrite (buffer, size, 1, (FILE*) serializeHandle);
}

static void DeSerializeFile (void* const serializeHandle, void* const buffer, int size)
{
   // check that each chunk is a multiple of 4 bytes, this is useful for easy little to big Indian conversion
   _ASSERTE ((size & 0x03) == 0);
   fread (buffer, size, 1, (FILE*) serializeHandle);
}

static void BodySerialization (NewtonBody* const body, void* const serializeHandle, NewtonSerializeCallback serializecallback)
{
   // here the use can save information of this body, ex:
   // a string naming the body, 
   // serialize the visual mesh, or save a link to the visual mesh
   // save labels for looking up the body call backs

}

void SerializationWorld (const char* const name, NewtonWorld* const world)
{
   char fullPathName[2048];
   GetWorkingFileName (name, fullPathName);
   FILE* file = fopen (fullPathName, "wb");

   NewtonSerialize (world, BodySerialization, SerializeFile, file);
   fclose (file);
}
Julio Jerez
Moderator
Moderator
 
Posts: 12426
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: kinetic friction decremental

Postby PJani » Sun Apr 22, 2012 6:59 am

Can't wait for vehicles :) GOOD news :)

Anyway would it be possible to have vehicle joint as joint for one wheel instead of one joint which holds all wheels?
| 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: kinetic friction decremental

Postby Julio Jerez » Sun Apr 22, 2012 9:13 am

I start refurbishing the joint today.
I can add a wheel joint, however a wheel joint is not really a vehicle, al vehicle is a contraction,
but it requires a lot of skill to go around the round error problems you get when joint move a high different speed, and at the same time they have high mass ratios.

Iwill fucus on teh vehicel package, then I can extract they wheel.
Julio Jerez
Moderator
Moderator
 
Posts: 12426
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: kinetic friction decremental

Postby Overhertz » Sat Aug 18, 2012 12:35 pm

Hi it has been a while since i checked back, just wanted to check if you got any further with the vehicle system? :)
Ziron Programming Language
Download the Assembler HERE
User avatar
Overhertz
 
Posts: 112
Joined: Mon Jul 06, 2009 11:19 am

Re: kinetic friction decremental

Postby Overhertz » Fri Aug 24, 2012 8:27 am

has the forum died or what??? :/
Ziron Programming Language
Download the Assembler HERE
User avatar
Overhertz
 
Posts: 112
Joined: Mon Jul 06, 2009 11:19 am

Re: kinetic friction decremental

Postby PJani » Fri Aug 24, 2012 10:31 am

Nop it didn't :D its just a slow week :)

Julio is working a lot on fixing bugs and continius collision mode if i am not mistaking.

I am waiting for proper vehicles too, since upgrade from 1.53 to 2.xx. Mean while i do other things on my project :)
| 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: kinetic friction decremental

Postby Julio Jerez » Fri Aug 24, 2012 10:41 am

Not it is not, I need to get the continue collision with champhered cylinder going before I add the new vehicle
Julio Jerez
Moderator
Moderator
 
Posts: 12426
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles

Re: kinetic friction decremental

Postby Overhertz » Mon Sep 03, 2012 12:26 pm

okay... i will keep checking back, thanks for replies :)
Ziron Programming Language
Download the Assembler HERE
User avatar
Overhertz
 
Posts: 112
Joined: Mon Jul 06, 2009 11:19 am


Return to General Discussion

Who is online

Users browsing this forum: No registered users and 1 guest

cron