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
29468906
Commit
29468906
authored
Mar 11, 2012
by
Henri Verbeet
Committed by
Alexandre Julliard
Mar 12, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Pass correctly offset pointers to surface_cpu_blt_compressed().
This was debugged by Alexey Loukianov.
parent
b39425f3
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
13 additions
and
8 deletions
+13
-8
surface.c
dlls/wined3d/surface.c
+13
-8
No files found.
dlls/wined3d/surface.c
View file @
29468906
...
...
@@ -6620,6 +6620,7 @@ static HRESULT surface_cpu_blt(struct wined3d_surface *dst_surface, const RECT *
const
struct
wined3d_format
*
src_format
,
*
dst_format
;
struct
wined3d_surface
*
orig_src
=
src_surface
;
struct
wined3d_mapped_rect
dst_map
,
src_map
;
const
BYTE
*
sbase
=
NULL
;
HRESULT
hr
=
WINED3D_OK
;
const
BYTE
*
sbuf
;
RECT
xdst
,
xsrc
;
...
...
@@ -6745,6 +6746,17 @@ static HRESULT surface_cpu_blt(struct wined3d_surface *dst_surface, const RECT *
dstwidth
=
xdst
.
right
-
xdst
.
left
;
width
=
(
xdst
.
right
-
xdst
.
left
)
*
bpp
;
if
(
src_surface
)
sbase
=
(
BYTE
*
)
src_map
.
data
+
((
xsrc
.
top
/
src_format
->
block_height
)
*
src_map
.
row_pitch
)
+
((
xsrc
.
left
/
src_format
->
block_width
)
*
src_format
->
block_byte_count
);
if
(
dst_rect
&&
src_surface
!=
dst_surface
)
dbuf
=
dst_map
.
data
;
else
dbuf
=
(
BYTE
*
)
dst_map
.
data
+
((
xdst
.
top
/
dst_format
->
block_height
)
*
dst_map
.
row_pitch
)
+
((
xdst
.
left
/
dst_format
->
block_width
)
*
dst_format
->
block_byte_count
);
if
(
src_format
->
flags
&
dst_format
->
flags
&
WINED3DFMT_FLAG_BLOCKS
)
{
TRACE
(
"%s -> %s copy.
\n
"
,
debug_d3dformat
(
src_format
->
id
),
debug_d3dformat
(
dst_format
->
id
));
...
...
@@ -6770,17 +6782,12 @@ static HRESULT surface_cpu_blt(struct wined3d_surface *dst_surface, const RECT *
goto
release
;
}
hr
=
surface_cpu_blt_compressed
(
s
rc_map
.
data
,
dst_map
.
data
,
hr
=
surface_cpu_blt_compressed
(
s
base
,
dbuf
,
src_map
.
row_pitch
,
dst_map
.
row_pitch
,
dstwidth
,
dstheight
,
src_format
,
flags
,
fx
);
goto
release
;
}
if
(
dst_rect
&&
src_surface
!=
dst_surface
)
dbuf
=
dst_map
.
data
;
else
dbuf
=
(
BYTE
*
)
dst_map
.
data
+
(
xdst
.
top
*
dst_map
.
row_pitch
)
+
(
xdst
.
left
*
bpp
);
/* First, all the 'source-less' blits */
if
(
flags
&
WINEDDBLT_COLORFILL
)
{
...
...
@@ -6820,7 +6827,6 @@ static HRESULT surface_cpu_blt(struct wined3d_surface *dst_surface, const RECT *
/* Now the 'with source' blits. */
if
(
src_surface
)
{
const
BYTE
*
sbase
;
int
sx
,
xinc
,
sy
,
yinc
;
if
(
!
dstwidth
||
!
dstheight
)
/* Hmm... stupid program? */
...
...
@@ -6833,7 +6839,6 @@ static HRESULT surface_cpu_blt(struct wined3d_surface *dst_surface, const RECT *
FIXME
(
"Filter %s not supported in software blit.
\n
"
,
debug_d3dtexturefiltertype
(
filter
));
}
sbase
=
(
BYTE
*
)
src_map
.
data
+
(
xsrc
.
top
*
src_map
.
row_pitch
)
+
xsrc
.
left
*
bpp
;
xinc
=
(
srcwidth
<<
16
)
/
dstwidth
;
yinc
=
(
srcheight
<<
16
)
/
dstheight
;
...
...
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