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
8305c597
Commit
8305c597
authored
Jan 25, 2022
by
Henri Verbeet
Committed by
Alexandre Julliard
Jan 25, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3d11/tests: Add some tests for ID3DUserDefinedAnnotation.
Signed-off-by:
Henri Verbeet
<
hverbeet@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
369ee8b0
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
41 additions
and
0 deletions
+41
-0
d3d11.c
dlls/d3d11/tests/d3d11.c
+41
-0
No files found.
dlls/d3d11/tests/d3d11.c
View file @
8305c597
...
@@ -33994,6 +33994,46 @@ static void test_dynamic_map_synchronization(void)
...
@@ -33994,6 +33994,46 @@ static void test_dynamic_map_synchronization(void)
release_test_context
(
&
test_context
);
release_test_context
(
&
test_context
);
}
}
static
void
test_user_defined_annotation
(
void
)
{
struct
d3d11_test_context
test_context
;
ID3DUserDefinedAnnotation
*
annotation
;
ID3D11DeviceContext
*
context
;
HRESULT
hr
;
int
ret
;
if
(
!
init_test_context
(
&
test_context
,
NULL
))
return
;
hr
=
ID3D11DeviceContext_QueryInterface
(
test_context
.
immediate_context
,
&
IID_ID3DUserDefinedAnnotation
,
(
void
**
)
&
annotation
);
ok
(
hr
==
S_OK
,
"Got unexpected hr %#x.
\n
"
,
hr
);
ret
=
ID3DUserDefinedAnnotation_BeginEvent
(
annotation
,
L"Event 1"
);
ok
(
ret
==
-
1
,
"Got unexpected ret %d.
\n
"
,
ret
);
ret
=
ID3DUserDefinedAnnotation_EndEvent
(
annotation
);
ok
(
ret
==
-
1
,
"Got unexpected ret %d.
\n
"
,
ret
);
ID3DUserDefinedAnnotation_SetMarker
(
annotation
,
L"Marker 1"
);
ret
=
ID3DUserDefinedAnnotation_GetStatus
(
annotation
);
ok
(
!
ret
,
"Got unexpected status %#x.
\n
"
,
ret
);
ID3DUserDefinedAnnotation_Release
(
annotation
);
hr
=
ID3D11Device_CreateDeferredContext
(
test_context
.
device
,
0
,
&
context
);
ok
(
hr
==
S_OK
,
"Got unexpected hr %#x.
\n
"
,
hr
);
hr
=
ID3D11DeviceContext_QueryInterface
(
context
,
&
IID_ID3DUserDefinedAnnotation
,
(
void
**
)
&
annotation
);
ok
(
hr
==
S_OK
,
"Got unexpected hr %#x.
\n
"
,
hr
);
ret
=
ID3DUserDefinedAnnotation_BeginEvent
(
annotation
,
L"Event 2"
);
ok
(
ret
==
-
1
,
"Got unexpected ret %d.
\n
"
,
ret
);
ret
=
ID3DUserDefinedAnnotation_EndEvent
(
annotation
);
ok
(
ret
==
-
1
,
"Got unexpected ret %d.
\n
"
,
ret
);
ID3DUserDefinedAnnotation_SetMarker
(
annotation
,
L"Marker 2"
);
ret
=
ID3DUserDefinedAnnotation_GetStatus
(
annotation
);
ok
(
!
ret
,
"Got unexpected status %#x.
\n
"
,
ret
);
ID3DUserDefinedAnnotation_Release
(
annotation
);
ID3D11DeviceContext_Release
(
context
);
release_test_context
(
&
test_context
);
}
START_TEST
(
d3d11
)
START_TEST
(
d3d11
)
{
{
unsigned
int
argc
,
i
;
unsigned
int
argc
,
i
;
...
@@ -34168,6 +34208,7 @@ START_TEST(d3d11)
...
@@ -34168,6 +34208,7 @@ START_TEST(d3d11)
queue_test
(
test_texture_compressed_3d
);
queue_test
(
test_texture_compressed_3d
);
queue_test
(
test_constant_buffer_offset
);
queue_test
(
test_constant_buffer_offset
);
queue_test
(
test_dynamic_map_synchronization
);
queue_test
(
test_dynamic_map_synchronization
);
queue_test
(
test_user_defined_annotation
);
run_queued_tests
();
run_queued_tests
();
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