Search icon CANCEL
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Game Development with Blender and Godot

You're reading from   Game Development with Blender and Godot Leverage the combined power of Blender and Godot for building a point-and-click adventure game

Arrow left icon
Product type Paperback
Published in Sep 2022
Publisher Packt
ISBN-13 9781801816021
Length 330 pages
Edition 1st Edition
Languages
Tools
Arrow right icon
Author (1):
Arrow left icon
Kumsal Obuz Kumsal Obuz
Author Profile Icon Kumsal Obuz
Kumsal Obuz
Arrow right icon
View More author details
Toc

Table of Contents (20) Chapters Close

Preface 1. Part 1: 3D Assets with Blender
2. Chapter 1: Creating Low-Poly Models FREE CHAPTER 3. Chapter 2: Building Materials and Shaders 4. Chapter 3: Adding and Creating Textures 5. Chapter 4: Adjusting Cameras and Lights 6. Chapter 5: Setting Up Animation and Rigging 7. Part 2: Asset Management
8. Chapter 6: Exporting Blender Assets 9. Chapter 7: Importing Blender Assets into Godot 10. Chapter 8: Adding Sound Assets 11. Part 3: Clara’s Fortune – An Adventure Game
12. Chapter 9: Designing the Level 13. Chapter 10: Making Things Look Better with Lights and Shadows 14. Chapter 11: Creating the User Interface 15. Chapter 12: Interacting with the World through Camera and Character Controllers 16. Chapter 13: Finishing with Sound and Animation 17. Chapter 14: Conclusion 18. Index 19. Other Books You May Enjoy

Discovering shaders

Shaders were defined as two things at the beginning of this chapter: a piece of code and a user manual. Have you felt like you’ve been writing code so far? Most likely, no.

Nevertheless, behind that Material user interface, there is a code layer, which is the shader. For example, the default shader you’ve been using so far has hundreds of lines of code. The following is only a portion of the code that makes that shader:

metallic = saturate(metallic);
transmission = saturate(transmission);
float diffuse_weight = (1.0 - transmission) * (1.0 - 
  metallic);
transmission *= (1.0 - metallic);
float specular_weight = (1.0 - transmission);
clearcoat = max(clearcoat, 0.0);
transmission_roughness = 1.0 - (1.0 - roughness) * (1.0 -
  transmission_roughness);
specular = max(0.0, specular);

Luckily for you, you don’t have to write a single line of code. More importantly, Blender interprets the shader code so that it can offer...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at R$50/month. Cancel anytime