wined3d: Introduce wined3d_device_get_cs_cb().

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-03-07 09:50:14 +01:00 committed by Alexandre Julliard
parent 948463ad37
commit e527b1035a
3 changed files with 15 additions and 0 deletions

View File

@ -2752,6 +2752,19 @@ void CDECL wined3d_device_set_cs_cb(struct wined3d_device *device, unsigned int
wined3d_device_set_constant_buffer(device, WINED3D_SHADER_TYPE_COMPUTE, idx, buffer);
}
struct wined3d_buffer * CDECL wined3d_device_get_cs_cb(const struct wined3d_device *device, unsigned int idx)
{
TRACE("device %p, idx %u.\n", device, idx);
if (idx >= MAX_CONSTANT_BUFFERS)
{
WARN("Invalid constant buffer index %u.\n", idx);
return NULL;
}
return device->state.cb[WINED3D_SHADER_TYPE_COMPUTE][idx];
}
void CDECL wined3d_device_set_cs_resource_view(struct wined3d_device *device,
unsigned int idx, struct wined3d_shader_resource_view *view)
{

View File

@ -53,6 +53,7 @@
@ cdecl wined3d_device_get_clip_status(ptr ptr)
@ cdecl wined3d_device_get_compute_shader(ptr)
@ cdecl wined3d_device_get_creation_parameters(ptr ptr)
@ cdecl wined3d_device_get_cs_cb(ptr long)
@ 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)

View File

@ -2165,6 +2165,7 @@ HRESULT __cdecl wined3d_device_get_clip_status(const struct wined3d_device *devi
struct wined3d_shader * __cdecl wined3d_device_get_compute_shader(const struct wined3d_device *device);
void __cdecl wined3d_device_get_creation_parameters(const struct wined3d_device *device,
struct wined3d_device_creation_parameters *creation_parameters);
struct wined3d_buffer * __cdecl wined3d_device_get_cs_cb(const struct wined3d_device *device, unsigned int idx);
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, WINED3DCAPS *caps);
HRESULT __cdecl wined3d_device_get_display_mode(const struct wined3d_device *device, UINT swapchain_idx,