4 #include "envGLImage.h"
8 #include "Primitives_A.h"
16 /*----------------------------------------------------------------------*\
18 \*---------------------------------------------------------------------*/
20 /*--------------------------------------*\
22 \*-------------------------------------*/
24 class CBI_GLIMAGE Graphic2Ds
28 /*--------------------------------------*\
30 \*-------------------------------------*/
32 Graphic2Ds(int width
, int height
);
34 /*--------------------------------------*\
36 \*-------------------------------------*/
38 virtual ~Graphic2Ds();
40 /*--------------------------------------*\
42 \*-------------------------------------*/
50 void setColor(Colorf colorf
);
52 void setColorRGB(float r01
, float g01
, float b01
, float a01
= 1.0f
);
54 void setColorHSB(float h01
, float s01
, float b01
, float a01
= 1.0f
);
56 void drawLigne(int x1
, int y1
, int x2
, int y2
);
58 void drawVerticalLigne(int x
, int y
, int height
);
60 void drawHorizontalLigne(int x
, int y
, int width
);
62 void drawWiredRect2D(int x
, int y
, int width
, int height
);
64 void drawRect2D(int x
, int y
, int width
, int height
);
66 void drawText(int x
, int y
, string texte
, const Font_A
* font
);
68 void drawTitleTop(string texte
, const Font_A
* font
);
70 void drawTitleMiddle(string texte
, const Font_A
* font
);
72 void drawTitleBottom(string texte
, const Font_A
* font
);
74 const Font_A
* getFont(string fontname
);
76 const Font_A
* getFont(FontType type
= HELVETICA_12
);
78 int texteWidth(string texte
, const Font_A
* font
);
80 int texteHeight(string texte
, const Font_A
* font
);
86 unsigned int getSize();
90 void reshape(int width
, int height
);
92 void startPainPrimitive(Panel_A
&ptrPanel
);
94 void drawPrimitive(Primitives_A
* primitive
);
96 Primitives_A
* popPrimitive();
100 /*--------------------------------------*\
102 \*-------------------------------------*/
112 queue
<Colorf
> queueColors
;
113 queue
<Primitives_A
*> queuePrimitives
;
121 /*----------------------------------------------------------------------*\
123 \*---------------------------------------------------------------------*/