Files
UnrealEngineUWP/Engine/Source/Runtime/Renderer/Private/PostProcess/PostProcessFFTBloom.h
tiago costa e963280676 Apply local exposure when calculating bloom.
- Otherwise bloom intensity will not properly match the bright regions of the final image.
- Can be disabled using r.Bloom.ApplyLocalExposure.
- For gaussian bloom, local exposure is applied during the setup pass.
- For FFT bloom, local exposure is applied using an extra pass before convolution.

- Implemented AddApplyLocalExposurePass which apply local exposure to an input texture.

#rb Guillaume.Abadie
#preflight 62b5f2e8bd4bf89e21c78caa
#jira FORT-460700

[CL 20812852 by tiago costa in ue5-main branch]
2022-06-24 13:53:19 -04:00

31 lines
797 B
C++

// Copyright Epic Games, Inc. All Rights Reserved.
#pragma once
#include "RenderGraph.h"
#include "ScenePrivate.h"
#include "ScreenPass.h"
class FEyeAdaptationParameters;
// Returns whether FFT bloom is enabled for the view.
bool IsFFTBloomEnabled(const FViewInfo& View);
float GetFFTBloomResolutionFraction(const FIntPoint& ViewSize);
struct FFFTBloomOutput
{
FScreenPassTexture BloomTexture;
FRDGBufferRef SceneColorApplyParameters = nullptr;
};
FFFTBloomOutput AddFFTBloomPass(
FRDGBuilder& GraphBuilder,
const FViewInfo& View,
const FScreenPassTexture& InputSceneColor,
float InputResolutionFraction,
const FEyeAdaptationParameters& EyeAdaptationParameters,
FRDGTextureRef EyeAdaptationTexture,
FRDGTextureRef LocalExposureTexture,
FRDGTextureRef BlurredLogLuminanceTexture);