HRV-reactive environment - mist, god rays and a rainbow responding to biofeedback
← Back to Revocure Shader · Biofeedback · VR

A biofeedback-reactive shader

Polar H10 → HLSL. A VR world whose vegetation, mist and light react to the user's heart rate variability - in real time, on standalone hardware.

Unity URPHLSL Polar H10 · BLEMeta Quest Revocure Role: Technical Artist

// Problem

Revocure measures the user's physiological state during breathing and relaxation exercises. A number on a screen doesn't work - someone inside a headset isn't looking at charts, they're looking at the world around them.

What was needed was feedback inside the scene itself: the environment should reward calm, balanced breathing and dim down when the user is dysregulated. All within a standalone VR frame budget, with no extra CPU load.

// Data pipeline

The path from a chest strap to a material parameter in the shader:

/01
Polar H10
The strap collects raw RR intervals (the time between heartbeats).
/02
BLE
Bluetooth Low Energy transmission to the app running on the headset.
/03
Normalization
HRV is computed and reduced to a single 0–1 float, smoothed so the scene doesn't flicker on noisy readings.
/04
Material parameter
The float reaches the shader as a global parameter - one value drives the entire scene.

// Shader implementation

A single normalized parameter propagates through the scene and drives several visual layers at once, so the reaction reads as one coherent response instead of scattered individual effects.

How it is built

Both shaders are written by hand in HLSL as custom URP Lit variants - no Shader Graph. One is opaque, for terrain and rock; the other is an alpha-cutout, two-sided companion for leaves, flowers and vines.

// Standalone optimization

// Result

The scene responds to live HRV data within the standalone Quest frame budget. The whole reaction is computed in the shader on the GPU - the CPU feeds one value per frame, and the vegetation reads a single global parameter instead of instancing materials per object.

// Video

The scene reacting to a change in the HRV parameter:

HRV reactive beach environment HRV reactive environment - lighting driven by heart rate variability

// Tech Stack

Unity URPHLSL Custom Lit shaderVertex animationC# BLEPolar H10 Meta Quest
// Related project
Revocure