Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark GDK / Physics in DGDK?

Author
Message
Hayer
18
Years of Service
User Offline
Joined: 4th Nov 2005
Location: Norway
Posted: 23rd Nov 2007 21:19
Hi!
Looked at some examples with Newton and stuff, but i really dont understand a s*** of them

Any one got some tuts or something?
plx plx plx

dbGamerX
16
Years of Service
User Offline
Joined: 23rd Nov 2007
Location:
Posted: 24th Nov 2007 05:28
If you're talking about Newton Game Dynamics, then you might be interested in the SDK. The Newton SDK comes with many tutorials, which would help you understand the structure and the inner works of the SDK.

Download the SDK here and run its Setup: http://www.newtondynamics.com/downloads.html

If you installed it to the default directory then the tutorials would be here: C:\Program Files\NewtonSDK\doc

dbPrint ( "Sig" );
Hayer
18
Years of Service
User Offline
Joined: 4th Nov 2005
Location: Norway
Posted: 24th Nov 2007 11:57 Edited at: 24th Nov 2007 15:55
mh-m.. Im having problem converting it from OpenGL / Glut to DGDK

Could any one write a tutorial for us n00bs in the forum?

Xarshi
18
Years of Service
User Offline
Joined: 25th Dec 2005
Location: Ohio
Posted: 24th Nov 2007 23:27
I may post a tutorial on it. I had newton working with many other graphics engines and know how to do it with the gdk, so I may post something. Or perhaps make an open source library. Its that or physx, but idk yet.

Hello
Hayer
18
Years of Service
User Offline
Joined: 4th Nov 2005
Location: Norway
Posted: 24th Nov 2007 23:35
OPEN SOURCE LIBRARY THAT IS EASY TO USE FOR NooBS!

caps off,
and a tutorial with the library would be über sweet nice.

Xarshi
18
Years of Service
User Offline
Joined: 25th Dec 2005
Location: Ohio
Posted: 24th Nov 2007 23:45
hah, ok. Yeah, physx won't install on my vista(system software that is), so it'll be newton. I'll start making some stuff for it. Do people care if it is OOP?

Hello
Hayer
18
Years of Service
User Offline
Joined: 4th Nov 2005
Location: Norway
Posted: 24th Nov 2007 23:54
mh-m..

Yea I would like 2 versions :p

one OOP and one with IDbase(or whatever DBPro is based on)

Xarshi
18
Years of Service
User Offline
Joined: 25th Dec 2005
Location: Ohio
Posted: 25th Nov 2007 00:05
alright, that can be easily done.

Hello
dbGamerX
16
Years of Service
User Offline
Joined: 23rd Nov 2007
Location:
Posted: 25th Nov 2007 03:50
@Benny53 - I'm looking forward to it too

dbPrint ( "Sig" );
Hayer
18
Years of Service
User Offline
Joined: 4th Nov 2005
Location: Norway
Posted: 25th Nov 2007 09:28
Ya!

At last I can implant physics to my game and hopefully understand the code at the same time

Go for it Benny53

Xarshi
18
Years of Service
User Offline
Joined: 25th Dec 2005
Location: Ohio
Posted: 26th Nov 2007 23:17
Ok, I am making some progress. Heres basicly how I have it planned out. You have a static class(well, holds two static fields and a static method), and then a set of classes for geometry. Now, basicly, heres how it will work:


I have a working vector class(borrowed stuff to make all this work from the newton tool box thing), and I have the NDKManager class. As you can see, this is a mix between the id stuff and oop. This is just testing this out, if I need to, I'll make it so you only use ids, but right now I'm seeing if using ids and oop will help any. Right now, I do not have anything running, because I haven't had all that much time to work with it atm.

DNDK - Dark Newton Development Kit. In progress.
Hayer
18
Years of Service
User Offline
Joined: 4th Nov 2005
Location: Norway
Posted: 27th Nov 2007 14:30
looks pretty nice!
Keep up the good work!

Gief gief gief!

Xarshi
18
Years of Service
User Offline
Joined: 25th Dec 2005
Location: Ohio
Posted: 1st Dec 2007 01:41
Bleh, for speed issues I have to go with oop. If I were to go with IDs for bodies, I'd have to set aside a large amount of memory for all the NewtonBody pointers you'd have... so going OOP is more memory friendly. Unless I can think of a better way of using ids, then I won't be using it. But I promise this will still be easy to use. You don't have to set the callbacks or anything, I'll be doing that all in the background. I may make a WIP here soon about it.

DNDK - Dark Newton Development Kit. In progress.
CuCuMBeR
21
Years of Service
User Offline
Joined: 11th Jan 2003
Location: Turkey
Posted: 2nd Dec 2007 00:16
Benny53 could you describe the setup process of the newton sdk within the DarkGDK please, i have problems setting the correct project properties as well as the includes and libraries.
as far as i know, all i need is newton.h, newton.lib and newton.dll right?
any help would be appreciated.
Xarshi
18
Years of Service
User Offline
Joined: 25th Dec 2005
Location: Ohio
Posted: 2nd Dec 2007 00:46
Ok, basicly, to set it up so you can use the functions, you just link the newton.lib(I use
). You have to set the library directory, and the include directory. After that, just put the dll in the executable directory. Now, getting it to work in gdk was really hard actually. I had to basicly take some tool box tools from the newton demos, and some code from irrlicht, and mix it and match. Then after that I got everything working. So heres what you'll need to make to get it to work: a 3 dimensional vector class where you have access to the 3 dimensions(X, Y, and Z), and you'll need a matrix class. The matrix is 4 dimensional. You'll need to add functions to position and rotate the matrix data, I (again, partially taken from irrlicht), have two methods called setTranslation() and setRotation(). Now, don't think you can go into irrlicht, then copy, and have everything work. Because I had to massively change stuff. I might as well post the headers because I've moved to working with PhysX now( it has features i need in my game...).

Now, an example of how you would set or get a bodies matrix, and apply it to a dgdk object.



I hope that helps. There will of course be more, but thats basicly the gist of it. Now, after that, you'll have to create the body, and set those as the callbacks like :


DNDK - Dark Newton Development Kit. In progress.

Attachments

Login to view attachments
CuCuMBeR
21
Years of Service
User Offline
Joined: 11th Jan 2003
Location: Turkey
Posted: 2nd Dec 2007 02:10
Hey i managed to set the newton up finally
Xarshi
18
Years of Service
User Offline
Joined: 25th Dec 2005
Location: Ohio
Posted: 2nd Dec 2007 02:27
haha, thats good to hear then.

WC Physics - PhysX wrapper for Dark GDK.
Deagle
19
Years of Service
User Offline
Joined: 28th Aug 2005
Location: Finland
Posted: 2nd Dec 2007 08:13
CuCUMBeR: How?? Can you please post your project files, i need the eternal power of newton!

Deagle aka D-Eagle
CuCuMBeR
21
Years of Service
User Offline
Joined: 11th Jan 2003
Location: Turkey
Posted: 2nd Dec 2007 13:30
I use Visual studio 2005 pro,
To describe it as simple as possible..

Install latest newton sdk.

After you setup your project settings for DarkGDK to work,

Alter your project settings as follows:
1- Configration properties / c/c++ / General:
Add this line to Additional Include directories:
or whatever your install dir is.

2- Configration properties / Linker / General:
Add this line to Additional Library directories:
or whatever your sdk/dll dir is.

3- Configration properties / Linker / Input:
Additional Dependencies:


4- You need one more thing, the newton.dll you can either copy it to your project.exe directory or in the build events - post build effect, you can adda command line to xcopy the newton.dll to your output diretory.

dont forget to
file and voila.

Hope it helps.
Xarshi
18
Years of Service
User Offline
Joined: 25th Dec 2005
Location: Ohio
Posted: 2nd Dec 2007 22:04
wait, cucumber, were you asking how to set it up in the IDE? Or did you mean actually get running physics?

WC Physics - PhysX wrapper for Dark GDK.
CuCuMBeR
21
Years of Service
User Offline
Joined: 11th Jan 2003
Location: Turkey
Posted: 3rd Dec 2007 00:40
setting it up in the ide, anyways you have been helpful
getting the physics run is simpler than setting it up with the ide, though ill release a library soon for that
Xarshi
18
Years of Service
User Offline
Joined: 25th Dec 2005
Location: Ohio
Posted: 3rd Dec 2007 03:21
@CuCuMBeR - Haha, thats cool. Thats definately a new one though. It isn't extremely hard to get running, but I definately think its harder than getting it set up in the IDE

WC Physics - PhysX wrapper for Dark GDK.
jason p sage
17
Years of Service
User Offline
Joined: 10th Jun 2007
Location: Ellington, CT USA
Posted: 15th Jan 2008 21:46
@Benny53 - How goes the Physics Battle with Ageia? Or are you just going to wait for DarkPhysics?

I May take a stab at Newton. What was it your game needed Ageia for not found in Newton?

Btw - when I ran the newton demos they were VERY slow, and would go crazy if you banged stuff around (possibly to much? To much "forces?")

I'm looking at some random free source code now for a rigid physics lib... that is rather small and is pure source - no dll's etc... and it has vehicles. I never did this kind of API coding (physics etc) so its all new - and DarkPhysics might serve me better but I'll play a little while and see how I do.

Really curious how you are doing with AGEIA directly.

Login to post a reply

Server time is: 2024-10-08 15:46:31
Your offset time is: 2024-10-08 15:46:31