n.
One who, or that which, shades.
| Dictionary: Shad·er |
| 5min Related Video: Shader |
| Wikipedia: Shader |
In the field of computer graphics, a shader is a set of software instructions, which is used primarily to calculate rendering effects on graphics hardware with a high degree of flexibility. Shaders are used to program the graphics processing unit (GPU) programmable rendering pipeline, which has mostly superseded the fixed-function pipeline that allowed only common geometry transformation and pixel shading functions; with shaders, customized effects can be used.
Contents |
Initially, shaders were used to perform pixel shading only (see Pixel shader). However, the term stuck and is used for other graphics pipeline stages now, too.
As Graphics Processing Units evolved, major graphics software libraries such as OpenGL and Direct3D began to exhibit enhanced ability to program these new GPUs by defining special shading functions in their API.
Shaders are simple programs that describe the traits of either a vertex or a pixel. Vertex shaders describe the traits (position, texture coordinates, colors, etc.) of a vertex, while pixel shaders describe the traits (color, z depth and alpha value) of a pixel. A vertex shader is called for each vertex in a primitive (possibly after tessellation) - thus one vertex in - one (updated) vertex out. Each vertex is then rendered as a series of pixels on the screen (or more correctly, onto a surface (block of memory) that will eventually be sent to the screen.
Shaders replace a section of video hardware that's typically called the Fixed Function Pipeline (FFP). This is because it performs lighting and texture mapping in a hard-coded manner, while shaders let you replace this hard-coded approach with a programmable one.[1]
The Direct3D and OpenGL graphic libraries use three types of shaders.
The unified shader model unifies the three aforementioned shaders in OpenGL and Direct3D 10. See NVIDIA faqs.
As these shader types are processed within the GPU pipeline, the following gives an example how they are embedded in the pipeline:
Shaders are written to apply transformations to a large set of elements at a time, for example, to each pixel in an area of the screen, or for every vertex of a model. This is well suited to parallel processing, and most modern GPUs have multiple shader pipelines to facilitate this, vastly improving computation throughput.
OpenGL (version 1.5 and newer) provides a C-like Shader language called OpenGL Shading Language, or GLSL.
In the Microsoft Direct3D API (Direct3D 9 and newer), shaders are programmed with High Level Shader Language, or HLSL.
Cg or C for Graphics is a high-level shading language developed by Nvidia in close collaboration with Microsoft for programming vertex and pixel shaders. It is very similar to Microsoft's HLSL.
This entry is from Wikipedia, the leading user-contributed encyclopedia. It may not have been reviewed by professional editors (see full disclaimer)
| Shopping: Shader |
| vertex (technology) | |
| vertex shader (technology) | |
| fragment processor (technology) |
| Where can you get a vertex shader? | |
| Where can you get pixer shader 3.0 if you have a videocart wih pixel shader 2.0? | |
| Can you emulate pixel shader 3 from shader 2? |
Copyrights:
![]() | Dictionary. Webster 1913 Dictionary edited by Patrick J. Cassidy Read more | |
![]() | Wikipedia. This article is licensed under the Creative Commons Attribution/Share-Alike License. It uses material from the Wikipedia article "Shader". Read more |
Mentioned in