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
f0b68737
Commit
f0b68737
authored
Feb 24, 2017
by
Henri Verbeet
Committed by
Alexandre Julliard
Feb 24, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Implement depth fills in the CPU blitter.
Signed-off-by:
Henri Verbeet
<
hverbeet@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
e3f55717
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
10 deletions
+17
-10
surface.c
dlls/wined3d/surface.c
+17
-10
No files found.
dlls/wined3d/surface.c
View file @
f0b68737
...
...
@@ -2975,10 +2975,8 @@ static BOOL cpu_blit_supported(const struct wined3d_gl_info *gl_info,
const
RECT
*
src_rect
,
DWORD
src_usage
,
enum
wined3d_pool
src_pool
,
const
struct
wined3d_format
*
src_format
,
const
RECT
*
dst_rect
,
DWORD
dst_usage
,
enum
wined3d_pool
dst_pool
,
const
struct
wined3d_format
*
dst_format
)
{
if
(
blit_op
==
WINED3D_BLIT_OP_COLOR_FILL
)
{
if
(
blit_op
==
WINED3D_BLIT_OP_COLOR_FILL
||
blit_op
==
WINED3D_BLIT_OP_DEPTH_FILL
)
return
TRUE
;
}
return
FALSE
;
}
...
...
@@ -3208,15 +3206,12 @@ static HRESULT surface_cpu_blt(struct wined3d_texture *dst_texture, unsigned int
}
/* First, all the 'source-less' blits */
if
(
flags
&
WINED3D_BLT_COLOR_FILL
)
if
(
flags
&
(
WINED3D_BLT_COLOR_FILL
|
WINED3D_BLT_DEPTH_FILL
)
)
{
hr
=
_Blt_ColorFill
(
dbuf
,
dst_width
,
dst_height
,
bpp
,
dst_map
.
row_pitch
,
fx
->
fill_color
);
flags
&=
~
WINED3D_BLT_COLOR_FILL
;
flags
&=
~
(
WINED3D_BLT_COLOR_FILL
|
WINED3D_BLT_DEPTH_FILL
)
;
}
if
(
flags
&
WINED3D_BLT_DEPTH_FILL
)
FIXME
(
"WINED3D_BLT_DEPTH_FILL needs to be implemented!
\n
"
);
/* Now the 'with source' blits. */
if
(
src_texture
)
{
...
...
@@ -3587,8 +3582,20 @@ static HRESULT cpu_blit_depth_fill(struct wined3d_device *device,
struct
wined3d_rendertarget_view
*
view
,
const
RECT
*
rect
,
DWORD
clear_flags
,
float
depth
,
DWORD
stencil
)
{
FIXME
(
"Depth/stencil filling not implemented by cpu_blit.
\n
"
);
return
WINED3DERR_INVALIDCALL
;
const
struct
wined3d_box
box
=
{
rect
->
left
,
rect
->
top
,
rect
->
right
,
rect
->
bottom
,
0
,
1
};
struct
wined3d_color
color
=
{
depth
,
0
.
0
f
,
0
.
0
f
,
0
.
0
f
};
static
const
struct
wined3d_box
src_box
;
struct
wined3d_blt_fx
fx
;
if
(
clear_flags
!=
WINED3DCLEAR_ZBUFFER
)
{
FIXME
(
"clear_flags %#x not implemented.
\n
"
,
clear_flags
);
return
WINED3DERR_INVALIDCALL
;
}
fx
.
fill_color
=
wined3d_format_convert_from_float
(
view
->
format
,
&
color
);
return
surface_cpu_blt
(
texture_from_resource
(
view
->
resource
),
view
->
sub_resource_idx
,
&
box
,
NULL
,
0
,
&
src_box
,
WINED3D_BLT_DEPTH_FILL
,
&
fx
,
WINED3D_TEXF_POINT
);
}
static
void
cpu_blit_blit_surface
(
struct
wined3d_device
*
device
,
enum
wined3d_blit_op
op
,
DWORD
filter
,
...
...
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