|
|
| Table of contents |
|
2 Details 3 Capabilities 4 See Also 5 External links |
Flexible shaders initially were used for non-interactive rendering applications like Pixar's RenderMan, famously used to render the feature film Toy Story.
3D hardware previously used fixed-function pipelines in which, for example, one was stuck with the lighting model chosen by the hardware vendor. Graphics hardware was able to do transformation and lighting (T&L for short) on the card, but it was not flexible. A vertex shader sidesteps the T&L stage in the pipeline and lets the user add on to it.
Pixel shaders operate after the geometry pipeline and before final rasterization. They operate in parallel with multitexturing to produce a final pixel color and z-value for the final, rasterization step in the graphics pipeline (where alpha blending and depth testing occur).
In the past few years, video cards from Nvidia and ATI have started supporting pixel and vertex shaders in hardware, allowing their use for real-time rendering. The technology is by now quite mature, and the latest generation of games, including Doom3 and Half-Life 2 make extensive use of hardware shaders. A brewing standards battle between ATI and Nvidia should prove entertaining viewing.
The programs are written in either the native assembly language of the card or in a high-level shader language like the aptly named High Level Shader Language. Some key facts about vertex and pixel shaders are that they
The capabilities of vertex and pixel shaders are still being explored, and since hardware capabilites are improving with each generation we can expect their abilities to approach those of programmable shaders such as RenderMan's.
There exist vertex shaders that
Background
Details
Capabilities
There exist pixel shaders that
One of the most intriguing uses of hardware shaders is for physical simulation. The powerful vector math and parallelized architecture make current graphics cards much faster than general-purpose CPU's for certain simulations where the current state at a certain point is only dependent upon the previous state for a small area around it, like turbulent flow. Several projects are exploiting this unintended use.