Instance Property

firstMaterial

The first material attached to the geometry.

Declaration

@property(nonatomic, retain) SCNMaterial *firstMaterial;

Discussion

Calling this convenience method is equivalent to retrieving the first object from the geometry’s materials array. This property’s value is nil if the geometry has no attached materials.

See Also

Managing a Geometry’s Materials

materials

An array of SCNMaterial objects that determine the geometry’s appearance when rendered.

- materialWithName:

Returns the first material attached to the geometry with the specified name.

- insertMaterial:atIndex:

Attaches a material to the geometry at the specified index.

- removeMaterialAtIndex:

Removes a material attached to the geometry.

- replaceMaterialAtIndex:withMaterial:

Replaces a material attached to the geometry with another.