More than 50 authors have contributed their expertise to ShaderX2: Shader Programming Tips & Tricks with DirectX 9. Divided into six sections, this book focuses on a wide array of shader programming topics, including:
* Terrain geomorphing * Cloth animation using vertex texturing * Rendering polygonal objects as thick volumes * Hemisphere lighting * Rendering volumes using ray tracing * Water simulations * Precomputed radiance transfer * Simulating iridescence and translucency * Fog effects * Simulating real-time depth of field * Implementing soft shadows * Using effects buffers
On the CD: The companion CD contains examples and source code discussed in the articles.
Author(s): Wolfgang F. Engel
Publisher: Wordware Publishing, Inc.
Year: 2003
Language: English
Pages: 729
Team DDU......Page 1
Contents......Page 4
Preface......Page 8
About the Authors......Page 10
Introduction......Page 20
Section I-Geometry Manipulation Tricks......Page 26
Using Vertex Shaders for Geometry Compression......Page 28
Using Lookup Tables in Vertex Shaders......Page 38
Terrain Geomorphing in the Vertex Shader......Page 43
3D Planets on the GPU......Page 58
Cloth Animation with Pixel and Vertex Shader 3.0......Page 65
Collision Shaders......Page 83
Displacement Mapping......Page 98
Section II - Rendering Techniques......Page 112
Rendering Objects as Thick Volumes......Page 114
Screen-aligned Particles with Minimal VertexBuffer Locking......Page 132
Hemisphere Lighting with Radiosity Maps......Page 138
Galaxy Textures......Page 148
Turbulent Sun......Page 152
Fragment-level Phong Illumination......Page 156
Specular Bump Mapping on Pre-ps_1_4 Hardware......Page 174
Voxel Rendering with PS_3_0......Page 186
Simulating Blending Operations on Floating-point Render Targets......Page 197
Rendering Volumes in a Vertex & Pixel Program by Ray Tracing......Page 202
Normal Map Compression......Page 210
Drops of Water and Texture Sprites......Page 215
Advanced Water Effects......Page 232
Efficient Evaluation of Irradiance Environment Maps......Page 251
Practical Precomputed Radiance Transfer......Page 257
Advanced Sky Dome Rendering......Page 265
Deferred Shading with Multiple Render Targets......Page 276
Meshuggah's Effects Explained......Page 295
Layered Car Paint Shader......Page 318
Motion Blur Using Geometry and Shading Distortion......Page 324
Simulation of Iridescence and Translucency on Thin Surfaces......Page 334
Floating-point Cube Maps......Page 344
Stereoscopic Rendering in Hardware Using Shaders......Page 349
Hatching, Stroke Styles, and Pointillism......Page 365
Layered Fog......Page 373
Dense Matrix Algebra on the GPU......Page 377
Section III - Software Shaders and Shader Programming Tips......Page 406
Software Vertex Shader Processing......Page 408
x86 Shaders–ps_2_0 Shaders in Software......Page 421
SoftD3D: A Software-only Implementation of Microsoft's Direct3D API......Page 438
Named Constants in Shader Development......Page 457
Section IV - Image Space......Page 462
Advanced Image Processing with DirectX 9 Pixel Shaders......Page 464
Night Vision: Frame Buffer Post-processing with ps.1.1 Hardware......Page 490
Non-Photorealistic Post-processing Filters in MotoGP 2......Page 494
Image Effects with DirectX 9 Pixel Shaders......Page 506
Using Pixel Shaders to Implement a Mosaic Effect Using Character Glyphs......Page 544
Mandelbrot Set Rendering......Page 551
Real-Time Depth of Field Simulation......Page 554
Section V - Shadows......Page 582
Soft Shadows......Page 584
Robust Object ID Shadows......Page 605
Reverse Extruded Shadow Volumes......Page 612
Section VI - 3D Engine and Tools Design......Page 620
Shader Abstraction......Page 622
Post-Process Fun with Effects Buffers......Page 639
Shaders under Control (Codecreatures Engine)......Page 650
Shader Integration in the Gamebryo Graphics Engine......Page 656
Vertex Shader Compiler......Page 675
Shader Disassembler......Page 692
Index......Page 716