5.0a: Introduction to Physics Engines Part 1 – The Nature of Code

43
6



In this video, I attempt to answer the questions: (1) what are Physics Engines? and (2) why would you want to use them? I discuss some common physics engines and their various pros/cons — box2d, toxiclibs, matter.js.

Part 2 of this video ( is a Q&A on the subject viewer-submitted questions.

Support this channel on Patreon:

Send me your questions and coding challenges!:

Contact:
Twitter:
The Coding Train website:

Links discussed in this video:
Box2D:
toxiclibs:
Bullet Physics Library:
Cannon.js:
Matter.js:
The Nature of Code:
My Nature of Code playlist on Physics Engines:
My Coding Challenge on 3D Cloth with toxiclibs:

Source Code for the all Video Lessons:

p5.js:
Processing:

For More Nature of Code videos:
For More Coding Challenges:
For an Intro to Programming using p5.js:

Help us caption & translate this video!

📄 Code of Conduct:

Nguồn: https://rodiziodirectory.com

Xem thêm bài viết khác: https://rodiziodirectory.com/game/

43 COMMENTS

  1. Hey – amazing videos! Keep it up 😀 . Uhm , I would like to see a video where you control a creature using revolute joints and the SetMotorSpeed function 😀 – only a tiny bit because cannot figure it out myself.

  2. It is possible to use box2d.ts in p5.js, I found a Bundled version super optimize, but I dont undertand good what is the better way to implments

  3. How do we access the physics engines in racing simulators to make an actuated base? People that make these basis and they react perfectly with the physics happening in game and im curious how they get access to those calculations?

  4. Excuse me Mr. Shiffman.. i've heard something about framerate independence which remove the dependency of the framerate when the program execute the loop() / draw() function.. could you make an explanation about that framerate independence and how to do it in code? Thank you..

    I love your video so much.. this the only channel I found which I could understand from the very basic..

  5. I don't know if you know seen "sluggy the unshaven" of yoshi's island I would like an explanation of its physics (and maths) , it is very interesting. I hope you answer [and I know if that explanation make me afraid XD]

  6. Could you make tutorials on how to use box 2d web with p5.js in ES6 Javascript because i am really struggling trying to use both together

  7. i couldn't be as much grateful for the time that you took to explain this in detail thank you very much sincerely!

  8. Dan, you making time on this update video on physics engines cant come at a better time. putting effort on it is much appreciated

  9. im studying programming and i think that you are really good im from south america so bravo eres genial

  10. ive started watching the series a few days ago and i was already wondering why you suddenly aged so quickly haha. but i love how you kept your energy and enthusiasm

  11. I love your videos because you make each experience fun and easy to follow. you also explain everything in very good and understandable detail. I will be suggesting you to anyone that wants to learn to program.

  12. Sir your videos are great can u plss. Give the code for the program u have shown in the beginning of this video of balls falling in matter.js

  13. Mini rant about a psychological observation:

    It's subtle, so you may not have even noticed what you did. At the beginning, you mention it's often easier and better to start with a well-established physics engine than to create a whole new one from scratch. Then, at 10:15, you get stuck on "joint" vs. "constraint" and rather than just choosing one, you make up a whole new term from scratch called "connection". Rather than simplifying the problem, you've made it more complex by adding yet another term into the equation, just like the authors of those physics engines did by choosing new words and making new physics engines!

    I call this "The Fork Problem". The name is based on the annoying thing that happens with Linux distros, where when the existing distros are evaluated and don't exactly suit your needs, rather than picking the closest one and contributing to it or adjusting it to work for you, you just make a whole new Linux distro, i.e., a "fork" of the project. Now we have 1,000s of variations of the same operating system, each with slight differences, and the whole ecosystem is divided in a puddle of confusion.

    Sometimes it's appropriate to make something new. Competition is good, variation is good, choice is good. Other times, you just make the problem worse when inventing new things for no reason. In this case, using the word "connection" just made things more confusing for the viewer. The impact this had on the video was extremely minor, but it's fun to think about these things in life and to make conscious decisions about whether or not it's beneficial to invent a whole new ideas vs. build upon the existing ones.

    Thanks for the video btw! Excellent material and I love your personality while presenting. 🙂

  14. Are there any videos that you have of making a basic physics engine? (With collisions and bouncing and such)

  15. Is the Example 5_7_car still available? because I looked for it all over, can u please let me know where i can find it

LEAVE A REPLY

Please enter your comment!
Please enter your name here