Table of Contents

Class SimpleExtensions

Namespace
Stride.Extensions
Assembly
Stride.Rendering.dll
public static class SimpleExtensions
Inheritance
SimpleExtensions

Methods

IsSimple(IndexBufferBinding)

Determines whether the specified index buffer binding data is simple. A index buffer binding data is simple if:

  • Offset is 0.
  • Is32Bit is true.
  • Buffer.Content.Length is equal to sizeof(int) * Count.
public static bool IsSimple(this IndexBufferBinding indexBufferBindingData)

Parameters

indexBufferBindingData IndexBufferBinding

The index buffer binding data.

Returns

bool

IsSimple(VertexBufferBinding)

Determines whether the specified vertex buffer binding data is simple. A vertex buffer binding data is simple if:

  • Offset is 0.
  • Stride is 0 (automatic), or equals to Declaration.VertexStride.
  • Buffer.Content.Length is equal to Declaration.VertexStride * Count
public static bool IsSimple(this VertexBufferBinding vertexBufferBindingData)

Parameters

vertexBufferBindingData VertexBufferBinding

The vertex buffer binding data.

Returns

bool

IsSimple(MeshDraw)

Determines whether the specified mesh draw data is simple. A MeshDraw is simple if:

  • It contains only one VertexBufferBinding, which must be simple.
  • It contains either no VertexBufferBinding, or a simple one.
  • StartLocation is 0.
  • DrawCount is IndexBuffer.Count if there is an index buffer, otherwise VertexBuffers[0].Count.
public static bool IsSimple(this MeshDraw meshDrawData)

Parameters

meshDrawData MeshDraw

The mesh draw data.

Returns

bool