Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
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-cw
Commits
5f3425b8
Commit
5f3425b8
authored
Sep 30, 2009
by
Henri Verbeet
Committed by
Alexandre Julliard
Sep 30, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Get rid of stateblock_copy().
parent
345b3292
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
23 deletions
+11
-23
stateblock.c
dlls/wined3d/stateblock.c
+11
-23
No files found.
dlls/wined3d/stateblock.c
View file @
5f3425b8
...
...
@@ -228,23 +228,6 @@ static void stateblock_copy_values(IWineD3DStateBlockImpl *dst, const IWineD3DSt
memcpy
(
dst
->
pixelShaderConstantF
,
src
->
pixelShaderConstantF
,
sizeof
(
float
)
*
gl_info
->
max_pshader_constantsF
*
4
);
}
static
void
stateblock_copy
(
IWineD3DStateBlockImpl
*
dst
,
const
IWineD3DStateBlockImpl
*
src
)
{
const
struct
wined3d_gl_info
*
gl_info
=
&
src
->
wineD3DDevice
->
adapter
->
gl_info
;
dst
->
lpVtbl
=
src
->
lpVtbl
;
dst
->
ref
=
src
->
ref
;
dst
->
parent
=
src
->
parent
;
dst
->
wineD3DDevice
=
src
->
wineD3DDevice
;
dst
->
blockType
=
src
->
blockType
;
/* Saved states */
stateblock_savedstates_copy
(
&
dst
->
changed
,
&
src
->
changed
,
gl_info
);
/* Saved values */
stateblock_copy_values
(
dst
,
src
,
gl_info
);
}
/**********************************************************
* IWineD3DStateBlockImpl IUnknown parts follows
**********************************************************/
...
...
@@ -1387,13 +1370,18 @@ HRESULT stateblock_init(IWineD3DStateBlockImpl *stateblock, IWineD3DDeviceImpl *
if
(
type
==
WINED3DSBT_INIT
||
type
==
WINED3DSBT_RECORDED
)
return
WINED3D_OK
;
/* Otherwise, might as well set the whole state block to the appropriate values */
if
(
device
->
stateBlock
)
stateblock_copy
(
stateblock
,
device
->
stateBlock
);
else
memset
(
stateblock
->
streamFreq
,
1
,
sizeof
(
stateblock
->
streamFreq
));
if
(
device
->
stateBlock
)
{
/* Saved states */
stateblock_savedstates_copy
(
&
stateblock
->
changed
,
&
device
->
stateBlock
->
changed
,
gl_info
);
/* Reset the ref and type after kludging it. */
stateblock
->
wineD3DDevice
=
device
;
stateblock
->
ref
=
1
;
stateblock
->
blockType
=
type
;
/* Saved values */
stateblock_copy_values
(
stateblock
,
device
->
stateBlock
,
gl_info
);
}
else
{
memset
(
stateblock
->
streamFreq
,
1
,
sizeof
(
stateblock
->
streamFreq
));
}
TRACE
(
"Updating changed flags appropriate for type %#x.
\n
"
,
type
);
...
...
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