January 2006

Newton 1.51 out

Already released yesterday (had no time to update my blog), Version 1.51 of the Newton Game Dynamics Engine is out!

So grab it while it’s hot. Besides some minor fixes, the vehicle container got a lot of attention in terms of bugfixing and is now a real beauty and fun to use. Note that there were no changes in the headers, so the pascal headers (link) for Newton 1.5 are still working with the 1.51 SDK.

And on to the next good part of this update : NewtonPlayGround is also as good as finished. It now contains over 30 different scenes to show of NGD’s features. Right now I’m going through the code and testing out the different scenes to see if there are any bugs (or problems) remaining, but I didn’t manage to find any of them (which is actually a good sign). So I plan to release it this weekend or maybe even a bit earlier.

Manual : Done

As I already mentioned (a dozen times or so…) writing manual for your own software is not only utterly boring but also not a very easy task. Why? Well, I’ve been working on the NewtonPlayGround since 2004 and I know it in and out (when you write your own applications, that’s what it should be) and now I had to write a rather large document (it’s in HTML form, with a TOC and so on) that should get people knowing nothing about the NewtonPlayGround started with this application. So you have to think about how to structure the manual, what to write, you need to take dozens of screenshots and write down stuff about functions, dialogs or whatever you’re already totally comfort with.

But well, that’s now history. After over 30 screenshots and 20 pages of HTML the manual is now in it’s finished state for the imminent release of the NewtonPlayGround. It feels like loosing a heavy burden!

And as for the PlayGround itself : Like stated on the last update, it’s finished in terms of coding. So in the last few days I only added some very minor stuff I thought would be nice to have. You can e.g. now switch to different camera modes when driving a vehicle, other changes were so small (like new icons for some of the buttons) that they’re not worth mentioning.

NewtonPlayGround is basically done

Yes, the application itself is finished! I’ve spent almost all time I could spare since my last posting (on average several hours a day) for finishing and fixing the last few things/quirks that were left and it’s finished as of now. There were many small things that annoyed me, which needed improvement/fixing and that was what I spent those hours on. It’s somehow frightening to see how those small things consume time fixing them, as there were so many. There were some aspects of the GUI that I disliked and therefore changed (e.g. you couldn’t access the main UI while in character controller or ego-mode), I optimized the shadow calculations to speed it up on complex scenes (though you still need a good system for enabled shadows, depending on the compelxity of the scene), fixed some bugs when loading objects, finally got around fixing some issues with objects that are later on connected into compounds and so on.

And we SDK developers already got a beta of Newton 1.51, which included a fix for the vehicle slowdown with 1.5 I mentioned some news post ago which allowed me to also finish up the vehicle stuff. One addition to the vehicles in NewtonPlayGround is the possibility to offset the center of mass for the chassis. Up until now, the CoM was always at the geometrical center, which was bad especially for high vehicles like a wheeled tank (TpZ Fuchs, if someone is into that military stuff), as such vehicles need a low CoM or otherwise they’ll too easily bend over when turning. So now the user can (after the vehicle is created) offset the center of mass to suite his needs.

Finally I also got around finishing some of the new demonstration scenes I already started (like that house to demonstrate the character controller. It now also has some interior) and made some new ones. I now onl<>

Media Update

Well, I’m still working hard on the NewtonPlayGround to get it out of the door not too long after the final bugfix release of Newton 1.5, so here is a media update to inform you on what’s up with it.

And so to show how much I did with the PlayGround, here are some screenshots :

And here are the descriptions (from left to right) :
Shot 1 : This is the most recent scene, and I just finished it some minutes ago. It’s a model of our solar system and all the planets are connected to disks that are connected with each other using the new custom gear joint. This means that when you rotate a disc, all planets will rotate according to the gear ratio that was set up. Looks fun and also is fun.
Shot 2 : You already saw the catapults, and this is just the graphically spiced-up version of that scene. The environment is loaded from an .X-file for which I wrote an importer to use Direct3D .X-files with OpenGL. And instead of simple spheres, the catapults now throw some real stones which make for a much more interesting flight-path.
Shot 3 : New scene to demonstrate all the joint types included with Newton/Playground. Nothing too different from the scene that was in the old PlayGround, but this one shows how many joints Newton actually has (no Upvector in there!), though you could do all the joints you ever need with the custom joint interface.
Shot 4 : Convex-hull madness at it’s best. This is a bowl full of famous teapots that are maed up using convex hulls. Though it get’s slow at times, framerates still are not too bad for Newton (and rendering also takes it’s time, especially with shadows enabled).
Shot 5 : As already posted on my blog, one of the new Features is a character controller included in the PlayGround, and that house is the scene to show it off. Using it is simple : Just open up the dialog and set up the size, forces and position of the character controller and off you go. Oh, and you can also grab stuff like in the ego-mode, just think of HL².

And behind the scenes I fixed much stuff and spent a whole lot of time for bug-fixing. I even fixed bugs that I was aware of for months, but until recently was too lazy to fix. So I’m pressing hard to get this thing done, both codewise and in terms of content and I think that I’ll have it ready for release short after the bugfixed version of Newton 1.5 is out.

Finally, here is the feedback thread for the NewtonPlayGround on the newton forums. So if you want to know more about what I did since the last official release or want to post feedback, just head on over there.

Bugs here, Bugs there, Bugs are everywhere

So every programmer out there knows them and as more complex your programs get, the more likely you’ll encounter them. But what also happens is, that you often (at least when doing hobby development) don’t catch those bugs since they don’t occure to you, but only happen for other users. And especially with a complex application like the NewtonPlayGround, where there is no real limitation in what to do for the user, it’s hard to catch all those bugs.
And exactly such a bug happened yesterday. I’ve released a test-build of my NewtonPlayGround to the maker of NGD for him to test out a problem I’ve found with the new vehicle container in NGD 1.5, but for him the vehicle wouldn’t drive at all, which made me wonder what happened. So after some long search (the code for the NewtonPlayGround is huge, I’m not sure, but maybe it’s the biggest piece of code I’ve ever written) I found out that, when loading the vehicle information from the XML file, I didn’t take care of the local decimal separator and that was the problem. The german decimal separator is the comma, which is different from most other countries in the world (at least those who speak english, as they use a point for that) and to take care of that I usually have a function for getting single values from an XML-node that takes care of the different decimal separators around the globe. But this time (better said “back then”, as I wrote that part of the code months ago) I just forgot to use that function for loading the value for the vehicle’s torque from the XML-node, and that means that the torque would be very small for english users and only right for german users (or those with a comma for decimal separator). And now that really bugs me! This is code that was written some months ago and I never thought there would have been a problem with that small part of the loading code, and that somehow scares me. I hope that there aren’t dozens of such errors left after the release of my PlayGround, which is rather anticipated.

And if we’re already on the thematics of Bugs : There are also bugs in the current release of Newton (1.5 that is), so the NewtonPlayGround won’t be out before a bugfix release for Newton. The main bug that I found out is a problem with the super-sampling of the new vehicle container which makes more complex vehicles (like the truck with the three trailers) bring the application to a crawl. Julio is already on that bug, so I should soon have a beta DLL to test, and then I’m gonna build some new scenes to show off different vehicles.

Newton 1.5 is finally out

Yes, it’s finally out! Though it’s no longer called 1.35, but 1.5 instead due to the huge number of changes/additions. So go to the Newton Page and download it ASAP.

And then get the Delphi/Pascal headers from my Newton Subdomain. This time, it’s not only the updated header, but it also contains a translation of the custom joints that are included in the Newton SDK (see my last news post for more info on what that actually is). If you find any bugs or encounter problems with the new headers or the custom joints please report them in this thread on the Newton forums.

And a note to all Free Pascal – users : The new newton.dll needs a stack-size of at least 1 MByte, but the default for FPC is much lower. So if you want to use the current SDK with FPC please make shure you set the stack-size for your application to something above 1 MByte.