aboutsummaryrefslogtreecommitdiff
path: root/src/OutputInfo.h
diff options
context:
space:
mode:
authorlbavoil <[email protected]>2018-03-15 11:08:34 +0100
committerlbavoil <[email protected]>2018-03-15 11:08:34 +0100
commit636807e68a85a978473764d171ed0c7cc36f9be6 (patch)
tree784a3d4fa8f48b4c085dd959678505b2af12f425 /src/OutputInfo.h
parentRemove test folder (diff)
downloadhbaoplus-636807e68a85a978473764d171ed0c7cc36f9be6.tar.xz
hbaoplus-636807e68a85a978473764d171ed0c7cc36f9be6.zip
HBAO+ 4.0.0.23740451
Diffstat (limited to 'src/OutputInfo.h')
-rw-r--r--src/OutputInfo.h70
1 files changed, 4 insertions, 66 deletions
diff --git a/src/OutputInfo.h b/src/OutputInfo.h
index b347225..a73ca57 100644
--- a/src/OutputInfo.h
+++ b/src/OutputInfo.h
@@ -1,5 +1,5 @@
/*
-* Copyright (c) 2008-2017, NVIDIA CORPORATION. All rights reserved.
+* Copyright (c) 2008-2018, NVIDIA CORPORATION. All rights reserved.
*
* NVIDIA CORPORATION and its licensors retain all intellectual property
* and proprietary rights in and to this software, related documentation
@@ -22,22 +22,13 @@ namespace D3D11
{
//--------------------------------------------------------------------------------
-enum BlendPassEnumType
-{
- BLEND_PASS_0,
- BLEND_PASS_1,
- BLEND_PASS_COUNT,
-};
-
-//--------------------------------------------------------------------------------
struct OutputInfo
{
GFSDK::SSAO::D3D11::UserTextureRTV RenderTarget;
GFSDK::SSAO::D3D11::UserTextureDSV DepthStencilBuffer;
- UINT BlendPassCount;
- GFSDK_SSAO_BlendState_D3D11 Blend[BLEND_PASS_COUNT];
- GFSDK_SSAO_DepthStencilState_D3D11 DepthStencil[BLEND_PASS_COUNT];
+ GFSDK_SSAO_BlendState_D3D11 Blend;
+ GFSDK_SSAO_DepthStencilState_D3D11 DepthStencil;
OutputInfo()
{
@@ -65,36 +56,13 @@ struct OutputInfo
GFSDK_SSAO_Status InitBlendState(const GFSDK_SSAO_Output_D3D11& Output)
{
- if (Output.TwoPassBlend.Enable)
- {
- return InitTwoPassBlend(Output.TwoPassBlend);
- }
-
return InitSinglePassBlend(Output.Blend);
}
private:
GFSDK_SSAO_Status InitSinglePassBlend(const GFSDK_SSAO_BlendState_D3D11& BlendState)
{
- BlendPassCount = 1;
- Blend[BLEND_PASS_0] = BlendState;
-
- return GFSDK_SSAO_OK;
- }
-
- GFSDK_SSAO_Status InitTwoPassBlend(const GFSDK_SSAO_TwoPassBlend_D3D11& TwoPassBlend)
- {
- GFSDK_SSAO_Status Status = DepthStencilBuffer.Init(TwoPassBlend.pDepthStencilView);
- if (Status != GFSDK_SSAO_OK)
- {
- return Status;
- }
-
- BlendPassCount = 2;
- Blend[BLEND_PASS_0] = TwoPassBlend.FirstPass.Blend;
- Blend[BLEND_PASS_1] = TwoPassBlend.SecondPass.Blend;
- DepthStencil[BLEND_PASS_0] = TwoPassBlend.FirstPass.DepthStencil;
- DepthStencil[BLEND_PASS_1] = TwoPassBlend.SecondPass.DepthStencil;
+ Blend = BlendState;
return GFSDK_SSAO_OK;
}
@@ -136,35 +104,5 @@ struct OutputInfo
} // namespace D3D12
#endif // SUPPORT_D3D12
-//--------------------------------------------------------------------------------
-#if SUPPORT_GL
-namespace GL
-{
-
-struct OutputInfo
-{
- OutputInfo()
- : FboId(0)
- , SampleCount(0)
- {
- }
-
- GFSDK_SSAO_Status Init(const GFSDK_SSAO_Output_GL& Output)
- {
- FboId = Output.OutputFBO;
- SampleCount = 1;
- Blend = Output.Blend;
-
- return GFSDK_SSAO_OK;
- }
-
- GLuint FboId;
- UINT SampleCount;
- GFSDK_SSAO_BlendState_GL Blend;
-};
-
-} // namespace GL
-#endif // SUPPORT_GL
-
} // namespace SSAO
} // namespace GFSDK