diff options
34 files changed, 33 insertions, 0 deletions
diff --git a/bin/win32/DemoAppCodeGenDebug_win32.exe b/bin/win32/DemoAppCodeGenDebug_win32.exe Binary files differindex 534eb04..60f8d7d 100644 --- a/bin/win32/DemoAppCodeGenDebug_win32.exe +++ b/bin/win32/DemoAppCodeGenDebug_win32.exe diff --git a/bin/win32/DemoAppCodeGenRelease_win32.exe b/bin/win32/DemoAppCodeGenRelease_win32.exe Binary files differindex 52405fd..32d3e16 100644 --- a/bin/win32/DemoAppCodeGenRelease_win32.exe +++ b/bin/win32/DemoAppCodeGenRelease_win32.exe diff --git a/bin/win32/DemoAppD3D11Debug_win32.dll b/bin/win32/DemoAppD3D11Debug_win32.dll Binary files differindex fc28bdb..52f6a12 100644 --- a/bin/win32/DemoAppD3D11Debug_win32.dll +++ b/bin/win32/DemoAppD3D11Debug_win32.dll diff --git a/bin/win32/DemoAppD3D11Release_win32.dll b/bin/win32/DemoAppD3D11Release_win32.dll Binary files differindex 63828e6..5d1c584 100644 --- a/bin/win32/DemoAppD3D11Release_win32.dll +++ b/bin/win32/DemoAppD3D11Release_win32.dll diff --git a/bin/win32/DemoAppD3D12Debug_win32.dll b/bin/win32/DemoAppD3D12Debug_win32.dll Binary files differindex 5f20d68..eef8fa5 100644 --- a/bin/win32/DemoAppD3D12Debug_win32.dll +++ b/bin/win32/DemoAppD3D12Debug_win32.dll diff --git a/bin/win32/DemoAppD3D12Release_win32.dll b/bin/win32/DemoAppD3D12Release_win32.dll Binary files differindex 0a1baa6..d565b13 100644 --- a/bin/win32/DemoAppD3D12Release_win32.dll +++ b/bin/win32/DemoAppD3D12Release_win32.dll diff --git a/bin/win32/DemoAppDebug_win32.exe b/bin/win32/DemoAppDebug_win32.exe Binary files differindex 0fe30fa..33926a6 100644 --- a/bin/win32/DemoAppDebug_win32.exe +++ b/bin/win32/DemoAppDebug_win32.exe diff --git a/bin/win32/DemoAppRelease_win32.exe b/bin/win32/DemoAppRelease_win32.exe Binary files differindex 90380a3..9b803e0 100644 --- a/bin/win32/DemoAppRelease_win32.exe +++ b/bin/win32/DemoAppRelease_win32.exe diff --git a/bin/win32/NvFlowLibDebug_win32.dll b/bin/win32/NvFlowLibDebug_win32.dll Binary files differindex 21527c7..7c8b83d 100644 --- a/bin/win32/NvFlowLibDebug_win32.dll +++ b/bin/win32/NvFlowLibDebug_win32.dll diff --git a/bin/win32/NvFlowLibRelease_win32.dll b/bin/win32/NvFlowLibRelease_win32.dll Binary files differindex c882d74..6ce3c9b 100644 --- a/bin/win32/NvFlowLibRelease_win32.dll +++ b/bin/win32/NvFlowLibRelease_win32.dll diff --git a/bin/win64/DemoAppCodeGenDebug_win64.exe b/bin/win64/DemoAppCodeGenDebug_win64.exe Binary files differindex 791cfc8..a6871ba 100644 --- a/bin/win64/DemoAppCodeGenDebug_win64.exe +++ b/bin/win64/DemoAppCodeGenDebug_win64.exe diff --git a/bin/win64/DemoAppCodeGenRelease_win64.exe b/bin/win64/DemoAppCodeGenRelease_win64.exe Binary files differindex 242a29d..d9ee7f7 100644 --- a/bin/win64/DemoAppCodeGenRelease_win64.exe +++ b/bin/win64/DemoAppCodeGenRelease_win64.exe diff --git a/bin/win64/DemoAppD3D11Debug_win64.dll b/bin/win64/DemoAppD3D11Debug_win64.dll Binary files differindex 26a709d..7d1d07e 100644 --- a/bin/win64/DemoAppD3D11Debug_win64.dll +++ b/bin/win64/DemoAppD3D11Debug_win64.dll diff --git a/bin/win64/DemoAppD3D11Release_win64.dll b/bin/win64/DemoAppD3D11Release_win64.dll Binary files differindex 520e0fd..e254458 100644 --- a/bin/win64/DemoAppD3D11Release_win64.dll +++ b/bin/win64/DemoAppD3D11Release_win64.dll diff --git a/bin/win64/DemoAppD3D12Debug_win64.dll b/bin/win64/DemoAppD3D12Debug_win64.dll Binary files differindex 3b0d446..acdc5c6 100644 --- a/bin/win64/DemoAppD3D12Debug_win64.dll +++ b/bin/win64/DemoAppD3D12Debug_win64.dll diff --git a/bin/win64/DemoAppD3D12Release_win64.dll b/bin/win64/DemoAppD3D12Release_win64.dll Binary files differindex 421a9a5..390e1ce 100644 --- a/bin/win64/DemoAppD3D12Release_win64.dll +++ b/bin/win64/DemoAppD3D12Release_win64.dll diff --git a/bin/win64/DemoAppDebug_win64.exe b/bin/win64/DemoAppDebug_win64.exe Binary files differindex 764404b..e09ca82 100644 --- a/bin/win64/DemoAppDebug_win64.exe +++ b/bin/win64/DemoAppDebug_win64.exe diff --git a/bin/win64/DemoAppRelease_win64.exe b/bin/win64/DemoAppRelease_win64.exe Binary files differindex 93b8666..4962e81 100644 --- a/bin/win64/DemoAppRelease_win64.exe +++ b/bin/win64/DemoAppRelease_win64.exe diff --git a/bin/win64/NvFlowLibDebug_win64.dll b/bin/win64/NvFlowLibDebug_win64.dll Binary files differindex 17e3627..4b433e5 100644 --- a/bin/win64/NvFlowLibDebug_win64.dll +++ b/bin/win64/NvFlowLibDebug_win64.dll diff --git a/bin/win64/NvFlowLibRelease_win64.dll b/bin/win64/NvFlowLibRelease_win64.dll Binary files differindex b66c9ce..9c648af 100644 --- a/bin/win64/NvFlowLibRelease_win64.dll +++ b/bin/win64/NvFlowLibRelease_win64.dll diff --git a/demo/DemoApp/sceneFlow.cpp b/demo/DemoApp/sceneFlow.cpp index 5cdb70a..41ddaf0 100644 --- a/demo/DemoApp/sceneFlow.cpp +++ b/demo/DemoApp/sceneFlow.cpp @@ -13,6 +13,12 @@ #include "imgui.h" #include "imguiser.h" +#define USE_CUSTOM_BLEND 0 + +#if USE_CUSTOM_BLEND +#include "NvFlowContextExt.h" +#endif + // ******************** FlowContext ************************ void FlowContext::init(AppGraphCtx* appctx) @@ -356,7 +362,20 @@ void FlowGridActor::init(FlowContext* flowContext, AppGraphCtx* appctx) NvFlowVolumeRenderDesc volumeRenderDesc; volumeRenderDesc.gridExport = gridExport; +#if USE_CUSTOM_BLEND + NvFlowBlendStateDesc blendDesc = {}; + blendDesc.enable = true; + blendDesc.srcBlendColor = eNvFlowBlend_One; //eBlendInvSrcAlpha; + blendDesc.dstBlendColor = eNvFlowBlend_SrcAlpha; + blendDesc.blendOpColor = eNvFlowBlendOp_Add; + blendDesc.srcBlendAlpha = eNvFlowBlend_One; // eBlendInvSrcAlpha; + blendDesc.dstBlendAlpha = eNvFlowBlend_One; + blendDesc.blendOpAlpha = eNvFlowBlendOp_RevSubtract; + + m_volumeRender = NvFlowCreateVolumeRenderCustomComposite(flowContext->m_renderContext, &volumeRenderDesc, &blendDesc); +#else m_volumeRender = NvFlowCreateVolumeRender(flowContext->m_renderContext, &volumeRenderDesc); +#endif NvFlowCrossSectionDesc crossSectionDesc = {}; crossSectionDesc.gridExport = gridExport; diff --git a/include/NvFlow.h b/include/NvFlow.h index 435c940..a23b555 100644 --- a/include/NvFlow.h +++ b/include/NvFlow.h @@ -1177,6 +1177,20 @@ struct NvFlowVolumeRenderDesc */ NV_FLOW_API NvFlowVolumeRender* NvFlowCreateVolumeRender(NvFlowContext* context, const NvFlowVolumeRenderDesc* desc); +//! From NvfContextExt +struct NvFlowBlendStateDesc; + +/** +* Creates a volume render object. +* +* @param[in] context The context for GPU resource allocation. +* @param[in] desc Description for memory allocation. +* @param[in] blendDesc Description for composite blending. +* +* @return The created volume render object. +*/ +NV_FLOW_API NvFlowVolumeRender* NvFlowCreateVolumeRenderCustomComposite(NvFlowContext* context, const NvFlowVolumeRenderDesc* desc, const NvFlowBlendStateDesc* blendDesc); + /** * Releases a volume render object. * diff --git a/lib/win32/NvFlowLibDebug_win32.dll b/lib/win32/NvFlowLibDebug_win32.dll Binary files differindex edb7208..7c8b83d 100644 --- a/lib/win32/NvFlowLibDebug_win32.dll +++ b/lib/win32/NvFlowLibDebug_win32.dll diff --git a/lib/win32/NvFlowLibDebug_win32.lib b/lib/win32/NvFlowLibDebug_win32.lib Binary files differindex fa6e878..8d452ad 100644 --- a/lib/win32/NvFlowLibDebug_win32.lib +++ b/lib/win32/NvFlowLibDebug_win32.lib diff --git a/lib/win32/NvFlowLibDebug_win32.pdb b/lib/win32/NvFlowLibDebug_win32.pdb Binary files differindex 11ebf5d..88aeddb 100644 --- a/lib/win32/NvFlowLibDebug_win32.pdb +++ b/lib/win32/NvFlowLibDebug_win32.pdb diff --git a/lib/win32/NvFlowLibRelease_win32.dll b/lib/win32/NvFlowLibRelease_win32.dll Binary files differindex e20854e..6ce3c9b 100644 --- a/lib/win32/NvFlowLibRelease_win32.dll +++ b/lib/win32/NvFlowLibRelease_win32.dll diff --git a/lib/win32/NvFlowLibRelease_win32.lib b/lib/win32/NvFlowLibRelease_win32.lib Binary files differindex 0d11fae..d635524 100644 --- a/lib/win32/NvFlowLibRelease_win32.lib +++ b/lib/win32/NvFlowLibRelease_win32.lib diff --git a/lib/win32/NvFlowLibRelease_win32.pdb b/lib/win32/NvFlowLibRelease_win32.pdb Binary files differindex 1a7c43d..d381e42 100644 --- a/lib/win32/NvFlowLibRelease_win32.pdb +++ b/lib/win32/NvFlowLibRelease_win32.pdb diff --git a/lib/win64/NvFlowLibDebug_win64.dll b/lib/win64/NvFlowLibDebug_win64.dll Binary files differindex 98e4363..4b433e5 100644 --- a/lib/win64/NvFlowLibDebug_win64.dll +++ b/lib/win64/NvFlowLibDebug_win64.dll diff --git a/lib/win64/NvFlowLibDebug_win64.lib b/lib/win64/NvFlowLibDebug_win64.lib Binary files differindex 32e8a29..304d7d1 100644 --- a/lib/win64/NvFlowLibDebug_win64.lib +++ b/lib/win64/NvFlowLibDebug_win64.lib diff --git a/lib/win64/NvFlowLibDebug_win64.pdb b/lib/win64/NvFlowLibDebug_win64.pdb Binary files differindex f753cff..1613e6e 100644 --- a/lib/win64/NvFlowLibDebug_win64.pdb +++ b/lib/win64/NvFlowLibDebug_win64.pdb diff --git a/lib/win64/NvFlowLibRelease_win64.dll b/lib/win64/NvFlowLibRelease_win64.dll Binary files differindex 5b779af..9c648af 100644 --- a/lib/win64/NvFlowLibRelease_win64.dll +++ b/lib/win64/NvFlowLibRelease_win64.dll diff --git a/lib/win64/NvFlowLibRelease_win64.lib b/lib/win64/NvFlowLibRelease_win64.lib Binary files differindex a95a907..9fabd5d 100644 --- a/lib/win64/NvFlowLibRelease_win64.lib +++ b/lib/win64/NvFlowLibRelease_win64.lib diff --git a/lib/win64/NvFlowLibRelease_win64.pdb b/lib/win64/NvFlowLibRelease_win64.pdb Binary files differindex 0b826e2..36174ca 100644 --- a/lib/win64/NvFlowLibRelease_win64.pdb +++ b/lib/win64/NvFlowLibRelease_win64.pdb |