d3d11: Implement d3d11_immediate_context_DSSetShader().

Signed-off-by: Józef Kucia <jkucia@codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Józef Kucia 2017-04-20 11:04:16 +02:00 committed by Alexandre Julliard
parent 69d771618c
commit cefc48e882
3 changed files with 21 additions and 1 deletions

View File

@ -308,6 +308,7 @@ struct d3d11_domain_shader
HRESULT d3d11_domain_shader_create(struct d3d_device *device, const void *byte_code, SIZE_T byte_code_length,
struct d3d11_domain_shader **shader) DECLSPEC_HIDDEN;
struct d3d11_domain_shader *unsafe_impl_from_ID3D11DomainShader(ID3D11DomainShader *iface) DECLSPEC_HIDDEN;
/* ID3D11GeometryShader, ID3D10GeometryShader */
struct d3d_geometry_shader

View File

@ -1173,8 +1173,18 @@ static void STDMETHODCALLTYPE d3d11_immediate_context_DSSetShaderResources(ID3D1
static void STDMETHODCALLTYPE d3d11_immediate_context_DSSetShader(ID3D11DeviceContext *iface,
ID3D11DomainShader *shader, ID3D11ClassInstance *const *class_instances, UINT class_instance_count)
{
FIXME("iface %p, shader %p, class_instances %p, class_instance_count %u stub!\n",
struct d3d_device *device = device_from_immediate_ID3D11DeviceContext(iface);
struct d3d11_domain_shader *ds = unsafe_impl_from_ID3D11DomainShader(shader);
TRACE("iface %p, shader %p, class_instances %p, class_instance_count %u.\n",
iface, shader, class_instances, class_instance_count);
if (class_instances)
FIXME("Dynamic linking is not implemented yet.\n");
wined3d_mutex_lock();
wined3d_device_set_domain_shader(device->wined3d_device, ds ? ds->wined3d_shader : NULL);
wined3d_mutex_unlock();
}
static void STDMETHODCALLTYPE d3d11_immediate_context_DSSetSamplers(ID3D11DeviceContext *iface,

View File

@ -984,6 +984,15 @@ HRESULT d3d11_domain_shader_create(struct d3d_device *device, const void *byte_c
return S_OK;
}
struct d3d11_domain_shader *unsafe_impl_from_ID3D11DomainShader(ID3D11DomainShader *iface)
{
if (!iface)
return NULL;
assert(iface->lpVtbl == &d3d11_domain_shader_vtbl);
return impl_from_ID3D11DomainShader(iface);
}
/* ID3D11GeometryShader methods */
static inline struct d3d_geometry_shader *impl_from_ID3D11GeometryShader(ID3D11GeometryShader *iface)