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
bda6d092
Commit
bda6d092
authored
Aug 26, 2006
by
Ivan Gyurdiev
Committed by
Alexandre Julliard
Aug 28, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Add support for A16B16G16R16F and A32B32G32R32F texture formats.
parent
aec5bc33
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
36 additions
and
4 deletions
+36
-4
directx.c
dlls/wined3d/directx.c
+21
-2
utils.c
dlls/wined3d/utils.c
+2
-2
wined3d_gl.h
include/wine/wined3d_gl.h
+13
-0
No files found.
dlls/wined3d/directx.c
View file @
bda6d092
...
...
@@ -576,6 +576,12 @@ BOOL IWineD3DImpl_FillGLCaps(IWineD3D *iface, Display* display) {
}
else
if
(
strcmp
(
ThisExtn
,
"GL_ARB_texture_env_dot3"
)
==
0
)
{
TRACE_
(
d3d_caps
)(
" FOUND: ARB Dot3 support
\n
"
);
gl_info
->
supported
[
ARB_TEXTURE_ENV_DOT3
]
=
TRUE
;
}
else
if
(
strcmp
(
ThisExtn
,
"GL_ARB_texture_float"
)
==
0
)
{
TRACE_
(
d3d_caps
)(
" FOUND: ARB Float texture support
\n
"
);
gl_info
->
supported
[
ARB_TEXTURE_FLOAT
]
=
TRUE
;
}
else
if
(
strcmp
(
ThisExtn
,
"GL_ARB_half_float_pixel"
)
==
0
)
{
TRACE_
(
d3d_caps
)(
" FOUND: ARB Half-float pixel support
\n
"
);
gl_info
->
supported
[
ARB_HALF_FLOAT_PIXEL
]
=
TRUE
;
}
else
if
(
strcmp
(
ThisExtn
,
"GL_ARB_texture_border_clamp"
)
==
0
)
{
TRACE_
(
d3d_caps
)(
" FOUND: ARB Texture border clamp support
\n
"
);
gl_info
->
supported
[
ARB_TEXTURE_BORDER_CLAMP
]
=
TRUE
;
...
...
@@ -1639,6 +1645,21 @@ static HRESULT WINAPI IWineD3DImpl_CheckDeviceFormat(IWineD3D *iface, UINT Adapt
}
}
if
(
GL_SUPPORT
(
ARB_TEXTURE_FLOAT
))
{
BOOL
half_pixel_support
=
GL_SUPPORT
(
ARB_HALF_FLOAT_PIXEL
);
switch
(
CheckFormat
)
{
case
D3DFMT_A16B16G16R16F
:
if
(
!
half_pixel_support
)
break
;
case
D3DFMT_A32B32G32R32F
:
TRACE_
(
d3d_caps
)(
"[OK]
\n
"
);
return
WINED3D_OK
;
default:
break
;
/* Avoid compiler warnings */
}
}
/* This format is nothing special and it is supported perfectly.
* However, ati and nvidia driver on windows do not mark this format
* supported(tested with the dxCapsViewer) and pretending to
...
...
@@ -1729,10 +1750,8 @@ static HRESULT WINAPI IWineD3DImpl_CheckDeviceFormat(IWineD3D *iface, UINT Adapt
*/
case
WINED3DFMT_R16F
:
case
WINED3DFMT_G16R16F
:
case
WINED3DFMT_A16B16G16R16F
:
case
WINED3DFMT_R32F
:
case
WINED3DFMT_G32R32F
:
case
WINED3DFMT_A32B32G32R32F
:
case
WINED3DFMT_CxV8U8
:
TRACE_
(
d3d_caps
)(
"[FAILED]
\n
"
);
/* Enable when implemented */
return
WINED3DERR_NOTAVAILABLE
;
...
...
dlls/wined3d/utils.c
View file @
bda6d092
...
...
@@ -49,13 +49,13 @@ static const PixelFormatDesc formats[] = {
/* IEEE formats */
{
WINED3DFMT_R32F
,
0x0
,
0x0
,
0x0
,
0x0
,
4
,
FALSE
,
0
,
0
,
0
},
{
WINED3DFMT_G32R32F
,
0x0
,
0x0
,
0x0
,
0x0
,
8
,
FALSE
,
0
,
0
,
0
},
{
WINED3DFMT_A32B32G32R32F
,
0x0
,
0x0
,
0x0
,
0x0
,
16
,
FALSE
,
0
,
0
,
0
},
{
WINED3DFMT_A32B32G32R32F
,
0x0
,
0x0
,
0x0
,
0x0
,
16
,
FALSE
,
GL_RGBA32F_ARB
,
GL_RGBA
,
GL_FLOAT
},
/* Hmm? */
{
WINED3DFMT_CxV8U8
,
0x0
,
0x0
,
0x0
,
0x0
,
2
,
FALSE
,
0
,
0
,
0
},
/* Float */
{
WINED3DFMT_R16F
,
0x0
,
0x0
,
0x0
,
0x0
,
2
,
FALSE
,
0
,
0
,
0
},
{
WINED3DFMT_G16R16F
,
0x0
,
0x0
,
0x0
,
0x0
,
4
,
FALSE
,
0
,
0
,
0
},
{
WINED3DFMT_A16B16G16R16F
,
0x0
,
0x0
,
0x0
,
0x0
,
8
,
FALSE
,
0
,
0
,
0
},
{
WINED3DFMT_A16B16G16R16F
,
0x0
,
0x0
,
0x0
,
0x0
,
8
,
FALSE
,
GL_RGBA16F_ARB
,
GL_RGBA
,
GL_HALF_FLOAT_ARB
},
/* Palettized formats */
{
WINED3DFMT_A8P8
,
0x0000ff00
,
0x0
,
0x0
,
0x0
,
2
,
FALSE
,
0
,
0
,
0
},
{
WINED3DFMT_P8
,
0x0
,
0x0
,
0x0
,
0x0
,
1
,
FALSE
,
GL_COLOR_INDEX8_EXT
,
GL_COLOR_INDEX
,
GL_UNSIGNED_BYTE
},
...
...
include/wine/wined3d_gl.h
View file @
bda6d092
...
...
@@ -473,6 +473,17 @@ typedef void (APIENTRY * PGLFNGLTEXSUBIMAGE3DEXTPROC) (GLenum target, GLint leve
#define GL_DOT3_RGB_EXT 0x8740
#define GL_DOT3_RGBA_EXT 0x8741
#endif
/* GL_ARB_texture_float */
#ifndef GL_ARB_texture_float
#define GL_ARB_texture_float 1
#define GL_RGBA32F_ARB 0x8814
#define GL_RGBA16F_ARB 0x881A
#endif
/* GL_ARB_half_float_pixel */
#ifndef GL_ARB_half_float_pixel
#define GL_ARB_half_float_pixel
#define GL_HALF_FLOAT_ARB 0x140B
#endif
/* GL_ARB_vertex_program */
#ifndef GL_ARB_vertex_program
#define GL_ARB_vertex_program 1
...
...
@@ -1407,6 +1418,8 @@ typedef enum _GL_SupportedExt {
ARB_TEXTURE_ENV_ADD
,
ARB_TEXTURE_ENV_COMBINE
,
ARB_TEXTURE_ENV_DOT3
,
ARB_TEXTURE_FLOAT
,
ARB_HALF_FLOAT_PIXEL
,
ARB_TEXTURE_BORDER_CLAMP
,
ARB_TEXTURE_MIRRORED_REPEAT
,
ARB_VERTEX_PROGRAM
,
...
...
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