Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
6889a0c3
Commit
6889a0c3
authored
Nov 14, 2019
by
Matteo Bruni
Committed by
Alexandre Julliard
Nov 14, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3dcompiler/tests: Clean up test_reflection_desc_ps_output() a bit.
Signed-off-by:
Matteo Bruni
<
mbruni@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
44e65ebd
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
26 additions
and
24 deletions
+26
-24
reflection.c
dlls/d3dcompiler_43/tests/reflection.c
+26
-24
No files found.
dlls/d3dcompiler_43/tests/reflection.c
View file @
6889a0c3
...
...
@@ -908,27 +908,28 @@ static const DWORD test_reflection_desc_ps_output_blob_5[] = {
0x00000000
,
0x00000000
,
0x00000000
,
0x00000000
,
0x00000000
,
0x00000000
,
0x00000000
,
};
static
const
DWORD
*
test_reflection_desc_ps_output_blob
[]
=
{
test_reflection_desc_ps_output_blob_0
,
test_reflection_desc_ps_output_blob_1
,
test_reflection_desc_ps_output_blob_2
,
test_reflection_desc_ps_output_blob_3
,
test_reflection_desc_ps_output_blob_4
,
test_reflection_desc_ps_output_blob_5
,
};
static
const
D3D11_SIGNATURE_PARAMETER_DESC
test_reflection_desc_ps_output_result
[]
=
{
{
"SV_Target"
,
3
,
3
,
D3D_NAME_TARGET
,
D3D_REGISTER_COMPONENT_FLOAT32
,
0xf
,
0
,
0
},
{
"SV_DepthLessEqual"
,
0
,
0xffffffff
,
D3D_NAME_DEPTH_LESS_EQUAL
,
D3D_REGISTER_COMPONENT_FLOAT32
,
0x1
,
0xe
,
0
},
{
"SV_DepthGreaterEqual"
,
0
,
0xffffffff
,
D3D11_NAME_DEPTH_GREATER_EQUAL
,
D3D_REGISTER_COMPONENT_FLOAT32
,
0x1
,
0xe
,
0
},
{
"sV_DePtH"
,
0
,
0xffffffff
,
D3D_NAME_DEPTH
,
D3D_REGISTER_COMPONENT_FLOAT32
,
0x1
,
0xe
,
0
},
{
"SV_Depth"
,
0
,
0xffffffff
,
D3D_NAME_DEPTH
,
D3D_REGISTER_COMPONENT_FLOAT32
,
0x1
,
0xe
,
0
},
{
"SV_COVERAGE"
,
0
,
0xffffffff
,
D3D_NAME_COVERAGE
,
D3D_REGISTER_COMPONENT_UINT32
,
0x1
,
0xe
,
0
},
};
static
void
test_reflection_desc_ps_output
(
void
)
{
static
const
struct
test_reflection_desc_ps_output_test
{
const
DWORD
*
blob
;
D3D11_SIGNATURE_PARAMETER_DESC
desc
;
}
tests
[]
=
{
{
test_reflection_desc_ps_output_blob_0
,
{
"SV_Target"
,
3
,
3
,
D3D_NAME_TARGET
,
D3D_REGISTER_COMPONENT_FLOAT32
,
0xf
,
0
,
0
}},
{
test_reflection_desc_ps_output_blob_1
,
{
"SV_DepthLessEqual"
,
0
,
0xffffffff
,
D3D_NAME_DEPTH_LESS_EQUAL
,
D3D_REGISTER_COMPONENT_FLOAT32
,
0x1
,
0xe
,
0
}},
{
test_reflection_desc_ps_output_blob_2
,
{
"SV_DepthGreaterEqual"
,
0
,
0xffffffff
,
D3D11_NAME_DEPTH_GREATER_EQUAL
,
D3D_REGISTER_COMPONENT_FLOAT32
,
0x1
,
0xe
,
0
}},
{
test_reflection_desc_ps_output_blob_3
,
{
"sV_DePtH"
,
0
,
0xffffffff
,
D3D_NAME_DEPTH
,
D3D_REGISTER_COMPONENT_FLOAT32
,
0x1
,
0xe
,
0
}},
{
test_reflection_desc_ps_output_blob_4
,
{
"SV_Depth"
,
0
,
0xffffffff
,
D3D_NAME_DEPTH
,
D3D_REGISTER_COMPONENT_FLOAT32
,
0x1
,
0xe
,
0
}},
{
test_reflection_desc_ps_output_blob_5
,
{
"SV_COVERAGE"
,
0
,
0xffffffff
,
D3D_NAME_COVERAGE
,
D3D_REGISTER_COMPONENT_UINT32
,
0x1
,
0xe
,
0
}},
};
HRESULT
hr
;
ULONG
count
;
ID3D11ShaderReflection
*
ref11
;
...
...
@@ -936,12 +937,12 @@ static void test_reflection_desc_ps_output(void)
const
D3D11_SIGNATURE_PARAMETER_DESC
*
pdesc
;
unsigned
int
i
;
for
(
i
=
0
;
i
<
ARRAY_SIZE
(
test
_reflection_desc_ps_output_result
);
++
i
)
for
(
i
=
0
;
i
<
ARRAY_SIZE
(
test
s
);
++
i
)
{
hr
=
pD3DReflect
(
test
_reflection_desc_ps_output_blob
[
i
],
test_reflection_desc_ps_output_blob
[
i
]
[
6
],
&
IID_ID3D11ShaderReflection
,
(
void
**
)
&
ref11
);
ok
(
hr
==
S_OK
,
"(%u):
D3DReflect failed %x
\n
"
,
i
,
hr
);
hr
=
pD3DReflect
(
test
s
[
i
].
blob
,
tests
[
i
].
blob
[
6
],
&
IID_ID3D11ShaderReflection
,
(
void
**
)
&
ref11
);
ok
(
hr
==
S_OK
,
"(%u):
got unexpected hr %x.
\n
"
,
i
,
hr
);
pdesc
=
&
test
_reflection_desc_ps_output_result
[
i
]
;
pdesc
=
&
test
s
[
i
].
desc
;
hr
=
ref11
->
lpVtbl
->
GetOutputParameterDesc
(
ref11
,
0
,
&
desc
);
ok
(
hr
==
S_OK
,
"(%u): GetOutputParameterDesc failed, got %x, expected %x
\n
"
,
i
,
hr
,
S_OK
);
...
...
@@ -1050,7 +1051,8 @@ static void test_reflection_bound_resources(void)
const
D3D11_SHADER_INPUT_BIND_DESC
*
pdesc
;
unsigned
int
i
;
hr
=
pD3DReflect
(
test_reflection_bound_resources_blob
,
test_reflection_bound_resources_blob
[
6
],
&
IID_ID3D11ShaderReflection
,
(
void
**
)
&
ref11
);
hr
=
pD3DReflect
(
test_reflection_bound_resources_blob
,
test_reflection_bound_resources_blob
[
6
],
&
IID_ID3D11ShaderReflection
,
(
void
**
)
&
ref11
);
ok
(
hr
==
S_OK
,
"D3DReflect failed %x
\n
"
,
hr
);
/* check invalid cases */
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment