Blade Grass! Generate and Bake a Field Mesh Using a Compute Shader ✔️ 2020.3 | Game Dev Tutorial

Описание к видео Blade Grass! Generate and Bake a Field Mesh Using a Compute Shader ✔️ 2020.3 | Game Dev Tutorial

✔️ Works in 2020.2 ➕ 2020.3

Grass is one of those things most games need, but is really difficult to get right! In this video, I return to grass to try to conquer it! I lay the groundwork here, using a compute shader to generate blades of grass in a mesh, while randomizing and animating it in a graphics shader. I also try out level of detail to speed up rendering.

👋 Subscribe for weekly game development videos!
► https://www.youtube.com/c/nedmakesgam...

👑 Join my Patreon for extra influence over topics, early access to videos, and downloadable project files!
►   / nedmakesgames  

🔗 Check out my website for a searchable list of tutorials!
► https://nedmakesgames.github.io

🔴 Twitch ►   / nedmakesgames  
🐦 Twitter ►   / nedmakesgames  
🎮 Discord ► https://discordapp.com/invite/ubxSVBK
📸 Instagram ►   / nedmakesgames  
👽 Reddit ►   / nedmakesgames  
🎶 TikTok ►   / nedmakesgames  
☕ Ko-fi ► https://ko-fi.com/nedmakesgames

🎬 Previous videos
► Generating meshes with a compute shader:    • Generate a Mesh Asset Using Compute S...  
► Introduction to level of detail:    • Level of Detail in Unity Using LODGro...  
► Introduction to vertex/fragment/geometry shaders:    • Geometry Shaders Made Easy In Unity U...  
► Non-baked blade grass:    • Grass Fields in Unity URP! Generate B...  

✨ Follow up videos
► Adding shadow casting:    • Adding Shadow Casting to Grass Baked ...  
► Baked layer grass:    • Stylized Grass in Unity URP! Compute ...  

💬 Video transcript
► https://docs.google.com/document/d/15...

📜 Required scripts
► Pyramid baker scripts: https://gist.github.com/NedMakesGames...
► NMGBladeGrassComputeHelpers.hlsl: https://gist.github.com/NedMakesGames...
► NMGBladeGrassGraphicsHelpers.hlsl: https://gist.github.com/NedMakesGames...

📚 Reference scripts
► Single triangle: https://gist.github.com/NedMakesGames...
► Blade variety: https://gist.github.com/NedMakesGames...
► Curvature: https://gist.github.com/NedMakesGames...
► Reduced patterns: https://gist.github.com/NedMakesGames...
► Final: https://gist.github.com/NedMakesGames...

⏲️ Timestamps:
0:00 Intro
0:45 Project set up
1:48 Single triangle blades
7:04 The graphics shader
9:29 Blade variety
12:17 Curvature
15:40 Reducing patterns
17:39 Wind
19:38 Level of detail
20:14 Wrap up and credits

🎖️ Credits and references:
• Unity Technologies: GPU Instancing - https://docs.unity3d.com/Manual/GPUIn...
• VPellen: calculate a plane perpendicular to a normal - https://stackoverflow.com/questions/5...
• James "Nihilore" Opie: music "This Is Enough" -    • Nihilore - This is Enough  
• freepik: Wrinkled paper texture - https://www.freepik.com/premium-vecto...
• Keijiro Takahashi: AngleAxis3x3 - https://gist.github.com/keijiro/ee439...
• Erik Roystan Ross: Grass Shader - https://roystan.net/articles/grass-sh...
• Ronja Böhringer: White Noise - https://www.ronja-tutorials.com/post/...

#GameDev #IndieDev #Unity

Комментарии

Информация по комментариям в разработке