Arbor 3: FSM & BT Graph Editor 3.7.5

Public Member Functions | Static Public Member Functions | List of all members
RendererPropertyBlock Class Reference

A wrapper class for the MaterialPropertyBlock assigned to the Renderer. More...

## Public Member Functions
void | Update ()
| Update MaterialPropertyBlock from Renderer. More...
void | Apply ()
| Apply MaterialPropertyBlock to Renderer. More...
void | Clear ()
| Clear material property values. More...
bool | HasProperty (int nameID)
| Returns whether the PropertyBlock has a property value. More...
bool | HasProperty (string name)
| Returns whether the PropertyBlock has a property value. More...
float | GetFloat (int nameID)
| Get the float value. More...
float | GetFloat (string name)
| Get the float value. More...
void | SetFloat (int nameID, float value)
| Set the float value. More...
void | SetFloat (string name, float value)
| Set the float value. More...
Color | GetColor (int nameID)
| Get the Color value. More...
Color | GetColor (string name)
| Get the Color value. More...
void | SetColor (int nameID, Color value)
| Set the Color value. More...
void | SetColor (string name, Color value)
| Set the Color value. More...
Matrix4x4 | GetMatrix (int nameID)
| Get the Matrix4x4 value. More...
Matrix4x4 | GetMatrix (string name)
| Get the Matrix4x4 value. More...
void | SetMatrix (int nameID, Matrix4x4 value)
| Set the Matrix4x4 value. More...
void | SetMatrix (string name, Matrix4x4 value)
| Set the Matrix4x4 value. More...
Texture | GetTexture (int nameID)
| Get the Texture value. More...
Texture | GetTexture (string name)
| Get the Texture value. More...
void | SetTexture (int nameID, Texture value)
| Set the Texture value. More...
void | SetTexture (string name, Texture value)
| Set the Texture value. More...
Vector4 | GetVector (int nameID)
| Get the Vector4 value. More...
Vector4 | GetVector (string name)
| Get the Vector4 value. More...
void | SetVector (int nameID, Vector4 value)
| Set the Vector4 value. More...
void | SetVector (string name, Vector4 value)
| Set the Vector4 value. More...

## Static Public Member Functions
static RendererPropertyBlock | Get (Renderer renderer)
| Get the RendererPropertyBlock assigned to the Renderer. More...

## Detailed Description

A wrapper class for the MaterialPropertyBlock assigned to the Renderer.

## Member Function Documentation

## ◆ Apply()

void Apply | ( |  | ) |

Apply MaterialPropertyBlock to Renderer.

## ◆ Clear()

void Clear | ( |  | ) |

Clear material property values.

## ◆ Get()

static RendererPropertyBlock Get | ( | Renderer | renderer | ) |
| static

Get the RendererPropertyBlock assigned to the Renderer.

Parameters

  renderer | Renderer

Returns
  RendererPropertyBlock

## ◆ GetColor() [1/2]

Color GetColor | ( | int | nameID | ) |

Get the Color value.

Parameters

  nameID | Property name ID

Returns
  Color value

## ◆ GetColor() [2/2]

Color GetColor | ( | string | name | ) |

Get the Color value.

Parameters

  name | Property name

Returns
  Color value

## ◆ GetFloat() [1/2]

float GetFloat | ( | int | nameID | ) |

Get the float value.

Parameters

  nameID | Property name ID

Returns
  float value

## ◆ GetFloat() [2/2]

float GetFloat | ( | string | name | ) |

Get the float value.

Parameters

  name | Property name

Returns
  float value

## ◆ GetMatrix() [1/2]

Matrix4x4 GetMatrix | ( | int | nameID | ) |

Get the Matrix4x4 value.

Parameters

  nameID | Property name ID

Returns
  Matrix4x4 value

## ◆ GetMatrix() [2/2]

Matrix4x4 GetMatrix | ( | string | name | ) |

Get the Matrix4x4 value.

Parameters

  name | Property name

Returns
  Matrix4x4 value

## ◆ GetTexture() [1/2]

Texture GetTexture | ( | int | nameID | ) |

Get the Texture value.

Parameters

  nameID | Property name ID

Returns
  Texture value

## ◆ GetTexture() [2/2]

Texture GetTexture | ( | string | name | ) |

Get the Texture value.

Parameters

  name | Property name

Returns
  Texture value

## ◆ GetVector() [1/2]

Vector4 GetVector | ( | int | nameID | ) |

Get the Vector4 value.

Parameters

  nameID | Property name ID

Returns
  Vector4 value

## ◆ GetVector() [2/2]

Vector4 GetVector | ( | string | name | ) |

Get the Vector4 value.

Parameters

  name | Property name

Returns
  Vector4 value

## ◆ HasProperty() [1/2]

bool HasProperty | ( | int | nameID | ) |

Returns whether the PropertyBlock has a property value.

Parameters

  nameID | Property name ID

Returns
  Returns true if the property value is set.

If you change the MaterialPropertyBlock directly, it will not be reflected. Be sure to use the Set method of RendererPropertyBlock.

## ◆ HasProperty() [2/2]

bool HasProperty | ( | string | name | ) |

Returns whether the PropertyBlock has a property value.

Parameters

  name | Property name

Returns
  Returns true if the property value is set.

If you change the MaterialPropertyBlock directly, it will not be reflected. Be sure to use the Set method of RendererPropertyBlock.

## ◆ SetColor() [1/2]

void SetColor | ( | int | nameID,
|  | Color | value
| ) |  |

Set the Color value.

Parameters

  nameID | Property name ID
  value | Value

## ◆ SetColor() [2/2]

void SetColor | ( | string | name,
|  | Color | value
| ) |  |

Set the Color value.

Parameters

  name | Property name
  value | Value

## ◆ SetFloat() [1/2]

void SetFloat | ( | int | nameID,
|  | float | value
| ) |  |

Set the float value.

Parameters

  nameID | Property name ID
  value | Value

## ◆ SetFloat() [2/2]

void SetFloat | ( | string | name,
|  | float | value
| ) |  |

Set the float value.

Parameters

  name | Property name
  value | Value

## ◆ SetMatrix() [1/2]

void SetMatrix | ( | int | nameID,
|  | Matrix4x4 | value
| ) |  |

Set the Matrix4x4 value.

Parameters

  nameID | Property name ID
  value | Value

## ◆ SetMatrix() [2/2]

void SetMatrix | ( | string | name,
|  | Matrix4x4 | value
| ) |  |

Set the Matrix4x4 value.

Parameters

  name | Property name
  value | Value

## ◆ SetTexture() [1/2]

void SetTexture | ( | int | nameID,
|  | Texture | value
| ) |  |

Set the Texture value.

Parameters

  nameID | Property name ID
  value | Value

## ◆ SetTexture() [2/2]

void SetTexture | ( | string | name,
|  | Texture | value
| ) |  |

Set the Texture value.

Parameters

  name | Property name
  value | Value

## ◆ SetVector() [1/2]

void SetVector | ( | int | nameID,
|  | Vector4 | value
| ) |  |

Set the Vector4 value.

Parameters

  nameID | Property name ID
  value | Value

## ◆ SetVector() [2/2]

void SetVector | ( | string | name,
|  | Vector4 | value
| ) |  |

Set the Vector4 value.

Parameters

  name | Property name
  value | Value

## ◆ Update()

void Update | ( |  | ) |

Update MaterialPropertyBlock from Renderer.