--- /dev/null
+#include <iostream>\r
+#include <assert.h>\r
+#include <math.h>\r
+\r
+#include "Image.h"\r
+#include "StringTools.h"\r
+#include "MathTools.h"\r
+\r
+using std::cout;\r
+using std::endl;\r
+\r
+/*----------------------------------------------------------------------*\\r
+ |* Declaration *|\r
+ \*---------------------------------------------------------------------*/\r
+\r
+/*--------------------------------------*\\r
+ |* Imported *|\r
+ \*-------------------------------------*/\r
+\r
+/*--------------------------------------*\\r
+ |* Public *|\r
+ \*-------------------------------------*/\r
+\r
+/*--------------------------------------*\\r
+ |* Private *|\r
+ \*-------------------------------------*/\r
+\r
+/*----------------------------------------------------------------------*\\r
+ |* Implementation *|\r
+ \*---------------------------------------------------------------------*/\r
+\r
+/*--------------------------------------*\\r
+ |* Public *|\r
+ \*-------------------------------------*/\r
+\r
+Image::Image(Animable_I* ptrAnimable,ColorRGB_01* ptrColorTitreRGB) :\r
+ ImageMOOs_A(ptrAnimable->getW(), ptrAnimable->getH())\r
+ {\r
+ this->ptrAnimable = ptrAnimable;\r
+ this->ptrColorTitreRGB=ptrColorTitreRGB;\r
+ }\r
+\r
+Image::~Image(void)\r
+ {\r
+ delete ptrAnimable;\r
+ }\r
+\r
+/**\r
+ * Override\r
+ */\r
+void Image::animationStep(bool& isNeedUpdateView)\r
+ {\r
+ // cout << "[CBI] : Image : animationStep" <<endl;\r
+\r
+ ptrAnimable->animationStep();\r
+ isNeedUpdateView = true; // true par default\r
+ }\r
+\r
+/**\r
+ * Override\r
+ */\r
+void Image::fillImageGL(uchar4* ptrDevImageGL, int w, int h)\r
+ {\r
+ // cout << "[CBI] : Image : fillImageGL" <<endl;\r
+\r
+ ptrAnimable->runGPU(ptrDevImageGL);\r
+ }\r
+\r
+/**\r
+ * Override\r
+ */\r
+void Image::paintPrimitives(Graphic2Ds& graphic2D) // redefinition\r
+ {\r
+ const Font_A* ptrfont = graphic2D.getFont(TIMES_ROMAN_24);\r
+\r
+ float r = ptrColorTitreRGB->r;\r
+ float g = ptrColorTitreRGB->g;\r
+ float b = ptrColorTitreRGB->b;\r
+ graphic2D.setColorRGB(r, g, b);\r
+\r
+ // top\r
+ {\r
+ float t = ptrAnimable->getT();\r
+ string message = "t = " + StringTools::toString(t);\r
+ graphic2D.drawTitleTop(message, ptrfont);\r
+ }\r
+\r
+ // bottom\r
+ {\r
+ string title = ptrAnimable->getTitle();\r
+ graphic2D.drawTitleBottom(title, ptrfont);\r
+ }\r
+ }\r
+\r
+/*--------------------------------------*\\r
+ |* Private *|\r
+ \*-------------------------------------*/\r
+\r
+/*----------------------------------------------------------------------*\\r
+ |* End *|\r
+ \*---------------------------------------------------------------------*/\r