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
6909b514
Commit
6909b514
authored
Sep 23, 2012
by
Henri Verbeet
Committed by
Alexandre Julliard
Sep 24, 2012
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Just return the shader from wined3d_device_get_vertex_shader().
parent
b97ec7ae
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
18 deletions
+5
-18
device.c
dlls/d3d8/device.c
+3
-7
device.c
dlls/d3d9/device.c
+1
-3
device.c
dlls/wined3d/device.c
+1
-8
No files found.
dlls/d3d8/device.c
View file @
6909b514
...
@@ -2174,7 +2174,6 @@ static HRESULT WINAPI d3d8_device_DeleteVertexShader(IDirect3DDevice8 *iface, DW
...
@@ -2174,7 +2174,6 @@ static HRESULT WINAPI d3d8_device_DeleteVertexShader(IDirect3DDevice8 *iface, DW
{
{
struct
d3d8_device
*
device
=
impl_from_IDirect3DDevice8
(
iface
);
struct
d3d8_device
*
device
=
impl_from_IDirect3DDevice8
(
iface
);
struct
d3d8_vertex_shader
*
shader_impl
;
struct
d3d8_vertex_shader
*
shader_impl
;
struct
wined3d_shader
*
cur
;
TRACE
(
"iface %p, shader %#x.
\n
"
,
iface
,
shader
);
TRACE
(
"iface %p, shader %#x.
\n
"
,
iface
,
shader
);
...
@@ -2187,12 +2186,9 @@ static HRESULT WINAPI d3d8_device_DeleteVertexShader(IDirect3DDevice8 *iface, DW
...
@@ -2187,12 +2186,9 @@ static HRESULT WINAPI d3d8_device_DeleteVertexShader(IDirect3DDevice8 *iface, DW
return
D3DERR_INVALIDCALL
;
return
D3DERR_INVALIDCALL
;
}
}
if
((
cur
=
wined3d_device_get_vertex_shader
(
device
->
wined3d_device
)))
if
(
shader_impl
->
wined3d_shader
{
&&
wined3d_device_get_vertex_shader
(
device
->
wined3d_device
)
==
shader_impl
->
wined3d_shader
)
if
(
cur
==
shader_impl
->
wined3d_shader
)
IDirect3DDevice8_SetVertexShader
(
iface
,
0
);
IDirect3DDevice8_SetVertexShader
(
iface
,
0
);
wined3d_shader_decref
(
cur
);
}
wined3d_mutex_unlock
();
wined3d_mutex_unlock
();
...
...
dlls/d3d9/device.c
View file @
6909b514
...
@@ -2286,13 +2286,11 @@ static HRESULT WINAPI d3d9_device_GetVertexShader(IDirect3DDevice9Ex *iface, IDi
...
@@ -2286,13 +2286,11 @@ static HRESULT WINAPI d3d9_device_GetVertexShader(IDirect3DDevice9Ex *iface, IDi
TRACE
(
"iface %p, shader %p.
\n
"
,
iface
,
shader
);
TRACE
(
"iface %p, shader %p.
\n
"
,
iface
,
shader
);
wined3d_mutex_lock
();
wined3d_mutex_lock
();
wined3d_shader
=
wined3d_device_get_vertex_shader
(
device
->
wined3d_device
);
if
((
wined3d_shader
=
wined3d_device_get_vertex_shader
(
device
->
wined3d_device
)))
if
(
wined3d_shader
)
{
{
shader_impl
=
wined3d_shader_get_parent
(
wined3d_shader
);
shader_impl
=
wined3d_shader_get_parent
(
wined3d_shader
);
*
shader
=
&
shader_impl
->
IDirect3DVertexShader9_iface
;
*
shader
=
&
shader_impl
->
IDirect3DVertexShader9_iface
;
IDirect3DVertexShader9_AddRef
(
*
shader
);
IDirect3DVertexShader9_AddRef
(
*
shader
);
wined3d_shader_decref
(
wined3d_shader
);
}
}
else
else
{
{
...
...
dlls/wined3d/device.c
View file @
6909b514
...
@@ -2480,16 +2480,9 @@ void CDECL wined3d_device_set_vertex_shader(struct wined3d_device *device, struc
...
@@ -2480,16 +2480,9 @@ void CDECL wined3d_device_set_vertex_shader(struct wined3d_device *device, struc
struct
wined3d_shader
*
CDECL
wined3d_device_get_vertex_shader
(
const
struct
wined3d_device
*
device
)
struct
wined3d_shader
*
CDECL
wined3d_device_get_vertex_shader
(
const
struct
wined3d_device
*
device
)
{
{
struct
wined3d_shader
*
shader
;
TRACE
(
"device %p.
\n
"
,
device
);
TRACE
(
"device %p.
\n
"
,
device
);
shader
=
device
->
stateBlock
->
state
.
vertex_shader
;
return
device
->
stateBlock
->
state
.
vertex_shader
;
if
(
shader
)
wined3d_shader_incref
(
shader
);
TRACE
(
"Returning %p.
\n
"
,
shader
);
return
shader
;
}
}
HRESULT
CDECL
wined3d_device_set_vs_consts_b
(
struct
wined3d_device
*
device
,
HRESULT
CDECL
wined3d_device_set_vs_consts_b
(
struct
wined3d_device
*
device
,
...
...
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