Class LineBatch
The 3D line batch.
Inherited Members
Namespace: Evergine.Framework.Graphics
Assembly: Evergine.Framework.dll
Syntax
public abstract class LineBatch : RenderObjectInfo
Constructors
LineBatch(GraphicsContext, RenderLayerDescription)
Initializes a new instance of the LineBatch class.
Declaration
public LineBatch(GraphicsContext graphicsContext, RenderLayerDescription renderLayerDescription)
Parameters
Type | Name | Description |
---|---|---|
GraphicsContext | graphicsContext | The graphics context. |
RenderLayerDescription | renderLayerDescription | The render layer description. |
Fields
LineBatchOrderBias
The line batch order bias.
Declaration
public int LineBatchOrderBias
Field Value
Type | Description |
---|---|
int |
ResetAfterRender
Indicates whether the linebatch will reset after the lines are rendered.
Declaration
public bool ResetAfterRender
Field Value
Type | Description |
---|---|
bool |
beginDataBtr
Beginning data pointer.
Declaration
protected VertexPositionColor* beginDataBtr
Field Value
Type | Description |
---|---|
VertexPositionColor* |
capacity
The vertex capacity.
Declaration
protected uint capacity
Field Value
Type | Description |
---|---|
uint |
currentDataPtr
Pointer to the current data.
Declaration
protected VertexPositionColor* currentDataPtr
Field Value
Type | Description |
---|---|
VertexPositionColor* |
vertexCount
The number of vertices.
Declaration
protected uint vertexCount
Field Value
Type | Description |
---|---|
uint |
Properties
InputLayoutID
Gets the Input Layout ID.
Declaration
public override uint InputLayoutID { get; }
Property Value
Type | Description |
---|---|
uint |
Overrides
InputLayouts
Gets the input layout.
Declaration
public override InputLayouts InputLayouts { get; }
Property Value
Type | Description |
---|---|
InputLayouts |
Overrides
IsReady
Gets a value indicating whether this instance is ready to render.
Declaration
public override bool IsReady { get; }
Property Value
Type | Description |
---|---|
bool |
Overrides
Material
Gets the material.
Declaration
public override Material Material { get; }
Property Value
Type | Description |
---|---|
Material |
Overrides
MaterialID
Gets the material ID.
Declaration
public override uint MaterialID { get; }
Property Value
Type | Description |
---|---|
uint |
Overrides
Mesh
Gets the LineBatch mesh.
Declaration
public Mesh Mesh { get; }
Property Value
Type | Description |
---|---|
Mesh |
OrderBias
Gets the order bias.
Declaration
public override int OrderBias { get; }
Property Value
Type | Description |
---|---|
int |
Overrides
PrimitiveTopology
Gets the primitive topology.
Declaration
public override PrimitiveTopology PrimitiveTopology { get; }
Property Value
Type | Description |
---|---|
PrimitiveTopology |
Overrides
RenderLayerDescription
Gets or sets the render layer description.
Declaration
public RenderLayerDescription RenderLayerDescription { get; set; }
Property Value
Type | Description |
---|---|
RenderLayerDescription |
RenderStateOrder
Gets the order of the render state.
Declaration
public override int RenderStateOrder { get; }
Property Value
Type | Description |
---|---|
int |
Overrides
SortMode
Gets the sorting mode.
Declaration
public override SortMode SortMode { get; }
Property Value
Type | Description |
---|---|
SortMode |
Overrides
Methods
Collect(DrawContext)
Prepares this object with the specified draw context.
Declaration
public override void Collect(DrawContext drawContext)
Parameters
Type | Name | Description |
---|---|---|
DrawContext | drawContext | The draw context. |
Overrides
Destroy()
Destroys all resources of this instance.
Declaration
protected override void Destroy()
Overrides
DrawLine(ref Line)
Draws the line.
Declaration
public void DrawLine(ref Line line)
Parameters
Type | Name | Description |
---|---|---|
Line | line | The line. |
DrawLine(Vector3, Vector3, Color)
Draws a line.
Declaration
public void DrawLine(Vector3 start, Vector3 end, Color color)
Parameters
Type | Name | Description |
---|---|---|
Vector3 | start | The starting point. |
Vector3 | end | The ending point. |
Color | color | The color. |
DrawLine(ref Vector3, ref Vector3, ref Color)
Draws a line.
Declaration
public void DrawLine(ref Vector3 startPoint, ref Vector3 endPoint, ref Color color)
Parameters
Type | Name | Description |
---|---|---|
Vector3 | startPoint | The starting point. |
Vector3 | endPoint | The ending point. |
Color | color | The color. |
RefreshBoundingBox()
Refreshes the bounding box.
Declaration
protected override void RefreshBoundingBox()
Overrides
RefreshBufferCapacity(uint)
Refreshes the buffer with the specified capacity.
Declaration
protected void RefreshBufferCapacity(uint newCapacity)
Parameters
Type | Name | Description |
---|---|---|
uint | newCapacity | The buffer capacity. |
Reset()
Resets the LineBatch, allowing users to start adding lines.
Declaration
public void Reset()