A collection of ShaderKeyword that represents a specific platform variant.
A PlatformKeywordKeywordSet
represents a part of one shader variant, a unique combination of keywords you can use to enable or disable functionality within a shader.PlatformKeywordSet
mirrors ShaderKeywordSet's functionality, but does not contain user-defined keywords.
Instead, this struct provides information on the rendering capabilities and rendering API of the target platform.
For example, framebuffer fetch (represented via the keyword BuiltinShaderDefine.UNITY_FRAMEBUFFER_FETCH_AVAILABLE) may be available when compiling a shader for BuildTarget.Android, but not for BuildTarget.StandaloneWindows.
For more information on shader variants and keywords, refer to Shader variants and keywords and Changing how shaders work via branching and keywords.
Additional resources: ShaderKeyword, Shader.EnableKeyword, Shader.EnableKeyword.