Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


SetGlobalBuffer

Add a "set global shader buffer property" command.
Read time 1 minuteLast updated 5 days ago

Definition

SetGlobalBuffer(string, ComputeBuffer)

Add a "set global shader buffer property" command.
public void SetGlobalBuffer(string name, ComputeBuffer value)

Parameters

name

The name of the property.

The buffer to set.

Remarks

When the command buffer will be executed, a global shader buffer property will be set at this point. The effect is as if Shader.SetGlobalBuffer was called.

SetGlobalBuffer(int, ComputeBuffer)

Add a "set global shader buffer property" command.
public void SetGlobalBuffer(int nameID, ComputeBuffer value)

Parameters

nameID

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

The buffer to set.

Remarks

When the command buffer will be executed, a global shader buffer property will be set at this point. The effect is as if Shader.SetGlobalBuffer was called.

SetGlobalBuffer(string, GraphicsBuffer)

Add a "set global shader buffer property" command.
public void SetGlobalBuffer(string name, GraphicsBuffer value)

Parameters

name

The name of the property.

The buffer to set.

Remarks

When the command buffer will be executed, a global shader buffer property will be set at this point. The effect is as if Shader.SetGlobalBuffer was called.

SetGlobalBuffer(int, GraphicsBuffer)

Add a "set global shader buffer property" command.
public void SetGlobalBuffer(int nameID, GraphicsBuffer value)

Parameters

nameID

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

The buffer to set.

Remarks

When the command buffer will be executed, a global shader buffer property will be set at this point. The effect is as if Shader.SetGlobalBuffer was called.