1 #ifndef BLOBS_GRAPHICS_PLANETSURFACE_HPP_
2 #define BLOBS_GRAPHICS_PLANETSURFACE_HPP_
17 static constexpr int MAX_LIGHTS = 8;
23 PlanetSurface(const PlanetSurface &) = delete;
24 PlanetSurface &operator =(const PlanetSurface &) = delete;
26 PlanetSurface(PlanetSurface &&) = delete;
27 PlanetSurface &operator =(PlanetSurface &&) = delete;
30 void Activate() noexcept;
32 void SetM(const glm::mat4 &m) noexcept;
33 void SetVP(const glm::mat4 &v, const glm::mat4 &p) noexcept;
34 void SetMVP(const glm::mat4 &m, const glm::mat4 &v, const glm::mat4 &p) noexcept;
35 void SetNormal(const glm::vec3 &) noexcept;
36 void SetTexture(ArrayTexture &) noexcept;
37 void SetLight(int n, const glm::vec3 &pos, const glm::vec3 &color, float strength) noexcept;
38 void SetNumLights(int n) noexcept;
40 const glm::mat4 &M() const noexcept { return m; }
41 const glm::mat4 &V() const noexcept { return v; }
42 const glm::mat4 &P() const noexcept { return p; }
43 const glm::mat4 &MV() const noexcept { return mv; }
44 const glm::mat4 &MVP() const noexcept { return mvp; }
60 GLuint sampler_handle;
63 GLuint num_lights_handle;
64 GLuint light_handle[MAX_LIGHTS * 3];