Deepwatch

Keyboard shortcuts

Space or k
Play or pause
j and l
Back or forward 10 seconds
Left and right arrows
Back or forward 5 seconds
f
Fullscreen
m
Mute or unmute
Shift and < or >
Slower or faster
?
Show or hide this list

Noise vs Random in p5.js

The Coding Train, 11 min, 141.2K views, Jun 23, 2016

Chapters

Show description

In Part I.3 of my Perlin Noise Tutorial, I demonstrate the difference between two p5.js functions that return random numbers: noise() and random(). Code: https://thecodingtrain.com/tracks/the-nature-of-code-2/noc/perlin/noise-vs-random šŸ•¹ļø p5.js Web Editor Sketch: https://editor.p5js.org/codingtrain/sketches/u6Te_XMF5 šŸŽ„ Previous video: https://youtu.be/Qf4dIN99e2w?list=PLRqwX-V7Uu6ZV4yEcW3uDwOgGXKUUsPOM šŸŽ„ Next video: https://youtu.be/y7sgcFhk6ZM?list=PLRqwX-V7Uu6ZV4yEcW3uDwOgGXKUUsPOM šŸŽ„ All videos: https://www.youtube.com/playlist?list=PLRqwX-V7Uu6ZV4yEcW3uDwOgGXKUUsPOM References: šŸ”— noise(): https://p5js.org/reference/#/p5/noise šŸ”— random(): https://p5js.org/reference/#/p5/random šŸ”— The Nature of Code: https://natureofcode.com/book/ šŸ”— NOC Github: https://github.com/nature-of-code šŸ”— NOC Examples p5.js: https://github.com/nature-of-code/noc-examples-p5.js Timestamps: 0:00 Introduction 0:50 Random function 1:43 The argument to the noise function 4:17 The noise value distribution 5:11 Let's code! 6:35 Mapping the noise value 8:04 Using xoff to get new noise values 9:05 Updating the value of xoff Editing by Mathieu Blanchette Animations by Jason Heglund Music from Epidemic Sound šŸš‚ Website: http://thecodingtrain.com/ šŸ‘¾ Share Your Creation! https://thecodingtrain.com/guides/passenger-showcase-guide 🚩 Suggest Topics: https://github.com/CodingTrain/Suggestion-Box šŸ’” GitHub: https://github.com/CodingTrain šŸ’¬ Discord: https://thecodingtrain.com/discord ✪ Nebula: https://go.nebula.tv/codingtrain šŸ’– Membership: http://youtube.com/thecodingtrain/join šŸ›’ Store: https://standard.tv/codingtrain šŸ–‹ļø Twitter: https://twitter.com/thecodingtrain šŸ“ø Instagram: https://www.instagram.com/the.coding.train/ šŸŽ„ Coding Challenges: https://www.youtube.com/playlist?list=PLRqwX-V7Uu6ZiZxtDDRCi6uhfTH4FilpH šŸŽ„ Intro to Programming: https://www.youtube.com/playlist?list=PLRqwX-V7Uu6Zy51Q-x9tMWIv9cueOFTFA šŸ”— p5.js: https://p5js.org šŸ”— p5.js Web Editor: https://editor.p5js.org/ šŸ”— Processing: https://processing.org šŸ“„ Code of Conduct: https://github.com/CodingTrain/Code-of-Conduct This description was auto-generated. If you see a problem, please open an issue: https://github.com/CodingTrain/thecodingtrain.com/issues/new #forbeginners #javascript #p5js

When you're done