Click or drag to resize

OrderedCompositePrimitiveAdd Method

Adds a primitive to the front of the composite. Primitives at the front are rendered on top of primitives at the bottom.

Namespace:  AGI.Foundation.Graphics
Assembly:  AGI.Foundation.Graphics (in AGI.Foundation.Graphics.dll) Version: 24.2.419.0 (24.2.419.0)
Syntax
public void Add(
	Primitive primitive
)

Parameters

primitive
Type: AGI.Foundation.GraphicsPrimitive
The primitive to add to the composite.
Exceptions
ExceptionCondition
ArgumentNullExceptionprimitive is null.
ArgumentExceptionprimitive doesn't have the same ReferenceFrame as the composite.
ArgumentExceptionprimitive already was already added to a composite or the primitive manager.
Remarks
Primitives are rendered in the order they are added, so the first primitive added to the composite is rendered on the bottom and the last primitive added is rendered on top. The order can be changed with calls such as BringToFront(Primitive) and SendToBack(Primitive).

The ordered composite primitive is intended to contain primitives rendered on the globe's surface. It is only recommonded to add the following primitives:

In particular, it is not intended for use with: ModelPrimitive, SolidPrimitive, or CompositePrimitive.

Regardless of order in the composite, all SurfaceMeshPrimitives are rendered before other primitives in the composite.

See Also