Command Palette

Search for a command to run...

Hectal
Phase 17: Performance
3D Web · Exercise 3 of 4 PreviousNext
Advanced

Stop the colour leak

Each click on a colour button makes a new texture and forgets the old one. Make 10 clicks leave at most 1 extra texture in GPU memory.

Keep the colour changing on every click.

What Check tests

  1. Ten clicks leave at most 1 texture
  2. The colour still changes

Stuck? One hint at a time

The solution unlocks after your first Check. Try first: that is where the learning happens.

Runs in your browser. Your code is saved here.

Your page

Press Run to see the page.

Console

Nothing logged yet.