Tech Focus: Killzone 3
Digital Foundry goes head-to-head with Guerrilla Games on the technical make-up of its latest shooter
A major reason to switch was the fact that we really liked the look of MLAA. Quincunx always had a slight blurring effect on the screen and although it had its charms, it also made everything a bit murky. With MLAA everything was much crisper and textures look sharper, and if we want everything a bit softer we have depth of field, bloom and motion blur which we can tweak.
With MLAA we reduced our load on the RSX quite a bit, we halved the size of the G-buffers and some depth/stencil re-primes between passes were no longer necessary, which gave us additional speed boosts. In the end it gave us quite a bit of RSX cycles and memory back, which we invested back into texture streaming, draw distance, texture sampling quality and - more indirectly - the variety in characters, environments and so on.
We were already doing most of our post process effects on the SPUs, but with MLAA moving to SPUs as well we had the entire post chain running there. We also need to store a full resolution colour buffer in XDR RAM (the main RAM) all of sudden, so we had to take a hit there.
Yes, we've entertained the thought, but the cost of doing so didn't seem too appealing to us. Although it'd look incredible, we'd have to trade off other factors such as draw distance or variety which were much higher on our wish list.
"We could keep some assets from Killzone 2, but in general we had to up the texture resolution, model complexity, shader complexity and colour use between the two titles."
This is largely an artistic direction, but there is some technology that played parts in it as well. There is a delicate balance in our colour pipeline, from what the artwork writes into the albedo buffer, to how it's lit and then how colour-correction deals with it. We were quite happy with the general look, but we also thought it was a bit too monochrome and it was very difficult to colour correct properly.
Together with the Art Director we worked on improving the algorithms that we use and improving our colour pipeline. We have specific hue controls at the end of the pipeline and preserve precision and colour better throughout.
We could keep some assets from Killzone 2, but in general we had to up the texture resolution, model complexity, shader complexity and colour use between the two titles.
The physics in Killzone 2 is done with Havok middleware and a lot of our custom work as well. We've been working closely with Havok to move more code to SPUs over time and also reduce the memory use and SPU time spent in physics. We run Havok in parallel with a lot of graphics work on the same SPUs. It's definitely not cheap, but we do a lot of physics in quite a short time.
Animation is all done with PlayStation Edge for the lower level parts and our own code for the higher level. The Edge part is really fast, but we noticed that the high level parts (which was still running on PPU) was becoming quite a bottleneck. At some point we'll have to move that to SPUs as well, but it'll be quite a re-factor!
We did improve a lot on the AI, but the major systems stayed the same. We optimised more code to run on SPUs so we could do more AI and bigger battles, but the focus was really on the behaviours this time. We've spent a lot of time making them more diverse and recognisable for different enemy types, as well as improving their overall quality so they're more responsive, their animations look better, they're good in close combat and brutal melee and they're just more fun to play with.
A lot of the network code was scratched and re-written from the ground up. For us community is one of the most important aspects of multiplayer and although we were quite happy with Killzone 2's feature set, we felt our networking systems wouldn't scale with what we wanted to do in future. It's too bad that you don't get street credit for re-inventing yourselves, but we've got a much more flexible system now which is much more stable, responsive, gives us richer stats and provides a solid foundation for things to come.
We're doing occlusion culling of (sub) meshes on screen and it's difficult to quantify what it gives you exactly because you need to compare it against something. Compared to Killzone 2 I think we have 10 to 30 per cent less overdraw and primitives being wasted (so more of the stuff that we send to the RSX ends up on-screen and being drawn), but it depends on the circumstances.