Version: Unity 6.3 Beta (6000.3)
Language : English
Shader compilation
Introduction to shader variants

Reducing shader variants

Strategies for reducing shaderA program that runs on the GPU. More info
See in Glossary
variants to optimize builds and performance.

Page Description
Introduction to shader variants Understand how Unity compiles shaders into multiple shader variants.
Check how many shader variants you have Use the shader logging and profiling tools in Unity.
Reduce shader variants Prevent Unity compiling shader variants.
Reduce shader variants in custom shader code Use the #pragma directive or preprocessor macros to limit shader variants in custom shaders.
Default keyword sets Resources for the default shader keywords in Unity, and creating sets of built-in keywords.

Additional resources

Shader compilation
Introduction to shader variants
Copyright © 2023 Unity Technologies
优美缔软件(上海)有限公司 版权所有
"Unity"、Unity 徽标及其他 Unity 商标是 Unity Technologies 或其附属机构在美国及其他地区的商标或注册商标。其他名称或品牌是其各自所有者的商标。
公安部备案号:
31010902002961