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
920225d4
Commit
920225d4
authored
Dec 10, 2006
by
Stefan Dösinger
Committed by
Alexandre Julliard
Dec 11, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Move WINED3DRS_POINTSPRITEENABLE to the state table.
parent
2b775221
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
26 additions
and
26 deletions
+26
-26
device.c
dlls/wined3d/device.c
+1
-25
state.c
dlls/wined3d/state.c
+25
-1
No files found.
dlls/wined3d/device.c
View file @
920225d4
...
...
@@ -3406,6 +3406,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_SetRenderState(IWineD3DDevice *iface, W
case
WINED3DRS_LOCALVIEWER
:
case
WINED3DRS_LASTPIXEL
:
case
WINED3DRS_SOFTWAREVERTEXPROCESSING
:
case
WINED3DRS_POINTSPRITEENABLE
:
StateTable
[
STATE_RENDER
(
State
)].
apply
(
STATE_RENDER
(
State
),
This
->
stateBlock
);
break
;
...
...
@@ -3415,31 +3416,6 @@ static HRESULT WINAPI IWineD3DDeviceImpl_SetRenderState(IWineD3DDevice *iface, W
LEAVE_GL
();
return
WINED3DERR_INVALIDCALL
;
}
case
WINED3DRS_POINTSPRITEENABLE
:
{
/* TODO: NV_POINT_SPRITE */
if
(
!
GL_SUPPORT
(
ARB_POINT_SPRITE
))
{
TRACE
(
"Point sprites not supported
\n
"
);
break
;
}
/*
* Point sprites are always enabled. Value controls texture coordinate
* replacement mode. Must be set true for point sprites to use
* textures.
*/
glEnable
(
GL_POINT_SPRITE_ARB
);
checkGLcall
(
"glEnable(GL_POINT_SPRITE_ARB)"
);
if
(
Value
)
{
glTexEnvf
(
GL_POINT_SPRITE_ARB
,
GL_COORD_REPLACE_ARB
,
TRUE
);
checkGLcall
(
"glTexEnvf(GL_POINT_SPRITE, GL_COORD_REPLACE, TRUE)"
);
}
else
{
glTexEnvf
(
GL_POINT_SPRITE_ARB
,
GL_COORD_REPLACE_ARB
,
FALSE
);
checkGLcall
(
"glTexEnvf(GL_POINT_SPRITE, GL_COORD_REPLACE, FALSE)"
);
}
break
;
}
case
WINED3DRS_WRAP0
:
case
WINED3DRS_WRAP1
:
...
...
dlls/wined3d/state.c
View file @
920225d4
...
...
@@ -1044,6 +1044,30 @@ static void state_lastpixel(DWORD state, IWineD3DStateBlockImpl *stateblock) {
}
}
static
void
state_pointsprite
(
DWORD
state
,
IWineD3DStateBlockImpl
*
stateblock
)
{
/* TODO: NV_POINT_SPRITE */
if
(
!
GL_SUPPORT
(
ARB_POINT_SPRITE
))
{
TRACE
(
"Point sprites not supported
\n
"
);
return
;
}
/*
* Point sprites are always enabled. Value controls texture coordinate
* replacement mode. Must be set true for point sprites to use
* textures.
*/
glEnable
(
GL_POINT_SPRITE_ARB
);
checkGLcall
(
"glEnable(GL_POINT_SPRITE_ARB)"
);
if
(
stateblock
->
renderState
[
WINED3DRS_POINTSPRITEENABLE
])
{
glTexEnvf
(
GL_POINT_SPRITE_ARB
,
GL_COORD_REPLACE_ARB
,
TRUE
);
checkGLcall
(
"glTexEnvf(GL_POINT_SPRITE, GL_COORD_REPLACE, TRUE)"
);
}
else
{
glTexEnvf
(
GL_POINT_SPRITE_ARB
,
GL_COORD_REPLACE_ARB
,
FALSE
);
checkGLcall
(
"glTexEnvf(GL_POINT_SPRITE, GL_COORD_REPLACE, FALSE)"
);
}
}
const
struct
StateEntry
StateTable
[]
=
{
/* State name representative, apply function */
...
...
@@ -1205,7 +1229,7 @@ const struct StateEntry StateTable[] =
{
/*153, WINED3DRS_SOFTWAREVERTEXPROCESSING */
0
,
state_nogl
},
{
/*154, WINED3DRS_POINTSIZE */
STATE_RENDER
(
WINED3DRS_POINTSIZE
),
state_psize
},
{
/*155, WINED3DRS_POINTSIZE_MIN */
STATE_RENDER
(
WINED3DRS_POINTSIZE_MIN
),
state_psizemin
},
{
/*156, WINED3DRS_POINTSPRITEENABLE */
STATE_RENDER
(
WINED3DRS_POINTSPRITEENABLE
),
state_
unknown
},
{
/*156, WINED3DRS_POINTSPRITEENABLE */
STATE_RENDER
(
WINED3DRS_POINTSPRITEENABLE
),
state_
pointsprite
},
{
/*157, WINED3DRS_POINTSCALEENABLE */
STATE_RENDER
(
WINED3DRS_POINTSCALEENABLE
),
state_pscale
},
{
/*158, WINED3DRS_POINTSCALE_A */
STATE_RENDER
(
WINED3DRS_POINTSCALEENABLE
),
state_pscale
},
{
/*159, WINED3DRS_POINTSCALE_B */
STATE_RENDER
(
WINED3DRS_POINTSCALEENABLE
),
state_pscale
},
...
...
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