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
c964134a
Commit
c964134a
authored
Jan 26, 2011
by
Henri Verbeet
Committed by
Alexandre Julliard
Jan 27, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Add support for the NULL format.
parent
2469597e
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
17 additions
and
3 deletions
+17
-3
context.c
dlls/wined3d/context.c
+4
-3
directx.c
dlls/wined3d/directx.c
+5
-0
utils.c
dlls/wined3d/utils.c
+7
-0
wined3d.idl
include/wine/wined3d.idl
+1
-0
No files found.
dlls/wined3d/context.c
View file @
c964134a
...
...
@@ -271,7 +271,7 @@ static void context_attach_surface_fbo(const struct wined3d_context *context,
TRACE
(
"Attach surface %p to %u
\n
"
,
surface
,
idx
);
if
(
surface
)
if
(
surface
&&
surface
->
resource
.
format
->
id
!=
WINED3DFMT_NULL
)
{
switch
(
location
)
{
...
...
@@ -1932,7 +1932,7 @@ static void context_apply_draw_buffers(struct wined3d_context *context, UINT rt_
for
(
i
=
0
;
i
<
gl_info
->
limits
.
buffers
;
++
i
)
{
if
(
i
<
rt_count
&&
rts
[
i
])
if
(
i
<
rt_count
&&
rts
[
i
]
&&
rts
[
i
]
->
resource
.
format
->
id
!=
WINED3DFMT_NULL
)
context
->
draw_buffers
[
i
]
=
GL_COLOR_ATTACHMENT0
+
i
;
else
context
->
draw_buffers
[
i
]
=
GL_NONE
;
...
...
@@ -2062,7 +2062,8 @@ static BOOL context_validate_rt_config(UINT rt_count,
for
(
i
=
0
;
i
<
rt_count
;
++
i
)
{
if
(
rts
[
i
])
return
TRUE
;
if
(
rts
[
i
]
&&
rts
[
i
]
->
resource
.
format
->
id
!=
WINED3DFMT_NULL
)
return
TRUE
;
}
WARN
(
"Invalid render target config, need at least one attachment.
\n
"
);
...
...
dlls/wined3d/directx.c
View file @
c964134a
...
...
@@ -3470,6 +3470,11 @@ static BOOL CheckTextureCapability(struct wined3d_adapter *adapter, const struct
TRACE_
(
d3d_caps
)(
"[FAILED]
\n
"
);
return
FALSE
;
case
WINED3DFMT_NULL
:
if
(
gl_info
->
supported
[
ARB_FRAMEBUFFER_OBJECT
])
return
TRUE
;
return
FALSE
;
case
WINED3DFMT_UNKNOWN
:
return
FALSE
;
...
...
dlls/wined3d/utils.c
View file @
c964134a
...
...
@@ -133,6 +133,7 @@ static const struct StaticPixelFormatDesc formats[] =
{
WINED3DFMT_INTZ
,
0x0
,
0x0
,
0x0
,
0x0
,
4
,
24
,
8
},
{
WINED3DFMT_NVHU
,
0x0
,
0x0
,
0x0
,
0x0
,
2
,
0
,
0
},
{
WINED3DFMT_NVHS
,
0x0
,
0x0
,
0x0
,
0x0
,
2
,
0
,
0
},
{
WINED3DFMT_NULL
,
0xff000000
,
0x000000ff
,
0x0000ff00
,
0x00ff0000
,
4
,
0
,
0
},
};
struct
wined3d_format_base_flags
...
...
@@ -158,6 +159,7 @@ static const struct wined3d_format_base_flags format_base_flags[] =
{
WINED3DFMT_G8R8_G8B8
,
WINED3DFMT_FLAG_FOURCC
},
{
WINED3DFMT_R8G8_B8G8
,
WINED3DFMT_FLAG_FOURCC
},
{
WINED3DFMT_INTZ
,
WINED3DFMT_FLAG_FOURCC
},
{
WINED3DFMT_NULL
,
WINED3DFMT_FLAG_FOURCC
},
{
WINED3DFMT_P8_UINT
,
WINED3DFMT_FLAG_GETDC
},
{
WINED3DFMT_B8G8R8_UNORM
,
WINED3DFMT_FLAG_GETDC
},
{
WINED3DFMT_B8G8R8A8_UNORM
,
WINED3DFMT_FLAG_GETDC
},
...
...
@@ -868,6 +870,10 @@ static const struct wined3d_format_texture_info format_texture_info[] =
WINED3DFMT_FLAG_POSTPIXELSHADER_BLENDING
|
WINED3DFMT_FLAG_FILTERING
|
WINED3DFMT_FLAG_DEPTH
|
WINED3DFMT_FLAG_STENCIL
,
ARB_FRAMEBUFFER_OBJECT
,
NULL
},
{
WINED3DFMT_NULL
,
GL_RGBA8
,
GL_RGBA8
,
0
,
GL_RGBA
,
GL_UNSIGNED_INT_8_8_8_8_REV
,
0
,
WINED3DFMT_FLAG_RENDERTARGET
,
ARB_FRAMEBUFFER_OBJECT
,
NULL
},
};
static
inline
int
getFmtIdx
(
enum
wined3d_format_id
format_id
)
...
...
@@ -1740,6 +1746,7 @@ const char *debug_d3dformat(enum wined3d_format_id format_id)
FMT_TO_STR
(
WINED3DFMT_B8G8R8A8_UNORM
);
FMT_TO_STR
(
WINED3DFMT_B8G8R8X8_UNORM
);
FMT_TO_STR
(
WINED3DFMT_INTZ
);
FMT_TO_STR
(
WINED3DFMT_NULL
);
#undef FMT_TO_STR
default:
{
...
...
include/wine/wined3d.idl
View file @
c964134a
...
...
@@ -275,6 +275,7 @@ enum wined3d_format_id
WINED3DFMT_NVHU
=
WINEMAKEFOURCC
(
'N'
,
'V'
,
'H'
,
'U'
),
WINED3DFMT_NVHS
=
WINEMAKEFOURCC
(
'N'
,
'V'
,
'H'
,
'S'
),
WINED3DFMT_INTZ
=
WINEMAKEFOURCC
(
'I'
,
'N'
,
'T'
,
'Z'
),
WINED3DFMT_NULL
=
WINEMAKEFOURCC
(
'N'
,
'U'
,
'L'
,
'L'
),
WINED3DFMT_FORCE_DWORD
=
0
xffffffff
}
;
...
...
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