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
9f212a6c
Commit
9f212a6c
authored
Jul 24, 2012
by
Henri Verbeet
Committed by
Alexandre Julliard
Jul 25, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3d10: Implement d3d10_effect_sampler_variable_GetBackingStore().
parent
98751a49
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
31 additions
and
22 deletions
+31
-22
effect.c
dlls/d3d10/effect.c
+12
-2
effect.c
dlls/d3d10/tests/effect.c
+19
-20
No files found.
dlls/d3d10/effect.c
View file @
9f212a6c
...
...
@@ -6569,9 +6569,19 @@ static HRESULT STDMETHODCALLTYPE d3d10_effect_sampler_variable_GetSampler(ID3D10
static
HRESULT
STDMETHODCALLTYPE
d3d10_effect_sampler_variable_GetBackingStore
(
ID3D10EffectSamplerVariable
*
iface
,
UINT
index
,
D3D10_SAMPLER_DESC
*
desc
)
{
FIXME
(
"iface %p, index %u, desc %p stub!
\n
"
,
iface
,
index
,
desc
);
struct
d3d10_effect_variable
*
v
=
impl_from_ID3D10EffectVariable
((
ID3D10EffectVariable
*
)
iface
);
return
E_NOTIMPL
;
TRACE
(
"iface %p, index %u, desc %p.
\n
"
,
iface
,
index
,
desc
);
if
(
index
>=
max
(
v
->
type
->
element_count
,
1
))
{
WARN
(
"Invalid index %u.
\n
"
,
index
);
return
E_FAIL
;
}
*
desc
=
((
D3D10_SAMPLER_DESC
*
)
v
->
data
)[
index
];
return
S_OK
;
}
...
...
dlls/d3d10/tests/effect.c
View file @
9f212a6c
...
...
@@ -3826,22 +3826,21 @@ static void test_effect_state_groups(ID3D10Device *device)
v
=
effect
->
lpVtbl
->
GetVariableByName
(
effect
,
"sampler0"
);
s
=
v
->
lpVtbl
->
AsSampler
(
v
);
memset
(
&
sampler_desc
,
0
,
sizeof
(
sampler_desc
));
s
->
lpVtbl
->
GetBackingStore
(
s
,
0
,
&
sampler_desc
);
todo_wine
ok
(
sampler_desc
.
Filter
==
D3D10_FILTER_MIN_MAG_MIP_LINEAR
,
"Got unexpected Filter %#x.
\n
"
,
sampler_desc
.
Filter
);
todo_wine
ok
(
sampler_desc
.
AddressU
==
D3D10_TEXTURE_ADDRESS_WRAP
,
"Got unexpected AddressU %#x.
\n
"
,
sampler_desc
.
AddressU
);
todo_wine
ok
(
sampler_desc
.
AddressV
==
D3D10_TEXTURE_ADDRESS_MIRROR
,
"Got unexpected AddressV %#x.
\n
"
,
sampler_desc
.
AddressV
);
todo_wine
ok
(
sampler_desc
.
AddressW
==
D3D10_TEXTURE_ADDRESS_CLAMP
,
"Got unexpected AddressW %#x.
\n
"
,
sampler_desc
.
AddressW
);
todo_wine
ok
(
sampler_desc
.
MipLODBias
==
-
1
.
0
f
,
"Got unexpected MipLODBias %.8e.
\n
"
,
sampler_desc
.
MipLODBias
);
todo_wine
ok
(
sampler_desc
.
MaxAnisotropy
==
4
,
"Got unexpected MaxAnisotropy %#x.
\n
"
,
sampler_desc
.
MaxAnisotropy
);
todo_wine
ok
(
sampler_desc
.
ComparisonFunc
==
D3D10_COMPARISON_ALWAYS
,
"Got unexpected ComparisonFunc %#x.
\n
"
,
ok
(
sampler_desc
.
Filter
==
D3D10_FILTER_MIN_MAG_MIP_LINEAR
,
"Got unexpected Filter %#x.
\n
"
,
sampler_desc
.
Filter
);
ok
(
sampler_desc
.
AddressU
==
D3D10_TEXTURE_ADDRESS_WRAP
,
"Got unexpected AddressU %#x.
\n
"
,
sampler_desc
.
AddressU
);
ok
(
sampler_desc
.
AddressV
==
D3D10_TEXTURE_ADDRESS_MIRROR
,
"Got unexpected AddressV %#x.
\n
"
,
sampler_desc
.
AddressV
);
ok
(
sampler_desc
.
AddressW
==
D3D10_TEXTURE_ADDRESS_CLAMP
,
"Got unexpected AddressW %#x.
\n
"
,
sampler_desc
.
AddressW
);
ok
(
sampler_desc
.
MipLODBias
==
-
1
.
0
f
,
"Got unexpected MipLODBias %.8e.
\n
"
,
sampler_desc
.
MipLODBias
);
ok
(
sampler_desc
.
MaxAnisotropy
==
4
,
"Got unexpected MaxAnisotropy %#x.
\n
"
,
sampler_desc
.
MaxAnisotropy
);
ok
(
sampler_desc
.
ComparisonFunc
==
D3D10_COMPARISON_ALWAYS
,
"Got unexpected ComparisonFunc %#x.
\n
"
,
sampler_desc
.
ComparisonFunc
);
todo_wine
ok
(
sampler_desc
.
BorderColor
[
0
]
==
1
.
0
f
,
"Got unexpected BorderColor[0] %.8e.
\n
"
,
sampler_desc
.
BorderColor
[
0
]);
todo_wine
ok
(
sampler_desc
.
BorderColor
[
1
]
==
2
.
0
f
,
"Got unexpected BorderColor[1] %.8e.
\n
"
,
sampler_desc
.
BorderColor
[
1
]);
todo_wine
ok
(
sampler_desc
.
BorderColor
[
2
]
==
3
.
0
f
,
"Got unexpected BorderColor[2] %.8e.
\n
"
,
sampler_desc
.
BorderColor
[
2
]);
todo_wine
ok
(
sampler_desc
.
BorderColor
[
3
]
==
4
.
0
f
,
"Got unexpected BorderColor[3] %.8e.
\n
"
,
sampler_desc
.
BorderColor
[
3
]);
todo_wine
ok
(
sampler_desc
.
MinLOD
==
6
.
0
f
,
"Got unexpected MinLOD %.8e.
\n
"
,
sampler_desc
.
MinLOD
);
todo_wine
ok
(
sampler_desc
.
MaxLOD
==
5
.
0
f
,
"Got unexpected MaxLOD %.8e.
\n
"
,
sampler_desc
.
MaxLOD
);
ok
(
sampler_desc
.
BorderColor
[
0
]
==
1
.
0
f
,
"Got unexpected BorderColor[0] %.8e.
\n
"
,
sampler_desc
.
BorderColor
[
0
]);
ok
(
sampler_desc
.
BorderColor
[
1
]
==
2
.
0
f
,
"Got unexpected BorderColor[1] %.8e.
\n
"
,
sampler_desc
.
BorderColor
[
1
]);
ok
(
sampler_desc
.
BorderColor
[
2
]
==
3
.
0
f
,
"Got unexpected BorderColor[2] %.8e.
\n
"
,
sampler_desc
.
BorderColor
[
2
]);
ok
(
sampler_desc
.
BorderColor
[
3
]
==
4
.
0
f
,
"Got unexpected BorderColor[3] %.8e.
\n
"
,
sampler_desc
.
BorderColor
[
3
]);
ok
(
sampler_desc
.
MinLOD
==
6
.
0
f
,
"Got unexpected MinLOD %.8e.
\n
"
,
sampler_desc
.
MinLOD
);
ok
(
sampler_desc
.
MaxLOD
==
5
.
0
f
,
"Got unexpected MaxLOD %.8e.
\n
"
,
sampler_desc
.
MaxLOD
);
v
=
effect
->
lpVtbl
->
GetVariableByName
(
effect
,
"blend_state"
);
b
=
v
->
lpVtbl
->
AsBlend
(
v
);
...
...
@@ -4077,19 +4076,19 @@ static void test_effect_state_group_defaults(ID3D10Device *device)
memset
(
&
sampler_desc
,
0
,
sizeof
(
sampler_desc
));
s
->
lpVtbl
->
GetBackingStore
(
s
,
0
,
&
sampler_desc
);
ok
(
sampler_desc
.
Filter
==
D3D10_FILTER_MIN_MAG_MIP_POINT
,
"Got unexpected Filter %#x.
\n
"
,
sampler_desc
.
Filter
);
todo_wine
ok
(
sampler_desc
.
AddressU
==
D3D10_TEXTURE_ADDRESS_WRAP
,
"Got unexpected AddressU %#x.
\n
"
,
sampler_desc
.
AddressU
);
todo_wine
ok
(
sampler_desc
.
AddressV
==
D3D10_TEXTURE_ADDRESS_WRAP
,
"Got unexpected AddressV %#x.
\n
"
,
sampler_desc
.
AddressV
);
todo_wine
ok
(
sampler_desc
.
AddressW
==
D3D10_TEXTURE_ADDRESS_WRAP
,
"Got unexpected AddressW %#x.
\n
"
,
sampler_desc
.
AddressW
);
ok
(
sampler_desc
.
AddressU
==
D3D10_TEXTURE_ADDRESS_WRAP
,
"Got unexpected AddressU %#x.
\n
"
,
sampler_desc
.
AddressU
);
ok
(
sampler_desc
.
AddressV
==
D3D10_TEXTURE_ADDRESS_WRAP
,
"Got unexpected AddressV %#x.
\n
"
,
sampler_desc
.
AddressV
);
ok
(
sampler_desc
.
AddressW
==
D3D10_TEXTURE_ADDRESS_WRAP
,
"Got unexpected AddressW %#x.
\n
"
,
sampler_desc
.
AddressW
);
ok
(
sampler_desc
.
MipLODBias
==
0
.
0
f
,
"Got unexpected MipLODBias %.8e.
\n
"
,
sampler_desc
.
MipLODBias
);
todo_wine
ok
(
sampler_desc
.
MaxAnisotropy
==
16
,
"Got unexpected MaxAnisotropy %#x.
\n
"
,
sampler_desc
.
MaxAnisotropy
);
todo_wine
ok
(
sampler_desc
.
ComparisonFunc
==
D3D10_COMPARISON_NEVER
,
"Got unexpected ComparisonFunc %#x.
\n
"
,
ok
(
sampler_desc
.
MaxAnisotropy
==
16
,
"Got unexpected MaxAnisotropy %#x.
\n
"
,
sampler_desc
.
MaxAnisotropy
);
ok
(
sampler_desc
.
ComparisonFunc
==
D3D10_COMPARISON_NEVER
,
"Got unexpected ComparisonFunc %#x.
\n
"
,
sampler_desc
.
ComparisonFunc
);
ok
(
sampler_desc
.
BorderColor
[
0
]
==
0
.
0
f
,
"Got unexpected BorderColor[0] %.8e.
\n
"
,
sampler_desc
.
BorderColor
[
0
]);
ok
(
sampler_desc
.
BorderColor
[
1
]
==
0
.
0
f
,
"Got unexpected BorderColor[1] %.8e.
\n
"
,
sampler_desc
.
BorderColor
[
1
]);
ok
(
sampler_desc
.
BorderColor
[
2
]
==
0
.
0
f
,
"Got unexpected BorderColor[2] %.8e.
\n
"
,
sampler_desc
.
BorderColor
[
2
]);
ok
(
sampler_desc
.
BorderColor
[
3
]
==
0
.
0
f
,
"Got unexpected BorderColor[3] %.8e.
\n
"
,
sampler_desc
.
BorderColor
[
3
]);
ok
(
sampler_desc
.
MinLOD
==
0
.
0
f
,
"Got unexpected MinLOD %.8e.
\n
"
,
sampler_desc
.
MinLOD
);
todo_wine
ok
(
sampler_desc
.
MaxLOD
==
FLT_MAX
,
"Got unexpected MaxLOD %.8e.
\n
"
,
sampler_desc
.
MaxLOD
);
ok
(
sampler_desc
.
MaxLOD
==
FLT_MAX
,
"Got unexpected MaxLOD %.8e.
\n
"
,
sampler_desc
.
MaxLOD
);
v
=
effect
->
lpVtbl
->
GetVariableByName
(
effect
,
"blend_state"
);
b
=
v
->
lpVtbl
->
AsBlend
(
v
);
...
...
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