This document provides an introduction to shaders, which are small scriptlets executed on the GPU to render content to the screen. It discusses how shaders manipulate pixel colors, vertices, and surfaces to process 2D and 3D graphics. Shader programming languages like GLSL and HLSL allow manipulating color components and performing math operations. The document outlines common shader operations like color spaces, interpolations, primitives, and filters. It introduces shader graphs in Unity and techniques like tone mapping. Examples of using shaders for effects like blur and edge detection are provided. The goal is to explain shaders through the metaphor of magic and wizardry at a school of witchcraft and wizardry.
4. House of Colors at Hogwarts
4
RGB(A) HSV YUV
● All color components are represented between 0 to 1
● Fragments deal with pixel colors
● Shader scripts manipulate color components
● Need to convert to different house of colors for some operations
● Final output must be in RGB
0
1