Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrecht Van Lommel <brechtvanlommel@gmail.com>2015-11-25 02:16:48 +0300
committerBrecht Van Lommel <brechtvanlommel@gmail.com>2015-11-25 22:31:46 +0300
commitd4ad89c1eeb306b4e0d85d9c5d04656b47e4b5bf (patch)
tree9c3b20cddeb5a28b8d1f52dd36b1bc9ad1378938 /source/blender/gpu/intern/gpu_codegen.c
parentd2a822fe07eb845180d8b51f8b4c45e51ee5075b (diff)
Fix OpenSubdiv geometry shader error on Linux / AMD.
Differential Revision: https://developer.blender.org/D1638
Diffstat (limited to 'source/blender/gpu/intern/gpu_codegen.c')
-rw-r--r--source/blender/gpu/intern/gpu_codegen.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/source/blender/gpu/intern/gpu_codegen.c b/source/blender/gpu/intern/gpu_codegen.c
index d479415556e..c7f77011197 100644
--- a/source/blender/gpu/intern/gpu_codegen.c
+++ b/source/blender/gpu/intern/gpu_codegen.c
@@ -829,10 +829,11 @@ static char *code_generate_geometry(ListBase *nodes, bool use_opensubdiv)
for (input = node->inputs.first; input; input = input->next) {
if (input->source == GPU_SOURCE_ATTRIB && input->attribfirst) {
if (input->attribtype == CD_MTFACE) {
- BLI_dynstr_appendf(ds, "%s %s var%d;\n",
+ BLI_dynstr_appendf(ds, "%s %s var%d%s;\n",
GLEW_VERSION_3_0 ? "in" : "varying",
GPU_DATATYPE_STR[input->type],
- input->attribid);
+ input->attribid,
+ GLEW_VERSION_3_0 ? "[]" : "");
BLI_dynstr_appendf(ds, "uniform int fvar%d_offset;\n",
input->attribid);
}