Signed-off-by: Zebediah Figura z.figura12@gmail.com --- dlls/d3d11/device.c | 4 ++-- dlls/wined3d/device.c | 10 +++++----- dlls/wined3d/wined3d.spec | 2 +- include/wine/wined3d.h | 4 ++-- 4 files changed, 10 insertions(+), 10 deletions(-)
diff --git a/dlls/d3d11/device.c b/dlls/d3d11/device.c index 70d14c7f2c5..d56be188cf6 100644 --- a/dlls/d3d11/device.c +++ b/dlls/d3d11/device.c @@ -2161,7 +2161,7 @@ static void STDMETHODCALLTYPE d3d11_immediate_context_OMGetBlendState(ID3D11Devi static void STDMETHODCALLTYPE d3d11_immediate_context_OMGetDepthStencilState(ID3D11DeviceContext1 *iface, ID3D11DepthStencilState **depth_stencil_state, UINT *stencil_ref) { - struct d3d_device *device = device_from_immediate_ID3D11DeviceContext1(iface); + struct d3d11_immediate_context *context = impl_from_ID3D11DeviceContext1(iface); struct wined3d_depth_stencil_state *wined3d_state; struct d3d_depthstencil_state *state_impl;
@@ -2169,7 +2169,7 @@ static void STDMETHODCALLTYPE d3d11_immediate_context_OMGetDepthStencilState(ID3 iface, depth_stencil_state, stencil_ref);
wined3d_mutex_lock(); - if ((wined3d_state = wined3d_device_get_depth_stencil_state(device->wined3d_device, stencil_ref))) + if ((wined3d_state = wined3d_device_context_get_depth_stencil_state(context->wined3d_context, stencil_ref))) { state_impl = wined3d_depth_stencil_state_get_parent(wined3d_state); ID3D11DepthStencilState_AddRef(*depth_stencil_state = &state_impl->ID3D11DepthStencilState_iface); diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c index 39701886450..c370c5dff7c 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c @@ -1623,12 +1623,12 @@ void CDECL wined3d_device_set_depth_stencil_state(struct wined3d_device *device, wined3d_device_context_set_depth_stencil_state(&device->cs->c, depth_stencil_state, stencil_ref); }
-struct wined3d_depth_stencil_state * CDECL wined3d_device_get_depth_stencil_state(const struct wined3d_device *device, - unsigned int *stencil_ref) +struct wined3d_depth_stencil_state * CDECL wined3d_device_context_get_depth_stencil_state( + const struct wined3d_device_context *context, unsigned int *stencil_ref) { - const struct wined3d_state *state = device->cs->c.state; + const struct wined3d_state *state = context->state;
- TRACE("device %p, stencil_ref %p.\n", device, stencil_ref); + TRACE("context %p, stencil_ref %p.\n", context, stencil_ref);
*stencil_ref = state->stencil_ref; return state->depth_stencil_state; @@ -4221,7 +4221,7 @@ void CDECL wined3d_device_apply_stateblock(struct wined3d_device *device, if (wined3d_bitmap_is_set(changed->renderState, WINED3D_RS_STENCILREF)) stencil_ref = state->rs[WINED3D_RS_STENCILREF]; else - wined3d_device_get_depth_stencil_state(device, &stencil_ref); + wined3d_device_context_get_depth_stencil_state(context, &stencil_ref);
if ((entry = wine_rb_get(&device->depth_stencil_states, &desc))) { diff --git a/dlls/wined3d/wined3d.spec b/dlls/wined3d/wined3d.spec index 35fbc44ee64..e9650c10024 100644 --- a/dlls/wined3d/wined3d.spec +++ b/dlls/wined3d/wined3d.spec @@ -61,7 +61,6 @@ @ cdecl wined3d_device_get_cs_resource_view(ptr long) @ cdecl wined3d_device_get_cs_sampler(ptr long) @ cdecl wined3d_device_get_cs_uav(ptr long) -@ cdecl wined3d_device_get_depth_stencil_state(ptr) @ cdecl wined3d_device_get_depth_stencil_view(ptr) @ cdecl wined3d_device_get_device_caps(ptr ptr) @ cdecl wined3d_device_get_display_mode(ptr long ptr ptr) @@ -171,6 +170,7 @@ @ cdecl wined3d_device_context_generate_mipmaps(ptr ptr) @ cdecl wined3d_device_context_get_blend_state(ptr ptr ptr) @ cdecl wined3d_device_context_get_constant_buffer(ptr long long) +@ cdecl wined3d_device_context_get_depth_stencil_state(ptr ptr) @ cdecl wined3d_device_context_get_shader(ptr long) @ cdecl wined3d_device_context_issue_query(ptr ptr long) @ cdecl wined3d_device_context_map(ptr ptr long ptr ptr long) diff --git a/include/wine/wined3d.h b/include/wine/wined3d.h index 7dcb969966c..188a73cb694 100644 --- a/include/wine/wined3d.h +++ b/include/wine/wined3d.h @@ -2385,8 +2385,6 @@ struct wined3d_shader_resource_view * __cdecl wined3d_device_get_cs_resource_vie struct wined3d_sampler * __cdecl wined3d_device_get_cs_sampler(const struct wined3d_device *device, unsigned int idx); struct wined3d_unordered_access_view * __cdecl wined3d_device_get_cs_uav(const struct wined3d_device *device, unsigned int idx); -struct wined3d_depth_stencil_state * __cdecl wined3d_device_get_depth_stencil_state( - const struct wined3d_device *device, unsigned int *stencil_ref); struct wined3d_rendertarget_view * __cdecl wined3d_device_get_depth_stencil_view(const struct wined3d_device *device); HRESULT __cdecl wined3d_device_get_device_caps(const struct wined3d_device *device, struct wined3d_caps *caps); HRESULT __cdecl wined3d_device_get_display_mode(const struct wined3d_device *device, UINT swapchain_idx, @@ -2567,6 +2565,8 @@ struct wined3d_blend_state * __cdecl wined3d_device_context_get_blend_state( const struct wined3d_device_context *context, struct wined3d_color *blend_factor, unsigned int *sample_mask); struct wined3d_buffer * __cdecl wined3d_device_context_get_constant_buffer(const struct wined3d_device_context *context, enum wined3d_shader_type shader_type, unsigned int idx); +struct wined3d_depth_stencil_state * __cdecl wined3d_device_context_get_depth_stencil_state( + const struct wined3d_device_context *context, unsigned int *stencil_ref); struct wined3d_shader * __cdecl wined3d_device_context_get_shader(const struct wined3d_device_context *context, enum wined3d_shader_type type); void __cdecl wined3d_device_context_issue_query(struct wined3d_device_context *context,