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
372ca933
Commit
372ca933
authored
Apr 03, 2018
by
Sven Hesse
Committed by
Alexandre Julliard
Apr 03, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3d11: Implement d3d10_texture1d_GetDesc().
Signed-off-by:
Henri Verbeet
<
hverbeet@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
d7d0deab
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
43 additions
and
1 deletion
+43
-1
device.c
dlls/d3d10core/tests/device.c
+10
-0
d3d11.c
dlls/d3d11/tests/d3d11.c
+18
-0
texture.c
dlls/d3d11/texture.c
+15
-1
No files found.
dlls/d3d10core/tests/device.c
View file @
372ca933
...
@@ -1368,6 +1368,16 @@ static void test_create_texture1d(void)
...
@@ -1368,6 +1368,16 @@ static void test_create_texture1d(void)
ok
(
refcount
==
expected_refcount
,
"Got unexpected refcount %u, expected %u.
\n
"
,
refcount
,
expected_refcount
);
ok
(
refcount
==
expected_refcount
,
"Got unexpected refcount %u, expected %u.
\n
"
,
refcount
,
expected_refcount
);
ID3D10Device_Release
(
tmp
);
ID3D10Device_Release
(
tmp
);
ID3D10Texture1D_GetDesc
(
texture
,
&
desc
);
ok
(
desc
.
Width
==
512
,
"Got unexpected Width %u.
\n
"
,
desc
.
Width
);
ok
(
desc
.
MipLevels
==
10
,
"Got unexpected MipLevels %u.
\n
"
,
desc
.
MipLevels
);
ok
(
desc
.
ArraySize
==
1
,
"Got unexpected ArraySize %u.
\n
"
,
desc
.
ArraySize
);
ok
(
desc
.
Format
==
DXGI_FORMAT_R8G8B8A8_UNORM
,
"Got unexpected Format %#x.
\n
"
,
desc
.
Format
);
ok
(
desc
.
Usage
==
D3D10_USAGE_DEFAULT
,
"Got unexpected Usage %u.
\n
"
,
desc
.
Usage
);
ok
(
desc
.
BindFlags
==
D3D10_BIND_SHADER_RESOURCE
,
"Got unexpected BindFlags %#x.
\n
"
,
desc
.
BindFlags
);
ok
(
desc
.
CPUAccessFlags
==
0
,
"Got unexpected CPUAccessFlags %#x.
\n
"
,
desc
.
CPUAccessFlags
);
ok
(
desc
.
MiscFlags
==
0
,
"Got unexpected MiscFlags %#x.
\n
"
,
desc
.
MiscFlags
);
check_interface
(
texture
,
&
IID_IDXGISurface
,
FALSE
,
FALSE
);
check_interface
(
texture
,
&
IID_IDXGISurface
,
FALSE
,
FALSE
);
ID3D10Texture1D_Release
(
texture
);
ID3D10Texture1D_Release
(
texture
);
...
...
dlls/d3d11/tests/d3d11.c
View file @
372ca933
...
@@ -1992,6 +1992,7 @@ static void test_texture1d_interfaces(void)
...
@@ -1992,6 +1992,7 @@ static void test_texture1d_interfaces(void)
for
(
i
=
0
;
i
<
ARRAY_SIZE
(
desc_conversion_tests
);
++
i
)
for
(
i
=
0
;
i
<
ARRAY_SIZE
(
desc_conversion_tests
);
++
i
)
{
{
const
struct
test
*
current
=
&
desc_conversion_tests
[
i
];
const
struct
test
*
current
=
&
desc_conversion_tests
[
i
];
D3D10_TEXTURE1D_DESC
d3d10_desc
;
ID3D10Device
*
d3d10_device
;
ID3D10Device
*
d3d10_device
;
desc
.
Width
=
512
;
desc
.
Width
=
512
;
...
@@ -2029,6 +2030,23 @@ static void test_texture1d_interfaces(void)
...
@@ -2029,6 +2030,23 @@ static void test_texture1d_interfaces(void)
continue
;
continue
;
}
}
ID3D10Texture1D_GetDesc
(
d3d10_texture
,
&
d3d10_desc
);
ok
(
d3d10_desc
.
Width
==
desc
.
Width
,
"Test %u: Got unexpected Width %u.
\n
"
,
i
,
d3d10_desc
.
Width
);
ok
(
d3d10_desc
.
MipLevels
==
desc
.
MipLevels
,
"Test %u: Got unexpected MipLevels %u.
\n
"
,
i
,
d3d10_desc
.
MipLevels
);
ok
(
d3d10_desc
.
ArraySize
==
desc
.
ArraySize
,
"Test %u: Got unexpected ArraySize %u.
\n
"
,
i
,
d3d10_desc
.
ArraySize
);
ok
(
d3d10_desc
.
Format
==
desc
.
Format
,
"Test %u: Got unexpected Format %u.
\n
"
,
i
,
d3d10_desc
.
Format
);
ok
(
d3d10_desc
.
BindFlags
==
current
->
expected_bind_flags
,
"Test %u: Got unexpected BindFlags %#x.
\n
"
,
i
,
d3d10_desc
.
BindFlags
);
ok
(
d3d10_desc
.
CPUAccessFlags
==
desc
.
CPUAccessFlags
,
"Test %u: Got unexpected CPUAccessFlags %#x.
\n
"
,
i
,
d3d10_desc
.
CPUAccessFlags
);
ok
(
d3d10_desc
.
MiscFlags
==
current
->
expected_misc_flags
,
"Test %u: Got unexpected MiscFlags %#x.
\n
"
,
i
,
d3d10_desc
.
MiscFlags
);
d3d10_device
=
(
ID3D10Device
*
)
0xdeadbeef
;
d3d10_device
=
(
ID3D10Device
*
)
0xdeadbeef
;
ID3D10Texture1D_GetDevice
(
d3d10_texture
,
&
d3d10_device
);
ID3D10Texture1D_GetDevice
(
d3d10_texture
,
&
d3d10_device
);
todo_wine
ok
(
!
d3d10_device
,
"Test %u: Got unexpected device pointer %p, expected NULL.
\n
"
,
i
,
d3d10_device
);
todo_wine
ok
(
!
d3d10_device
,
"Test %u: Got unexpected device pointer %p, expected NULL.
\n
"
,
i
,
d3d10_device
);
dlls/d3d11/texture.c
View file @
372ca933
...
@@ -360,7 +360,21 @@ static void STDMETHODCALLTYPE d3d10_texture1d_Unmap(ID3D10Texture1D *iface, UINT
...
@@ -360,7 +360,21 @@ static void STDMETHODCALLTYPE d3d10_texture1d_Unmap(ID3D10Texture1D *iface, UINT
static
void
STDMETHODCALLTYPE
d3d10_texture1d_GetDesc
(
ID3D10Texture1D
*
iface
,
D3D10_TEXTURE1D_DESC
*
desc
)
static
void
STDMETHODCALLTYPE
d3d10_texture1d_GetDesc
(
ID3D10Texture1D
*
iface
,
D3D10_TEXTURE1D_DESC
*
desc
)
{
{
FIXME
(
"iface %p, desc %p stub!
\n
"
,
iface
,
desc
);
struct
d3d_texture1d
*
texture
=
impl_from_ID3D10Texture1D
(
iface
);
D3D11_TEXTURE1D_DESC
d3d11_desc
;
TRACE
(
"iface %p, desc %p.
\n
"
,
iface
,
desc
);
d3d11_texture1d_GetDesc
(
&
texture
->
ID3D11Texture1D_iface
,
&
d3d11_desc
);
desc
->
Width
=
d3d11_desc
.
Width
;
desc
->
MipLevels
=
d3d11_desc
.
MipLevels
;
desc
->
ArraySize
=
d3d11_desc
.
ArraySize
;
desc
->
Format
=
d3d11_desc
.
Format
;
desc
->
Usage
=
d3d10_usage_from_d3d11_usage
(
d3d11_desc
.
Usage
);
desc
->
BindFlags
=
d3d10_bind_flags_from_d3d11_bind_flags
(
d3d11_desc
.
BindFlags
);
desc
->
CPUAccessFlags
=
d3d10_cpu_access_flags_from_d3d11_cpu_access_flags
(
d3d11_desc
.
CPUAccessFlags
);
desc
->
MiscFlags
=
d3d10_resource_misc_flags_from_d3d11_resource_misc_flags
(
d3d11_desc
.
MiscFlags
);
}
}
static
const
struct
ID3D10Texture1DVtbl
d3d10_texture1d_vtbl
=
static
const
struct
ID3D10Texture1DVtbl
d3d10_texture1d_vtbl
=
...
...
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