Real-time Raytracing For PC Games Almost A Reality
Vigile writes "Real-time raytracing has often been called the pinnacle of computer rendering for games but only recently has it been getting traction in the field. A German student, and now Intel employee, has been working on raytraced versions of the Quake 3 and Quake 4 game engines for years and is now using the power of Intel's development teams to push the technology further. With antialiasing implemented and anisotropic filtering close behind, they speculate that within two years the hardware will exist on the desktop to make 'game quality' raytracing graphics a reality."
Or is it? Simply means games will appear more eye-candy than they currently are. Gameplay will not change. EA will continue to use take last years sport game, through some new people into it, perhaps introduce some bug which makes it unusable and peddle it as The New Deluxe Edition. I wonder how many geometric objects it will be able to handle (and whether it handles transparancy with textures and patterns well) Having done a bit of raytracing I'm familiar with how quick things can bog down. It'll probably be a bit clunky at first, but get much better as horsepower and horsepower/dollar ratio improve.
There was some game I played on an Amiga (got that? A really old computer) where I raced around in an aircar zapping stuff (some bastard borrowed the game and I've never seen it since!) Very nicely rendered graphics, beautiful even, nearly looked ray-traced. Must have been about 15 years ago.
While I look forward to more realistic, or creative and beautiful gamescapes, do keep in mind -- we were all blown away by the first high quality animated films, now almost everything animated is rendered, raytraced, etc. and there's a lot of junk out there now. So this will be exciting for about 2 years then become "meh".
Lastly, they've got to get the motion down. Characters in games, including sports, look so damn wooden in their movement! That's where real improvement needs doing.
A feeling of having made the same mistake before: Deja Foobar
I grew up with video games where the blob of pixels barely resembles anything. The power of gameplay, lasting gameplay far outstrips graphics. Not that a little eye candy doesn't hurt. I guess the core problem is that nothing Intel produces can run time optimize "Lair" into "Tetris" or otherwise correct for this.
www.voiceofthehive.com - Beekeeping and Honeybees for those who don't.
...but Q4RT seems to have handicapped most of what makes the Doom 3 engine so impressive-looking to begin with. The reflection effects sure are nice, but it's a long way from making anything comparable to modern methods.
Sure is interesting, all the same.
I was a founder of Deep Productions, one of the Chicago's first rendering farms about 15 years ago. I recall having dozens of Pentium 60s (Were they called Pentium Pros back then?) with 512MB of RAM (if I remember correctly) running a variety of rendering programs (usually 3D Studio, but others based on clients needs). IIRC, a single raytraced frame took about 20 minutes. 2 dozen machines churning full speed were able to render approximately 60 fields per hour, or 1 second of animation in an hour.
I exited that market and Deep eventually moved out of that field entirely, but looking back, I can't believe we made the money that we made at the time. Now that ray tracing is getting closer to real time, it gives me a few minutes pause to realize how much technology has changed in ways that the AVERAGE consumer has no understanding of -- and doesn't need to. In the end, I'm glad that so many entrepreneurs take risks so that consumers needs (and yes, entertainment for some is a need) and wants are fulfilled, without those consumers even knowing the process necessary to get there.
Raytracing comes under a class of problems that are embarassingly parallel. Want to render 2 million(~1920x1020) pixels? Send them to 2 million processors(cores) simultaneously and get results back. This is possible because there is rendering each pixel is independent of rendering another. Note that all the data required(like textures, lights, etc.) should be available to all the processors, so SETI style high latency computation is out of the question.
What makes it interesting is that the gigahertz race is done with and has turned into a "core" race. Intel was already showcasing 80 cores on the same chip. A few cores dedicated to Phong shading algorithms and radiosity and the rest to ray tracing would simply overshadow the current raster rendering. Also, raytracing is mathematically elegant and simple compared to all the dirty tricks employed by current graphics technology so it should make programmers' lives easier(unlike the Cell processor which is a nightmare to code for).
This space for rent.
And to the above posts bemoaning the focus on graphics over gameplay, remember if they get a good real-time raytracing system in place then that frees the dev team up quite a bit. No longer having to work so hard on faking proper lighting, they can then focus on the more important things like gameplay/AI/physics.
Most people who pine for better game play are not looking hard enough. Generally they suffer form a severe case of nostalgia. Back int he bad old days for each Super Mario brothers or Missile command there were 4 ET's, Coeleco smurfs or Custer's Revenge. You just don't remember them. The past wasn't some golden age where game play trumps graphics. IT was a place where event he brilliant games had significant control issues, where top shelf games wouldn't been be considered tier 3 dreck today. Take a much maligned games liek Lair, is the basic controls any worse then say NARC for the NES? but NARC was a "good" game for it's time while Lair is a maligned as crap. I haven't played lair but bad controls are no longer acceptable.
There is game play innovation today, and it doesn't have to be independent of pretty graphics. In fact the people responsible for the game play aren't the ones responsible for innovative game play. One does not diminish the other. Good game play is also not the same as innovative game play. They coincide for instance in games like Katamari damacy but often innovation ~= unpolished ~= crap. What we're all looking for is polished game play. It never changes that around 80% of everything will be considered crap. So just rmeember that back int he day 80% of everything was crap too but you just don't remember. So they can ray trace graphics, thats awesome. Will it diminish gameplay.. not really you'll still have 80/20 rule. It's not an indication that things were better then before only that your brain works in a funny way.
"There are more things in heaven and earth, Horatio, than are dreamt of in your philosophy."
I wonder if this is still relevant.
Don't get me wrong, I love raytracers, but what once was their exclusive domain (reflections, shadows,...) has been done in a "fake" but very convincing way since the few latest generations of 3D video cards. What's left? True refraction? True curved surfaces? Is it that important? I tend to side with the "give me gameplay" crowd here.
Realtime caustics and global illumination, on the other hand...
My website
Most likely the ray traced games of tomorrow will be running on ray tracing accelerators, namely graphics cards. Probably the same graphics cards as the next generation or two, running the ray tracing via shaders...
Sure, Intel like to talk about their 80 core x86 chip, but when it comes down to it I'm fairly certain that to get anything better than 'barely acceptable' you'll have a beast of an accelerator from nVidia or AMD. However it may make it easier for Intel to elbow into the game.
Note that you could buy ray tracing accelerators 10 years ago. There was a Cambridge based company that put them in a form factor like a DIMM.
I don't see why most slashdotter's think that if a company does decent graphics they cannot have good gameplay. Sure there is a lot of crap games that come out but this was true in the past too. Graphics have been going up but I can't say that gameplay has necessarily been going down completely. There were plenty of genesis/nintendo games I simply didn't find to be fun. In any case improved graphics in the last ten years has allowed for more diverse, immersing, and heart wrenching games.
PS2+ games are the same but with a slight increase in learning curve (most older games you can just pickup immediately and it was a matter of skill and timing mastery to complete, newer systems usually employ more complicated but still fun gameplay). It has great games and crappy games, just all the graphics are 3d and generally better looking. Some dev's just don't understand how to make an enjoyable game.
Also better graphics allows for different games and more complex games. Imagine if you were limited to the graphics of let's say early tetris/pac-man (i wonder why we only remember a handful of games from the era =P hint hint*) or even more primitive like the first version of pong. It's safe to say if we were limited to the most basic levels of gaming for the last 30 years the market wouldn't be as large, appealing, or diverse as it is now.
Racing simulator's, cinematic rpgs, cinematic fps's (or any fps for that matter), simply wouldn't be possible. With pong lvl graphics yo'd be limited to one dot as a target and maybe different colored squares to target. Simply not anywhere near as immersive. Imagine when Resident Evil started the survival horror genre. I remember playing it at night on my PC (RE: 2) and just being completely freaking spooked during certain parts. I don't think ultra basic midi music and little blurbs of pixels could ever accomplish that.
Hmmm... Pie...
I remember fifteen years ago doing VR research work and people joking about real-time raytracing for games and VR. Computers are massively faster now than they were then. Why aren't we doing it at this point?
Resolutions have gone up enormously. Polygon count has gone up enormously. If we talk the sort of quality scenes we were rendering in 1993, it was only a few more years before it was possible to do them real-time... but at that point models were 10x more complicated and you weren't rendering for 320x240, you were looking at 640x480. Now we're doing millions of polygons at HD resolutions.
As long as people want more polygons, more texture detail, and higher resolutions, realtime raytracing will never be a production reality. Better hardware, faster CPUs, etc are all consumed quickly to handle richer environments and then suddenly there isn't overhead for raytracing anymore.
I don't care at all how the video card decides something needs to be rendered, so long as the results look good. I'm not concerned with the "correctness" of the calculations, only the results. I'd be all for a raytracing card if they found a way to make that work faster with less silicon than the existing rasterization systems. However, it seems we've really done a pretty good job of figuring out what can be quickly accelerated in silicon.
I'd much rather have good, fast, fake stuff than something that is done "right". As an example I actually generally like the graphics in UT2004 better than Doom 3. Despite Doom having a more "correct" lighting engine (all light comes from a source in game, there's no magic global lights) I find that the illusion breaks down too easy. Shadows are too hard, textures get too unrealistic when you get next to them (even in ultra mode) and so on. Now a lot of what UT2004 does to fight that is "faking" it. For example the whole detail texture thing. You get close enough to something, it fades in another texture layer over top that adds grit, imperfections, etc to what you are looking at. While that's "faked" it looks damn good and helps keep the illusion.
So I'm with you on the "give me gameplay". If they can make hardware that does raytracing as fast or faster than what we have and if it looks as good or better, great, I'm all for that. However I'm not at all interested in something that ends up being worse visually, either because it is slower or less detailed or whatever, just in the name of doing it more "correct".
Raytracing has no advantage over rasterizing for opaque surfaces. Rasterizers are faster there, since their performance is not tied directly to the screen resolution. The advantages lie in refraction/reflection/shadows/translucency, which are painful to implement with rasterizers.
Actually, there's a big advantage. Raytracing is O(log n), but rasterization is O(n). OpenRT's demo of a 350 million triangle model of a Boeing rendered in real time on a single PC (without GPU support) is a good example. The entire model doesn't even fit in memory, so visible surfaces are cached. The result is still realtime (although only a few FPS) with incredible detail. Go slashdot the server and watch the movie. Modern raster based cards can only render that many triangles in a whole second with all their fancy hardware, if they're lucky.
"Where are we on the scale."
People sometimes get a little too giddy talking about Big O notation. Yes, something that scales logarithmicly rather than linearly will eventually be faster, but it kinda depends on where you are now if that will happen any time soon and thus is worth worrying about. To use arbitrary units, suppose at an 'n' of 1000 is the intersection point between the line for rasterization and the curve for ray tracing. So when we pass 1000, it starts to be a case that ray tracing is more worthwhile. Now suppose that current generation of graphics is 100, and it grows at a rate of 2 per year. Ya... Ok, not going to be worrying about that any time soon.
I think that was his point is that just saying "But it's O(log n)!" doesn't mean it is necessarily better at this point.
Also there is the silicon problem to be considered. We don't do our graphics on general purpose processors, we do them on highly specialized DSPs that actually have only recently gained turning completeness (and aren't very good at it, they are really slow at branching among other things). The graphics we see today are possible only because we can make a special purpose processor that can accelerate them very efficiently. Can the same be done for raytracing? I don't know. I mean I'm sure it is possible to an extent, especially since it is a very parallel problem, but that doesn't mean that we will be able to as efficiently accelerate it.
So while it is appreciated that at some point, on equal general purpose hardware, ray tracing is more efficient that isn't the question. The question is What is that point (and how soon will we reach it) and does that carry over to the special purpose graphics hardware?
"Hey look, the photons accurately react with the environment according to current laws of physics! Finally they figured out how to make games fun!"
:-\
The obsession with graphics is ruining the gaming industry. Compare the PS3's sales to the Wii's for evidence.
I have never understood the race to photorealism in games. Perhaps it's for those back-of-box screenshots ("from a version you'll never own"). Better graphics are nice, but they swap the the player's imagination for visual detail. Games companies do this, diverting programming resources from what a game plays like to what a game looks like, without realising that there's a "+5, imagination" gameplay boost that comes from believing that the collection of bad sprites on screen is humanity's last chance for survival against some alien creatures. I think that the greatest advance in the last decade for immersion is the use of surround speakers, not better graphics.
Sometimes I think he's right. While I can see the merits of high definition and DTS, I've also seen plenty of films that seem to rely entirely on CGI and pretty graphics but have a weak plot (and plenty of games too for that matter). I hope this isn't going to make the developers spend even more time making textures, models and scenes just because you can see them so clearly.
The kind of hardware needed to run raytracing really fast is well understood, and it doesn't really look like today's GPUs or like intel's CPUs, though even today you can get better results if you take advantage of the GPU as well. If ATI or nVidia doesn't come up with a hardware raytracing GPU someone else will. It's a pity that Intel doesn't seem to be interested in working on that angle.
Here's an article I've dug out of the Wayback machine and cleaned up, Raytracing vs Rasterization. Phillip Slusallek's home page is here, and you can follow that to SaarCOR and OpenRT. They built a prototype RPU (R for raytracing) that at 66 MHz was comparable in performance to a 2.6 GHz P4. The video is pretty impressive, considering how slow the hardware is.
- O(log n) in the number of objects in the scene
- O(n) in the number of primary rays, generally some multiple of the number of pixels on the screen (though it might be a bit less if you're using MLRTA)
- O(n) in the number of lights (though there may be some shortcuts) if shadow rays tests dominate
- O(something big) if there's a lot of reflective and/or refractive objects and you don't do anything to mitigate the rampant recursion
- O(n log n) in the number of photons, if you're using photon mapping
- O(n log n) in the number of objects that moved since the last time you rebuilt the acceleration structure
That first one was what the original post was refering to. (Tracing a single ray is O(n log n). Tracing a pixel involves sending one or more rays and a shadow ray for each light for each primary ray that hit an object. Tracing a whole image involves tracing a lot of pixels. If the number of pixels and the number of lights are assumed to be a constant, they drop out of the big O equation. It's a very big constant, though, and that's one reason why ray tracers are so slow. However, once you get enough CPU to compensate for that large constant, the algorithm starts running pretty fast, and it doesn't slow down much at all when you throw lots of geometry at it.While I am not sure that realtime raytracing will really be the next big thing, I think there are unintended consequences you overwatched.
Today, most CG effects must be hard coded, using tricks, shaders, complex modeling techniques, multiple passes, etc... In the raytracing world, as you are aware, the engine is easier to use, and I would also say, easier to code. It is also very easy to parallelize (so a specialized card could bring HUGE performance gains) and require few modeling tweaking compared to the current T&L world. In a raytracer, shadows (including self-projecting), reflections, refractions, bump mapping, displacement mapping, etc... are an integral part of the renderer, they are not a lot of different modules stacked on top of each other. Bringing down the complexity of the rendering engine hopefully frees more resources to work on other parts of the game.
The Wise adapts himself to the world. The Fool adapts the world to himself. Therefore, all progress depends on the Fool.