I Made Interactive Snow in Godot
ฝัง
- เผยแพร่เมื่อ 7 ก.พ. 2025
- I implemented a deformable snow system in Godot, here's the #devlog!
Support the channel & get source code access: / rachelftech
Instagram: / rachelftech
Bluesky: bsky.app/profi...
TikTok: / rachelftech
Try the demo: rachelftech.it...
Music channel: / @rachelfguitar
I love how you choose the stuff most people would be intimidated by and take ten days to figure it out. amazing.
Interactive shaders and shaders in general can be pretty scary
Yeah, I spent far too much time trying to flatten the entire snow field. So very, very satisfying.
I suppose the hook for me here is just watching the problems solving though. The "oh hey, I think I know what I'm doing... no, I'll just hack it around a little, no idea why that worked... hrm, oh hey I was right all along... I think." is so very relatable! Even after being a developer for 30 years, it's satisfying to see some things just don't change!
It's why I love the channel. You'll see a lot of creatives (especially authors, but it applies in a lot of places) who will say that the journey is everything. And as far as that goes, it's true. It's where all the fun and learning is. But you do need a satisfying pay off at the end. It doesn't need to be earth shattering, but satisfying. This snow demo is the very definition of satisfying!
Thanks so much for the kind words, I'm really glad to hear people are enjoying this video format! I'm having a lot of fun making these, so it's cool to hear they resonate :).
Thankful to see I’m not alone. I’ve been into coding for about a year now (beyond structured schooling - ie personal projects/for work) and I still - with roughly “four years” of experience from university and a year working I still sometimes have no idea why I’ve broken something or how I fixed it when it seems I remade the same thing (but it worked the second time!) all this to say - document your work. A quick screenshot and a few sentences on what you were doing/attempting has helped me SO much!
This is the coolest Godot channel on TH-cam. You're doing such interesting stuff! And I love watching your process. Thanks for making such great content :)
Thanks so much, I really appreciate it!
another cool project, the snow angel penguin was funny 😂
Thanks :)
I really appreciate you going into detail about the bugs you encounter instead of glossing over them, your videos are a treasure trove of knowledge! Always love watching them when they come out.
You did in a few days what Farming Simulator should have done for ground deformation in 10 years, I really appreciate you.
Your videos are so cool.. you are not only informative but you radiate so much energy and passion that I always feel motivated
Incredible work !! You are moving the Godot community forward !
Thank you! :)
this is really great and versatile, looks great for snow and could be used for sand or mud as well with a shallower or deeper layer and some tweaks, really great work
Thanks for sharing Rachel! :D One idea for speeding things up is to use some kind of LOD mesh for the snow, which there are a few possible approaches for, most of which entail either the CPU doing more work or a compute shader building vertex buffers. There's an old terrain rendering algorithm that takes heightmap detail/features and camera proximity into account called ROAM, or Realtime Optimally Adaptive Meshes. ROAM has been my jam, in some form or another, for literally decades across a dozen different projects.
Space in the UV maps was fine with the seams showing. You are right it is the mip map problem, but you can tell by looking at the screenshot you are actually showing that the edge of the "lighter" penguin color is transitioning into "darker" penguin color with pixel precision, but of course UV coordinates are vector. When it generates MIPs that difference in the edges becomes more harsh.
The solution in the game art workflows is to "grow" the padding of all the colors that touch the UV shell edges. The term we use is "texture padding" you can look it up.
Great video as always, cheers!
This video was so fun to watch the 30 minutes just blew by! I appreciate you thoroughly explaining your process because I learned a lot as well
this is so awesome! the color shifting based on depth and little specular sparkles in the snow are great!
i tried my hand at deformable snow for Unity back in 2017 and went down almost the exact same path, even down to having debug textures in the scene showing the depth from my ortho cam, which i, of course, also wrote into the red channel. for the actual snow rendering part, i went with a raymarching/signed distance field approach. using raymarching gave me normals by sampling the heightmap gradient and sidestepped issues like the vertex count of the surface effecting "resolution" of the snow, but also made the actual rendering of the surface quite a bit more complicated... which is probably why i never got my actual snow to look good.
Another awesome project, I love to see it! Keep up the great work, can't wait to see more!
Thank you! :)
This is so cool. I spent some time doing some audio stuff over a decade ago. But these days I'm mostly just writing form and list software for enterprise. Never done anything with graphics and 3d, not a gamer either. But this looks like so much freaking fun. So many interesting problems to solve. And you receive such rich and nuanced feedback along the way. Going to have to think about an idea to get into this stuff.
For future reference: Patches on the penguin model are caused by "texture bleeding" (blue bg of the texture bleeds around the edges of UV island) which is worsened by mipmap generator. To prevent this and keep using mipmaps it's better to enable "bleed" option in blender's texture painting, so that you'll be painting slightly outside UVs thus preventing bg bleeding into UVs
Always in awe of your cool project ideas and the wonderful execution! Very awesome!
Thanks so much!
those who snow
those who snow
does he snow?
If you snow you snow
If you don't snow, now you snow
You snow nothing Jon Know
awesome job! love the in depth technical video
"It took way longer than I expected", oh thank god! 😂 Also, I love how you said, you're gonna wrap things up and just add final finishing touches, and lo and behold, 2 days and an army of penguins later, "oh wait! I need to add a new snow angel animation cycle to a penguin!" 😂😂
Jokes aside, super engaging video and amazing results! 😊
I'm so glad you made this tutorial. I had tried doing this for a game previously and there were like 2 tutorials for snow shaders, that I couldn't wrap my head around. This is amazing!
This wasn't really a tutorial, it was an experiment and she herself was learning as she went.
But it is indeed amazing
You are a freaking G! I am always impressed by what I see when I stumble across your videos! You are my inspiration dude! I'm subscribing.
I never would have thought of the camera trick!
One thing that might be worth trying is making the snow pile up on the edges a little so it gives the illusion that volume is being preserved. You could make a duplicate of the depth texture with a more extreme blur applied and then remap the height of the intermediate values on the fringes to create peaks
Always such a joy to follow along. Can't wait to dive into some of my own projects later this year when I'm not so much immersed in other programming projects. Glad to have found this channel for inspiration and I'll almost certainly check out the demos!
Thanks, I appreciate it!
Thanks for sharing! Really enjoyed seeing the progress and the end result was great!
Nice, i'm a self taught noob godot dev, and watching a video like this is super inspiring, nice work !
awesome! i just started learning godot a few weeks ago (making an autorunner). so cool to see what's possible if you invest the time. you're an inspiration! :)
Thank you! Best of luck with the autorunner :)
totall agree I was like waaauw when I first say the snow in RD2! This was cool I subscribed thank you!
really cool! i think part of snow being able to look even more natural would be to make your character controller not instantly rotate to whatever direction you are facing, but lerping it, so less straight lines.
Thanks! I should definitely try that out :)
I agree that linear interpolation, is great for camera movements...
Calling it "lerp" is just unforgivable, though. That's not how a portmanteau is made!
It _obviously_ should be spelled "lirp". 🤓
Yaaaaas. Was literally think about this the other day. Clutched it as always Rachel!
That penguin has big "Duo from Duolingo" energy. Those eyes 👀
Amazing video and really insightful. Thank you so much for sharing!
Thanks, Jace, helps a lot!
That looks awesome! Awesome work! I've always been fascinated with how deformable surfaces worked in game: snow, track in dirt, grass getting pushed down by character
I really enjoyed watching the video ❤
I never thought that you can do something satisfying like that with Godot.
I realized that it’s not about the simplicity of the tool, but rather the skill of the person and the time and effort they dedicate to bringing their idea to life.❤❤❤
Thank you, glad you enjoyed the video! 😁
Awesome work Rachel! Shader programming is one of those things I've rarely touched and so still seems like some sort of black magic at this point!
This is definitely an example of where a compute shader would be useful.
Two viewports, one rendering terrain depth, and one rendering actor depth.
A compute shader to produce the deformation texture based on those two depth textures and reduce the effect of past deformation:
Current = (previous - decay) + new
Great video. I love the problem explanations you give. Just top notch. Thank you :)
This showcase looks fun, interesting and cool. Solid work, thanks for sharing.
Oh wow! The end result is so satisfying, and the penguin making snow angels cracked me up 😂. Great video! And thanks for sharing the progress and issues in details. I'm pretty sure most of it went over my head, but I feel I might have learned something anyway haha.
Thank you! :)
Thank you so much for posting the breakdown! I will be working on something similar for my Bushcraft Survival game. Awesome work.
Awesome, hope it's helpful!
she always smile 🤭..amazing project !
It's rather funny, I was working on a snowball rolling sort of game recently at the Global Games Jam, Boba tea instead of snow, I worked with a fixed grid but it's amusing that youtube would recommend your video :D
Love it! Especially the part with the shaders, where i didn't understand anything except that i have to learn so much more :D
Thanks for showing!
Thank you! I keep feeling that way about shaders as well haha!
That actually looks really good, thanks for sharing.
Just got an M4 Mac mini and this video made me even more exited to download and start on GoDot for the first time. Amazing work as always!
Thank you! Hope you have fun with it! :)
you always have the best godot projects
I loved seeing you work through this. I wish the character (penguin) had individual footsteps like a dog and that the blocks were shaded to look more translucent like ice!
words can not describe how much i love you and your videos, i have learnt more from you than from my college ever could, sending you hugs and kisses , keep doing what you do
XD
Impressed about your perseverance, results and process blow my mind! I start creating raycast vehicle mechanics (by the way it has some examples on godot) and after only one day feel overwhelmed :D
Thank you! I definitely hit many points of feeling overwhelmed during this project and wasn't sure I would get it all working. I find taking lots of breaks helps!
What a cool project! Awesome job!
Great and useful video, thank you for sharing !
I'm glad there were pretty pictures on the screen to help translate this strange language you're speaking!!😅 I have NEVER survived past Hello World in any programming class I've taken. Except maybe visual basic. Not sure how I got as far as I did but then the brick wall of passing values hit me and I never figured it out!
I feel that. Perhaps it's time to knock that wall down.
Just as I thought it would be cool to have a faceplanting snow angel penguin, you did it xD Your projects are always so cute and creative, it is really inspiring. I tried to do a dice roller with 3d dice where the shapes get created dynamically depending on the number of faces from 1 to 100. I have pretty much given up on it, but with every upload I come back working on it for a day or two. Please keep uploading so I will eventually finish the thing haha
Thank you! That sounds like a cool project too, best of luck with it! 😁
Just got to the 5:18 part, and want to leave a comment to see if my guess of why that was happening was correct.
I bet it's because you only have limited space between the -1 and 1, so if you see farther, closer things necessarily move up in intensity due to the range of values being so limited as now -1 means a farther distance that is being represented, so things that were before closer to it move up since they are relative to the far plane getting closer.
Time to see if I was right.
Good video by the way.
Nope, was not right, but that was an interesting thing to find out.
Whenever I use HDRIs for the skybox, I like to set a custom ground color for them so the lighting looks a bit more realistic. If you copy over the ground shader code from the PhysicalSky material and make your own custom shader that just takes in an image, ground color, etc. You'll get some much nicer lighting.
If you did the same thing for this project, and set the ground color to white, you'd get rid of the dark lighting on the bottom of the snowball :)
These are so much fun to watch!
5:06 perhaps it is because the depth value is calculated kinda like depth = (pos-near)/(far-near), so that it is 0 at near plane and 1 at far plane. And if you make far further it doesn't affect the absolute value pos-near, but rescales the normalized one. IDK how it actually works, just had an idea
Amazing work!!
A penguin making a snow angel! My life is complete! But wow so much dedication! I could never figure that out. It turned out great and would be so fun if it was turned into a platformer/puzzle game.
It would be really fun to come back to this eventually and make it into a real game! :)
Such a cool project!
Awesome, great job!
7:54 I thought that you would do something like:
pre allocate a texture buffer to store how the snow should be modified
calculate the change of each pixel ( subtract the current frame from the last frame )
add the change with the buffer and take the average
Really Nice video :D yes the uv-map on Penguin is correct you need its called padding, i often use 8px minimum as padding when i uv-map from atlas or Trimm sheet :) but some times it can be ok to turn off the texture mip-map function or deactivate specific mip-map steps :) and how the bal grow perhaps use some sort of raycast that samples from your dept texture :)
Thanks, will definitely remember to add padding next time! :)
@@RachelfTech :D
Yup, banging your head against the wall for days on end to have smoother snow normals... that's game dev for ya!
Your best video so far
very impressive
That's crazy coincidence, was just about to start making a game with snow in it!
Good timing, there's snow outside and I just started a new godot project :D
I love it!
Great job
+1Sub from me! This is the coolest video i've seen in 2025 so far. very interesting to watch how you tried different ideas and ways to tackle a problem. the result was so awesome! super satisfying snow!! i've barely started using godot, but im excited to get into 3D. i came from gamemaker studio 2.0 lol. great video!
Thanks so much, I appreciate it!
Very cool! Inspiring
So cool!
Love seeing the problem solving! Only a few minutes in, I’m going to guess the solution to the ortho camera is using a small far-clipping plain and setting the camera’s layers up to ignore anything but people 🤞
I did have the camera set up to only see snow impacting objects/characters! Left that part out of the video though I believe.
@@RachelfTechthose srgb conversions agh! Great video, love that the snow angel penguin worked 🐧
Nice effort, good to see your approach. Just FYI Martin Donald applied exactly this technique in Godot 4 years ago. He made a video about it on youtube "Christmas special, making it snow."
Thanks! I think he's actually using the simpler approach (drawing a specific sprite to the mask texture) that doesn't involve a camera or depth information. Still looks great though!
If I recall correctly, getting access to the depth map was something new around Godot 4, so chances are this method wasn't possible in Godot 4 years ago.
The _not quite_ vine boom every time you say "come back the next day" is making that way funnier to me than it should be.
This is really cool!
@NeonfireStudio Thank you! :)
I concur. This is very impressive. You have officially eclipsed my hobbyist programming knowledge and I understood almost nothing you were talking about, but it was still fun to see you work through obstacles and seeing the final product. Keep on keeping on 😄
Cool project!
Wow!!! That's awesome. U got a subscriber. 😀🙌
Looks very nice!!
Thank you!
Hell yeah, snow sim in winter!!
You should make a game with that! I would buy it, the system is pretty awesome and satisfying
I do think it would be cool to eventually use this in a real game!
22:54 haha I'm doing the same moves all the time when figuring out 3D stuff in games haha
as always, 10/10 content
This is very nice.
Amazing! 🌨
Dead or Alive 3 on the original xbox used the direct x 8.1 snow to beautiful effect on the stage "Snow". Some 18 years later the dead or alive 6 stage that (supposedly) has snow on it looks terrible by comparison.
excellent work you're way ahead of Team Ninja.
I released a game on Steam that was successful (as far as indie devs go) but I really disliked the framework. So now I'm learning Godot to make something better. Your enthusiasm is infectious and your backlog of Godot videos are just so good. I hope you continue these. Thank you.
That is so cool to hear! Definitely will be continuing with more similar videos :), thanks!
Amaizing!🎉
I wonder if you could use a similar technique to snap ground to base of house of trees or other props 🤔seen many floating trees lately 😄
that penguin is BONKERS
super cool!
I wonder if you could replace the depth texture with an ambient occlusion pass of the snow so that the ground could be something other than a flat plane.
Amazing! :D
I have no idea what's going on but I kinda wanna download this and learn now.
Amazing... I just recently decided to take another stab at this video game idea using a interactive water surface simulation... And this popped up in my feed... Yeah I'm gonna need that normal fixing stuff and prob a few other ideas, thank you... 😂
Oh nice, hope this is helpful! :)
Yes I tested this shader, you can do more .... now sky material can use shader ...
Great video
I've just started learning Godot, and it's taking a while to get the hang of it, this video was great inspiration to keep working at it, and gives me so many ideas, and questions - like is it possible to vary snow density/depth according to underlaying terrain, wind etc, can collapse mechanics be added if vertical height/angle exceeds a threshold?
Looking forward to learning enough to play with this stuff. 😀
Watching this was an all too familiar process. Beautiful work and showcase!
It's too bad Godot doesn't support geometry shaders or tessellation for dynamic mesh subdivision around the deformed areas. Although it seems mesh shaders are the next big thing anyway.
The basic shapes in snow look so satisfying!
Where are you from? Norway?
Amazing!! 😭Try to make it in roblox now, might a bit more time with editable meshes.
Now we're talking.