fix for surfaces that don't support shadow mask (ray traced or screen space shadows) such as envmaps, transparents;
change default ao power to 1;
This commit is contained in:
@@ -31,7 +31,7 @@ private:
|
||||
XMFLOAT4 outlineColor = XMFLOAT4(0, 0, 0, 1);
|
||||
float aoRange = 1.0f;
|
||||
uint32_t aoSampleCount = 16;
|
||||
float aoPower = 2.0f;
|
||||
float aoPower = 1.0f;
|
||||
float chromaticAberrationAmount = 2.0f;
|
||||
uint32_t screenSpaceShadowSampleCount = 16;
|
||||
float screenSpaceShadowRange = 1;
|
||||
|
||||
@@ -135,10 +135,10 @@ inline void DirectionalLight(in ShaderEntity light, in Surface surface, inout Li
|
||||
[branch]
|
||||
if (light.IsCastingShadow() && surface.IsReceiveShadow())
|
||||
{
|
||||
#ifndef RTAPI
|
||||
#ifdef SHADOW_MASK_ENABLED
|
||||
[branch]
|
||||
if ((g_xFrame_Options & OPTION_BIT_RAYTRACED_SHADOWS) == 0)
|
||||
#endif // RTAPI
|
||||
#endif // SHADOW_MASK_ENABLED
|
||||
{
|
||||
// Loop through cascades from closest (smallest) to furthest (largest)
|
||||
[loop]
|
||||
@@ -221,10 +221,10 @@ inline void PointLight(in ShaderEntity light, in Surface surface, inout Lighting
|
||||
[branch]
|
||||
if (light.IsCastingShadow() && surface.IsReceiveShadow())
|
||||
{
|
||||
#ifndef RTAPI
|
||||
#ifdef SHADOW_MASK_ENABLED
|
||||
[branch]
|
||||
if ((g_xFrame_Options & OPTION_BIT_RAYTRACED_SHADOWS) == 0)
|
||||
#endif // RTAPI
|
||||
#endif // SHADOW_MASK_ENABLED
|
||||
{
|
||||
shadow *= shadowCube(light, L, Lunnormalized);
|
||||
}
|
||||
@@ -277,10 +277,10 @@ inline void SpotLight(in ShaderEntity light, in Surface surface, inout Lighting
|
||||
[branch]
|
||||
if (light.IsCastingShadow() && surface.IsReceiveShadow())
|
||||
{
|
||||
#ifndef RTAPI
|
||||
#ifdef SHADOW_MASK_ENABLED
|
||||
[branch]
|
||||
if ((g_xFrame_Options & OPTION_BIT_RAYTRACED_SHADOWS) == 0)
|
||||
#endif // RTAPI
|
||||
#endif // SHADOW_MASK_ENABLED
|
||||
{
|
||||
float4 ShPos = mul(MatrixArray[light.GetMatrixIndex() + 0], float4(surface.P, 1));
|
||||
ShPos.xyz /= ShPos.w;
|
||||
|
||||
@@ -334,7 +334,7 @@ namespace wiRenderer
|
||||
wiGraphics::CommandList cmd,
|
||||
float range = 1.0f,
|
||||
uint32_t samplecount = 16,
|
||||
float power = 2.0f
|
||||
float power = 1.0f
|
||||
);
|
||||
void Postprocess_HBAO(
|
||||
const SSAOResources& res,
|
||||
@@ -342,7 +342,7 @@ namespace wiRenderer
|
||||
const wiGraphics::Texture& lineardepth,
|
||||
const wiGraphics::Texture& output,
|
||||
wiGraphics::CommandList cmd,
|
||||
float power = 2.0f
|
||||
float power = 1.0f
|
||||
);
|
||||
struct MSAOResources
|
||||
{
|
||||
@@ -373,7 +373,7 @@ namespace wiRenderer
|
||||
const wiGraphics::Texture& lineardepth,
|
||||
const wiGraphics::Texture& output,
|
||||
wiGraphics::CommandList cmd,
|
||||
float power = 2.0f
|
||||
float power = 1.0f
|
||||
);
|
||||
struct RTAOResources
|
||||
{
|
||||
@@ -396,7 +396,7 @@ namespace wiRenderer
|
||||
const wiGraphics::Texture& output,
|
||||
wiGraphics::CommandList cmd,
|
||||
float range = 1.0f,
|
||||
float power = 2.0f
|
||||
float power = 1.0f
|
||||
);
|
||||
struct RTReflectionResources
|
||||
{
|
||||
|
||||
@@ -9,7 +9,7 @@ namespace wiVersion
|
||||
// minor features, major updates, breaking compatibility changes
|
||||
const int minor = 56;
|
||||
// minor bug fixes, alterations, refactors, updates
|
||||
const int revision = 82;
|
||||
const int revision = 83;
|
||||
|
||||
const std::string version_string = std::to_string(major) + "." + std::to_string(minor) + "." + std::to_string(revision);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user