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
ac689f0a
Commit
ac689f0a
authored
Nov 16, 2017
by
Henri Verbeet
Committed by
Alexandre Julliard
Nov 15, 2017
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Use raw blits in wined3d_device_copy_resource().
Signed-off-by:
Henri Verbeet
<
hverbeet@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
786ebbde
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
10 additions
and
7 deletions
+10
-7
cs.c
dlls/wined3d/cs.c
+2
-2
device.c
dlls/wined3d/device.c
+2
-2
surface.c
dlls/wined3d/surface.c
+5
-3
wined3d.h
include/wine/wined3d.h
+1
-0
No files found.
dlls/wined3d/cs.c
View file @
ac689f0a
...
...
@@ -2045,14 +2045,14 @@ static void wined3d_cs_exec_blt_sub_resource(struct wined3d_cs *cs, const void *
struct
wined3d_context
*
context
;
struct
wined3d_bo_address
addr
;
if
(
op
->
flags
)
if
(
op
->
flags
&
~
WINED3D_BLT_RAW
)
{
FIXME
(
"Flags %#x not implemented for %s resources.
\n
"
,
op
->
flags
,
debug_d3dresourcetype
(
op
->
dst_resource
->
type
));
goto
error
;
}
if
(
op
->
src_resource
->
format
!=
op
->
dst_resource
->
format
)
if
(
!
(
op
->
flags
&
WINED3D_BLT_RAW
)
&&
op
->
src_resource
->
format
!=
op
->
dst_resource
->
format
)
{
FIXME
(
"Format conversion not implemented for %s resources.
\n
"
,
debug_d3dresourcetype
(
op
->
dst_resource
->
type
));
...
...
dlls/wined3d/device.c
View file @
ac689f0a
...
...
@@ -4041,7 +4041,7 @@ void CDECL wined3d_device_copy_resource(struct wined3d_device *device,
{
wined3d_box_set
(
&
box
,
0
,
0
,
src_resource
->
size
,
1
,
0
,
1
);
wined3d_cs_emit_blt_sub_resource
(
device
->
cs
,
dst_resource
,
0
,
&
box
,
src_resource
,
0
,
&
box
,
0
,
NULL
,
WINED3D_TEXF_POINT
);
src_resource
,
0
,
&
box
,
WINED3D_BLT_RAW
,
NULL
,
WINED3D_TEXF_POINT
);
return
;
}
...
...
@@ -4068,7 +4068,7 @@ void CDECL wined3d_device_copy_resource(struct wined3d_device *device,
unsigned
int
idx
=
j
*
dst_texture
->
level_count
+
i
;
wined3d_cs_emit_blt_sub_resource
(
device
->
cs
,
dst_resource
,
idx
,
&
box
,
src_resource
,
idx
,
&
box
,
0
,
NULL
,
WINED3D_TEXF_POINT
);
src_resource
,
idx
,
&
box
,
WINED3D_BLT_RAW
,
NULL
,
WINED3D_TEXF_POINT
);
}
}
}
...
...
dlls/wined3d/surface.c
View file @
ac689f0a
...
...
@@ -3073,7 +3073,7 @@ static HRESULT surface_cpu_blt(struct wined3d_texture *dst_texture, unsigned int
same_sub_resource
=
FALSE
;
dst_format
=
dst_texture
->
resource
.
format
;
dst_fmt_flags
=
dst_texture
->
resource
.
format_flags
;
if
(
dst_texture
->
resource
.
format
->
id
!=
src_texture
->
resource
.
format
->
id
)
if
(
!
(
flags
&
WINED3D_BLT_RAW
)
&&
dst_texture
->
resource
.
format
->
id
!=
src_texture
->
resource
.
format
->
id
)
{
if
(
!
(
converted_texture
=
surface_convert_format
(
src_texture
,
src_sub_resource_idx
,
dst_format
)))
{
...
...
@@ -3108,6 +3108,7 @@ static HRESULT surface_cpu_blt(struct wined3d_texture *dst_texture, unsigned int
dst_map
.
data
=
context_map_bo_address
(
context
,
&
dst_data
,
dst_texture
->
sub_resources
[
dst_sub_resource_idx
].
size
,
GL_PIXEL_UNPACK_BUFFER
,
0
);
}
flags
&=
~
WINED3D_BLT_RAW
;
bpp
=
dst_format
->
byte_count
;
src_height
=
src_box
->
bottom
-
src_box
->
top
;
...
...
@@ -3737,7 +3738,8 @@ HRESULT wined3d_surface_blt(struct wined3d_surface *dst_surface, const RECT *dst
static
const
DWORD
simple_blit
=
WINED3D_BLT_SRC_CKEY
|
WINED3D_BLT_SRC_CKEY_OVERRIDE
|
WINED3D_BLT_ALPHA_TEST
;
|
WINED3D_BLT_ALPHA_TEST
|
WINED3D_BLT_RAW
;
TRACE
(
"dst_surface %p, dst_rect %s, src_surface %p, src_rect %s, flags %#x, fx %p, filter %s.
\n
"
,
dst_surface
,
wine_dbgstr_rect
(
dst_rect
),
src_surface
,
wine_dbgstr_rect
(
src_rect
),
...
...
@@ -3908,7 +3910,7 @@ HRESULT wined3d_surface_blt(struct wined3d_surface *dst_surface, const RECT *dst
return
WINED3D_OK
;
}
else
if
(
!
scale
&&
!
convert
)
else
if
(
(
flags
&
WINED3D_BLT_RAW
)
||
(
!
scale
&&
!
convert
)
)
{
blit_op
=
WINED3D_BLIT_OP_RAW_BLIT
;
}
...
...
include/wine/wined3d.h
View file @
ac689f0a
...
...
@@ -1342,6 +1342,7 @@ enum wined3d_shader_byte_code_format
#define WINED3D_BLT_SRC_CKEY_OVERRIDE 0x00010000
#define WINED3D_BLT_WAIT 0x01000000
#define WINED3D_BLT_DO_NOT_WAIT 0x08000000
#define WINED3D_BLT_RAW 0x20000000
#define WINED3D_BLT_SYNCHRONOUS 0x40000000
#define WINED3D_BLT_ALPHA_TEST 0x80000000
#define WINED3D_BLT_MASK 0x0901e800
...
...
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