Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-fonts
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
Aleksandr Isakov
wine-fonts
Commits
40c06ea2
Commit
40c06ea2
authored
Sep 19, 2008
by
Stefan Dösinger
Committed by
Alexandre Julliard
Nov 04, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3d9: Add a test for GetTexture with no texture set.
parent
620a423b
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
3 deletions
+17
-3
device.c
dlls/d3d9/device.c
+5
-3
texture.c
dlls/d3d9/tests/texture.c
+12
-0
No files found.
dlls/d3d9/device.c
View file @
40c06ea2
...
...
@@ -990,11 +990,13 @@ static HRESULT WINAPI IDirect3DDevice9Impl_GetTexture(LPDIRECT3DDEVICE9EX ifac
EnterCriticalSection
(
&
d3d9_cs
);
rc
=
IWineD3DDevice_GetTexture
(
This
->
WineD3DDevice
,
Stage
,
&
retTexture
);
if
(
rc
==
D3D_OK
&&
NULL
!=
retTexture
)
{
if
(
SUCCEEDED
(
rc
)
&&
NULL
!=
retTexture
)
{
IWineD3DBaseTexture_GetParent
(
retTexture
,
(
IUnknown
**
)
ppTexture
);
IWineD3DBaseTexture_Release
(
retTexture
);
}
else
{
FIXME
(
"Call to get texture (%d) failed (%p)
\n
"
,
Stage
,
retTexture
);
}
else
{
if
(
FAILED
(
rc
))
{
WARN
(
"Call to get texture (%d) failed (%p)
\n
"
,
Stage
,
retTexture
);
}
*
ppTexture
=
NULL
;
}
LeaveCriticalSection
(
&
d3d9_cs
);
...
...
dlls/d3d9/tests/texture.c
View file @
40c06ea2
...
...
@@ -323,6 +323,17 @@ static void test_filter(IDirect3DDevice9 *device) {
IDirect3D9_Release
(
d3d9
);
}
static
void
test_gettexture
(
IDirect3DDevice9
*
device
)
{
HRESULT
hr
;
IDirect3DBaseTexture9
*
texture
=
(
IDirect3DBaseTexture9
*
)
0xdeadbeef
;
hr
=
IDirect3DDevice9_SetTexture
(
device
,
0
,
NULL
);
ok
(
hr
==
D3D_OK
,
"IDirect3DDevice9_SetTexture failed, hr = 0x%08x
\n
"
,
hr
);
hr
=
IDirect3DDevice9_GetTexture
(
device
,
0
,
&
texture
);
ok
(
hr
==
D3D_OK
,
"IDirect3DDevice9_GetTexture failed, hr = 0x%08x
\n
"
,
hr
);
ok
(
texture
==
NULL
,
"Texture returned is %p, expected NULL
\n
"
,
texture
);
}
START_TEST
(
texture
)
{
D3DCAPS9
caps
;
...
...
@@ -345,4 +356,5 @@ START_TEST(texture)
test_cube_textures
(
device_ptr
,
caps
.
TextureCaps
);
test_mipmap_gen
(
device_ptr
);
test_filter
(
device_ptr
);
test_gettexture
(
device_ptr
);
}
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