Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
25ce3a42
Commit
25ce3a42
authored
Jan 15, 2013
by
Rico Schüller
Committed by
Alexandre Julliard
Jan 16, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3dx9: Add support for D3DFMT_A32B32G32R32F.
parent
f30b6d0b
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
9 additions
and
5 deletions
+9
-5
d3dx9_36_private.h
dlls/d3dx9_36/d3dx9_36_private.h
+1
-0
texture.c
dlls/d3dx9_36/tests/texture.c
+2
-2
texture.c
dlls/d3dx9_36/texture.c
+5
-3
util.c
dlls/d3dx9_36/util.c
+1
-0
No files found.
dlls/d3dx9_36/d3dx9_36_private.h
View file @
25ce3a42
...
...
@@ -48,6 +48,7 @@ struct volume
enum
format_type
{
FORMAT_ARGB
,
/* unsigned */
FORMAT_ARGBF16
,
/* float 16 */
FORMAT_ARGBF
,
/* float */
FORMAT_DXT
,
FORMAT_UNKNOWN
};
...
...
dlls/d3dx9_36/tests/texture.c
View file @
25ce3a42
...
...
@@ -1101,7 +1101,7 @@ static void test_D3DXFillTexture(IDirect3DDevice9 *device)
if
(
SUCCEEDED
(
hr
))
{
hr
=
D3DXFillTexture
(
tex
,
fillfunc
,
NULL
);
todo_wine
ok
(
hr
==
D3D_OK
,
"D3DXFillTexture returned %#x, expected %#x
\n
"
,
hr
,
D3D_OK
);
ok
(
hr
==
D3D_OK
,
"D3DXFillTexture returned %#x, expected %#x
\n
"
,
hr
,
D3D_OK
);
hr
=
IDirect3DTexture9_LockRect
(
tex
,
0
,
&
lock_rect
,
NULL
,
D3DLOCK_READONLY
);
if
(
SUCCEEDED
(
hr
))
...
...
@@ -1124,7 +1124,7 @@ static void test_D3DXFillTexture(IDirect3DDevice9 *device)
expected
.
z
=
1
.
0
f
/
4
.
0
f
;
expected
.
w
=
1
.
0
f
;
todo_wine
expect_vec4
(
&
expected
,
&
got
);
expect_vec4
(
&
expected
,
&
got
);
}
}
...
...
dlls/d3dx9_36/texture.c
View file @
25ce3a42
...
...
@@ -1236,6 +1236,8 @@ static inline void fill_texture(const struct pixel_format_desc *format, BYTE *po
if
(
format
->
type
==
FORMAT_ARGBF16
)
v
=
float_32_to_16
(
comp_value
);
else
if
(
format
->
type
==
FORMAT_ARGBF
)
v
=
*
(
DWORD
*
)
&
comp_value
;
else
if
(
format
->
type
==
FORMAT_ARGB
)
v
=
comp_value
*
((
1
<<
format
->
bits
[
c
])
-
1
)
+
0
.
5
f
;
else
...
...
@@ -1282,7 +1284,7 @@ HRESULT WINAPI D3DXFillTexture(struct IDirect3DTexture9 *texture, LPD3DXFILL2D f
return
D3DERR_INVALIDCALL
;
format
=
get_format_info
(
desc
.
Format
);
if
(
format
->
type
!=
FORMAT_ARGB
&&
format
->
type
!=
FORMAT_ARGBF16
)
if
(
format
->
type
!=
FORMAT_ARGB
&&
format
->
type
!=
FORMAT_ARGBF16
&&
format
->
type
!=
FORMAT_ARGBF
)
{
FIXME
(
"Unsupported texture format %#x
\n
"
,
desc
.
Format
);
return
D3DERR_INVALIDCALL
;
...
...
@@ -1649,7 +1651,7 @@ HRESULT WINAPI D3DXFillCubeTexture(struct IDirect3DCubeTexture9 *texture, LPD3DX
return
D3DERR_INVALIDCALL
;
format
=
get_format_info
(
desc
.
Format
);
if
(
format
->
type
!=
FORMAT_ARGB
&&
format
->
type
!=
FORMAT_ARGBF16
)
if
(
format
->
type
!=
FORMAT_ARGB
&&
format
->
type
!=
FORMAT_ARGBF16
&&
format
->
type
!=
FORMAT_ARGBF
)
{
FIXME
(
"Unsupported texture format %#x
\n
"
,
desc
.
Format
);
return
D3DERR_INVALIDCALL
;
...
...
@@ -1708,7 +1710,7 @@ HRESULT WINAPI D3DXFillVolumeTexture(struct IDirect3DVolumeTexture9 *texture, LP
return
D3DERR_INVALIDCALL
;
format
=
get_format_info
(
desc
.
Format
);
if
(
format
->
type
!=
FORMAT_ARGB
&&
format
->
type
!=
FORMAT_ARGBF16
)
if
(
format
->
type
!=
FORMAT_ARGB
&&
format
->
type
!=
FORMAT_ARGBF16
&&
format
->
type
!=
FORMAT_ARGBF
)
{
FIXME
(
"Unsupported texture format %#x
\n
"
,
desc
.
Format
);
return
D3DERR_INVALIDCALL
;
...
...
dlls/d3dx9_36/util.c
View file @
25ce3a42
...
...
@@ -71,6 +71,7 @@ static const struct pixel_format_desc formats[] =
{
D3DFMT_DXT4
,
{
0
,
0
,
0
,
0
},
{
0
,
0
,
0
,
0
},
1
,
4
,
4
,
16
,
FORMAT_DXT
,
NULL
,
NULL
},
{
D3DFMT_DXT5
,
{
0
,
0
,
0
,
0
},
{
0
,
0
,
0
,
0
},
1
,
4
,
4
,
16
,
FORMAT_DXT
,
NULL
,
NULL
},
{
D3DFMT_A16B16G16R16F
,
{
16
,
16
,
16
,
16
},
{
48
,
0
,
16
,
32
},
8
,
1
,
1
,
8
,
FORMAT_ARGBF16
,
NULL
,
NULL
},
{
D3DFMT_A32B32G32R32F
,
{
32
,
32
,
32
,
32
},
{
96
,
0
,
32
,
64
},
16
,
1
,
1
,
16
,
FORMAT_ARGBF
,
NULL
,
NULL
},
/* marks last element */
{
D3DFMT_UNKNOWN
,
{
0
,
0
,
0
,
0
},
{
0
,
0
,
0
,
0
},
0
,
1
,
1
,
0
,
FORMAT_UNKNOWN
,
NULL
,
NULL
},
};
...
...
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