ドキュメント

Unity Engine

Download Unity

Unity Engine

ApplyMaterialPropertyDrawers

Applies the initial values of custom material property drawers to a single material.
読み終わるまでの所要時間 1 分最終更新 1ヶ月前

Definition

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

ApplyMaterialPropertyDrawers(Material)

Applies the initial values of custom material property drawers to a single material.
public static void ApplyMaterialPropertyDrawers(Material material)

Parameters

material

The material to apply the drawer values to.

Remarks

This method calls MaterialPropertyDrawer.Apply for every property of the shader that has a custom drawer, so each material starts with the values that its custom drawers expect.

ApplyMaterialPropertyDrawers(Object[])

Applies the initial values of custom material property drawers to a set of materials.
public static void ApplyMaterialPropertyDrawers(Object[] targets)

Parameters

targets

The materials to apply the drawer values to.

Remarks

This method calls MaterialPropertyDrawer.Apply for every property of the shader that has a custom drawer, so each material starts with the values that its custom drawers expect. If
targets
is null or empty, the method does nothing.