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
4674b94d
Commit
4674b94d
authored
Mar 29, 2011
by
Henri Verbeet
Committed by
Alexandre Julliard
Mar 30, 2011
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Get rid of struct wined3d_geometryshader.
parent
dab01d43
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
23 deletions
+17
-23
device.c
dlls/wined3d/device.c
+1
-1
shader.c
dlls/wined3d/shader.c
+12
-12
wined3d_private.h
dlls/wined3d/wined3d_private.h
+4
-10
No files found.
dlls/wined3d/device.c
View file @
4674b94d
...
...
@@ -1549,7 +1549,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_CreateGeometryShader(IWineD3DDevice *if
IWineD3DBaseShader
**
shader
)
{
IWineD3DDeviceImpl
*
This
=
(
IWineD3DDeviceImpl
*
)
iface
;
struct
wined3d_geometryshader
*
object
;
IWineD3DBaseShaderImpl
*
object
;
HRESULT
hr
;
object
=
HeapAlloc
(
GetProcessHeap
(),
HEAP_ZERO_MEMORY
,
sizeof
(
*
object
));
...
...
dlls/wined3d/shader.c
View file @
4674b94d
...
...
@@ -1913,8 +1913,8 @@ static HRESULT STDMETHODCALLTYPE geometryshader_QueryInterface(IWineD3DBaseShade
static
ULONG
STDMETHODCALLTYPE
geometryshader_AddRef
(
IWineD3DBaseShader
*
iface
)
{
struct
wined3d_geometryshader
*
shader
=
(
struct
wined3d_geometryshader
*
)
iface
;
ULONG
refcount
=
InterlockedIncrement
(
&
shader
->
base
_s
hader
.
ref
);
IWineD3DBaseShaderImpl
*
shader
=
(
IWineD3DBaseShaderImpl
*
)
iface
;
ULONG
refcount
=
InterlockedIncrement
(
&
shader
->
base
S
hader
.
ref
);
TRACE
(
"%p increasing refcount to %u.
\n
"
,
shader
,
refcount
);
...
...
@@ -1924,15 +1924,15 @@ static ULONG STDMETHODCALLTYPE geometryshader_AddRef(IWineD3DBaseShader *iface)
/* Do not call while under the GL lock. */
static
ULONG
STDMETHODCALLTYPE
geometryshader_Release
(
IWineD3DBaseShader
*
iface
)
{
struct
wined3d_geometryshader
*
shader
=
(
struct
wined3d_geometryshader
*
)
iface
;
ULONG
refcount
=
InterlockedDecrement
(
&
shader
->
base
_s
hader
.
ref
);
IWineD3DBaseShaderImpl
*
shader
=
(
IWineD3DBaseShaderImpl
*
)
iface
;
ULONG
refcount
=
InterlockedDecrement
(
&
shader
->
base
S
hader
.
ref
);
TRACE
(
"%p decreasing refcount to %u.
\n
"
,
shader
,
refcount
);
if
(
!
refcount
)
{
shader_cleanup
(
(
IWineD3DBaseShaderImpl
*
)
shader
);
shader
->
base
_shader
.
parent_ops
->
wined3d_object_destroyed
(
shader
->
base_s
hader
.
parent
);
shader_cleanup
(
shader
);
shader
->
base
Shader
.
parent_ops
->
wined3d_object_destroyed
(
shader
->
baseS
hader
.
parent
);
HeapFree
(
GetProcessHeap
(),
0
,
shader
);
}
...
...
@@ -1975,24 +1975,24 @@ static const IWineD3DBaseShaderVtbl wined3d_geometryshader_vtbl =
geometryshader_SetLocalConstantsF
,
};
HRESULT
geometryshader_init
(
struct
wined3d_geometryshader
*
shader
,
IWineD3DDeviceImpl
*
device
,
HRESULT
geometryshader_init
(
IWineD3DBaseShaderImpl
*
shader
,
IWineD3DDeviceImpl
*
device
,
const
DWORD
*
byte_code
,
const
struct
wined3d_shader_signature
*
output_signature
,
void
*
parent
,
const
struct
wined3d_parent_ops
*
parent_ops
)
{
HRESULT
hr
;
shader
->
v
tbl
=
&
wined3d_geometryshader_vtbl
;
shader_init
(
&
shader
->
base
_s
hader
,
device
,
parent
,
parent_ops
);
shader
->
lpV
tbl
=
&
wined3d_geometryshader_vtbl
;
shader_init
(
&
shader
->
base
S
hader
,
device
,
parent
,
parent_ops
);
hr
=
shader_set_function
(
(
IWineD3DBaseShaderImpl
*
)
shader
,
byte_code
,
output_signature
,
0
);
hr
=
shader_set_function
(
shader
,
byte_code
,
output_signature
,
0
);
if
(
FAILED
(
hr
))
{
WARN
(
"Failed to set function, hr %#x.
\n
"
,
hr
);
shader_cleanup
(
(
IWineD3DBaseShaderImpl
*
)
shader
);
shader_cleanup
(
shader
);
return
hr
;
}
shader
->
base
_s
hader
.
load_local_constsF
=
FALSE
;
shader
->
base
S
hader
.
load_local_constsF
=
FALSE
;
return
WINED3D_OK
;
}
...
...
dlls/wined3d/wined3d_private.h
View file @
4674b94d
...
...
@@ -2738,6 +2738,10 @@ typedef struct IWineD3DBaseShaderImpl {
}
u
;
}
IWineD3DBaseShaderImpl
;
HRESULT
geometryshader_init
(
IWineD3DBaseShaderImpl
*
shader
,
IWineD3DDeviceImpl
*
device
,
const
DWORD
*
byte_code
,
const
struct
wined3d_shader_signature
*
output_signature
,
void
*
parent
,
const
struct
wined3d_parent_ops
*
parent_ops
)
DECLSPEC_HIDDEN
;
void
find_vs_compile_args
(
const
struct
wined3d_state
*
state
,
IWineD3DBaseShaderImpl
*
shader
,
struct
vs_compile_args
*
args
)
DECLSPEC_HIDDEN
;
HRESULT
vertexshader_init
(
IWineD3DBaseShaderImpl
*
shader
,
IWineD3DDeviceImpl
*
device
,
...
...
@@ -2828,16 +2832,6 @@ static inline BOOL shader_constant_is_local(IWineD3DBaseShaderImpl* This, DWORD
}
struct
wined3d_geometryshader
{
const
struct
IWineD3DBaseShaderVtbl
*
vtbl
;
IWineD3DBaseShaderClass
base_shader
;
};
HRESULT
geometryshader_init
(
struct
wined3d_geometryshader
*
shader
,
IWineD3DDeviceImpl
*
device
,
const
DWORD
*
byte_code
,
const
struct
wined3d_shader_signature
*
output_signature
,
void
*
parent
,
const
struct
wined3d_parent_ops
*
parent_ops
)
DECLSPEC_HIDDEN
;
/*****************************************************************************
* IDirect3DPixelShader implementation structure
*/
...
...
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