sparkle
sparkle(
inputColor,uv,time,density?,intensity?,sparkleColor?,speed?,threshold?):Node<"vec4">
Defined in: packages/nodes/src/vfx/sparkle.ts:30
Add sparkle/glitter effect to a color. Creates randomly appearing bright spots that twinkle over time.
Parameters
Section titled “Parameters”inputColor
Section titled “inputColor”Node <"vec4">
Base color (vec4)
Node <"vec2">
UV coordinates
Animation time
density?
Section titled “density?”FloatInput = 50
Sparkle density (higher = more sparkles, default: 50)
intensity?
Section titled “intensity?”FloatInput = 2
Sparkle brightness (default: 2)
sparkleColor?
Section titled “sparkleColor?”Vec3Input = ...
Color of sparkles (default: white)
speed?
Section titled “speed?”FloatInput = 3
Animation speed (default: 3)
threshold?
Section titled “threshold?”FloatInput = 0.97
Sparkle appearance threshold (default: 0.97)
Returns
Section titled “Returns”Node <"vec4">
Color with sparkle effect
Example
Section titled “Example”const sparkly = sparkle(inputColor, uv, time, 40, 2, [1, 1, 1])