nvpro-samples / vk_raytrace

Ray tracing glTF scene with Vulkan
Apache License 2.0
551 stars 34 forks source link

is eStore image are float or int format #17

Closed tigrazone closed 2 years ago

tigrazone commented 2 years ago

Hello. My question is about final image. Is used float or integer format for image data?

mklefrancois commented 2 years ago

Hi @tigrazone , the output image has the following format

VkFormat m_offscreenColorFormat{VK_FORMAT_R32G32B32A32_SFLOAT};

You can find the creation of the image under RenderOutput::createOffscreenRender(). We are using float because of the accumulation of the frame. When displaying the rendered image, we run a fragment shader with this image as input and the swap-image attached to the frame-buffer.

tigrazone commented 2 years ago

Thanks a lot!