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-27 23:32:14 +0300
committerBrecht Van Lommel <brechtvanlommel@gmail.com>2015-12-06 21:35:15 +0300
commit147f7a1e860587a928f465b0b4d0ecf816c997be (patch)
treef391edb612d8a53a5b31ecfb3fd2a91c3d9683b2 /source/blender/blenkernel/intern/pbvh.c
parent42bff8bb1ef759caaf0c6c419349cbf4cc866e9a (diff)
OpenGL: isolate fixed function lighting in simple shader code.
Differential Revision: https://developer.blender.org/D1645
Diffstat (limited to 'source/blender/blenkernel/intern/pbvh.c')
-rw-r--r--source/blender/blenkernel/intern/pbvh.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/blenkernel/intern/pbvh.c b/source/blender/blenkernel/intern/pbvh.c
index b3cb8fbf3f6..d4c62fa57dc 100644
--- a/source/blender/blenkernel/intern/pbvh.c
+++ b/source/blender/blenkernel/intern/pbvh.c
@@ -1682,6 +1682,7 @@ void BKE_pbvh_node_draw(PBVHNode *node, void *data_v)
#if 0
/* XXX: Just some quick code to show leaf nodes in different colors */
float col[3];
+ float spec[3] = {0.0f, 0.0f, 0.0f};
if (0) { //is_partial) {
col[0] = (rand() / (float)RAND_MAX); col[1] = col[2] = 0.6;
@@ -1691,8 +1692,8 @@ void BKE_pbvh_node_draw(PBVHNode *node, void *data_v)
for (int i = 0; i < 3; ++i)
col[i] = (rand() / (float)RAND_MAX) * 0.3 + 0.7;
}
- glMaterialfv(GL_FRONT_AND_BACK, GL_DIFFUSE, col);
+ GPU_simple_shader_colors(col, spec, 0, 1.0f);
glColor3f(1, 0, 0);
#endif