wined3d: Pass a wined3d_device_context to wined3d_cs_emit_set_depth_stencil_state().

Signed-off-by: Zebediah Figura <z.figura12@gmail.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Zebediah Figura 2021-03-10 19:25:15 -06:00 committed by Alexandre Julliard
parent 86a06f7e97
commit a3102c7b39
3 changed files with 7 additions and 7 deletions

View File

@ -1679,17 +1679,17 @@ static void wined3d_cs_exec_set_depth_stencil_state(struct wined3d_cs *cs, const
device_invalidate_state(cs->c.device, STATE_STENCIL_REF);
}
void wined3d_cs_emit_set_depth_stencil_state(struct wined3d_cs *cs,
void wined3d_device_context_emit_set_depth_stencil_state(struct wined3d_device_context *context,
struct wined3d_depth_stencil_state *state, unsigned int stencil_ref)
{
struct wined3d_cs_set_depth_stencil_state *op;
op = wined3d_device_context_require_space(&cs->c, sizeof(*op), WINED3D_CS_QUEUE_DEFAULT);
op = wined3d_device_context_require_space(context, sizeof(*op), WINED3D_CS_QUEUE_DEFAULT);
op->opcode = WINED3D_CS_OP_SET_DEPTH_STENCIL_STATE;
op->state = state;
op->stencil_ref = stencil_ref;
wined3d_device_context_submit(&cs->c, WINED3D_CS_QUEUE_DEFAULT);
wined3d_device_context_submit(context, WINED3D_CS_QUEUE_DEFAULT);
}
static void wined3d_cs_exec_set_rasterizer_state(struct wined3d_cs *cs, const void *data)

View File

@ -1774,7 +1774,7 @@ void CDECL wined3d_device_set_depth_stencil_state(struct wined3d_device *device,
wined3d_depth_stencil_state_incref(depth_stencil_state);
state->depth_stencil_state = depth_stencil_state;
state->stencil_ref = stencil_ref;
wined3d_cs_emit_set_depth_stencil_state(device->cs, depth_stencil_state, stencil_ref);
wined3d_device_context_emit_set_depth_stencil_state(&device->cs->c, depth_stencil_state, stencil_ref);
if (prev)
wined3d_depth_stencil_state_decref(prev);
}
@ -2027,7 +2027,7 @@ void CDECL wined3d_device_set_state(struct wined3d_device *device, struct wined3
}
wined3d_device_context_emit_set_blend_state(context, state->blend_state, &state->blend_factor, state->sample_mask);
wined3d_cs_emit_set_depth_stencil_state(device->cs, state->depth_stencil_state, state->stencil_ref);
wined3d_device_context_emit_set_depth_stencil_state(context, state->depth_stencil_state, state->stencil_ref);
wined3d_cs_emit_set_rasterizer_state(device->cs, state->rasterizer_state);
}

View File

@ -4745,8 +4745,6 @@ void wined3d_cs_emit_set_clip_plane(struct wined3d_cs *cs, UINT plane_idx,
const struct wined3d_vec4 *plane) DECLSPEC_HIDDEN;
void wined3d_cs_emit_set_color_key(struct wined3d_cs *cs, struct wined3d_texture *texture,
WORD flags, const struct wined3d_color_key *color_key) DECLSPEC_HIDDEN;
void wined3d_cs_emit_set_depth_stencil_state(struct wined3d_cs *cs,
struct wined3d_depth_stencil_state *state, unsigned int stencil_ref) DECLSPEC_HIDDEN;
void wined3d_cs_emit_set_depth_stencil_view(struct wined3d_cs *cs,
struct wined3d_rendertarget_view *view) DECLSPEC_HIDDEN;
void wined3d_cs_emit_set_index_buffer(struct wined3d_cs *cs, struct wined3d_buffer *buffer,
@ -4813,6 +4811,8 @@ void wined3d_device_context_emit_set_blend_state(struct wined3d_device_context *
unsigned int sample_mask) DECLSPEC_HIDDEN;
void wined3d_device_context_emit_set_constant_buffer(struct wined3d_device_context *context,
enum wined3d_shader_type type, UINT cb_idx, struct wined3d_buffer *buffer) DECLSPEC_HIDDEN;
void wined3d_device_context_emit_set_depth_stencil_state(struct wined3d_device_context *context,
struct wined3d_depth_stencil_state *state, unsigned int stencil_ref) DECLSPEC_HIDDEN;
void wined3d_device_context_emit_set_shader(struct wined3d_device_context *context, enum wined3d_shader_type type,
struct wined3d_shader *shader) DECLSPEC_HIDDEN;