diff options
Diffstat (limited to 'source/blender/gpu')
-rw-r--r-- | source/blender/gpu/intern/gpu_buffers.c | 2 | ||||
-rw-r--r-- | source/blender/gpu/shaders/gpu_shader_material.glsl | 8 |
2 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/gpu/intern/gpu_buffers.c b/source/blender/gpu/intern/gpu_buffers.c index 072ff5235bf..09d0a383426 100644 --- a/source/blender/gpu/intern/gpu_buffers.c +++ b/source/blender/gpu/intern/gpu_buffers.c @@ -823,7 +823,7 @@ void GPU_interleaved_attrib_setup(GPUBuffer *buffer, GPUAttrib data[], int numda for (i = 0; i < numdata; i++) { glEnableVertexAttribArray(data[i].index); glVertexAttribPointer(data[i].index, data[i].size, data[i].type, - GL_FALSE, elementsize, BUFFER_OFFSET(offset)); + GL_TRUE, elementsize, BUFFER_OFFSET(offset)); offset += data[i].size * GPU_typesize(data[i].type); attribData[i].index = data[i].index; diff --git a/source/blender/gpu/shaders/gpu_shader_material.glsl b/source/blender/gpu/shaders/gpu_shader_material.glsl index dcb888b1a9b..be7228b979a 100644 --- a/source/blender/gpu/shaders/gpu_shader_material.glsl +++ b/source/blender/gpu/shaders/gpu_shader_material.glsl @@ -2573,11 +2573,11 @@ void node_gamma(vec4 col, float gamma, out vec4 outcol) /* geometry */ -void node_attribute(vec3 attr_uv, out vec4 outcol, out vec3 outvec, out float outf) +void node_attribute(vec3 attr, out vec4 outcol, out vec3 outvec, out float outf) { - outcol = vec4(attr_uv, 1.0); - outvec = attr_uv; - outf = (attr_uv.x + attr_uv.y + attr_uv.z)/3.0; + outcol = vec4(attr, 1.0); + outvec = attr; + outf = (attr.x + attr.y + attr.z)/3.0; } void node_uvmap(vec3 attr_uv, out vec3 outvec) |