Move isTriangleMode to utilities.h.

TRAC #22245
Signed-off-by: Daniel Koch
Signed-off-by: Geoff Lang
Author: Nicolas Capens

git-svn-id: https://angleproject.googlecode.com/svn/branches/dx11proto@1581 736b8ea6-26fd-11df-bfd4-992fa37f6226
diff --git a/src/libGLESv2/Context.cpp b/src/libGLESv2/Context.cpp
index f75545f..b500083 100644
--- a/src/libGLESv2/Context.cpp
+++ b/src/libGLESv2/Context.cpp
@@ -1734,7 +1734,7 @@
     Framebuffer *framebufferObject = getDrawFramebuffer();
 
     GLint frontCCW = programBinary->getDxFrontCCWLocation();
-    GLfloat ccw = !isTriangleMode(drawMode) ? 0.0f : (mState.rasterizer.frontFace == GL_CCW ? 1.0f : -1.0f);
+    GLfloat ccw = !IsTriangleMode(drawMode) ? 0.0f : (mState.rasterizer.frontFace == GL_CCW ? 1.0f : -1.0f);
     programBinary->setUniform1fv(frontCCW, 1, &ccw);
 
     mRenderer->setRasterizerState(mState.rasterizer);
@@ -2498,7 +2498,7 @@
             return true;
         }
     }
-    else if (isTriangleMode(drawMode))
+    else if (IsTriangleMode(drawMode))
     {
         if (mState.rasterizer.cullFace && mState.rasterizer.cullMode == GL_FRONT_AND_BACK)
         {
@@ -2509,25 +2509,6 @@
     return false;
 }
 
-bool Context::isTriangleMode(GLenum drawMode)
-{
-    switch (drawMode)
-    {
-      case GL_TRIANGLES:
-      case GL_TRIANGLE_FAN:
-      case GL_TRIANGLE_STRIP:
-        return true;
-      case GL_POINTS:
-      case GL_LINES:
-      case GL_LINE_LOOP:
-      case GL_LINE_STRIP:
-        return false;
-      default: UNREACHABLE();
-    }
-
-    return false;
-}
-
 void Context::setVertexAttrib(GLuint index, const GLfloat *values)
 {
     ASSERT(index < gl::MAX_VERTEX_ATTRIBS);