summaryrefslogtreecommitdiffstats
path: root/src/glsl
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2015-10-01 13:12:57 -0600
committerBrian Paul <[email protected]>2015-10-06 08:51:33 -0600
commitb7766a95e1b81e27624d91edf83dea91fb64a42e (patch)
treef778216bcbf24d2887ac0c79aeb46f82fb630b85 /src/glsl
parent50d5a36f3575bae38266e2445989c3b672ddbdbf (diff)
glsl: whitespace/formatting/typo fixes in link_uniforms.cpp
Diffstat (limited to 'src/glsl')
-rw-r--r--src/glsl/link_uniforms.cpp15
1 files changed, 9 insertions, 6 deletions
diff --git a/src/glsl/link_uniforms.cpp b/src/glsl/link_uniforms.cpp
index 0642ddc4bf5..0ccd9c8c865 100644
--- a/src/glsl/link_uniforms.cpp
+++ b/src/glsl/link_uniforms.cpp
@@ -739,7 +739,7 @@ private:
handle_subroutines(base_type, &this->uniforms[id]);
/* For array of arrays or struct arrays the base location may have
- * already been set so dont set it again.
+ * already been set so don't set it again.
*/
if (ubo_block_index == -1 && current_var->data.location == -1) {
current_var->data.location = id;
@@ -764,7 +764,7 @@ private:
this->explicit_location + field_counter;
field_counter += entries;
} else {
- this->uniforms[id].remap_location = this->explicit_location;
+ this->uniforms[id].remap_location = this->explicit_location;
}
} else {
/* Initialize to to indicate that no location is set */
@@ -815,12 +815,13 @@ private:
if (type->without_array()->is_matrix()) {
const glsl_type *matrix = type->without_array();
const unsigned N = matrix->base_type == GLSL_TYPE_DOUBLE ? 8 : 4;
- const unsigned items = row_major ? matrix->matrix_columns : matrix->vector_elements;
+ const unsigned items =
+ row_major ? matrix->matrix_columns : matrix->vector_elements;
assert(items <= 4);
if (packing == GLSL_INTERFACE_PACKING_STD430)
this->uniforms[id].matrix_stride = items < 3 ? items * N :
- glsl_align(items * N, 16);
+ glsl_align(items * N, 16);
else
this->uniforms[id].matrix_stride = glsl_align(items * N, 16);
this->uniforms[id].row_major = row_major;
@@ -1154,7 +1155,8 @@ link_assign_uniform_locations(struct gl_shader_program *prog,
foreach_in_list(ir_instruction, node, prog->_LinkedShaders[i]->ir) {
ir_variable *const var = node->as_variable();
- if ((var == NULL) || (var->data.mode != ir_var_uniform && var->data.mode != ir_var_shader_storage))
+ if ((var == NULL) || (var->data.mode != ir_var_uniform &&
+ var->data.mode != ir_var_shader_storage))
continue;
parcel.set_and_process(prog, var);
@@ -1163,7 +1165,8 @@ link_assign_uniform_locations(struct gl_shader_program *prog,
prog->_LinkedShaders[i]->active_samplers = parcel.shader_samplers_used;
prog->_LinkedShaders[i]->shadow_samplers = parcel.shader_shadow_samplers;
- STATIC_ASSERT(sizeof(prog->_LinkedShaders[i]->SamplerTargets) == sizeof(parcel.targets));
+ STATIC_ASSERT(sizeof(prog->_LinkedShaders[i]->SamplerTargets) ==
+ sizeof(parcel.targets));
memcpy(prog->_LinkedShaders[i]->SamplerTargets, parcel.targets,
sizeof(prog->_LinkedShaders[i]->SamplerTargets));
}