Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


ShaderVariant(Shader, PassType, params string[])

Creates a ShaderVariant structure.
Read time 1 minuteLast updated 13 days ago

Definition

  • Type: Constructor
  • Namespace: UnityEngine
  • Assembly: UnityEngine.CoreModule

ShaderVariant(Shader, PassType, string[])

public ShaderVariant(Shader shader, PassType passType, params string[] keywords)

Parameters

shader


passType


keywords

Remarks

Note that this will throw an ArgumentException if shader is null, pass type does not exist or variant with the passed keywords is not found.
Additional Resources: ShaderVariantCollection.Add.