Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
wine
Manage
Activity
Members
Labels
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Package registry
Container Registry
Model registry
Operate
Terraform modules
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Lorenzo Ferrillo
wine
Commits
989a6435
Commit
989a6435
authored
13 years ago
by
Henri Verbeet
Committed by
Alexandre Julliard
13 years ago
Browse files
Options
Downloads
Patches
Plain Diff
d3d10: Implement D3D10StateBlockMaskUnion().
parent
f5e7de6b
No related branches found
Branches containing commit
No related tags found
Tags containing commit
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
dlls/d3d10/d3d10.spec
+1
-1
1 addition, 1 deletion
dlls/d3d10/d3d10.spec
dlls/d3d10/stateblock.c
+23
-0
23 additions, 0 deletions
dlls/d3d10/stateblock.c
dlls/d3d10/tests/device.c
+11
-0
11 additions, 0 deletions
dlls/d3d10/tests/device.c
include/d3d10effect.h
+2
-0
2 additions, 0 deletions
include/d3d10effect.h
with
37 additions
and
1 deletion
dlls/d3d10/d3d10.spec
+
1
−
1
View file @
989a6435
...
...
@@ -26,4 +26,4 @@
@ stdcall D3D10StateBlockMaskEnableCapture(ptr long long long)
@ stdcall D3D10StateBlockMaskGetSetting(ptr long long)
@ stdcall D3D10StateBlockMaskIntersect(ptr ptr ptr)
@ st
ub
D3D10StateBlockMaskUnion
@ st
dcall
D3D10StateBlockMaskUnion
(ptr ptr ptr)
This diff is collapsed.
Click to expand it.
dlls/d3d10/stateblock.c
+
23
−
0
View file @
989a6435
...
...
@@ -508,3 +508,26 @@ HRESULT WINAPI D3D10StateBlockMaskIntersect(D3D10_STATE_BLOCK_MASK *mask_x,
return
S_OK
;
}
HRESULT
WINAPI
D3D10StateBlockMaskUnion
(
D3D10_STATE_BLOCK_MASK
*
mask_x
,
D3D10_STATE_BLOCK_MASK
*
mask_y
,
D3D10_STATE_BLOCK_MASK
*
result
)
{
UINT
count
=
sizeof
(
*
result
)
/
sizeof
(
DWORD
);
UINT
i
;
TRACE
(
"mask_x %p, mask_y %p, result %p.
\n
"
,
mask_x
,
mask_y
,
result
);
if
(
!
mask_x
||
!
mask_y
||
!
result
)
return
E_INVALIDARG
;
for
(
i
=
0
;
i
<
count
;
++
i
)
{
((
DWORD
*
)
result
)[
i
]
=
((
DWORD
*
)
mask_x
)[
i
]
|
((
DWORD
*
)
mask_y
)[
i
];
}
for
(
i
=
count
*
sizeof
(
DWORD
);
i
<
sizeof
(
*
result
);
++
i
)
{
((
BYTE
*
)
result
)[
i
]
=
((
BYTE
*
)
mask_x
)[
i
]
|
((
BYTE
*
)
mask_y
)[
i
];
}
return
S_OK
;
}
This diff is collapsed.
Click to expand it.
dlls/d3d10/tests/device.c
+
11
−
0
View file @
989a6435
...
...
@@ -128,6 +128,17 @@ static void test_stateblock_mask(void)
hr
=
D3D10StateBlockMaskIntersect
(
&
mask_x
,
&
mask_y
,
NULL
);
ok
(
hr
==
E_INVALIDARG
,
"Got unexpect hr %#x.
\n
"
,
hr
);
hr
=
D3D10StateBlockMaskUnion
(
&
mask_x
,
&
mask_y
,
&
result
);
ok
(
SUCCEEDED
(
hr
),
"D3D10StateBlockMaskUnion failed, hr %#x.
\n
"
,
hr
);
ok
(
result
.
VS
==
0x77
,
"Got unexpected result.VS %#x.
\n
"
,
result
.
VS
);
ok
(
result
.
Predication
==
0xbb
,
"Got unexpected result.Predication %#x.
\n
"
,
result
.
Predication
);
hr
=
D3D10StateBlockMaskUnion
(
NULL
,
&
mask_y
,
&
result
);
ok
(
hr
==
E_INVALIDARG
,
"Got unexpect hr %#x.
\n
"
,
hr
);
hr
=
D3D10StateBlockMaskUnion
(
&
mask_x
,
NULL
,
&
result
);
ok
(
hr
==
E_INVALIDARG
,
"Got unexpect hr %#x.
\n
"
,
hr
);
hr
=
D3D10StateBlockMaskUnion
(
&
mask_x
,
&
mask_y
,
NULL
);
ok
(
hr
==
E_INVALIDARG
,
"Got unexpect hr %#x.
\n
"
,
hr
);
memset
(
&
result
,
0xff
,
sizeof
(
result
));
hr
=
D3D10StateBlockMaskDisableAll
(
&
result
);
ok
(
SUCCEEDED
(
hr
),
"D3D10StateBlockMaskDisableAll failed, hr %#x.
\n
"
,
hr
);
...
...
This diff is collapsed.
Click to expand it.
include/d3d10effect.h
+
2
−
0
View file @
989a6435
...
...
@@ -844,6 +844,8 @@ BOOL WINAPI D3D10StateBlockMaskGetSetting(D3D10_STATE_BLOCK_MASK *mask,
D3D10_DEVICE_STATE_TYPES
state_type
,
UINT
idx
);
HRESULT
WINAPI
D3D10StateBlockMaskIntersect
(
D3D10_STATE_BLOCK_MASK
*
mask_x
,
D3D10_STATE_BLOCK_MASK
*
mask_y
,
D3D10_STATE_BLOCK_MASK
*
result
);
HRESULT
WINAPI
D3D10StateBlockMaskUnion
(
D3D10_STATE_BLOCK_MASK
*
mask_x
,
D3D10_STATE_BLOCK_MASK
*
mask_y
,
D3D10_STATE_BLOCK_MASK
*
result
);
#ifdef __cplusplus
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment