sunShadow.h 502 B

123456789101112131415161718192021222324252627
  1. #pragma once
  2. #include <rendering/renderer.h>
  3. struct SunShadow
  4. {
  5. Renderer::FBO shadowMapCascades[3];
  6. Renderer::FBO shadowTexturePreview;
  7. Shader renderShadowIntoTextureShader;
  8. GLuint64 bindlessShadowTextures[3] = {};
  9. GLint u_depthTexture;
  10. GLint u_far;
  11. GLint u_close;
  12. void init();
  13. void update();
  14. glm::mat4 lightSpaceMatrixCascades[3]{glm::mat4(1.f)};
  15. glm::ivec3 lightSpacePositionCascades[3] = {};
  16. void renderShadowIntoTexture(Camera &camera);
  17. //glm::mat4 getLightSpaceMatrix();
  18. };