24 #ifndef PXR_IMAGING_GLF_SIMPLE_SHADOW_ARRAY_H
25 #define PXR_IMAGING_GLF_SIMPLE_SHADOW_ARRAY_H
55 GlfSimpleShadowArray&
operator=(
const GlfSimpleShadowArray&) =
delete;
121 void _AllocResources();
122 void _AllocTextures();
123 void _FreeResources();
124 void _FreeTextures();
125 bool _ShadowMapExists()
const;
126 void _BindFramebuffer(
size_t index);
127 void _UnbindFramebuffer();
130 std::vector<GfVec2i> _resolutions;
131 std::vector<GLuint> _textures;
133 std::vector<GfMatrix4d> _viewMatrix;
134 std::vector<GfMatrix4d> _projectionMatrix;
138 GLuint _shadowDepthSampler;
139 GLuint _shadowCompareSampler;
141 GLuint _unbindRestoreDrawFramebuffer;
142 GLuint _unbindRestoreReadFramebuffer;
144 GLint _unbindRestoreViewport[4];
146 bool _texturesAllocatedExternally;
GLF_API GfVec2i GetShadowMapSize(size_t pass) const
GLF_API size_t GetNumShadowMapPasses() const
GLF_API GLuint GetShadowMapDepthSampler() const
GLF_API GLuint GetShadowMapTexture(int shadowIndex) const
GLF_API GlfSimpleShadowArray()
GLF_API void SetShadowMapResolutions(std::vector< GfVec2i > const &resolutions)
GLF_API void SetTextures(std::vector< GLuint > textureIds)
GLF_API GfMatrix4d GetProjectionMatrix(size_t index) const
GLF_API ~GlfSimpleShadowArray() override
GLF_API GfMatrix4d GetWorldToShadowMatrix(size_t index) const
GLF_API void SetViewMatrix(size_t index, GfMatrix4d const &matrix)
GLF_API void AllocSamplers()
GLF_API void SetProjectionMatrix(size_t index, GfMatrix4d const &matrix)
PXR_NAMESPACE_CLOSE_SCOPE PXR_NAMESPACE_OPEN_SCOPE
GLF_API GLuint GetShadowMapCompareSampler() const
#define PXR_NAMESPACE_CLOSE_SCOPE
GLF_API GfMatrix4d GetViewMatrix(size_t index) const
GLF_API void EndCapture(size_t index)
GlfSimpleShadowArray & operator=(const GlfSimpleShadowArray &)=delete
GLF_API void BeginCapture(size_t index, bool clear)