Textures

The same gradient image on two quads, sampled by an identical shader that simulates what a lit material does: work on the texture value as linear light, then encode the result back to sRGB for display (pow(color, 1.0 / 2.2)). The left quad's Texture.colorSpace is 'linear' (no decoding on sample), so the encode step is applied to already-encoded bytes and the result looks washed out. The right quad is 'srgb': the GPU decodes it to linear on sample, the shader's encode step undoes that, and the colors come out matching the source image. Edit colorSpace or flipY below to see the effect change.

← all examples