d3d11: Fix calculation of array size for 1D textures.
Signed-off-by: Michael Müller <michael@fds-team.de> Signed-off-by: Sebastian Lackner <sebastian@fds-team.de> Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
53714bd6a8
commit
983b3577ca
|
@ -184,7 +184,7 @@ static HRESULT normalize_dsv_desc(D3D11_DEPTH_STENCIL_VIEW_DESC *desc, ID3D11Res
|
||||||
{
|
{
|
||||||
case D3D11_DSV_DIMENSION_TEXTURE1DARRAY:
|
case D3D11_DSV_DIMENSION_TEXTURE1DARRAY:
|
||||||
if (desc->u.Texture1DArray.ArraySize == ~0u && desc->u.Texture1DArray.FirstArraySlice < layer_count)
|
if (desc->u.Texture1DArray.ArraySize == ~0u && desc->u.Texture1DArray.FirstArraySlice < layer_count)
|
||||||
desc->u.Texture1DArray.ArraySize = layer_count - desc->u.Texture1DArray.ArraySize;
|
desc->u.Texture1DArray.ArraySize = layer_count - desc->u.Texture1DArray.FirstArraySlice;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case D3D11_DSV_DIMENSION_TEXTURE2DARRAY:
|
case D3D11_DSV_DIMENSION_TEXTURE2DARRAY:
|
||||||
|
@ -412,7 +412,7 @@ static HRESULT normalize_rtv_desc(D3D11_RENDER_TARGET_VIEW_DESC *desc, ID3D11Res
|
||||||
{
|
{
|
||||||
case D3D11_RTV_DIMENSION_TEXTURE1DARRAY:
|
case D3D11_RTV_DIMENSION_TEXTURE1DARRAY:
|
||||||
if (desc->u.Texture1DArray.ArraySize == ~0u && desc->u.Texture1DArray.FirstArraySlice < layer_count)
|
if (desc->u.Texture1DArray.ArraySize == ~0u && desc->u.Texture1DArray.FirstArraySlice < layer_count)
|
||||||
desc->u.Texture1DArray.ArraySize = layer_count - desc->u.Texture1DArray.ArraySize;
|
desc->u.Texture1DArray.ArraySize = layer_count - desc->u.Texture1DArray.FirstArraySlice;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case D3D11_RTV_DIMENSION_TEXTURE2DARRAY:
|
case D3D11_RTV_DIMENSION_TEXTURE2DARRAY:
|
||||||
|
@ -915,7 +915,7 @@ static HRESULT normalize_uav_desc(D3D11_UNORDERED_ACCESS_VIEW_DESC *desc, ID3D11
|
||||||
{
|
{
|
||||||
case D3D11_UAV_DIMENSION_TEXTURE1DARRAY:
|
case D3D11_UAV_DIMENSION_TEXTURE1DARRAY:
|
||||||
if (desc->u.Texture1DArray.ArraySize == ~0u && desc->u.Texture1DArray.FirstArraySlice < layer_count)
|
if (desc->u.Texture1DArray.ArraySize == ~0u && desc->u.Texture1DArray.FirstArraySlice < layer_count)
|
||||||
desc->u.Texture1DArray.ArraySize = layer_count - desc->u.Texture1DArray.ArraySize;
|
desc->u.Texture1DArray.ArraySize = layer_count - desc->u.Texture1DArray.FirstArraySlice;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
case D3D11_UAV_DIMENSION_TEXTURE2DARRAY:
|
case D3D11_UAV_DIMENSION_TEXTURE2DARRAY:
|
||||||
|
|
Loading…
Reference in New Issue