From 4aaf24b5d88e5699a16a384d8df9072bab9aaac9 Mon Sep 17 00:00:00 2001 From: Robert Osfield Date: Sat, 20 Sep 2008 10:09:56 +0000 Subject: [PATCH] From Mathias Froehlich, added catch for GL_COLOR_MATERIAL mode being set. --- src/osg/StateSet.cpp | 32 ++++++++++++++++++++++---------- 1 file changed, 22 insertions(+), 10 deletions(-) diff --git a/src/osg/StateSet.cpp b/src/osg/StateSet.cpp index e89ffaafe..260057cd4 100644 --- a/src/osg/StateSet.cpp +++ b/src/osg/StateSet.cpp @@ -790,11 +790,7 @@ void StateSet::merge(const StateSet& rhs) void StateSet::setMode(StateAttribute::GLMode mode, StateAttribute::GLModeValue value) { - if (!getTextureGLModeSet().isTextureMode(mode)) - { - setMode(_modeList,mode,value); - } - else + if (getTextureGLModeSet().isTextureMode(mode)) { notify(NOTICE)<<"Warning: texture mode '"<