GetSharedMaterials(List<Material>)
Returns all the shared materials of this object.
Read time 1 minuteLast updated 4 days ago
Definition
- Type: Method
- Namespace: UnityEngine
- Assembly: UnityEngine.CoreModule
public void GetSharedMaterials(List<Material> m)
Parameters
A list of materials to populate.
Remarks
Use this method instead of Renderer.sharedMaterials if you control the life cycle of the list passed in and you want to avoid allocating a new array with every access.