From e51767b3c0315934d43d714f0834ea1fb4d72f8f Mon Sep 17 00:00:00 2001 From: Maganty Rushyendra Date: Mon, 25 May 2020 15:44:30 +0800 Subject: [PATCH] Document usage requirement for Viewport to sample ViewportTexture as HDR Modified class documentation to specify that `USAGE_3D` or `USAGE_3D_NO_EFFECTS` is required in order to use HDR in a ViewPort. Fixes #38702 --- doc/classes/Viewport.xml | 1 + 1 file changed, 1 insertion(+) diff --git a/doc/classes/Viewport.xml b/doc/classes/Viewport.xml index c55bc9b6a31..2ef0552fa68 100644 --- a/doc/classes/Viewport.xml +++ b/doc/classes/Viewport.xml @@ -248,6 +248,7 @@ If [code]true[/code], the viewport rendering will receive benefits from High Dynamic Range algorithm. High Dynamic Range allows the viewport to receive values that are outside the 0-1 range. In Godot HDR uses 16 bits, meaning it does not store the full range of a floating point number. + [b]Note:[/b] Requires [member usage] to be set to [constant USAGE_3D] or [constant USAGE_3D_NO_EFFECTS], since HDR is not supported for 2D. If [code]true[/code], the result after 3D rendering will not have a linear to sRGB color conversion applied. This is important when the viewport is used as a render target where the result is used as a texture on a 3D object rendered in another viewport. It is also important if the viewport is used to create data that is not color based (noise, heightmaps, pickmaps, etc.). Do not enable this when the viewport is used as a texture on a 2D object or if the viewport is your final output.