diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c index dfd15d413e6..edd11a32217 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c @@ -2709,6 +2709,13 @@ struct wined3d_shader * CDECL wined3d_device_get_domain_shader(const struct wine return device->state.shader[WINED3D_SHADER_TYPE_DOMAIN]; } +void CDECL wined3d_device_set_ds_cb(struct wined3d_device *device, unsigned int idx, struct wined3d_buffer *buffer) +{ + TRACE("device %p, idx %u, buffer %p.\n", device, idx, buffer); + + wined3d_device_set_constant_buffer(device, WINED3D_SHADER_TYPE_DOMAIN, idx, buffer); +} + void CDECL wined3d_device_set_geometry_shader(struct wined3d_device *device, struct wined3d_shader *shader) { struct wined3d_shader *prev = device->update_state->shader[WINED3D_SHADER_TYPE_GEOMETRY]; diff --git a/dlls/wined3d/state.c b/dlls/wined3d/state.c index 389d777c772..531dd9858df 100644 --- a/dlls/wined3d/state.c +++ b/dlls/wined3d/state.c @@ -5006,6 +5006,8 @@ const struct StateEntryTemplate misc_state_template[] = { STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_VERTEX), { STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_VERTEX), state_cb_warn, }, WINED3D_GL_EXT_NONE }, { STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_HULL), { STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_HULL), state_cb, }, ARB_UNIFORM_BUFFER_OBJECT }, { STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_HULL), { STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_HULL), state_cb_warn, }, WINED3D_GL_EXT_NONE }, + { STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_DOMAIN), { STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_DOMAIN), state_cb, }, ARB_UNIFORM_BUFFER_OBJECT }, + { STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_DOMAIN), { STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_DOMAIN), state_cb_warn, }, WINED3D_GL_EXT_NONE }, { STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_GEOMETRY),{ STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_GEOMETRY),state_cb, }, ARB_UNIFORM_BUFFER_OBJECT }, { STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_GEOMETRY),{ STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_GEOMETRY),state_cb_warn, }, WINED3D_GL_EXT_NONE }, { STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_PIXEL), { STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_PIXEL), state_cb, }, ARB_UNIFORM_BUFFER_OBJECT }, @@ -5999,6 +6001,7 @@ static void validate_state_table(struct StateEntry *state_table) STATE_SHADER(WINED3D_SHADER_TYPE_COMPUTE), STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_VERTEX), STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_HULL), + STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_DOMAIN), STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_GEOMETRY), STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_PIXEL), STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_COMPUTE), diff --git a/dlls/wined3d/wined3d.spec b/dlls/wined3d/wined3d.spec index 02dee0b3c3c..32b2f6ca0c0 100644 --- a/dlls/wined3d/wined3d.spec +++ b/dlls/wined3d/wined3d.spec @@ -128,6 +128,7 @@ @ cdecl wined3d_device_set_depth_stencil_view(ptr ptr) @ cdecl wined3d_device_set_dialog_box_mode(ptr long) @ cdecl wined3d_device_set_domain_shader(ptr ptr) +@ cdecl wined3d_device_set_ds_cb(ptr long ptr) @ cdecl wined3d_device_set_gamma_ramp(ptr long long ptr) @ cdecl wined3d_device_set_geometry_shader(ptr ptr) @ cdecl wined3d_device_set_gs_cb(ptr long ptr) diff --git a/include/wine/wined3d.h b/include/wine/wined3d.h index 1c9f854b381..5f84c775640 100644 --- a/include/wine/wined3d.h +++ b/include/wine/wined3d.h @@ -2319,6 +2319,7 @@ void __cdecl wined3d_device_set_depth_stencil_view(struct wined3d_device *device struct wined3d_rendertarget_view *view); HRESULT __cdecl wined3d_device_set_dialog_box_mode(struct wined3d_device *device, BOOL enable_dialogs); void __cdecl wined3d_device_set_domain_shader(struct wined3d_device *device, struct wined3d_shader *shader); +void __cdecl wined3d_device_set_ds_cb(struct wined3d_device *device, unsigned int idx, struct wined3d_buffer *buffer); void __cdecl wined3d_device_set_gamma_ramp(const struct wined3d_device *device, UINT swapchain_idx, DWORD flags, const struct wined3d_gamma_ramp *ramp); void __cdecl wined3d_device_set_geometry_shader(struct wined3d_device *device, struct wined3d_shader *shader);