X-Git-Url: http://git.euphorik.ch/?a=blobdiff_plain;f=WCudaMSE%2FStudent_Cuda_Image%2Fsrc%2Fcpp%2Fcore%2FmainGL.cpp;h=b15ca7b3423f9972d57c41cabc8dc25668f2daf9;hb=fd0031be0a39a5d902750affaff6322fcd5229b1;hp=d2b6adfa87016f91fc6386860b3120afeca1ac68;hpb=2d95edd9a2d09421e5eae56755bdf3105e12edf7;p=GPU.git diff --git a/WCudaMSE/Student_Cuda_Image/src/cpp/core/mainGL.cpp b/WCudaMSE/Student_Cuda_Image/src/cpp/core/mainGL.cpp index d2b6adf..b15ca7b 100755 --- a/WCudaMSE/Student_Cuda_Image/src/cpp/core/mainGL.cpp +++ b/WCudaMSE/Student_Cuda_Image/src/cpp/core/mainGL.cpp @@ -12,40 +12,46 @@ using namespace std; #include "RipplingProvider.h" #include "FractalProvider.h" #include "NewtonProvider.h" - +#include "HeatTransfertProvider.h" +#include "RayTracingProvider.h" template class Viewer { private: - TOutput* ptrProvider; + TOutput* ptrOutput; GLUTImageViewers viewer; public: Viewer(bool isAnimation, bool isSelection, int pxFrame, int pyFrame): - ptrProvider(TProvider::createGL()), - viewer(ptrProvider, isAnimation, isSelection, pxFrame, pyFrame) + ptrOutput(TProvider::createGL()), + viewer(ptrOutput, isAnimation, isSelection, pxFrame, pyFrame) + { + } + + Viewer(TOutput* output, bool isAnimation, bool isSelection, int pxFrame, int pyFrame): + ptrOutput(output), + viewer(ptrOutput, isAnimation, isSelection, pxFrame, pyFrame) { } ~Viewer() { - delete this->ptrProvider; + delete this->ptrOutput; } }; int mainGL(void) { - //Viewer rippling0(true, true, 10, 10); - //Viewer rippling0(true, true, 10, 10); - //Viewer fractalMandelbrot(true, true, 20, 20); - //Viewer fractalJulia(true, true, 30, 30); - - - Viewer newtown(true, true, 20, 20); - - - GLUTImageViewers::runALL(); // Bloquant, Tant qu'une fenetre est ouverte + // Viewer rippling0(true, true, 10, 10); + // Viewer rippling0(true, true, 10, 10); + Viewer fractalMandelbrot(MandelbrotProvider::createGL(true), true, true, 20, 20); + // Viewer fractalJulia(true, true, 30, 30); + // Viewer newtown(true, true, 20, 20); + // Viewer heatTransfert(true, false, 20, 20); + // Viewer rayTracing(true, true, 20, 20); + + GLUTImageViewers::runALL(); // Bloquant, Tant qu'une fenetre est ouverte. return EXIT_SUCCESS; }