AI, Data Science & Cloud Certificates from Google, IBM & Meta
The Most Addictive Python and SQL Courses
Overview
Google, IBM & Meta Certificates – 40% Off
One Coursera Plus subscription covers most Professional Certificates on Coursera.
Unlock All Certificates
This beginner course demonstrates how to draw and animate sine waves on an HTML5 Canvas. It covers point-by-point control, amplitude and wavelength, dat.gui controls, animation, fading, and color effects.
Syllabus
01. Draw a line
02. Ensure line has individual points to control y coordinates
03. Alter each point with Math.sin
04. Add amplitude to increase wave height
05. Add wavelength to elongate waves
06. Import dat.gui to fine-tune wave properties
07. Animate frequency with requestAnimationFrame
08. Clear background
09. Add fade effect
10. Add colors to wave
11. Add colors to background
12. Make properties dynamic with animation and Math.sin
13. Experiment!
Taught by
Chris Courses