Class IndexBuffer
public class IndexBuffer : GraphicsResource, IDisposable
- Inheritance
-
IndexBuffer
- Implements
- Derived
- Inherited Members
Constructors
IndexBuffer(GraphicsDevice, IndexElementSize, int, BufferUsage)
public IndexBuffer(GraphicsDevice graphicsDevice, IndexElementSize indexElementSize, int indexCount, BufferUsage bufferUsage)
Parameters
graphicsDevice
GraphicsDeviceindexElementSize
IndexElementSizeindexCount
intbufferUsage
BufferUsage
IndexBuffer(GraphicsDevice, IndexElementSize, int, BufferUsage, bool)
protected IndexBuffer(GraphicsDevice graphicsDevice, IndexElementSize indexElementSize, int indexCount, BufferUsage usage, bool dynamic)
Parameters
graphicsDevice
GraphicsDeviceindexElementSize
IndexElementSizeindexCount
intusage
BufferUsagedynamic
bool
IndexBuffer(GraphicsDevice, Type, int, BufferUsage)
public IndexBuffer(GraphicsDevice graphicsDevice, Type indexType, int indexCount, BufferUsage usage)
Parameters
graphicsDevice
GraphicsDeviceindexType
TypeindexCount
intusage
BufferUsage
IndexBuffer(GraphicsDevice, Type, int, BufferUsage, bool)
protected IndexBuffer(GraphicsDevice graphicsDevice, Type indexType, int indexCount, BufferUsage usage, bool dynamic)
Parameters
graphicsDevice
GraphicsDeviceindexType
TypeindexCount
intusage
BufferUsagedynamic
bool
Properties
BufferUsage
public BufferUsage BufferUsage { get; }
Property Value
IndexCount
public int IndexCount { get; }
Property Value
IndexElementSize
public IndexElementSize IndexElementSize { get; }
Property Value
Methods
Dispose(bool)
The method that derived classes should override to implement disposing of managed and native resources.
protected override void Dispose(bool disposing)
Parameters
disposing
boolTrue if managed objects should be disposed.
Remarks
Native resources should always be released regardless of the value of the disposing parameter.
GetData<T>(int, T[], int, int)
public void GetData<T>(int offsetInBytes, T[] data, int startIndex, int elementCount) where T : struct
Parameters
Type Parameters
T
GetData<T>(T[])
public void GetData<T>(T[] data) where T : struct
Parameters
data
T[]
Type Parameters
T
GetData<T>(T[], int, int)
public void GetData<T>(T[] data, int startIndex, int elementCount) where T : struct
Parameters
Type Parameters
T
GraphicsDeviceResetting()
The GraphicsDevice is resetting, so GPU resources must be recreated.
protected override void GraphicsDeviceResetting()
SetDataInternal<T>(int, T[], int, int, SetDataOptions)
protected void SetDataInternal<T>(int offsetInBytes, T[] data, int startIndex, int elementCount, SetDataOptions options) where T : struct
Parameters
offsetInBytes
intdata
T[]startIndex
intelementCount
intoptions
SetDataOptions
Type Parameters
T
SetData<T>(int, T[], int, int)
public void SetData<T>(int offsetInBytes, T[] data, int startIndex, int elementCount) where T : struct
Parameters
Type Parameters
T
SetData<T>(T[])
public void SetData<T>(T[] data) where T : struct
Parameters
data
T[]
Type Parameters
T
SetData<T>(T[], int, int)
public void SetData<T>(T[] data, int startIndex, int elementCount) where T : struct
Parameters
Type Parameters
T