Commit 8cdad7d4 authored by Zebediah Figura's avatar Zebediah Figura Committed by Alexandre Julliard

wined3d: Introduce wined3d_device_context_draw_indexed().

parent 27fed4a5
......@@ -2409,6 +2409,18 @@ void CDECL wined3d_device_context_draw(struct wined3d_device_context *context, u
0, start_vertex, vertex_count, start_instance, instance_count, false);
}
void CDECL wined3d_device_context_draw_indexed(struct wined3d_device_context *context, int base_vertex_index,
unsigned int start_index, unsigned int index_count, unsigned int start_instance, unsigned int instance_count)
{
struct wined3d_state *state = context->state;
TRACE("context %p, base_vertex_index %d, start_index %u, index_count %u, start_instance %u, instance_count %u.\n",
context, base_vertex_index, start_index, index_count, start_instance, instance_count);
wined3d_device_context_emit_draw(context, state->primitive_type, state->patch_vertex_count,
base_vertex_index, start_index, index_count, start_instance, instance_count, true);
}
void CDECL wined3d_device_set_vertex_shader(struct wined3d_device *device, struct wined3d_shader *shader)
{
TRACE("device %p, shader %p.\n", device, shader);
......@@ -4486,8 +4498,7 @@ void CDECL wined3d_device_draw_indexed_primitive(struct wined3d_device *device,
TRACE("device %p, start_idx %u, index_count %u.\n", device, start_idx, index_count);
wined3d_device_context_emit_draw(&device->cs->c, state->primitive_type, state->patch_vertex_count,
state->base_vertex_index, start_idx, index_count, 0, 0, true);
wined3d_device_context_draw_indexed(&device->cs->c, state->base_vertex_index, start_idx, index_count, 0, 0);
}
void CDECL wined3d_device_draw_indexed_primitive_instanced(struct wined3d_device *device,
......@@ -4498,8 +4509,8 @@ void CDECL wined3d_device_draw_indexed_primitive_instanced(struct wined3d_device
TRACE("device %p, start_idx %u, index_count %u, start_instance %u, instance_count %u.\n",
device, start_idx, index_count, start_instance, instance_count);
wined3d_device_context_emit_draw(&device->cs->c, state->primitive_type, state->patch_vertex_count,
state->base_vertex_index, start_idx, index_count, start_instance, instance_count, true);
wined3d_device_context_draw_indexed(&device->cs->c, state->base_vertex_index,
start_idx, index_count, start_instance, instance_count);
}
void CDECL wined3d_device_draw_indexed_primitive_instanced_indirect(struct wined3d_device *device,
......
......@@ -167,6 +167,7 @@
@ cdecl wined3d_device_validate_device(ptr ptr)
@ cdecl wined3d_device_context_draw(ptr long long long long)
@ cdecl wined3d_device_context_draw_indexed(ptr long long long long long)
@ cdecl wined3d_device_context_dispatch(ptr long long long)
@ cdecl wined3d_device_context_dispatch_indirect(ptr ptr long)
@ cdecl wined3d_device_context_set_blend_state(ptr ptr ptr long)
......
......@@ -2562,6 +2562,8 @@ void __cdecl wined3d_device_context_dispatch_indirect(struct wined3d_device_cont
struct wined3d_buffer *buffer, unsigned int offset);
void __cdecl wined3d_device_context_draw(struct wined3d_device_context *context, unsigned int start_vertex,
unsigned int vertex_count, unsigned int start_instance, unsigned int instance_count);
void __cdecl wined3d_device_context_draw_indexed(struct wined3d_device_context *context, int base_vertex_index,
unsigned int start_index, unsigned int index_count, unsigned int start_instance, unsigned int instance_count);
void __cdecl wined3d_device_context_set_blend_state(struct wined3d_device_context *context,
struct wined3d_blend_state *state, const struct wined3d_color *blend_factor, unsigned int sample_mask);
void __cdecl wined3d_device_context_set_constant_buffer(struct wined3d_device_context *context,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment