Bagikan melalui


ModelMeshPart.Effect Property

Gets or sets the material Effect for this mesh part.

Namespace: Microsoft.Xna.Framework.Graphics
Assembly: Microsoft.Xna.Framework (in microsoft.xna.framework.dll)

Syntax

public Effect Effect { get; set; }

Property Value

The material effect for this mesh part.

Remarks

ModelMesh.Effects is a shortcut for iterating over the MeshParts property of the ModelMesh and looking up the ModelMeshPart.Effect property of each ModelMeshPart.

ModelMesh.Effects is a collection of all the Effect properties of the for the MeshParts of this ModelMesh. Each ModelMeshPart has a single Effect which is a reference to one of the Effects of the parent ModelMesh property. By updating all the effects of the ModelMesh all of the effects of each ModelMeshPart are updated as well.

See Also

Reference

ModelMeshPart Class
ModelMeshPart Members
Microsoft.Xna.Framework.Graphics Namespace

Platforms

Xbox 360, Windows XP SP2, Windows Vista