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
6e827317
Commit
6e827317
authored
Oct 23, 2011
by
Henri Verbeet
Committed by
Alexandre Julliard
Oct 24, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Reject multisampled readbacks in wined3d_surface_get_render_target_data().
parent
4229d865
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
18 additions
and
3 deletions
+18
-3
device.c
dlls/d3d9/device.c
+1
-2
visual.c
dlls/d3d9/tests/visual.c
+1
-1
surface.c
dlls/wined3d/surface.c
+13
-0
wined3d.spec
dlls/wined3d/wined3d.spec
+1
-0
wined3d.h
include/wine/wined3d.h
+2
-0
No files found.
dlls/d3d9/device.c
View file @
6e827317
...
...
@@ -971,8 +971,7 @@ static HRESULT WINAPI IDirect3DDevice9Impl_GetRenderTargetData(IDirect3DDevice9E
TRACE
(
"iface %p, render_target %p, dst_surface %p.
\n
"
,
iface
,
pRenderTarget
,
pDestSurface
);
wined3d_mutex_lock
();
hr
=
wined3d_surface_bltfast
(
destSurface
->
wined3d_surface
,
0
,
0
,
renderTarget
->
wined3d_surface
,
NULL
,
WINEDDBLTFAST_NOCOLORKEY
);
hr
=
wined3d_surface_get_render_target_data
(
destSurface
->
wined3d_surface
,
renderTarget
->
wined3d_surface
);
wined3d_mutex_unlock
();
return
hr
;
...
...
dlls/d3d9/tests/visual.c
View file @
6e827317
...
...
@@ -12644,7 +12644,7 @@ static void multisample_get_rtdata_test(IDirect3DDevice9 *device)
hr
=
IDirect3DDevice9_Clear
(
device
,
0
,
NULL
,
D3DCLEAR_TARGET
,
0xff00ff00
,
0
.
0
,
0
);
ok
(
SUCCEEDED
(
hr
),
"Failed to clear render target, hr %#x.
\n
"
,
hr
);
hr
=
IDirect3DDevice9_GetRenderTargetData
(
device
,
rt
,
readback
);
todo_wine
ok
(
hr
==
D3DERR_INVALIDCALL
,
"Got unexpected hr %#x.
\n
"
,
hr
);
ok
(
hr
==
D3DERR_INVALIDCALL
,
"Got unexpected hr %#x.
\n
"
,
hr
);
hr
=
IDirect3DDevice9_SetDepthStencilSurface
(
device
,
original_ds
);
ok
(
SUCCEEDED
(
hr
),
"Failed to set depth/stencil, hr %#x.
\n
"
,
hr
);
...
...
dlls/wined3d/surface.c
View file @
6e827317
...
...
@@ -1826,6 +1826,19 @@ HRESULT CDECL wined3d_surface_bltfast(struct wined3d_surface *dst_surface, DWORD
return
wined3d_surface_blt
(
dst_surface
,
&
dst_rect
,
src_surface
,
&
src_rect
,
flags
,
NULL
,
WINED3DTEXF_POINT
);
}
HRESULT
CDECL
wined3d_surface_get_render_target_data
(
struct
wined3d_surface
*
surface
,
struct
wined3d_surface
*
render_target
)
{
TRACE
(
"surface %p, render_target %p.
\n
"
,
surface
,
render_target
);
/* TODO: Check surface sizes, pools, etc. */
if
(
render_target
->
resource
.
multisample_type
)
return
WINED3DERR_INVALIDCALL
;
return
wined3d_surface_blt
(
surface
,
NULL
,
render_target
,
NULL
,
0
,
NULL
,
WINED3DTEXF_POINT
);
}
/* Context activation is done by the caller. */
static
void
surface_remove_pbo
(
struct
wined3d_surface
*
surface
,
const
struct
wined3d_gl_info
*
gl_info
)
{
...
...
dlls/wined3d/wined3d.spec
View file @
6e827317
...
...
@@ -212,6 +212,7 @@
@ cdecl wined3d_surface_get_parent(ptr)
@ cdecl wined3d_surface_get_pitch(ptr)
@ cdecl wined3d_surface_get_priority(ptr)
@ cdecl wined3d_surface_get_render_target_data(ptr ptr)
@ cdecl wined3d_surface_get_resource(ptr)
@ cdecl wined3d_surface_getdc(ptr ptr)
@ cdecl wined3d_surface_incref(ptr)
...
...
include/wine/wined3d.h
View file @
6e827317
...
...
@@ -2428,6 +2428,8 @@ struct wined3d_palette * __cdecl wined3d_surface_get_palette(const struct wined3
void
*
__cdecl
wined3d_surface_get_parent
(
const
struct
wined3d_surface
*
surface
);
DWORD
__cdecl
wined3d_surface_get_pitch
(
const
struct
wined3d_surface
*
surface
);
DWORD
__cdecl
wined3d_surface_get_priority
(
const
struct
wined3d_surface
*
surface
);
HRESULT
__cdecl
wined3d_surface_get_render_target_data
(
struct
wined3d_surface
*
surface
,
struct
wined3d_surface
*
render_target
);
struct
wined3d_resource
*
__cdecl
wined3d_surface_get_resource
(
struct
wined3d_surface
*
surface
);
HRESULT
__cdecl
wined3d_surface_getdc
(
struct
wined3d_surface
*
surface
,
HDC
*
dc
);
ULONG
__cdecl
wined3d_surface_incref
(
struct
wined3d_surface
*
surface
);
...
...
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