Unity3d emission 的使用

1、首先enable 关键字(shader keyword

**.material.EnableKeyword("_EMISSION");
uity中常用的关键字有:

_NORMALMAP Normal Mapping
_ALPHATEST_ON “Cut out” Transparency Rendering Mode
_ALPHABLEND_ON “Fade” Transparency Rendering Mode
_ALPHAPREMULTIPLY_ON “Transparent” Transparency Rendering Mode
_EMISSION Emission Colour or Emission Mapping
_PARALLAXMAP Height Mapping
_DETAIL_MULX2 Secondary “Detail” Maps (Albedo & Normal Map)
_METALLICGLOSSMAP Metallic/Smoothness Mapping in Metallic Workflow
_SPECGLOSSMAP Specular/Smoothness Mapping in Specular Workflow
参考:https://docs.unity3d.com/Manual/MaterialsAccessingViaScript.html

2、使用shader中的属性

常用的属性有:

  1. _Color
  2. _MainTex
  3. _Cutoff
  4. _Glossiness
  5. _Metallic
  6. _MetallicGlossMap
  7. _BumpScale
  8. _BumpMap
  9. _Parallax
  10. _ParallaxMap
  11. _OcclusionStrength
  12. _OcclusionMap
  13. _EmissionColor
  14. _EmissionMap
  15. _DetailMask
  16. _DetailAlbedoMap
  17. _DetailNormalMapScale
  18. _DetailNormalMap
  19. _UVSec
  20. _EmissionScaleUI
  21. _EmissionColorUI
  22. _Mode
  23. _SrcBlend
  24. _DstBlend
  25. _ZWrite

你可能感兴趣的:(随笔,unity3d)