From 3412c6811e1887ceba12c6666d0366f46ff06d6e Mon Sep 17 00:00:00 2001 From: Don BURNS Date: Mon, 6 Dec 2004 19:32:59 +0000 Subject: [PATCH] Changed the strcmp() to use std::string instead. --- src/osg/LightModel.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/osg/LightModel.cpp b/src/osg/LightModel.cpp index 9675860bf..52bc99787 100644 --- a/src/osg/LightModel.cpp +++ b/src/osg/LightModel.cpp @@ -10,6 +10,7 @@ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * OpenSceneGraph Public License for more details. */ +#include #include #include @@ -48,7 +49,8 @@ void LightModel::apply(State&) const { glLightModelfv(GL_LIGHT_MODEL_AMBIENT,_ambient.ptr()); - static bool s_separateSpecularSupported = strcmp((const char *)glGetString(GL_VERSION),"1.2")>=0; + //static bool s_separateSpecularSupported = strcmp((const char *)glGetString(GL_VERSION),"1.2")>=0; + static bool s_separateSpecularSupported = (std::string((const char *)glGetString(GL_VERSION)) == "1.2"); if (s_separateSpecularSupported) { if (_colorControl==SEPARATE_SPECULAR_COLOR)