Http://www.guerrilla-games.com/presentations/GDC09_Valient_Rendering_Technology_Of_Killzone_2.pptx
Http://www.guerrilla-games.com/presentations/GDC09_Valient_Rendering_Technology_Of_Killzone_2_Extended_Presenter_Notes.pdf
An old article, but some details are very good.
Killzone2 has been developed for four years.
Deferredshading
Deferred shading is too common now. Skip the basic introduction.
At first, guerrila tried light Prepass, but for kz, there is not that big demand for light Prepass. If cryengine and Bungie are indeed the final illumination, it is necessary to use the pipeline of the Light Prepass class. kz is unnecessary. In this case, the efficiency of the Light Prepass is lower than that of the traditional deferred shading.
Gbuffer format of kz2:
Lighting accumulation is quite special. It also describes the level at which kz2 lighting reaches. It is used to store
- Indirect lighting,
- The indirectlighting of static object is placed in the light map.
- Dynamic Object uses the spherical harmonics coefficient to store indirect light.
- Reflection map: environment map
An indirect lighting only graph:
- During render lighting, zcull, depth bound test and stencel are used to minimize the lighting area.
- Lighting code can be simplified according to specific situations, for example, some do not need specular.
- Use stencel mask to mark pixel completely in shadow, so that Skip lighting can be used.
- The depth bound test is also used for full-screen lighting. In this way, several levels of lighting can be divided into several levels, and some levels of pads on the lighting quality can be implemented.
Shadow
- Soft shadow filter is a Poisson Disk Filter.
- For a relatively small object, you do not need to cast shadow. This threshold can be specified per object or per light.
- Use the bounding sphere of the camera view frustum as the basis for building the shadow view frustum, instead of for the camera view frustum itself, because camera will convert and building based on the camera frustum will cause flashes.