Fix T62930 Eevee: Wireframe input node not working with certain compiler
authorClément Foucault <foucault.clem@gmail.com>
Mon, 25 Mar 2019 18:44:31 +0000 (19:44 +0100)
committerClément Foucault <foucault.clem@gmail.com>
Mon, 25 Mar 2019 18:44:44 +0000 (19:44 +0100)
source/blender/gpu/intern/gpu_codegen.c

index c94668cf6e99e2d8aa6e5e76a58ff7ad33029f98..cf770599fc71f473096dc40b8c76bc9801e23cad 100644 (file)
@@ -1204,8 +1204,8 @@ static char *code_generate_geometry(ListBase *nodes, const char *geom_code, cons
                BLI_dynstr_append(ds, "#ifdef HAIR_SHADER\n");
                BLI_dynstr_append(ds, "\tbarycentricTexCo = barycentricTexCog[vert];\n");
                BLI_dynstr_append(ds, "#else\n");
-               BLI_dynstr_append(ds, "\tbarycentricTexCo.x = float((vert %% 3) == 0);\n");
-               BLI_dynstr_append(ds, "\tbarycentricTexCo.y = float((vert %% 3) == 1);\n");
+               BLI_dynstr_append(ds, "\tbarycentricTexCo.x = float((vert % 3) == 0);\n");
+               BLI_dynstr_append(ds, "\tbarycentricTexCo.y = float((vert % 3) == 1);\n");
                BLI_dynstr_append(ds, "#endif\n");
        }