1
0
mirror of https://github.com/LearnOpenGL-CN/LearnOpenGL-CN.git synced 2025-08-23 12:45:29 +08:00

奇怪的缩进

This commit is contained in:
cathy0612
2020-02-04 20:16:57 +08:00
parent 2be023a1c1
commit 6b1e6c4585

View File

@@ -88,9 +88,9 @@ glBindFramebuffer(GL_FRAMEBUFFER, 0);
// 1. first render to depth cubemap // 1. first render to depth cubemap
glViewport(0, 0, SHADOW_WIDTH, SHADOW_HEIGHT); glViewport(0, 0, SHADOW_WIDTH, SHADOW_HEIGHT);
glBindFramebuffer(GL_FRAMEBUFFER, depthMapFBO); glBindFramebuffer(GL_FRAMEBUFFER, depthMapFBO);
glClear(GL_DEPTH_BUFFER_BIT); glClear(GL_DEPTH_BUFFER_BIT);
ConfigureShaderAndMatrices(); ConfigureShaderAndMatrices();
RenderScene(); RenderScene();
glBindFramebuffer(GL_FRAMEBUFFER, 0); glBindFramebuffer(GL_FRAMEBUFFER, 0);
// 2. then render scene as normal with shadow mapping (using depth cubemap) // 2. then render scene as normal with shadow mapping (using depth cubemap)
glViewport(0, 0, SCR_WIDTH, SCR_HEIGHT); glViewport(0, 0, SCR_WIDTH, SCR_HEIGHT);