Click or drag to resize

ModelPrimitive Class

The model primitive loads and renders glTF 2.0 (.gltf, .glb), COLLADA (DAE) and AGI MDL (MDL) models.
Inheritance Hierarchy

Namespace:  AGI.Foundation.Graphics
Assembly:  AGI.Foundation.Graphics (in AGI.Foundation.Graphics.dll) Version: 24.2.419.0 (24.2.419.0)
Syntax
public sealed class ModelPrimitive : Primitive

The ModelPrimitive type exposes the following members.

Constructors
  NameDescription
Public methodModelPrimitive
Initializes a default model primitive.
Public methodModelPrimitive(String)
For convenience. Initializes a model primitive with the specified file path.
Public methodModelPrimitive(Uri)
Initializes a model primitive with the specified uri.
Public methodModelPrimitive(String, ModelUpAxis)
For convenience. Initializes a model primitive with the specified file path and up axis.
Public methodModelPrimitive(Uri, ModelUpAxis)
Initializes a model primitive with the specified uri and up axis.
Top
Properties
  NameDescription
Public propertyArticulations
Gets the model's articulations. Articulations identify geometry and contain transformations for manipulating that geometry.
Public propertyAutomaticallyComputeBoundingSphere
Gets or sets if the primitive's BoundingSphere is automatically computed.
(Inherited from Primitive.)
Public propertyBoundingSphere
Gets or sets the bounding sphere that encompasses the primitive. The center is defined in the primitive's ReferenceFrame.
(Inherited from Primitive.)
Public propertyColor
Gets or sets the primitive's color.
(Inherited from Primitive.)
Public propertyDisplay
Gets or sets if the primitive should be rendered. Both this and DisplayCondition must evaluate to true for the primitive to be rendered.
(Inherited from Primitive.)
Public propertyDisplayCondition
Gets or sets the display condition that determines if the primitive should be rendered. Both this and Display must evaluate to true for the primitive to be rendered.
(Inherited from Primitive.)
Public propertyOrientation
Gets or sets the model's orientation. The quaternion is a rotation from the model's local axes to the axes of the model's ReferenceFrame.
Public propertyPosition
Gets or sets the position of the model. The position is defined in the model's ReferenceFrame.
Public propertyReferenceFrame
Gets or sets the reference frame this primitive is defined and rendered in.
(Inherited from Primitive.)
Public propertyScale
Gets or sets the linear scale used to increase or decrease the size of the rendered model.
Public propertyTag
Gets or sets custom data associated with this primitive.
(Inherited from Primitive.)
Public propertyTranslucency
Gets or sets the primitive's translucency. The model primitive only supports a translucency of 0.
(Overrides PrimitiveTranslucency.)
Public propertyUri
Gets the URI of the file used to load the file.
Top
Methods
  NameDescription
Public methodDispose (Inherited from Primitive.)
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodLoad(String)
For convenience. Loads a glTF 2.0 (.gltf, .glb), COLLADA (DAE) or AGI MDL (MDL) model using a file path.
Public methodLoad(Uri)
Loads a glTF 2.0 (.gltf, .glb), COLLADA (DAE) or AGI MDL (MDL) model using the specified uri.
Public methodLoad(String, ModelUpAxis)
For convenience. Loads a glTF 2.0 (.gltf, .glb), COLLADA (DAE) or AGI MDL (MDL) model using a file path.
Public methodLoad(Uri, ModelUpAxis)
Loads a glTF 2.0 (.gltf, .glb), COLLADA (DAE) or AGI MDL (MDL) model using the specified uri and upAxis.
Public methodSetPositionCartographic
For convenience. Sets the Cartographic position of the model. Longitude and latitude are in radians, and altitude is in meters. This also sets Position.
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Top
See Also