History

Final cleans and tests using R11G11B10 for lighting buffer

samcake committed 10 years ago

Commit 0492bb11 parent f6c80e02 files · +7 −9Browse files

Showing the changes to libraries/render-utils/src/FramebufferCache.cpp (1 of 2 files). Show all

Unified · Split

libraries/render-utils/src/FramebufferCache.cpp+3−2
@@ -89,9 +89,10 @@ void FramebufferCache::createPrimaryFramebuffer() { · 88 unmodified lines
8989
9090 auto smoothSampler = gpu::Sampler(gpu::Sampler::FILTER_MIN_MAG_MIP_LINEAR);
9191
92+ // FIXME: Decide on the proper one, let s stick to R11G11B10 for now
9293 //_lightingTexture = gpu::TexturePointer(gpu::Texture::create2D(gpu::Element::COLOR_RGBA_32, width, height, defaultSampler));
93− //lightingTexture = gpu::TexturePointer(gpu::Texture::create2D(gpu::Element(gpu::VEC3, gpu::NUINT8, gpu::R11G11B10), width, height, defaultSampler));
94− _lightingTexture = gpu::TexturePointer(gpu::Texture::create2D(gpu::Element(gpu::VEC4, gpu::HALF, gpu::RGBA), width, height, smoothSampler));
94+ _lightingTexture = gpu::TexturePointer(gpu::Texture::create2D(gpu::Element(gpu::VEC3, gpu::NUINT8, gpu::R11G11B10), width, height, defaultSampler));
95+ //_lightingTexture = gpu::TexturePointer(gpu::Texture::create2D(gpu::Element(gpu::VEC4, gpu::HALF, gpu::RGBA), width, height, defaultSampler));
9596 _lightingFramebuffer = gpu::FramebufferPointer(gpu::Framebuffer::create());
9697 _lightingFramebuffer->setRenderBuffer(0, _lightingTexture);
9798 _lightingFramebuffer->setDepthStencilBuffer(_primaryDepthTexture, depthFormat);