Showing the changes to libraries/render-utils/src/ToneMapAndResampleTask.cpp (1 of 7 files). Show all
Unified · Split
| @@ -68,13 +68,13 @@ void ToneMapAndResample::run(const RenderContextPointer& renderContext, const In · 67 unmodified lines | |||
| 68 | RenderArgs* args = renderContext->args; | 68 | RenderArgs* args = renderContext->args; |
| 69 | 69 | ||
| 70 | auto lightingBuffer = input.get0()->getRenderBuffer(0); | 70 | auto lightingBuffer = input.get0()->getRenderBuffer(0); |
| 71 | auto resampledFramebuffer = input.get1(); | 71 | auto destinationFramebuffer = input.get1(); |
| 72 | 72 | ||
| 73 | if (!resampledFramebuffer) { | 73 | if (!destinationFramebuffer) { |
| 74 | resampledFramebuffer = args->_blitFramebuffer; | 74 | destinationFramebuffer = args->_blitFramebuffer; |
| 75 | } | 75 | } |
| 76 | 76 | ||
| 77 | if (!lightingBuffer || !resampledFramebuffer) { | 77 | if (!lightingBuffer || !destinationFramebuffer) { |
| 78 | return; | 78 | return; |
| 79 | } | 79 | } |
| 80 | 80 | ||
| @@ -82,7 +82,7 @@ void ToneMapAndResample::run(const RenderContextPointer& renderContext, const In · 1 unmodified line | |||
| 82 | init(); | 82 | init(); |
| 83 | } | 83 | } |
| 84 | 84 | ||
| 85 | const auto bufferSize = resampledFramebuffer->getSize(); | 85 | const auto bufferSize = destinationFramebuffer->getSize(); |
| 86 | 86 | ||
| 87 | auto srcBufferSize = glm::ivec2(lightingBuffer->getDimensions()); | 87 | auto srcBufferSize = glm::ivec2(lightingBuffer->getDimensions()); |
| 88 | 88 | ||
| @@ -90,7 +90,7 @@ void ToneMapAndResample::run(const RenderContextPointer& renderContext, const In · 1 unmodified line | |||
| 90 | 90 | ||
| 91 | gpu::doInBatch("Resample::run", args->_context, [&](gpu::Batch& batch) { | 91 | gpu::doInBatch("Resample::run", args->_context, [&](gpu::Batch& batch) { |
| 92 | batch.enableStereo(false); | 92 | batch.enableStereo(false); |
| 93 | batch.setFramebuffer(resampledFramebuffer); | 93 | batch.setFramebuffer(destinationFramebuffer); |
| 94 | 94 | ||
| 95 | batch.setViewportTransform(destViewport); | 95 | batch.setViewportTransform(destViewport); |
| 96 | batch.setProjectionTransform(glm::mat4()); | 96 | batch.setProjectionTransform(glm::mat4()); |
| @@ -106,5 +106,5 @@ void ToneMapAndResample::run(const RenderContextPointer& renderContext, const In · 9 unmodified lines | |||
| 106 | // Set full final viewport | 106 | // Set full final viewport |
| 107 | args->_viewport = destViewport; | 107 | args->_viewport = destViewport; |
| 108 | 108 | ||
| 109 | output = resampledFramebuffer; | 109 | output = destinationFramebuffer; |
| 110 | } | 110 | } |