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
graphicsDeviceGraphicsDeviceindexElementSizeIndexElementSizeindexCountintbufferUsageBufferUsage
IndexBuffer(GraphicsDevice, IndexElementSize, int, BufferUsage, bool)
protected IndexBuffer(GraphicsDevice graphicsDevice, IndexElementSize indexElementSize, int indexCount, BufferUsage usage, bool dynamic)
Parameters
graphicsDeviceGraphicsDeviceindexElementSizeIndexElementSizeindexCountintusageBufferUsagedynamicbool
IndexBuffer(GraphicsDevice, Type, int, BufferUsage)
public IndexBuffer(GraphicsDevice graphicsDevice, Type indexType, int indexCount, BufferUsage usage)
Parameters
graphicsDeviceGraphicsDeviceindexTypeTypeindexCountintusageBufferUsage
IndexBuffer(GraphicsDevice, Type, int, BufferUsage, bool)
protected IndexBuffer(GraphicsDevice graphicsDevice, Type indexType, int indexCount, BufferUsage usage, bool dynamic)
Parameters
graphicsDeviceGraphicsDeviceindexTypeTypeindexCountintusageBufferUsagedynamicbool
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
disposingboolTrue 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
dataT[]
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
offsetInBytesintdataT[]startIndexintelementCountintoptionsSetDataOptions
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
dataT[]
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