3D Web · Exercise 1 of 5Next
Advanced
Write a stripe shader
The plane covers the screen but its fragment shader paints it black. Make it show four vertical white stripes on black: white in the second half of each quarter of the width, using vUv.x, fract and step.
What Check tests
- The first quarter's first half is black
- The first quarter's second half is white
- The second stripe is white too
- The gap between stripes is black
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.