]> git.tdb.fi Git - libs/gl.git/blobdiff - source/core/primitivetype.cpp
Check the flat qualifier from the correct member
[libs/gl.git] / source / core / primitivetype.cpp
index 81375843c9f649609e4ef2c7e60873eca3534dfa..ed4b154561aa0b276d5010d5d7508a27dfe82002 100644 (file)
@@ -1,6 +1,8 @@
 #include <msp/strings/format.h>
 #include "primitivetype.h"
 
+using namespace std;
+
 namespace Msp {
 namespace GL {
 
@@ -10,8 +12,6 @@ void operator>>(const LexicalConverter &conv, PrimitiveType &pt)
                pt = POINTS;
        else if(conv.get()=="LINES")
                pt = LINES;
-       else if(conv.get()=="LINE_LOOP")
-               pt = LINE_LOOP;
        else if(conv.get()=="LINE_STRIP")
                pt = LINE_STRIP;
        else if(conv.get()=="TRIANGLES")
@@ -20,6 +20,8 @@ void operator>>(const LexicalConverter &conv, PrimitiveType &pt)
                pt = TRIANGLE_STRIP;
        else if(conv.get()=="TRIANGLE_FAN")
                pt = TRIANGLE_FAN;
+       else if(conv.get()=="PATCHES")
+               pt = PATCHES;
        else
                throw lexical_error(format("conversion of '%s' to PrimitiveType", conv.get()));
 }