wined3d: Pass a wined3d_context_gl structure to shader_glsl_generate_vshader().
Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
c65d522f91
commit
c85df2edc6
|
@ -7870,15 +7870,14 @@ static void shader_glsl_generate_vs_epilogue(const struct wined3d_gl_info *gl_in
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Context activation is done by the caller. */
|
/* Context activation is done by the caller. */
|
||||||
static GLuint shader_glsl_generate_vshader(const struct wined3d_context *context,
|
static GLuint shader_glsl_generate_vertex_shader(const struct wined3d_context_gl *context_gl,
|
||||||
struct shader_glsl_priv *priv, const struct wined3d_shader *shader, const struct vs_compile_args *args)
|
struct shader_glsl_priv *priv, const struct wined3d_shader *shader, const struct vs_compile_args *args)
|
||||||
{
|
{
|
||||||
const struct wined3d_context_gl *context_gl = wined3d_context_gl_const(context);
|
|
||||||
struct wined3d_string_buffer_list *string_buffers = &priv->string_buffers;
|
struct wined3d_string_buffer_list *string_buffers = &priv->string_buffers;
|
||||||
const struct wined3d_shader_reg_maps *reg_maps = &shader->reg_maps;
|
const struct wined3d_shader_reg_maps *reg_maps = &shader->reg_maps;
|
||||||
const struct wined3d_shader_version *version = ®_maps->shader_version;
|
const struct wined3d_shader_version *version = ®_maps->shader_version;
|
||||||
|
const struct wined3d_gl_info *gl_info = context_gl->c.gl_info;
|
||||||
struct wined3d_string_buffer *buffer = &priv->shader_buffer;
|
struct wined3d_string_buffer *buffer = &priv->shader_buffer;
|
||||||
const struct wined3d_gl_info *gl_info = context->gl_info;
|
|
||||||
struct shader_glsl_ctx_priv priv_ctx;
|
struct shader_glsl_ctx_priv priv_ctx;
|
||||||
GLuint shader_id;
|
GLuint shader_id;
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
|
@ -8479,11 +8478,11 @@ static inline BOOL vs_args_equal(const struct vs_compile_args *stored, const str
|
||||||
static GLuint find_glsl_vshader(const struct wined3d_context *context, struct shader_glsl_priv *priv,
|
static GLuint find_glsl_vshader(const struct wined3d_context *context, struct shader_glsl_priv *priv,
|
||||||
struct wined3d_shader *shader, const struct vs_compile_args *args)
|
struct wined3d_shader *shader, const struct vs_compile_args *args)
|
||||||
{
|
{
|
||||||
UINT i;
|
const struct wined3d_context_gl *context_gl = wined3d_context_gl_const(context);
|
||||||
DWORD new_size;
|
|
||||||
DWORD use_map = context->stream_info.use_map;
|
|
||||||
struct glsl_vs_compiled_shader *gl_shaders, *new_array;
|
struct glsl_vs_compiled_shader *gl_shaders, *new_array;
|
||||||
|
uint32_t use_map = context->stream_info.use_map;
|
||||||
struct glsl_shader_private *shader_data;
|
struct glsl_shader_private *shader_data;
|
||||||
|
unsigned int i, new_size;
|
||||||
GLuint ret;
|
GLuint ret;
|
||||||
|
|
||||||
if (!shader->backend_data)
|
if (!shader->backend_data)
|
||||||
|
@ -8534,7 +8533,7 @@ static GLuint find_glsl_vshader(const struct wined3d_context *context, struct sh
|
||||||
gl_shaders[shader_data->num_gl_shaders].args = *args;
|
gl_shaders[shader_data->num_gl_shaders].args = *args;
|
||||||
|
|
||||||
string_buffer_clear(&priv->shader_buffer);
|
string_buffer_clear(&priv->shader_buffer);
|
||||||
ret = shader_glsl_generate_vshader(context, priv, shader, args);
|
ret = shader_glsl_generate_vertex_shader(context_gl, priv, shader, args);
|
||||||
gl_shaders[shader_data->num_gl_shaders++].id = ret;
|
gl_shaders[shader_data->num_gl_shaders++].id = ret;
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
|
|
Loading…
Reference in New Issue