Coding Challenge #19: Superellipse
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