12345678910111213141516171819202122232425262728293031323334353637383940414243 |
- #ifndef MOSAIC_H_INCLUDED
- #define MOSAIC_H_INCLUDED
- // Includes OpenGL
- #ifdef WIN32
- #include <GL/glew.h>
- #else
- #define GL3_PROTOTYPES 1
- #include <GL/gl.h>
- #endif
- // Includes GLM
- #include <glm/glm.hpp>
- #include <glm/gtx/transform.hpp>
- #include <glm/gtc/type_ptr.hpp>
- // Includes
- #include <SDL2/SDL.h>
- #include <iostream>
- #include "ColorCube.h"
- #include "Shader.h"
- #define DIM 32
- class Mosaic
- {
- public:
- Mosaic(std::string const vertexShader, std::string const fragmentShader, std::string const fichierImg, Uint8 redMask, Uint8 greenMask, Uint8 blueMask);
- ~Mosaic();
- void afficher(glm::mat4 &projection, glm::mat4 modelview);
- private:
- Shader m_shader;
- ColorCube m_mosaic[DIM][DIM];//y;x
- bool m_opaque[DIM][DIM];
- };
- #endif // MOSAIC_H_INCLUDED
|