diff options
author | Timothy Arceri <timothy.arceri@collabora.com> | 2016-06-22 12:41:28 +1000 |
---|---|---|
committer | Timothy Arceri <t_arceri@yahoo.com.au> | 2016-06-23 11:01:46 +1000 |
commit | ab99196b6bc5b0170db20db6cc3837ce7642d22a (patch) | |
tree | 0e37f19fba45438d45cad609ab4b940b0ab6b997 /src/mesa/main/shaderobj.c | |
parent | 24b3be093870a9a77325ac33c8fce97fae143e8e (diff) | |
download | external_mesa3d-ab99196b6bc5b0170db20db6cc3837ce7642d22a.zip external_mesa3d-ab99196b6bc5b0170db20db6cc3837ce7642d22a.tar.gz external_mesa3d-ab99196b6bc5b0170db20db6cc3837ce7642d22a.tar.bz2 |
glsl/mesa: stop duplicating geom and tcs layout values
We already store these in gl_shader and gl_program here we
remove it from gl_shader_program and just use the values
from gl_shader.
This will allow us to keep the shader cache restore code as
simple as it can be while making it somewhat clearer where these
values originate from.
Reviewed-by: Iago Toral Quiroga <itoral@igalia.com>
Diffstat (limited to 'src/mesa/main/shaderobj.c')
-rw-r--r-- | src/mesa/main/shaderobj.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/mesa/main/shaderobj.c b/src/mesa/main/shaderobj.c index 8283555..f3d5c2e 100644 --- a/src/mesa/main/shaderobj.c +++ b/src/mesa/main/shaderobj.c @@ -92,6 +92,9 @@ void _mesa_init_shader(struct gl_context *ctx, struct gl_shader *shader) { shader->RefCount = 1; + shader->Geom.VerticesOut = -1; + shader->Geom.InputType = GL_TRIANGLES; + shader->Geom.OutputType = GL_TRIANGLE_STRIP; } /** @@ -230,9 +233,6 @@ init_shader_program(struct gl_shader_program *prog) prog->FragDataBindings = string_to_uint_map_ctor(); prog->FragDataIndexBindings = string_to_uint_map_ctor(); - prog->Geom.VerticesOut = -1; - prog->Geom.InputType = GL_TRIANGLES; - prog->Geom.OutputType = GL_TRIANGLE_STRIP; prog->Geom.UsesEndPrimitive = false; prog->Geom.UsesStreams = false; |