diff options
author | Robert Bragg <robert@linux.intel.com> | 2011-09-09 14:28:40 +0100 |
---|---|---|
committer | Robert Bragg <robert@linux.intel.com> | 2011-09-09 14:40:48 +0100 |
commit | d43505db22e3dcd384e78894c3c3f877363f65f0 (patch) | |
tree | 3afa8749a8b08d48ba5dca2faed3d464fbe72d27 /cogl | |
parent | b6cea6bed6e51e59322e9f9398c9d1810a147563 (diff) | |
download | cogl-d43505db22e3dcd384e78894c3c3f877363f65f0.tar.gz |
arbfp: remove redundant unit_state re-initialization
When we are about to start arbfp codegen we call shader_state_new() to
allocate new state structures used to build up the code and that
function makes sure to zero the newly allocated structures.
Right after calling shader_state_new() we were then also explicitly
iterating though the newly allocated unit_state structures and zeroing
the .sampled and .dirty_combine_constant members as well as resetting
shader_state->next_constant_id = 0. This patch removes that redundant
re-initialization of state.
Reviewed-by: Neil Roberts <neil@linux.intel.com>
Diffstat (limited to 'cogl')
-rw-r--r-- | cogl/cogl-pipeline-fragend-arbfp.c | 7 |
1 files changed, 0 insertions, 7 deletions
diff --git a/cogl/cogl-pipeline-fragend-arbfp.c b/cogl/cogl-pipeline-fragend-arbfp.c index 813bf144..294daa96 100644 --- a/cogl/cogl-pipeline-fragend-arbfp.c +++ b/cogl/cogl-pipeline-fragend-arbfp.c @@ -252,13 +252,6 @@ _cogl_pipeline_fragend_arbfp_start (CoglPipeline *pipeline, "PARAM one = {1, 1, 1, 1};\n" "PARAM two = {2, 2, 2, 2};\n" "PARAM minus_one = {-1, -1, -1, -1};\n"); - - for (i = 0; i < n_layers; i++) - { - shader_state->unit_state[i].sampled = FALSE; - shader_state->unit_state[i].dirty_combine_constant = FALSE; - } - shader_state->next_constant_id = 0; } } |