Referencia finalColor

finalColor

A shader hook block that modifies the final color of each pixel after all lighting is applied. This hook can be used inside buildMaterialShader() and similar shader modify() calls to adjust the color before it appears on the screen. Modifications happen between the .begin() and .end() methods of the hook.

finalColor has the following properties:

  • color: a four-component vector representing the pixel color (red, green, blue, alpha).

Call .set() on the hook with a vector with four components (red, green, blue, alpha) to update the final color.

This hook is available in:

Ejemplos

Notice any errors or typos? Please let us know. Please feel free to edit src/strands/p5.strands.js and open a pull request!

Referencias Relacionadas