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
6c866e06
Commit
6c866e06
authored
Jul 12, 2011
by
Michael Stefaniuc
Committed by
Alexandre Julliard
Jul 12, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
d3d10core: Use unsafe_impl_from_ID3D10InputLayout for an app provided iface.
parent
dc3ee8b9
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
18 additions
and
1 deletion
+18
-1
d3d10core_private.h
dlls/d3d10core/d3d10core_private.h
+1
-0
device.c
dlls/d3d10core/device.c
+2
-1
inputlayout.c
dlls/d3d10core/inputlayout.c
+15
-0
No files found.
dlls/d3d10core/d3d10core_private.h
View file @
6c866e06
...
...
@@ -164,6 +164,7 @@ struct d3d10_input_layout
HRESULT
d3d10_input_layout_init
(
struct
d3d10_input_layout
*
layout
,
struct
d3d10_device
*
device
,
const
D3D10_INPUT_ELEMENT_DESC
*
element_descs
,
UINT
element_count
,
const
void
*
shader_byte_code
,
SIZE_T
shader_byte_code_length
)
DECLSPEC_HIDDEN
;
struct
d3d10_input_layout
*
unsafe_impl_from_ID3D10InputLayout
(
ID3D10InputLayout
*
iface
)
DECLSPEC_HIDDEN
;
/* ID3D10VertexShader */
struct
d3d10_vertex_shader
...
...
dlls/d3d10core/device.c
View file @
6c866e06
...
...
@@ -192,11 +192,12 @@ static void STDMETHODCALLTYPE d3d10_device_IASetInputLayout(ID3D10Device *iface,
ID3D10InputLayout
*
input_layout
)
{
struct
d3d10_device
*
This
=
impl_from_ID3D10Device
(
iface
);
struct
d3d10_input_layout
*
layout
=
unsafe_impl_from_ID3D10InputLayout
(
input_layout
);
TRACE
(
"iface %p, input_layout %p
\n
"
,
iface
,
input_layout
);
wined3d_device_set_vertex_declaration
(
This
->
wined3d_device
,
input_layout
?
((
struct
d3d10_input_layout
*
)
input_layout
)
->
wined3d_decl
:
NULL
);
layout
?
layout
->
wined3d_decl
:
NULL
);
}
static
void
STDMETHODCALLTYPE
d3d10_device_IASetVertexBuffers
(
ID3D10Device
*
iface
,
UINT
start_slot
,
...
...
dlls/d3d10core/inputlayout.c
View file @
6c866e06
...
...
@@ -19,6 +19,7 @@
#include "config.h"
#include "wine/port.h"
#include <assert.h>
#include "d3d10core_private.h"
...
...
@@ -100,6 +101,11 @@ static HRESULT d3d10_input_layout_to_wined3d_declaration(const D3D10_INPUT_ELEME
return
S_OK
;
}
static
inline
struct
d3d10_input_layout
*
impl_from_ID3D10InputLayout
(
ID3D10InputLayout
*
iface
)
{
return
CONTAINING_RECORD
(
iface
,
struct
d3d10_input_layout
,
vtbl
);
}
/* IUnknown methods */
static
HRESULT
STDMETHODCALLTYPE
d3d10_input_layout_QueryInterface
(
ID3D10InputLayout
*
iface
,
...
...
@@ -238,3 +244,12 @@ HRESULT d3d10_input_layout_init(struct d3d10_input_layout *layout, struct d3d10_
return
S_OK
;
}
struct
d3d10_input_layout
*
unsafe_impl_from_ID3D10InputLayout
(
ID3D10InputLayout
*
iface
)
{
if
(
!
iface
)
return
NULL
;
assert
(
iface
->
lpVtbl
==
&
d3d10_input_layout_vtbl
);
return
impl_from_ID3D10InputLayout
(
iface
);
}
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