Signed-off-by: Nikolay Sivov nsivov@codeweavers.com --- dlls/d3d10/effect.c | 13 +++++++++++-- dlls/d3d10/tests/effect.c | 4 +--- 2 files changed, 12 insertions(+), 5 deletions(-)
diff --git a/dlls/d3d10/effect.c b/dlls/d3d10/effect.c index dd4e04d6374..70f6c3b3166 100644 --- a/dlls/d3d10/effect.c +++ b/dlls/d3d10/effect.c @@ -4113,9 +4113,18 @@ static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_Apply(ID3D10EffectPass *iface static HRESULT STDMETHODCALLTYPE d3d10_effect_pass_ComputeStateBlockMask(ID3D10EffectPass *iface, D3D10_STATE_BLOCK_MASK *mask) { - FIXME("iface %p, mask %p stub!\n", iface, mask); + struct d3d10_effect_pass *pass = impl_from_ID3D10EffectPass(iface);
- return E_NOTIMPL; + FIXME("iface %p, mask %p semi-stub!\n", iface, mask); + + if (pass->vs.shader != &null_shader_variable) + D3D10StateBlockMaskEnableCapture(mask, D3D10_DST_VS, 0, 1); + if (pass->ps.shader != &null_shader_variable) + D3D10StateBlockMaskEnableCapture(mask, D3D10_DST_PS, 0, 1); + if (pass->gs.shader != &null_shader_variable) + D3D10StateBlockMaskEnableCapture(mask, D3D10_DST_GS, 0, 1); + + return S_OK; }
static const struct ID3D10EffectPassVtbl d3d10_effect_pass_vtbl = diff --git a/dlls/d3d10/tests/effect.c b/dlls/d3d10/tests/effect.c index 06c5aa68776..f3b81a2c58d 100644 --- a/dlls/d3d10/tests/effect.c +++ b/dlls/d3d10/tests/effect.c @@ -3016,7 +3016,6 @@ if (0) hr = D3D10StateBlockMaskDisableAll(&mask); ok(hr == S_OK, "Unexpected hr %#x.\n", hr); hr = p->lpVtbl->ComputeStateBlockMask(p, &mask); -todo_wine ok(hr == S_OK, "Unexpected hr %#x.\n", hr); ret = D3D10StateBlockMaskGetSetting(&mask, D3D10_DST_VS, 0); ok(!ret, "Unexpected mask.\n"); @@ -3164,7 +3163,6 @@ todo_wine hr = D3D10StateBlockMaskDisableAll(&mask); ok(hr == S_OK, "Unexpected hr %#x.\n", hr); hr = p->lpVtbl->ComputeStateBlockMask(p, &mask); -todo_wine { ok(hr == S_OK, "Unexpected hr %#x.\n", hr); ret = D3D10StateBlockMaskGetSetting(&mask, D3D10_DST_VS, 0); ok(ret, "Unexpected mask.\n"); @@ -3172,7 +3170,7 @@ todo_wine { ok(ret, "Unexpected mask.\n"); ret = D3D10StateBlockMaskGetSetting(&mask, D3D10_DST_GS, 0); ok(ret, "Unexpected mask.\n"); -} + /* pass 2 */ p = t->lpVtbl->GetPassByIndex(t, 2);