Exemplo n.º 1
0
 /// <summary>
 /// Sets a dynamic vertex buffer as a compute resource.
 /// </summary>
 /// <param name="stage">The resource stage to set.</param>
 /// <param name="buffer">The buffer to set.</param>
 /// <param name="access">Access control flags.</param>
 public void SetComputeBuffer(byte stage, DynamicVertexBuffer buffer, ComputeBufferAccess access)
 {
     NativeMethods.bgfx_encoder_set_compute_dynamic_vertex_buffer(ptr, stage, buffer.handle, access);
 }
Exemplo n.º 2
0
 /// <summary>
 /// Sets instance data to use for drawing primitives.
 /// </summary>
 /// <param name="vertexBuffer">The vertex buffer containing instance data.</param>
 /// <param name="firstVertex">The index of the first vertex to use.</param>
 /// <param name="count">The number of vertices to pull from the buffer.</param>
 public void SetInstanceDataBuffer(DynamicVertexBuffer vertexBuffer, int firstVertex, int count)
 {
     NativeMethods.bgfx_encoder_set_instance_data_from_dynamic_vertex_buffer(ptr, vertexBuffer.handle, firstVertex, count);
 }
Exemplo n.º 3
0
 /// <summary>
 /// Sets the vertex buffer to use for drawing primitives.
 /// </summary>
 /// <param name="stream">The index of the vertex stream to set.</param>
 /// <param name="vertexBuffer">The vertex buffer to set.</param>
 /// <param name="startVertex">The index of the first vertex to use.</param>
 /// <param name="count">The number of vertices to pull from the buffer.</param>
 public void SetVertexBuffer(int stream, DynamicVertexBuffer vertexBuffer, int startVertex, int count)
 {
     NativeMethods.bgfx_encoder_set_dynamic_vertex_buffer(ptr, (byte)stream, vertexBuffer.handle, startVertex, count);
 }
Exemplo n.º 4
0
 /// <summary>
 /// Sets the vertex buffer to use for drawing primitives.
 /// </summary>
 /// <param name="stream">The index of the vertex stream to set.</param>
 /// <param name="vertexBuffer">The vertex buffer to set.</param>
 public void SetVertexBuffer(int stream, DynamicVertexBuffer vertexBuffer)
 {
     NativeMethods.bgfx_encoder_set_dynamic_vertex_buffer(ptr, (byte)stream, vertexBuffer.handle, 0, -1);
 }
Exemplo n.º 5
0
 /// <summary>
 /// Sets the vertex buffer to use for drawing primitives.
 /// </summary>
 /// <param name="vertexBuffer">The vertex buffer to set.</param>
 /// <param name="startVertex">The index of the first vertex to use.</param>
 /// <param name="count">The number of vertices to pull from the buffer.</param>
 public static void SetVertexBuffer(DynamicVertexBuffer vertexBuffer, int startVertex, int count)
 {
     NativeMethods.bgfx_set_dynamic_vertex_buffer(vertexBuffer.handle, startVertex, count);
 }
Exemplo n.º 6
0
 /// <summary>
 /// Sets the vertex buffer to use for drawing primitives.
 /// </summary>
 /// <param name="vertexBuffer">The vertex buffer to set.</param>
 public static void SetVertexBuffer(DynamicVertexBuffer vertexBuffer)
 {
     NativeMethods.bgfx_set_dynamic_vertex_buffer(vertexBuffer.handle, 0, -1);
 }