Commit bfca7dad authored by Józef Kucia's avatar Józef Kucia Committed by Alexandre Julliard

wined3d: Introduce wined3d_device_set_hs_cb().

parent 4db17152
...@@ -2678,6 +2678,13 @@ struct wined3d_shader * CDECL wined3d_device_get_hull_shader(const struct wined3 ...@@ -2678,6 +2678,13 @@ struct wined3d_shader * CDECL wined3d_device_get_hull_shader(const struct wined3
return device->state.shader[WINED3D_SHADER_TYPE_HULL]; return device->state.shader[WINED3D_SHADER_TYPE_HULL];
} }
void CDECL wined3d_device_set_hs_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_HULL, idx, buffer);
}
void CDECL wined3d_device_set_domain_shader(struct wined3d_device *device, struct wined3d_shader *shader) void CDECL wined3d_device_set_domain_shader(struct wined3d_device *device, struct wined3d_shader *shader)
{ {
struct wined3d_shader *prev; struct wined3d_shader *prev;
......
...@@ -5004,6 +5004,8 @@ const struct StateEntryTemplate misc_state_template[] = ...@@ -5004,6 +5004,8 @@ const struct StateEntryTemplate misc_state_template[] =
{ {
{ STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_VERTEX), { STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_VERTEX), state_cb, }, ARB_UNIFORM_BUFFER_OBJECT }, { STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_VERTEX), { STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_VERTEX), state_cb, }, ARB_UNIFORM_BUFFER_OBJECT },
{ 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_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_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, }, 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_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 }, { STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_PIXEL), { STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_PIXEL), state_cb, }, ARB_UNIFORM_BUFFER_OBJECT },
...@@ -5996,6 +5998,7 @@ static void validate_state_table(struct StateEntry *state_table) ...@@ -5996,6 +5998,7 @@ static void validate_state_table(struct StateEntry *state_table)
STATE_SHADER(WINED3D_SHADER_TYPE_PIXEL), STATE_SHADER(WINED3D_SHADER_TYPE_PIXEL),
STATE_SHADER(WINED3D_SHADER_TYPE_COMPUTE), STATE_SHADER(WINED3D_SHADER_TYPE_COMPUTE),
STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_VERTEX), STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_VERTEX),
STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_HULL),
STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_GEOMETRY), STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_GEOMETRY),
STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_PIXEL), STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_PIXEL),
STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_COMPUTE), STATE_CONSTANT_BUFFER(WINED3D_SHADER_TYPE_COMPUTE),
......
...@@ -133,6 +133,7 @@ ...@@ -133,6 +133,7 @@
@ cdecl wined3d_device_set_gs_cb(ptr long ptr) @ cdecl wined3d_device_set_gs_cb(ptr long ptr)
@ cdecl wined3d_device_set_gs_resource_view(ptr long ptr) @ cdecl wined3d_device_set_gs_resource_view(ptr long ptr)
@ cdecl wined3d_device_set_gs_sampler(ptr long ptr) @ cdecl wined3d_device_set_gs_sampler(ptr long ptr)
@ cdecl wined3d_device_set_hs_cb(ptr long ptr)
@ cdecl wined3d_device_set_hull_shader(ptr ptr) @ cdecl wined3d_device_set_hull_shader(ptr ptr)
@ cdecl wined3d_device_set_index_buffer(ptr ptr long long) @ cdecl wined3d_device_set_index_buffer(ptr ptr long long)
@ cdecl wined3d_device_set_light(ptr long ptr) @ cdecl wined3d_device_set_light(ptr long ptr)
......
...@@ -2326,6 +2326,7 @@ void __cdecl wined3d_device_set_gs_cb(struct wined3d_device *device, UINT idx, s ...@@ -2326,6 +2326,7 @@ void __cdecl wined3d_device_set_gs_cb(struct wined3d_device *device, UINT idx, s
void __cdecl wined3d_device_set_gs_resource_view(struct wined3d_device *device, void __cdecl wined3d_device_set_gs_resource_view(struct wined3d_device *device,
UINT idx, struct wined3d_shader_resource_view *view); UINT idx, struct wined3d_shader_resource_view *view);
void __cdecl wined3d_device_set_gs_sampler(struct wined3d_device *device, UINT idx, struct wined3d_sampler *sampler); void __cdecl wined3d_device_set_gs_sampler(struct wined3d_device *device, UINT idx, struct wined3d_sampler *sampler);
void __cdecl wined3d_device_set_hs_cb(struct wined3d_device *device, unsigned int idx, struct wined3d_buffer *buffer);
void __cdecl wined3d_device_set_hull_shader(struct wined3d_device *device, struct wined3d_shader *shader); void __cdecl wined3d_device_set_hull_shader(struct wined3d_device *device, struct wined3d_shader *shader);
void __cdecl wined3d_device_set_index_buffer(struct wined3d_device *device, void __cdecl wined3d_device_set_index_buffer(struct wined3d_device *device,
struct wined3d_buffer *index_buffer, enum wined3d_format_id format_id, unsigned int offset); struct wined3d_buffer *index_buffer, enum wined3d_format_id format_id, unsigned int offset);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment