2004-08-19

 

3D ENGINE

I worked so hard last week, so hard that I couldn't remember doing it before in my life. Complete shader support is finally done and nK's shaders are almost 100% compatible with nVidia FX Composer (www.nvidia.com). Now it's time to start working on better tools and performance. The new engine is not doing any caching of states and texture changes at all, I expect a big improvement on these. I swapped my 9800xt back for my nVidia FX and compared some FPS. It looks like ATI's driver is doing some sort of caching there, because the difference between the old and new engine is not impressive, nor the difference between shaders off and shaders on mode. nVidia dropped badly in the new engine version and turning shaders on results in 50% performance hit. But, as I've said, there's no optimization in the engine at all.

Stability is one of my concerns at the moment since we've to close a demo version for a potential customer very soon so the tools and the new code went finally in the hands of Outrunner that started experimenting with it.

I officially hate ASE's normals, they're a nightmare, maybe we finally worked out a way to have them working but damn, I do hate them.

I did yet another major redisign for the 3D engine, again, closer to the data structure I am using for DX's VertexBuffers. I've worked out many things for shaders support such as tangents, binormals and edge list, the latter could be very interesting for a quick test of "Doom3's like" stencil shadows, as I've said in my last report, they don't match with alpha tested trees and fences but could be used for buildings and other solid geometry, I plan to do the test once the pressure goes a bit down.

 

THE RACING SIM MARKET

Racing sims market is a very difficult one. One after another every big software company left this game genre that has always been a centre of attention and popularity for every gaming platform. From the era of GP2, one of the "big" reason to have a PC back in those days to Sony's use of the GranTurismo serie to boost sells of the new PS2. So what's wrong with the racing sim market? Why can't this genre generate revenues, interest and succes just like the flight sim market does?

First of all, the problem is in the standard race simmer-wannabe. Compare the way we approach a flight simulator to the way we approach a driving simulator. In a flight simulator if we crash on our first take-off the reaction is likely to be "wow, that's hard, must be realistic!", if you spin out at the first corner in a racing sim, the scenario would easily change into "huh? what happened there? how is possible that car XYZ doesn't go around the corners like on rails?".

Can you see the problem? It's in the attitude, we all respect an airplane, no matter what, and, probably, the more advanced and fast it is the more we tend to respect it. We just don't "respect" cars. Cars are something we've around everyday, most of us drive one, and 99% of us think we're better drivers than the average. We do not "fear" cars,  And we think we understand cars. Go back to the plane example, 99% of us never flew an airplane, and have no idea what's involved in doing it, thus, they get the result of the game as "good". Back in the early days of flight sims on the PC, FlightSimulator already had a huge respect in the community, but think about that, probably, IndyCar Racing was closer (from a physical simulation) to a car than Flight Simulator to a real plane.

So, people don't have a very good idea of what a plane should do, so they use a Flight Sim asking the game to give them an idea. While people "think" to know cars and they ask the simulation to recreate what's their idea of driving a car. Let's see a typical example:

Many of us read magazines about cars, most of them report data on the car performance, and most of those put the accent on the data of "maximum speed". Now, the typical subconsious mental process is:

 

1) I know my Fiat UNO can do 150Km/h on a good day.

2) I know I can take the roundabout near my home at 60Km/h with my UNO.

3) I read that a Ferrari Enzo can do 350Km/h.

4) Thus (mental process), 350:150=x:70. With a Ferrari I would do the roundabout at 160Km/h!! Yuppie

 

Err.. no, you wouldn't, it doesn't work that way. There's a very good chance your very expensive dream car will go around a slow corner not much quicker than a Fiat UNO.

But this is just against what the world around us is teaching us! I mean, it's a Ferrari man! I shouldn't have to slow down.

 

This is an endless circle.  I've seen this happening on internet forums days after days after days. Solutions? Not really, this is just the way it is, racing sim community will just have to accept the situation and be as welcoming as possible with these sort of mental processes I've shown above.

 

HOW DEEP IS A RACING CAR SIM

As deep as it can be. But think about this: if it was possible, given the current technology and knowledge, to achive a simulation 100% perfect, why wouldn't Formula One teams invest in it? There's so much money available in there, why they don't come up with a complete simulation of a car so to get the perfect balance and the perfect aereodynamic configuration? Instead, they spend millions of $$$ to build wind tunnels. What's wrong?

Nothing is wrong, 100% simulation is not possible yet, not using multiprocessors super computers and absolutelly not using your relatively cheap home PC. And a racing sim is not just about simulating the car, you need to render the visual of it, and it has to be good, so your potential PC horsepower is even more limited by this factor.

But sims are close, all of the "new generation" sims are very close and, infact, they're getting similar. Consider the differences between 2 racing games 6 or 7 years ago, or even, consider the difference between 2 modern arcade racing games: they "feel" very different because of the way they approach the simulation and the compromises they want to take. But compare the "modern" racing sims, nK being one of them, can you really feel all THAT differrence? Provided that there are no bugs, most modern racing sims are using very similar equations and mathematical models, they all access ideas from the same sources. And there is more, the higher the scale of the simulation accuracy the smaller is the difference in the overall result.

If one would have to come up with a sort of "ladder" to indicate what is the most important element in a sim and how big is the contribuition of that element on the overall feeling then it would look something like;

 

1) Tyre math model - 80%

This is THE most important element in a car simulation, remember it is the only contact with the road and the main source of every force acting on the car. The implementation could go from a sad "no tyre modeling at all", still typical in arcade games, where the car behaviour is mapped against a series of predefined curves.. like to say, if the car is going at speed X then it car rotate around its center at speed Y. This is usually refered to by the racing community as "central pivot problem". Going up in complexity there could be a 2 point (or bycicle) model, where the car is simulated and simplified into a 2 wheels veichle, where each virtual wheel is responsable for an "axle". This was common in early racing sims. Then you have the full 4 contact points with each wheel simulated separatelly and generating separate forces. From there, you can have a good or bad model, but once that's right, you've nailed 80% of your sim's general feel. In other words, let's say you come up with an amazing 5 arm multilink suspension in real time but your tyre math model sucks, then your sim will suck as well, the suspension improvement won't save a bad tyre model. This is the same for wings and every other part of the sim.

 

2) Aereodynamic (depending on the car) 0-15%

 

3) All the rest,

 

The perfect example of the theory above is GPL, with its very good tyre model that feels great no matter how "simpified" (compared to modern sims) could be.

 

LINUX

And some more rant about Linux. I've installed Fedora Core 2 and I've to say I am very impressed with the progresses made in these 3 years by Linux. It just came in sweet and easy, found my Audigy 2, the network and, after a small download, nVidia drivers (ATI were a big pain and I gave up).

Being so DX-centred I can't promise any nKpro for Linux any time soon, also, as far as I am aware there's no Force Feedback support in Linux at the moment, so there will be no point in porting nKpro for the time being.

But I will keep an eye on the progresses here and, if nKpro turns out to be a success I could find myself writing something OpenSource for Linux in my "spare time" after nKpro's development.

 

NKPRO FEATURES

By the end of the month, all the basic features of nKpro should be defined and you can expect a partial list of those (some features will be kept "reserved" for a bit longer) coming in early september with some early screenshots hopefully by mid september too.

Pretty much the bigger picture is clear, we've to smooth out the details and make the final decisions about some issues.

 

back to you next week

 

stefano