SpeedTree8Input.hlsl 1.2 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061
  1. #ifndef UNIVERSAL_SPEEDTREE8_INPUT_INCLUDED
  2. #define UNIVERSAL_SPEEDTREE8_INPUT_INCLUDED
  3. #ifdef EFFECT_BUMP
  4. #define _NORMALMAP
  5. #endif
  6. #define _ALPHATEST_ON
  7. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/Core.hlsl"
  8. #include "Packages/com.unity.render-pipelines.universal/ShaderLibrary/SurfaceInput.hlsl"
  9. #if defined(ENABLE_WIND) && !defined(_WINDQUALITY_NONE)
  10. #define SPEEDTREE_Y_UP
  11. #include "SpeedTreeWind.cginc"
  12. float _WindEnabled;
  13. UNITY_INSTANCING_BUFFER_START(STWind)
  14. UNITY_DEFINE_INSTANCED_PROP(float, _GlobalWindTime)
  15. UNITY_INSTANCING_BUFFER_END(STWind)
  16. #endif
  17. half4 _Color;
  18. int _TwoSided;
  19. #ifdef SCENESELECTIONPASS
  20. int _ObjectId;
  21. int _PassValue;
  22. #endif
  23. TEXTURE2D(_MainTex);
  24. SAMPLER(sampler_MainTex);
  25. #ifdef EFFECT_EXTRA_TEX
  26. sampler2D _ExtraTex;
  27. #else
  28. half _Glossiness;
  29. half _Metallic;
  30. #endif
  31. #ifdef EFFECT_HUE_VARIATION
  32. half4 _HueVariationColor;
  33. #endif
  34. #ifdef EFFECT_BILLBOARD
  35. half _BillboardShadowFade;
  36. #endif
  37. #ifdef EFFECT_SUBSURFACE
  38. sampler2D _SubsurfaceTex;
  39. half4 _SubsurfaceColor;
  40. half _SubsurfaceIndirect;
  41. #endif
  42. float3 _LightDirection;
  43. #define GEOM_TYPE_BRANCH 0
  44. #define GEOM_TYPE_FROND 1
  45. #define GEOM_TYPE_LEAF 2
  46. #define GEOM_TYPE_FACINGLEAF 3
  47. #endif