Version: 2018.3 (switch to 2019.1)
LanguageEnglish
  • C#

ShaderUtil

class in UnityEditor

/

Implemented in:UnityEditor

Suggest a change

Success!

Thank you for helping us improve the quality of Unity Documentation. Although we cannot accept all submissions, we do read each suggested change from our users and will make updates where applicable.

Close

Submission failed

For some reason your suggested change could not be submitted. Please <a>try again</a> in a few minutes. And thank you for taking the time to help us improve the quality of Unity Documentation.

Close

Cancel

Description

Utility functions to assist with working with shaders from the editor.

Static Properties

hardwareSupportsRectRenderTextureDoes the current hardware support render textues.

Static Methods

ClearShaderErrorsClear compile time errors for the given shader.
GetAllShaderInfoReturns an array of ShaderInfo of all available shaders. That includes built-in shaders.
GetPropertyCountGet the number of properties in Shader s.
GetPropertyDescriptionGet the description of the shader propery at index propertyIdx of Shader s.
GetPropertyNameGet the name of the shader propery at index propertyIdx of Shader s.
GetPropertyTypeGet the ShaderProperyType of the shader propery at index propertyIdx of Shader s.
GetRangeLimitsGet Limits for a range property at index propertyIdx of Shader s.
GetShaderDataGet the shader data for a specific shader.
GetTexDimGets texture dimension of a shader property.
IsShaderPropertyHiddenIs the shader propery at index propertyIdx of Shader s hidden?
IsShaderPropertyNonModifiableTexurePropertyIs the shader propery at index propertyIdx of Shader s a NonModifiableTextureProperty?
RegisterShaderRegister a user created shader.

Did you find this page useful? Please give it a rating: