Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


SetGlobalFloatArray

Sets a global float array property for all shaders.
Read time 2 minutesLast updated 5 days ago

Definition

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

SetGlobalFloatArray(string, List<float>)

Sets a global float array property for all shaders.
public static void SetGlobalFloatArray(string name, List<float> values)

Parameters

name

The name of the property.

Remarks

Global properties are used if a shader needs them but the material does not have them defined (for example, if the shader does not expose them in Properties block).
Additional Resources: Shader.SetGlobalFloat.

SetGlobalFloatArray(int, List<float>)

Sets a global float array property for all shaders.
public static void SetGlobalFloatArray(int nameID, List<float> values)

Parameters

nameID

The name ID of the property retrieved by Shader.PropertyToID.

Remarks

Global properties are used if a shader needs them but the material does not have them defined (for example, if the shader does not expose them in Properties block).
Additional Resources: Shader.SetGlobalFloat.

SetGlobalFloatArray(string, float[])

Sets a global float array property for all shaders.
public static void SetGlobalFloatArray(string name, float[] values)

Parameters

name

The name of the property.

values

Remarks

Global properties are used if a shader needs them but the material does not have them defined (for example, if the shader does not expose them in Properties block).
Additional Resources: Shader.SetGlobalFloat.

SetGlobalFloatArray(int, float[])

Sets a global float array property for all shaders.
public static void SetGlobalFloatArray(int nameID, float[] values)

Parameters

nameID

The name ID of the property retrieved by Shader.PropertyToID.

values

Remarks

Global properties are used if a shader needs them but the material does not have them defined (for example, if the shader does not expose them in Properties block).
Additional Resources: Shader.SetGlobalFloat.