Skip to content

Commit 039f1b7

Browse files
* 第10章,习题5。已注释
1 parent 6aadeb2 commit 039f1b7

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

Chapter 10 Blending/GameApp.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -95,6 +95,8 @@ void GameApp::Startup(void)
9595
GraphicsPSO transparentPSO = defaultPSO;
9696
auto blend = Graphics::BlendTraditional;
9797
blend.RenderTarget[0].DestBlendAlpha = D3D12_BLEND_ZERO;
98+
// 习题5 只允许写入蓝和alpha通道
99+
//blend.RenderTarget[0].RenderTargetWriteMask = (D3D12_COLOR_WRITE_ENABLE_BLUE | D3D12_COLOR_WRITE_ENABLE_ALPHA);
98100
transparentPSO.SetBlendState(blend);
99101
transparentPSO.Finalize();
100102
m_mapPSO[E_EPT_TRANSPARENT] = transparentPSO;

0 commit comments

Comments
 (0)