Interface IGLPrimitive
- Namespace
- SearchAThing.OpenGL.Core
- Assembly
- netcore-opengl-core.dll
A primitive such a GLPoint, GLLine or GLTriangle can be
added to a figure through its add method.
A primitive can consists of 1, 2 or 3 GLVertex that will be registered into
GLVertexManager when the primitive added to the figure and figure to the model
through AddFigure(IEnumerable<GLFigureBase>).
[JsonObject(MemberSerialization.OptIn)]
public interface IGLPrimitive : IGLVertexManagerObject, INotifyPropertyChanged
- Inherited Members
- Extension Methods
Properties
LBBox
(cached) Bounding box of the primitive [local].
BBox LBBox { get; }
Property Value
Order
Primitive order appareance ( Default: 0 ).
Higher order primitives appears front to lower order primitives of the same figure.
From the opengl point of view figures with higher order ( front ) are drawn firstly then lower order ( back ).
Changing this property emits FigureInvalidated event.
[JsonProperty]
int Order { get; set; }
Property Value
ParentFigure
Reference to the parent figure.
IGLFigure? ParentFigure { get; }
Property Value
PrimitiveType
Enum that describe which type underlying to the instance.
GLPrimitiveType PrimitiveType { get; }
Property Value
Selected
States if primitive is actually selected.
It true the primitive is listed in model selected primitives SelectedPrimitives.
bool Selected { get; }
Property Value
Vertexes
Enumerate primitive gl vertexes.
IEnumerable<GLVertex> Vertexes { get; }
Property Value
Methods
SimpleCmd(bool)
Retrieve e simple cmd representation of this primtiive.
Its a textual representation of primitive information useful to regen in a separate tool.
string SimpleCmd(bool includeHeader = true)
Parameters
includeHeader
boolIf true header will prepended to form a complete command.