d3d11: Use wined3d_device_context_get_shader().
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:
parent
fd7231493d
commit
8cd9754b07
|
@ -1678,7 +1678,7 @@ static void STDMETHODCALLTYPE d3d11_immediate_context_PSGetShaderResources(ID3D1
|
|||
static void STDMETHODCALLTYPE d3d11_immediate_context_PSGetShader(ID3D11DeviceContext1 *iface,
|
||||
ID3D11PixelShader **shader, ID3D11ClassInstance **class_instances, UINT *class_instance_count)
|
||||
{
|
||||
struct d3d_device *device = device_from_immediate_ID3D11DeviceContext1(iface);
|
||||
struct d3d11_immediate_context *context = impl_from_ID3D11DeviceContext1(iface);
|
||||
struct wined3d_shader *wined3d_shader;
|
||||
struct d3d_pixel_shader *shader_impl;
|
||||
|
||||
|
@ -1691,7 +1691,7 @@ static void STDMETHODCALLTYPE d3d11_immediate_context_PSGetShader(ID3D11DeviceCo
|
|||
*class_instance_count = 0;
|
||||
|
||||
wined3d_mutex_lock();
|
||||
if (!(wined3d_shader = wined3d_device_get_pixel_shader(device->wined3d_device)))
|
||||
if (!(wined3d_shader = wined3d_device_context_get_shader(context->wined3d_context, WINED3D_SHADER_TYPE_PIXEL)))
|
||||
{
|
||||
wined3d_mutex_unlock();
|
||||
*shader = NULL;
|
||||
|
@ -1735,7 +1735,7 @@ static void STDMETHODCALLTYPE d3d11_immediate_context_PSGetSamplers(ID3D11Device
|
|||
static void STDMETHODCALLTYPE d3d11_immediate_context_VSGetShader(ID3D11DeviceContext1 *iface,
|
||||
ID3D11VertexShader **shader, ID3D11ClassInstance **class_instances, UINT *class_instance_count)
|
||||
{
|
||||
struct d3d_device *device = device_from_immediate_ID3D11DeviceContext1(iface);
|
||||
struct d3d11_immediate_context *context = impl_from_ID3D11DeviceContext1(iface);
|
||||
struct d3d_vertex_shader *shader_impl;
|
||||
struct wined3d_shader *wined3d_shader;
|
||||
|
||||
|
@ -1748,7 +1748,7 @@ static void STDMETHODCALLTYPE d3d11_immediate_context_VSGetShader(ID3D11DeviceCo
|
|||
*class_instance_count = 0;
|
||||
|
||||
wined3d_mutex_lock();
|
||||
if (!(wined3d_shader = wined3d_device_get_vertex_shader(device->wined3d_device)))
|
||||
if (!(wined3d_shader = wined3d_device_context_get_shader(context->wined3d_context, WINED3D_SHADER_TYPE_VERTEX)))
|
||||
{
|
||||
wined3d_mutex_unlock();
|
||||
*shader = NULL;
|
||||
|
@ -1869,7 +1869,7 @@ static void STDMETHODCALLTYPE d3d11_immediate_context_GSGetConstantBuffers(ID3D1
|
|||
static void STDMETHODCALLTYPE d3d11_immediate_context_GSGetShader(ID3D11DeviceContext1 *iface,
|
||||
ID3D11GeometryShader **shader, ID3D11ClassInstance **class_instances, UINT *class_instance_count)
|
||||
{
|
||||
struct d3d_device *device = device_from_immediate_ID3D11DeviceContext1(iface);
|
||||
struct d3d11_immediate_context *context = impl_from_ID3D11DeviceContext1(iface);
|
||||
struct d3d_geometry_shader *shader_impl;
|
||||
struct wined3d_shader *wined3d_shader;
|
||||
|
||||
|
@ -1882,7 +1882,7 @@ static void STDMETHODCALLTYPE d3d11_immediate_context_GSGetShader(ID3D11DeviceCo
|
|||
*class_instance_count = 0;
|
||||
|
||||
wined3d_mutex_lock();
|
||||
if (!(wined3d_shader = wined3d_device_get_geometry_shader(device->wined3d_device)))
|
||||
if (!(wined3d_shader = wined3d_device_context_get_shader(context->wined3d_context, WINED3D_SHADER_TYPE_GEOMETRY)))
|
||||
{
|
||||
wined3d_mutex_unlock();
|
||||
*shader = NULL;
|
||||
|
@ -2318,7 +2318,7 @@ static void STDMETHODCALLTYPE d3d11_immediate_context_HSGetShaderResources(ID3D1
|
|||
static void STDMETHODCALLTYPE d3d11_immediate_context_HSGetShader(ID3D11DeviceContext1 *iface,
|
||||
ID3D11HullShader **shader, ID3D11ClassInstance **class_instances, UINT *class_instance_count)
|
||||
{
|
||||
struct d3d_device *device = device_from_immediate_ID3D11DeviceContext1(iface);
|
||||
struct d3d11_immediate_context *context = impl_from_ID3D11DeviceContext1(iface);
|
||||
struct d3d11_hull_shader *shader_impl;
|
||||
struct wined3d_shader *wined3d_shader;
|
||||
|
||||
|
@ -2331,7 +2331,7 @@ static void STDMETHODCALLTYPE d3d11_immediate_context_HSGetShader(ID3D11DeviceCo
|
|||
*class_instance_count = 0;
|
||||
|
||||
wined3d_mutex_lock();
|
||||
if (!(wined3d_shader = wined3d_device_get_hull_shader(device->wined3d_device)))
|
||||
if (!(wined3d_shader = wined3d_device_context_get_shader(context->wined3d_context, WINED3D_SHADER_TYPE_HULL)))
|
||||
{
|
||||
wined3d_mutex_unlock();
|
||||
*shader = NULL;
|
||||
|
@ -2410,7 +2410,7 @@ static void STDMETHODCALLTYPE d3d11_immediate_context_DSGetShaderResources(ID3D1
|
|||
static void STDMETHODCALLTYPE d3d11_immediate_context_DSGetShader(ID3D11DeviceContext1 *iface,
|
||||
ID3D11DomainShader **shader, ID3D11ClassInstance **class_instances, UINT *class_instance_count)
|
||||
{
|
||||
struct d3d_device *device = device_from_immediate_ID3D11DeviceContext1(iface);
|
||||
struct d3d11_immediate_context *context = impl_from_ID3D11DeviceContext1(iface);
|
||||
struct d3d11_domain_shader *shader_impl;
|
||||
struct wined3d_shader *wined3d_shader;
|
||||
|
||||
|
@ -2423,7 +2423,7 @@ static void STDMETHODCALLTYPE d3d11_immediate_context_DSGetShader(ID3D11DeviceCo
|
|||
*class_instance_count = 0;
|
||||
|
||||
wined3d_mutex_lock();
|
||||
if (!(wined3d_shader = wined3d_device_get_domain_shader(device->wined3d_device)))
|
||||
if (!(wined3d_shader = wined3d_device_context_get_shader(context->wined3d_context, WINED3D_SHADER_TYPE_DOMAIN)))
|
||||
{
|
||||
wined3d_mutex_unlock();
|
||||
*shader = NULL;
|
||||
|
@ -2527,7 +2527,7 @@ static void STDMETHODCALLTYPE d3d11_immediate_context_CSGetUnorderedAccessViews(
|
|||
static void STDMETHODCALLTYPE d3d11_immediate_context_CSGetShader(ID3D11DeviceContext1 *iface,
|
||||
ID3D11ComputeShader **shader, ID3D11ClassInstance **class_instances, UINT *class_instance_count)
|
||||
{
|
||||
struct d3d_device *device = device_from_immediate_ID3D11DeviceContext1(iface);
|
||||
struct d3d11_immediate_context *context = impl_from_ID3D11DeviceContext1(iface);
|
||||
struct d3d11_compute_shader *shader_impl;
|
||||
struct wined3d_shader *wined3d_shader;
|
||||
|
||||
|
@ -2540,7 +2540,7 @@ static void STDMETHODCALLTYPE d3d11_immediate_context_CSGetShader(ID3D11DeviceCo
|
|||
*class_instance_count = 0;
|
||||
|
||||
wined3d_mutex_lock();
|
||||
if (!(wined3d_shader = wined3d_device_get_compute_shader(device->wined3d_device)))
|
||||
if (!(wined3d_shader = wined3d_device_context_get_shader(context->wined3d_context, WINED3D_SHADER_TYPE_COMPUTE)))
|
||||
{
|
||||
wined3d_mutex_unlock();
|
||||
*shader = NULL;
|
||||
|
@ -5046,7 +5046,8 @@ static void STDMETHODCALLTYPE d3d10_device_PSGetShader(ID3D10Device1 *iface, ID3
|
|||
TRACE("iface %p, shader %p.\n", iface, shader);
|
||||
|
||||
wined3d_mutex_lock();
|
||||
if (!(wined3d_shader = wined3d_device_get_pixel_shader(device->wined3d_device)))
|
||||
if (!(wined3d_shader = wined3d_device_context_get_shader(device->immediate_context.wined3d_context,
|
||||
WINED3D_SHADER_TYPE_PIXEL)))
|
||||
{
|
||||
wined3d_mutex_unlock();
|
||||
*shader = NULL;
|
||||
|
@ -5096,7 +5097,8 @@ static void STDMETHODCALLTYPE d3d10_device_VSGetShader(ID3D10Device1 *iface, ID3
|
|||
TRACE("iface %p, shader %p.\n", iface, shader);
|
||||
|
||||
wined3d_mutex_lock();
|
||||
if (!(wined3d_shader = wined3d_device_get_vertex_shader(device->wined3d_device)))
|
||||
if (!(wined3d_shader = wined3d_device_context_get_shader(device->immediate_context.wined3d_context,
|
||||
WINED3D_SHADER_TYPE_VERTEX)))
|
||||
{
|
||||
wined3d_mutex_unlock();
|
||||
*shader = NULL;
|
||||
|
@ -5218,7 +5220,8 @@ static void STDMETHODCALLTYPE d3d10_device_GSGetShader(ID3D10Device1 *iface, ID3
|
|||
TRACE("iface %p, shader %p.\n", iface, shader);
|
||||
|
||||
wined3d_mutex_lock();
|
||||
if (!(wined3d_shader = wined3d_device_get_geometry_shader(device->wined3d_device)))
|
||||
if (!(wined3d_shader = wined3d_device_context_get_shader(device->immediate_context.wined3d_context,
|
||||
WINED3D_SHADER_TYPE_GEOMETRY)))
|
||||
{
|
||||
wined3d_mutex_unlock();
|
||||
*shader = NULL;
|
||||
|
|
Loading…
Reference in New Issue