Coding Challenge #19: Superellipse

Subscribers:
1,740,000
Published on ● Video Link: https://www.youtube.com/watch?v=z86cx2A4_3E



Duration: 13:36
81,562 views
1,384


In this coding challenge, I’m going to use superformulas to create a superellipse in p5.js. This is part 1 of a multi-part series on superformulas, superellipses and supershapes. Code: https://thecodingtrain.com/challenges/19-superellipse

πŸ•ΉοΈ p5.js Web Editor Sketch: https://editor.p5js.org/codingtrain/sketches/Hk-1AMTgN

πŸŽ₯ Previous video: https://youtu.be/JcopTKXt8L8?list=PLRqwX-V7Uu6ZiZxtDDRCi6uhfTH4FilpH
πŸŽ₯ Next video: https://youtu.be/jrk_lOg_pVA?list=PLRqwX-V7Uu6ZiZxtDDRCi6uhfTH4FilpH
πŸŽ₯ All videos: https://www.youtube.com/playlist?list=PLRqwX-V7Uu6ZiZxtDDRCi6uhfTH4FilpH

References:
πŸ”— Superellipse on Wikipedia: https://en.wikipedia.org/wiki/Superellipse
πŸ”— Supershapes: http://paulbourke.net/geometry/supershape/
πŸ“• Nature of Code class on Kadenze: https://www.kadenze.com/courses/the-nature-of-code/info

Videos:
πŸŽ₯ Supershape track: https://thecodingtrain.com/tracks/supershapes
πŸ”΄ Coding Train Live 41: https://youtu.be/1Yo_AYzxA-o?t=7132s

Related Coding Challenges:
πŸš‚ #23 2D Supershapes: https://youtu.be/ksRoh-10lak
πŸš‚ #25 Spherical Geometry: https://youtu.be/RkuBWEkBrZA
πŸš‚ #26 3D Supershapes: https://youtu.be/akM4wMZIBWg
πŸš‚ #112 3D Rendering with Rotation and Projection: https://youtu.be/p4Iz0XJY-Qk

Timestamps:
0:00 Introduction to the Coding Challenge
0:56 Whiteboard discussion of polar coordinates
2:30 Into the code...drawing an ellipse using polar coordinates
4:38 Whiteboard discussion of the Superellipse formula
7:32 Implementing the Superellipse formula from Wikipedia
9:43 Explaining and implementing the sgn function
11:05 Testing the formula with different values
11:22 Creating a slider for the 'n' variable
12:14 What's next with superforumlas?

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://discord.gg/hPuGy2g
πŸ’– 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

#supershapes #maths #p5js







Tags:
challenge
coding
superformulas
tutorial
programming
coding challenge
creative coding
programming challenge
daniel shiffman
nature of code
p5.js
algorithms
javascript (programming language)
javascript
p5.js tutorial
pvector
superellipse
superellipse tutorial
superellipse math
superformula
supershape tutorial
java
java superellipse
code superellipse