Class LineBatch
The line batch 3D.
Implements
Inherited Members
Namespace: Evergine.Framework.Graphics
Assembly: Evergine.Framework.dll
Syntax
public abstract class LineBatch : RenderObjectInfo, IDisposable
  Constructors
LineBatch(GraphicsContext, RenderLayerDescription, DrawableType)
Initializes a new instance of the LineBatch class.
Declaration
public LineBatch(GraphicsContext graphicsContext, RenderLayerDescription renderLayerDescription, DrawableType drawableType)
  Parameters
| Type | Name | Description | 
|---|---|---|
| GraphicsContext | graphicsContext | The graphics context.  | 
      
| RenderLayerDescription | renderLayerDescription | The render layer.  | 
      
| DrawableType | drawableType | The drawable type of the lines.  | 
      
Fields
LineBatchOrderBias
The line batch order bias.
Declaration
public int LineBatchOrderBias
  Field Value
| Type | Description | 
|---|---|
| int | 
ResetAfterRender
Indicates if the linebatch will reset after the lines are rendered.
Declaration
public bool ResetAfterRender
  Field Value
| Type | Description | 
|---|---|
| bool | 
beginDataBtr
Begin 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
Current data pointer.
Declaration
protected VertexPositionColor* currentDataPtr
  Field Value
| Type | Description | 
|---|---|
| VertexPositionColor* | 
vertexCount
The vertex count.
Declaration
protected uint vertexCount
  Field Value
| Type | Description | 
|---|---|
| uint | 
Properties
DrawableType
Gets the drawable type.
Declaration
public override DrawableType DrawableType { get; }
  Property Value
| Type | Description | 
|---|---|
| DrawableType | 
Overrides
InputLayoutID
Gets the InputLayout 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 be rendered.
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)
Prepare 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()
Destroy 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 the line.
Declaration
public void DrawLine(Vector3 start, Vector3 end, Color color)
  Parameters
| Type | Name | Description | 
|---|---|---|
| Vector3 | start | The start.  | 
      
| Vector3 | end | The end.  | 
      
| Color | color | The color.  | 
      
DrawLine(ref Vector3, ref Vector3, ref Color)
Draws the line.
Declaration
public void DrawLine(ref Vector3 startPoint, ref Vector3 endPoint, ref Color color)
  Parameters
| Type | Name | Description | 
|---|---|---|
| Vector3 | startPoint | The start point.  | 
      
| Vector3 | endPoint | The end point.  | 
      
| Color | color | The color.  | 
      
RefreshBoundingBox()
Refresh the bounding box.
Declaration
protected override void RefreshBoundingBox()
  Overrides
RefreshBufferCapacity(uint)
Refresh the buffer with the specified capacity.
Declaration
protected void RefreshBufferCapacity(uint newCapacity)
  Parameters
| Type | Name | Description | 
|---|---|---|
| uint | newCapacity | The buffer capacity.  | 
      
Reset()
Reset the LineBatch, allowing to start adding lines.
Declaration
public void Reset()