21 #ifndef GLABSTRACTPOLYGON_H 
   22 #define GLABSTRACTPOLYGON_H 
   26 #include <tulip/Color.h> 
   27 #include <tulip/Coord.h> 
   28 #include <tulip/Size.h> 
   29 #include <tulip/GlSimpleEntity.h> 
   35 #if defined(__APPLE__) 
   36 #include <OpenGL/gl.h> 
   62   enum PolygonMode {POLYGON = 0, QUAD_STRIP = 1};
 
   67   PolygonMode getPolygonMode();
 
   72   void setPolygonMode(PolygonMode mode);
 
   82   void setFillMode(
const bool);
 
   87   bool getOutlineMode();
 
   92   void setOutlineMode(
const bool);
 
   97   bool getLightingMode();
 
  102   void setLightingMode(
const bool);
 
  107   Color getFillColor(
unsigned int i);
 
  112   void setFillColor(
unsigned int i, 
const Color &color);
 
  119   void setFillColor(
const Color &color);
 
  126   Color getOutlineColor(
unsigned int i);
 
  131   void setOutlineColor(
unsigned int i, 
const Color &color);
 
  138   void setOutlineColor(
const Color &color);
 
  143   std::string getTextureName();
 
  148   void setTextureName(
const std::string &name);
 
  153   float getOutlineSize();
 
  158   void setOutlineSize(
float size);
 
  165   float getHideOutlineLod();
 
  170   void setHideOutlineLod(
float lod);
 
  175   void setInvertYTexture(
bool invertYTexture);
 
  180   virtual void draw(
float lod,
Camera *camera);
 
  185   virtual void translate(
const Coord& mouvement);
 
  190   virtual void scale(
const tlp::Size& factor);
 
  195   virtual void getXML(std::string &outString);
 
  200   virtual void getXMLOnlyData(std::string &outString);
 
  205   virtual void setWithXML(
const std::string &outString, 
unsigned int ¤tPosition);
 
  216   virtual void setPoints(
const std::vector<Coord> &points);
 
  221   virtual void setPoint(
unsigned int index, 
const Coord &point);
 
  226   virtual void setFillColors(
const std::vector<Color> &colors);
 
  231   virtual void setOutlineColors(
const std::vector<Color> &colors);
 
  236   virtual void recomputeBoundingBox();
 
  241   virtual void clearGenerated();
 
  245   PolygonMode polygonMode;
 
  246   std::vector<Coord> points;
 
  247   std::vector<Color> fillColors;
 
  248   std::vector<Color> outlineColors;
 
  253   std::string textureName;
 
  255   float hideOutlineLod;
 
  257   std::vector<Coord> normalArray;