Soft Body Physics Explained

Поделиться
HTML-код
  • Опубликовано: 11 сен 2024

Комментарии • 390

  • @ja100o
    @ja100o 3 года назад +1227

    You have the potential to become the "3 blue one brown" of game and simulation development.
    You already earned my bell, so keep it up!💪🏽

    • @SLPCaires
      @SLPCaires 3 года назад +3

      Same!!!

    • @automatescellulaires8543
      @automatescellulaires8543 3 года назад +2

      Nice channel for sure

    • @ajbridgewater
      @ajbridgewater 3 года назад +5

      I couldn't have said it better!

    • @NHCH
      @NHCH 3 года назад +3

      He will never be the 3blue1brown of game development.
      He leaks the black background lol
      Jk, great work🔥 keep it up

    • @jamesorendorff2284
      @jamesorendorff2284 3 года назад +3

      @@NHCH "lacks"

  • @lucinoide-2174
    @lucinoide-2174 3 года назад +480

    this is really some of if not thee best content on math + programming on youtube. keep it up man these are blessed

  • @anupamrana8619
    @anupamrana8619 3 года назад +137

    Wow What a content.... you're so underrated may RUclips algorithm bless you

  • @AlexandriaLibraryGame
    @AlexandriaLibraryGame 3 года назад +68

    Nice, I was googling the other day trying to find a video like this.

  • @specialgorilla
    @specialgorilla 3 года назад +67

    Yo this video is actually sick. I was surprised to see it doesn't have more views. You definitely earned a subscriber, I've been looking for a good explanation of this for a long time.

    • @Gonkee
      @Gonkee  3 года назад +7

      Appreciate the support!

    • @nagualdesign
      @nagualdesign 2 года назад

      You've been looking for a long time, but without bothering to Google it or do a simple search on RUclips? 😊

  • @misterZalli
    @misterZalli 3 года назад +52

    A great introductory video!
    If you feel like it, I'd appreciate if you made a followup video(s) about the different approaches to soft bodies (and maybe integration techniques) that you mentioned.

  • @FenlonAcoustic
    @FenlonAcoustic 3 года назад +11

    Just came from your sound synthesis video, and I'm only a minute into this one, and I had to stop the video and take the time to say how utterly fantastic this content is. If the quality of the content on this channel continues as it has been, this channel is going to be HUGE. I'm absolutely delighted to have found this channel.

  • @bobsmithy3103
    @bobsmithy3103 3 года назад +25

    Amazing explanation. Even after learning about Hooke's law in high school and at uni, it never clicked with me how I'd actually make a program to simulate it. However this video does. Now I really want to implement it.

    • @Gonkee
      @Gonkee  3 года назад +8

      Thank you, good luck if you try to implement it :)

  • @TheSirako
    @TheSirako 3 года назад +166

    Incredible content, keep it up! I'm getting vibes of a soon-to-blow-up channel:)

    • @tiagol8200
      @tiagol8200 3 года назад +4

      100% Agreed

    • @random.123
      @random.123 3 года назад +1

      Same, this is really well made

  • @rentacowisgoogle
    @rentacowisgoogle 2 года назад +131

    where the beamNG fans at?

  • @ruchirraj5300
    @ruchirraj5300 3 года назад +13

    This video really helped me get started in this field, I really thought it to be very difficult to do something like this but after watching this video it really inspired me to venture into this field and learn more about physics simulations in general, Thanks a lot 😁

    • @magnuswootton6181
      @magnuswootton6181 2 года назад +1

      Its easy to do if you dont need realism, pretty much any haphazard way of connecting together points with velocities will give you a quite good result! complete self contrived baby numerics will work! :)

  • @thelostsoul9446
    @thelostsoul9446 3 года назад +5

    As a kid that would like to do some programming stuff as a job later in my life, this is awesome. Currently in class we started to study vectors, but i could still grasp somewhat of an understanding of everything that was said in this video due to the clarity of your explanations. I've learned a lot today. Thank you!

    • @rykehuss3435
      @rykehuss3435 3 года назад

      wait until you start studying tensors

    • @thelostsoul9446
      @thelostsoul9446 3 года назад

      @@rykehuss3435 i dunno if i should be scared or excited.....

    • @rykehuss3435
      @rykehuss3435 3 года назад

      @@thelostsoul9446 scared

    • @thelostsoul9446
      @thelostsoul9446 3 года назад +1

      @@rykehuss3435 good

  • @vb0t429
    @vb0t429 3 года назад +4

    I love this video!
    Total Sebastian Lague
    vibes, keep on making great videos!

  • @TheSpinTensor
    @TheSpinTensor 3 года назад +7

    Nice video. Regarding the integration algorithms you could check out verlet-integration (or variations thereof like leap-frog integration). It is only slightly more complicated than euler integration but fixes a lot of its problems. Also it is probably possible to implement a multistep-integration scheme, where you integrate the external forces on the point-masses with different timesteps than the springs, thus reducing the required computational power. If you do so, you can further optimize the integration of the springs, as they are harmonic, thus exactly integratable with terms, that can be precomputed.

  • @Testgeraeusch
    @Testgeraeusch 3 года назад +2

    8:44 "Exclamation mark not factorial sign"

  • @SuryanIsaac
    @SuryanIsaac 3 года назад +2

    Subscribed in 15 seconds - I can feel the effort that went into this video

  • @charliew.1122
    @charliew.1122 3 года назад +2

    Just spent the whole day coding this as well as I could from the video - furthest I've ever gone is circle-circle collisions so this was definitely a pretty big challenge to me.

  • @BrendanGraziani
    @BrendanGraziani 8 месяцев назад +1

    Great video, helped me create my own soft body simulation (in python!) without giving the code. Great explanation overall, really helped me understand the methods behind soft bodies. Definitely earned a subscription and a bell.

    • @BrendanGraziani
      @BrendanGraziani 8 месяцев назад

      I am having a little trouble implementing self-collision though. Any help would be much appreciated.

    • @gmdrandom6287
      @gmdrandom6287 7 месяцев назад +1

      @@BrendanGrazianigive each particle a radius. Check collisions between each particle kinda like:
      #idk how to actually python but example:
      for i, p1 in enumerate(shape):
      for j in range(i+1, len(shape):
      p2 = shape[j]
      #assuming that in a shape you have each point
      #get distance (squared) between each point with d = (x2-x1)^2 + (y2-y1)^2
      #sum the radius of both particles and square it. If the dist is less than sum of rad squared, then they are colliding
      #for resolution, take the difference between the position of p1 and p2
      #divide the difference by the magnitude of the difference to obtain the separation axis
      #sum up the radius of both points (not squared) and subtract that by distance (just take the sqrt of previously calculated d) to get penetration depth.
      #multiply the difference axis by the pen depth (separation vector) divided by 2 (because you apply it to both points).
      #Add and subtract the Sep Vec to both p1 and p2.

  • @Xenro66
    @Xenro66 3 года назад +1

    Tryna learn all I can about rigid body physics to make my own crude engine in Java (yes, I'm that -sadistic- masochistic. I always mix up those words), so this video is right up my alley of interest. That ray method for detecting collisions is so damn elegant that I feel stupid for not knowing about it sooner lmao. In before your channel blows up...It's well deserved!

  • @DThorn619
    @DThorn619 3 года назад

    Ever run across a channel and think "Wow how have I not seen their videos sooner, this quality must have attracted a huge following" only to be floored when you see the abysmal view and subscriber count!?!
    Those are rookie numbers (42k views / 7k subscribers as of 4/7/2021) we gotta pump this channel up!
    Eagerly looking forward to more. Also if you have a Github page where you can share your implementation of these codes that would likely help your viewers as well.

  • @boneman-calciumenjoyer8290
    @boneman-calciumenjoyer8290 2 года назад +1

    I'm not bright enough to understand what you're talking about, but I now do desire to play squishy Tetris.
    Great video... I think.
    I've also subscribed to your channel, so I may someday (in the far future) understand what you're talking about.

  • @TomasSab3D
    @TomasSab3D 2 года назад

    This is SO CLOSE to an advanced Ph.D. level course at a university! Only the quality - higher. Awesome.
    Though, at university, you get to see all of the different ways to model stiffness, complex geometries of elements, plasticity.... Still, introduction wise - this is amazing work.

  • @rhetorical_
    @rhetorical_ 3 года назад +2

    I am SO LUCKY to have found this channel! This is some awesome content, thank you Inspecto!

  • @CANProductionZz
    @CANProductionZz 3 года назад +10

    The amount of flashbacks I just had to A Level Maths and Physics is insane

    • @atom9885
      @atom9885 3 года назад +1

      whole lot of linear algebra as well

  • @andermium
    @andermium 3 года назад +4

    This gives me a whole new level of appreciation for the work C4D4U is doing with his softbody simulations!

    • @AkariInsko
      @AkariInsko 3 года назад

      Aprectiatcion*

    • @andermium
      @andermium 3 года назад

      @@AkariInsko Bone apple tea :)

  • @antoinecantin1780
    @antoinecantin1780 3 года назад +2

    I absolutely love your videos they are just next level quality with incredible animations and editing, along with great informative content, if you ever hit 1M, I won’t even be surprised

  • @chenmarkson7413
    @chenmarkson7413 3 года назад

    RUclips lacks good explanators in the field of computer science simulations -- I'm sure you will be the best one given a couple of years!

  • @alessi4249
    @alessi4249 3 года назад +1

    What an incredibly elegant and easy to understand explanation! I wish I had this when I was trying to figure this stuff out in the past!

  • @boggybolt6782
    @boggybolt6782 3 года назад

    Just imagining the limitations and issues these kind of simulations can create(like, example, the spring moving past its maximum extension in a single frame) makes me happy that I'm not going into that field myself.

  • @thatskap
    @thatskap 3 года назад +1

    Understanding soft bodies seemed so out of reach until this video. Nice job.

  • @rbcubosengenharia694
    @rbcubosengenharia694 3 года назад +4

    Are you Gonkee ? Pretty owesome explanation o/

  • @ferociousfeind8538
    @ferociousfeind8538 2 года назад

    This is... refreshingly comprehensive, assuming little to no prior knowledge. Just.. wonderful! I didn't know tutorials could come in this flavor.

  • @Mad3011
    @Mad3011 3 года назад +2

    Nice video! Just wanted to point out what you are doing is a semi implicit Euler integration which is already slightly more stable than the standard Euler method.

  • @Qubaef
    @Qubaef 3 года назад

    Holy, this was exactly what I was looking for. Physics for devs, with visuals and model names. Instantly subbed! Keep it up.

  • @ollie-d
    @ollie-d 3 года назад +1

    Very well made, informative video. You have a great speaking cadence and you present your material clearly. Thanks!

  • @nerkulec
    @nerkulec 3 года назад +1

    The quality of your content is so good, man! Keep it up!

  • @pixl237
    @pixl237 3 года назад

    I waited so long to find somebody alking about Physic simulation this smooth...I mean : I can create a whole Physic system only using this video EVEN IT'S the purpose was only the soft body...You're my Lord now

  • @MissPiggyM976
    @MissPiggyM976 10 месяцев назад +1

    Very good tutorial, thanks !

  • @siriema9238
    @siriema9238 3 года назад +1

    Wow, that explains a j2me game that i have so impressed how the developer could do that, the game was about a Drop of oil, i have so impressed, i forget the name cause I was younger when i played, but thanks man, the video explains so much than i wanted...

  • @Yutaro-Yoshii
    @Yutaro-Yoshii 3 года назад +4

    8:35 you can also add a small constant to the denominator to avoid dividing by zero while still being able to compute something (also one branching avoided)

  • @coolrat3816
    @coolrat3816 2 года назад

    This video is ridiculously practical and easy to understand. I'm beyond impressed!

  • @acatfrompoland5230
    @acatfrompoland5230 3 года назад +1

    This video is actually really good. Well done keep making more.

  • @ArnoldsKtm
    @ArnoldsKtm 3 года назад +1

    The visualization is spot on.

  • @MichaelHickman3D
    @MichaelHickman3D 2 года назад +1

    Wonderful video!!!

  • @HarhaMedia
    @HarhaMedia 3 года назад +5

    Great introduction!

  • @kubstoff1418
    @kubstoff1418 3 года назад

    This is by far the best video explaining the introduction to softbodies I have ever seen, kudos to you!

  • @avelione
    @avelione 9 месяцев назад

    I barely understand any of this but your voice is nice, it's nice to relax to in the background☺

  • @ypyketo
    @ypyketo 3 года назад +1

    So glad I found your channel. I do some physic simulation for kids myself, hope to learn a lot on the coding side from you! Keep up the great job!

  • @rickyspanish4792
    @rickyspanish4792 3 года назад +3

    this is super informative! thanks :)

  • @rafaelgpontes
    @rafaelgpontes 3 года назад

    Oh, boy. I wish I had known this Gonkee channel before. This content is gold!

  • @DrDrift-rl6cc
    @DrDrift-rl6cc Год назад

    Man, this video is S tier. God be with you.

  • @elishmuel1976
    @elishmuel1976 3 года назад

    5k subs only?? It's the first video I've seen of yours and I already subbed. I love the detail!

  • @BgfordeProductions
    @BgfordeProductions 3 года назад

    Excited to have stumbled upon this gem. Very well produced content sir, can't wait to see your next video!

  • @Ywqqqq
    @Ywqqqq 3 года назад

    That's exactly the type of content I was looking for, thanks a lot and keep going !

  • @deadmeme5291
    @deadmeme5291 3 года назад

    Amazing video. Such nice work from a small content creator. Im amazed!

  • @Sancarn
    @Sancarn 3 года назад

    5:47 - You probably want to use an r-tree to store those bounding boxes too.

  • @robins423
    @robins423 3 года назад +1

    This channel is gold. Glad I found it

  • @nextProgram
    @nextProgram 3 года назад +1

    Really great video, good work

  • @ghostsdefeated4078
    @ghostsdefeated4078 3 года назад

    The quality of your videos is incredible

  • @dawidzyrek6481
    @dawidzyrek6481 3 года назад

    That's soo good, I had no idea that that pattern of calculating velocity was called "Euler integration", but I've seen it already in many engines and frameworks. Keep it up

    • @AkariInsko
      @AkariInsko 3 года назад

      Ruler*

    • @redbuck1385
      @redbuck1385 8 месяцев назад

      Everything in math/physics is called "Euler ______"

  • @jacobyoung6876
    @jacobyoung6876 3 года назад

    Your explanations of physics simulations are just amazing.

  • @aleksanderbaszkiewicz536
    @aleksanderbaszkiewicz536 3 года назад

    The most underrated channel. You have such knowledge....

  • @MrLuigiBean1
    @MrLuigiBean1 3 года назад +1

    Quick Question: Was the thumbnail meant to say " _Softy_ Bodies" instead of "Soft Bodies"? I like the amusing ring to it!

  • @augustindvs
    @augustindvs 3 года назад

    your videos are very clear and comprehensive ! Thank you !

  • @Jesse-cx4rc
    @Jesse-cx4rc 2 года назад

    Love the explanation, i’ve personally obtained the best results in the past using a verlet integration scheme in terms of stability

  • @AxelWard
    @AxelWard 3 года назад

    This is such a good analysis of soft bodies. Well done!

  • @navid9852
    @navid9852 2 года назад

    Super cool presentation. Really liked the collision part

  • @danielweinmann960
    @danielweinmann960 3 года назад

    I realy like your Intro and the Style of your Videos!

  • @tomasdougan1419
    @tomasdougan1419 Год назад

    This is a concise and informative video-- thank you so much for making this!

  • @maibster
    @maibster 3 года назад

    Absolutely awesome video, completely perfect! Best explanation yet and maybe ever! Good job

  • @ChannelSho
    @ChannelSho 3 года назад +2

    Where was this when I had to do a simulation using a soft-body? 😂
    Good stuff though!

  • @samarthtandale9121
    @samarthtandale9121 2 года назад

    Please keep uploading videos !!! You are the great

  • @magnuswootton6181
    @magnuswootton6181 2 года назад

    I threw the rest of 3d physics modelling in the bin when I saw this!!!! it is way superior in all respects!!!

  • @yntxrrr
    @yntxrrr 3 года назад +1

    Me at 1:30 am: Oh cool, a video that explains something I mostly understand! This will be good to fall asleep to.
    Me at 1:40 am: As it turns out, I did not mostly understand the topic, and I am now much more awake.

  • @lucystarlight8887
    @lucystarlight8887 2 года назад +1

    For the process of raycasting, does 0 count as an even number? I'm assuming it would have to for the process to work for points outside of a polygon.

  • @runforitman
    @runforitman 3 года назад +2

    I love that I'm seeing this just after studying Hooke's law and a few other things in this video, at school

  • @capitaopacoca8454
    @capitaopacoca8454 3 года назад

    This is video is so well-explained that even I could understand.

  • @bobingstern4448
    @bobingstern4448 3 года назад

    Absolutely Fantastic video, I was able to implement the whole thing while watching the video

  • @resiknoiro7506
    @resiknoiro7506 Год назад +1

    spring force, the force that melts snow

  • @flameofthephoenix8395
    @flameofthephoenix8395 11 месяцев назад

    Ideally, we need to find a mathematic formula for determining the exact path that an object will move, then compute the intersection of the two paths, luckily you can add one path to the other to simplify the collision computation to just finding the intersection of a constantly changing shape that's rotating and morphing in seemingly random ways and the origin point 0,0 this still is not great, however given how it's not randomly changing shapes but doing it according to a pattern there is a single way I can think of that would have an O(n^2) time complexity at the least. I am fairly sure it is possible for rigid body collisions, but I think finding the path of a spring would be extremely difficult.

  • @huseyintemiz5249
    @huseyintemiz5249 2 года назад

    How amazing. I subscribed your channel in the middle of video. Thanks.

  • @Monkeymario.
    @Monkeymario. Месяц назад +1

    10:17 DONT FORGET RK4 INTEGRATION

  • @AbElsaied
    @AbElsaied 3 года назад

    Great video keep creating and one video will go viral. I just want to know what software do you use for simulation?

  • @fominvic81
    @fominvic81 3 года назад +1

    Thanks, amazing tutorial. Will you do the second part?

  • @enzowars
    @enzowars 3 года назад

    Woah are you Gonkee? Great information by the way!

  • @RamiCrafy
    @RamiCrafy 7 месяцев назад

    Yeah I don't know what I was expecting
    I don't understand anything but good video!

  • @kilroy987
    @kilroy987 3 года назад

    Nice discussion, thank you. You make me want to try this. So I bookmarked your video.

  • @enderb0t
    @enderb0t 3 года назад

    im still in school half of this is just random gibberish yet i still enjoy watching this

  • @Antuan2911
    @Antuan2911 2 года назад

    3:50 -> not "air resistance", but mostly loss of energy... as heat for example.

  • @Nafinafnaf
    @Nafinafnaf 3 года назад

    Why is this in my recommended. And why do I want to watch more of this guy’s work

  • @hgsilva89
    @hgsilva89 3 года назад

    Great video! Keep up the awesome work, your channel is very promising

  • @rommusteegan
    @rommusteegan 3 года назад

    happy this was recommended, really great video

  • @TheLex1972
    @TheLex1972 8 месяцев назад

    Love the video, great explanation! Thank you!
    Just one ask: please drop the background music. I find it distracting… just IMHO of course.

  • @J_E_N_T
    @J_E_N_T 3 года назад

    This is a really brilliant video, well done!

  • @o00nemesis00o
    @o00nemesis00o 10 месяцев назад +1

    6:49 is not true in all cases. If the point is off to the side of its closest edge, then its escape vector will not be the same as the surface normal.

  • @juniorcyans2988
    @juniorcyans2988 10 месяцев назад

    Interesting and inspiring topic!

  • @TheGameLix
    @TheGameLix Год назад

    4:58 This does not seem fully right to me. F_s would be a scalar according to this formula but shouldn't it be a vector as well? I think you also have to multiply it with the normalized vector between A and B like you did for F_d.

  • @bricaaron3978
    @bricaaron3978 10 месяцев назад

    9:50 I'm not sure why you mentioned a tick rate of 60 Hz. Of course one is limited by the available processing power, but there is no reason to limit the tick rate to the framerate. It just seems to me that some people may become confused on that point.

  • @OliverBevan23
    @OliverBevan23 3 года назад

    This video is great. So glad I got it in my recommendations.

  • @ombrezz7030
    @ombrezz7030 3 года назад

    first video I've seen from you, subbed in 20 seconds