Click or drag to resize
Ab4d.SharpEngine logo

PrimitiveIdMaterial Class

PrimitiveIdMaterial renders the primitives of the mesh (triangles, lines or positions) so that each primitive is rendered with a color that is calculated from the primitive id (for example triangle index). The AddedColor can be used to add a color to the calculated primitive id color. This can be used when other objects are rendered to the same ID bitmap to distinguish the object with this material from other objects.
Inheritance Hierarchy
SystemObject
  Ab4d.SharpEngine.CoreComponentBase
    Ab4d.SharpEngine.CoreInitializedSceneComponent
      Ab4d.SharpEngine.MaterialsMaterial
        Ab4d.SharpEngine.MaterialsPrimitiveIdMaterial

Namespace: Ab4d.SharpEngine.Materials
Assembly: Ab4d.SharpEngine (in Ab4d.SharpEngine.dll) Version: 3.2.9386+3a404a3e1ebfa4efd231da7fe6f10dfb23b95dc4
Syntax
C#
public class PrimitiveIdMaterial : Material, 
	ITwoSidedMaterial

The PrimitiveIdMaterial type exposes the following members.

Constructors
 NameDescription
Public methodPrimitiveIdMaterial(String) PrimitiveIdMaterial constructor.
Public methodPrimitiveIdMaterial(Color4, String) PrimitiveIdMaterial constructor with Color4 that is added to the color that is calculated from the primitive id
Top
Properties
 NameDescription
Public propertyAddedColor Gets or sets a Color4 that is added to the color that is calculated from the primitive id. Default value is (0, 0, 0, 0). It can be used when other objects are rendered to the same ID bitmap to distinguish the object with this material from other objects.
Public propertyIsTwoSided Gets a Boolean that specifies if the material should be rendered on both front and back side.
Top
Methods
 NameDescription
Protected methodCreateClone
(Overrides MaterialCreateClone)
Protected methodOnInitializeSceneResources Initializes resources with the specified Scene and GpuDevice. This method can be overriden and is called from InitializeSceneResources(Scene) method.
(Overrides MaterialOnInitializeSceneResources(Scene, VulkanDevice))
Top
Remarks

[Missing <remarks> documentation for "T:Ab4d.SharpEngine.Materials.PrimitiveIdMaterial"]

See Also