Showing the changes to libraries/render-utils/src/DebugDeferredBuffer.cpp (1 of 2 files). Show all
Unified · Split
| @@ -422,7 +422,6 @@ void DebugDeferredBuffer::run(const RenderContextPointer& renderContext, const I · 421 unmodified lines | ||
| 422 | 422 | return; |
| 423 | 423 | } |
| 424 | 424 | |
| 425 | −#if 0 | |
| 426 | 425 | assert(renderContext->args); |
| 427 | 426 | assert(renderContext->args->hasViewFrustum()); |
| 428 | 427 | RenderArgs* args = renderContext->args; |
| @@ -465,10 +464,11 @@ void DebugDeferredBuffer::run(const RenderContextPointer& renderContext, const I · 36 unmodified lines | ||
| 465 | 464 | batch.setResourceTexture(Textures::DeferredLighting, deferredFramebuffer->getLightingTexture()); |
| 466 | 465 | } |
| 467 | 466 | if (velocityFramebuffer) { |
| 468 | − batch.setResourceTexture(Textures::TaaVelocity, velocityFramebuffer->getVelocityTexture()); | |
| 467 | + batch.setResourceTexture(Textures::DebugVelocity, velocityFramebuffer->getVelocityTexture()); | |
| 469 | 468 | } |
| 470 | 469 | |
| 471 | − batch.setUniformBuffer(UBOs:: DebugParametersBuffer, _parameters); | |
| 470 | + // FIXME can't find the corresponding buffer | |
| 471 | + // batch.setUniformBuffer(UBOs:: DebugParametersBuffer, _parameters); | |
| 472 | 472 | |
| 473 | 473 | auto lightStage = renderContext->_scene->getStage<LightStage>(); |
| 474 | 474 | assert(lightStage); |
| @@ -482,41 +482,42 @@ void DebugDeferredBuffer::run(const RenderContextPointer& renderContext, const I · 7 unmodified lines | ||
| 482 | 482 | } |
| 483 | 483 | |
| 484 | 484 | if (linearDepthTarget) { |
| 485 | − batch.setResourceTexture(Textures::LLinearDepth, linearDepthTarget->getLinearDepthTexture()); | |
| 486 | − batch.setResourceTexture(HalfLinearDepth, linearDepthTarget->getHalfLinearDepthTexture()); | |
| 487 | − batch.setResourceTexture(HalfNormal, linearDepthTarget->getHalfNormalTexture()); | |
| 485 | + batch.setResourceTexture(Textures::DebugDepth, linearDepthTarget->getLinearDepthTexture()); | |
| 486 | + batch.setResourceTexture(Textures::DebugHalfDepth, linearDepthTarget->getHalfLinearDepthTexture()); | |
| 487 | + batch.setResourceTexture(Textures::DebugHalfNormal, linearDepthTarget->getHalfNormalTexture()); | |
| 488 | 488 | } |
| 489 | 489 | if (surfaceGeometryFramebuffer) { |
| 490 | − batch.setResourceTexture(Curvature, surfaceGeometryFramebuffer->getCurvatureTexture()); | |
| 491 | − batch.setResourceTexture(DiffusedCurvature, surfaceGeometryFramebuffer->getLowCurvatureTexture()); | |
| 490 | + batch.setResourceTexture(Textures::DeferredCurvature, surfaceGeometryFramebuffer->getCurvatureTexture()); | |
| 491 | + batch.setResourceTexture(Textures::DeferredDiffusedCurvature, | |
| 492 | + surfaceGeometryFramebuffer->getLowCurvatureTexture()); | |
| 492 | 493 | } |
| 493 | 494 | if (ambientOcclusionFramebuffer) { |
| 494 | − batch.setResourceTexture(Textures::SsaoOcclusion, ambientOcclusionFramebuffer->getOcclusionTexture()); | |
| 495 | − batch.setResourceTexture(AmbientOcclusionBlurred, ambientOcclusionFramebuffer->getOcclusionBlurredTexture()); | |
| 495 | + batch.setResourceTexture(Textures::DebugOcclusion, ambientOcclusionFramebuffer->getOcclusionTexture()); | |
| 496 | + batch.setResourceTexture(Textures::DebugOcclusionBlurred, | |
| 497 | + ambientOcclusionFramebuffer->getOcclusionBlurredTexture()); | |
| 496 | 498 | } |
| 497 | 499 | const glm::vec4 color(1.0f, 1.0f, 1.0f, 1.0f); |
| 498 | 500 | const glm::vec2 bottomLeft(_size.x, _size.y); |
| 499 | 501 | const glm::vec2 topRight(_size.z, _size.w); |
| 500 | 502 | geometryBuffer->renderQuad(batch, bottomLeft, topRight, color, _geometryId); |
| 501 | 503 | |
| 502 | − batch.setResourceTexture(Albedo, nullptr); | |
| 503 | − batch.setResourceTexture(Normal, nullptr); | |
| 504 | − batch.setResourceTexture(Specular, nullptr); | |
| 505 | − batch.setResourceTexture(Depth, nullptr); | |
| 506 | − batch.setResourceTexture(Lighting, nullptr); | |
| 507 | − batch.setResourceTexture(Shadow, nullptr); | |
| 508 | − batch.setResourceTexture(LinearDepth, nullptr); | |
| 509 | − batch.setResourceTexture(HalfLinearDepth, nullptr); | |
| 510 | − batch.setResourceTexture(HalfNormal, nullptr); | |
| 504 | + batch.setResourceTexture(Textures::DeferredColor, nullptr); | |
| 505 | + batch.setResourceTexture(Textures::DeferredNormal, nullptr); | |
| 506 | + batch.setResourceTexture(Textures::DeferredSpecular, nullptr); | |
| 507 | + batch.setResourceTexture(Textures::DeferredDepth, nullptr); | |
| 508 | + batch.setResourceTexture(Textures::DeferredLighting, nullptr); | |
| 509 | + batch.setResourceTexture(Textures::Shadow, nullptr); | |
| 510 | + batch.setResourceTexture(Textures::DebugDepth, nullptr); | |
| 511 | + batch.setResourceTexture(Textures::DebugHalfDepth, nullptr); | |
| 512 | + batch.setResourceTexture(Textures::DebugHalfNormal, nullptr); | |
| 511 | 513 | |
| 512 | − batch.setResourceTexture(Curvature, nullptr); | |
| 513 | − batch.setResourceTexture(DiffusedCurvature, nullptr); | |
| 514 | + batch.setResourceTexture(Textures::DeferredCurvature, nullptr); | |
| 515 | + batch.setResourceTexture(Textures::DeferredDiffusedCurvature, nullptr); | |
| 514 | 516 | |
| 515 | − batch.setResourceTexture(AmbientOcclusion, nullptr); | |
| 516 | − batch.setResourceTexture(AmbientOcclusionBlurred, nullptr); | |
| 517 | + batch.setResourceTexture(Textures::DebugOcclusion, nullptr); | |
| 518 | + batch.setResourceTexture(Textures::DebugOcclusionBlurred, nullptr); | |
| 517 | 519 | |
| 518 | − batch.setResourceTexture(Velocity, nullptr); | |
| 520 | + batch.setResourceTexture(Textures::DebugVelocity, nullptr); | |
| 519 | 521 | |
| 520 | 522 | }); |
| 521 | −#endif | |
| 522 | 523 | } |