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
2dd18635
Commit
2dd18635
authored
Dec 14, 2008
by
Stefan Dösinger
Committed by
Alexandre Julliard
Jan 12, 2009
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Move fogdensity and fogcolor to the fragment pipeline.
parent
e61aa24a
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
12 additions
and
4 deletions
+12
-4
arb_program_shader.c
dlls/wined3d/arb_program_shader.c
+2
-0
ati_fragment_shader.c
dlls/wined3d/ati_fragment_shader.c
+2
-0
nvidia_texture_shader.c
dlls/wined3d/nvidia_texture_shader.c
+2
-0
state.c
dlls/wined3d/state.c
+4
-4
wined3d_private.h
dlls/wined3d/wined3d_private.h
+2
-0
No files found.
dlls/wined3d/arb_program_shader.c
View file @
2dd18635
...
...
@@ -3191,6 +3191,8 @@ static const struct StateEntryTemplate arbfp_fragmentstate_template[] = {
{
STATE_RENDER
(
WINED3DRS_FOGTABLEMODE
),
{
STATE_RENDER
(
WINED3DRS_FOGENABLE
),
state_arbfp_fog
},
0
},
{
STATE_RENDER
(
WINED3DRS_FOGVERTEXMODE
),
{
STATE_RENDER
(
WINED3DRS_FOGENABLE
),
state_arbfp_fog
},
0
},
{
STATE_RENDER
(
WINED3DRS_SRGBWRITEENABLE
),
{
STATE_PIXELSHADER
,
fragment_prog_arbfp
},
0
},
{
STATE_RENDER
(
WINED3DRS_FOGCOLOR
),
{
STATE_RENDER
(
WINED3DRS_FOGCOLOR
),
state_fogcolor
},
0
},
{
STATE_RENDER
(
WINED3DRS_FOGDENSITY
),
{
STATE_RENDER
(
WINED3DRS_FOGDENSITY
),
state_fogdensity
},
0
},
{
STATE_TEXTURESTAGE
(
0
,
WINED3DTSS_TEXTURETRANSFORMFLAGS
),{
STATE_TEXTURESTAGE
(
0
,
WINED3DTSS_TEXTURETRANSFORMFLAGS
),
textransform
},
0
},
{
STATE_TEXTURESTAGE
(
1
,
WINED3DTSS_TEXTURETRANSFORMFLAGS
),{
STATE_TEXTURESTAGE
(
1
,
WINED3DTSS_TEXTURETRANSFORMFLAGS
),
textransform
},
0
},
{
STATE_TEXTURESTAGE
(
2
,
WINED3DTSS_TEXTURETRANSFORMFLAGS
),{
STATE_TEXTURESTAGE
(
2
,
WINED3DTSS_TEXTURETRANSFORMFLAGS
),
textransform
},
0
},
...
...
dlls/wined3d/ati_fragment_shader.c
View file @
2dd18635
...
...
@@ -909,6 +909,8 @@ static void atifs_apply_pixelshader(DWORD state, IWineD3DStateBlockImpl *statebl
static
const
struct
StateEntryTemplate
atifs_fragmentstate_template
[]
=
{
{
STATE_RENDER
(
WINED3DRS_TEXTUREFACTOR
),
{
STATE_RENDER
(
WINED3DRS_TEXTUREFACTOR
),
state_texfactor_atifs
},
0
},
{
STATE_RENDER
(
WINED3DRS_FOGCOLOR
),
{
STATE_RENDER
(
WINED3DRS_FOGCOLOR
),
state_fogcolor
},
0
},
{
STATE_RENDER
(
WINED3DRS_FOGDENSITY
),
{
STATE_RENDER
(
WINED3DRS_FOGDENSITY
),
state_fogdensity
},
0
},
{
STATE_TEXTURESTAGE
(
0
,
WINED3DTSS_COLOROP
),
{
STATE_TEXTURESTAGE
(
0
,
WINED3DTSS_COLOROP
),
set_tex_op_atifs
},
0
},
{
STATE_TEXTURESTAGE
(
0
,
WINED3DTSS_COLORARG1
),
{
STATE_TEXTURESTAGE
(
0
,
WINED3DTSS_COLOROP
),
set_tex_op_atifs
},
0
},
{
STATE_TEXTURESTAGE
(
0
,
WINED3DTSS_COLORARG2
),
{
STATE_TEXTURESTAGE
(
0
,
WINED3DTSS_COLOROP
),
set_tex_op_atifs
},
0
},
...
...
dlls/wined3d/nvidia_texture_shader.c
View file @
2dd18635
...
...
@@ -792,6 +792,8 @@ static const struct StateEntryTemplate nvrc_fragmentstate_template[] = {
{
STATE_PIXELSHADER
,
{
STATE_PIXELSHADER
,
apply_pixelshader
},
0
},
{
STATE_RENDER
(
WINED3DRS_SRGBWRITEENABLE
),
{
STATE_PIXELSHADER
,
apply_pixelshader
},
0
},
{
STATE_RENDER
(
WINED3DRS_TEXTUREFACTOR
),
{
STATE_RENDER
(
WINED3DRS_TEXTUREFACTOR
),
nvrc_texfactor
},
0
},
{
STATE_RENDER
(
WINED3DRS_FOGCOLOR
),
{
STATE_RENDER
(
WINED3DRS_FOGCOLOR
),
state_fogcolor
},
0
},
{
STATE_RENDER
(
WINED3DRS_FOGDENSITY
),
{
STATE_RENDER
(
WINED3DRS_FOGDENSITY
),
state_fogdensity
},
0
},
{
STATE_SAMPLER
(
0
),
{
STATE_SAMPLER
(
0
),
nvts_texdim
},
NV_TEXTURE_SHADER2
},
{
STATE_SAMPLER
(
0
),
{
STATE_SAMPLER
(
0
),
sampler_texdim
},
0
},
{
STATE_SAMPLER
(
1
),
{
STATE_SAMPLER
(
1
),
nvts_texdim
},
NV_TEXTURE_SHADER2
},
...
...
dlls/wined3d/state.c
View file @
2dd18635
...
...
@@ -1117,14 +1117,14 @@ static void state_rangefog(DWORD state, IWineD3DStateBlockImpl *stateblock, Wine
}
}
static
void
state_fogcolor
(
DWORD
state
,
IWineD3DStateBlockImpl
*
stateblock
,
WineD3DContext
*
context
)
{
void
state_fogcolor
(
DWORD
state
,
IWineD3DStateBlockImpl
*
stateblock
,
WineD3DContext
*
context
)
{
float
col
[
4
];
D3DCOLORTOGLFLOAT4
(
stateblock
->
renderState
[
WINED3DRS_FOGCOLOR
],
col
);
glFogfv
(
GL_FOG_COLOR
,
&
col
[
0
]);
checkGLcall
(
"glFog GL_FOG_COLOR"
);
}
static
void
state_fogdensity
(
DWORD
state
,
IWineD3DStateBlockImpl
*
stateblock
,
WineD3DContext
*
context
)
{
void
state_fogdensity
(
DWORD
state
,
IWineD3DStateBlockImpl
*
stateblock
,
WineD3DContext
*
context
)
{
union
{
DWORD
d
;
float
f
;
...
...
@@ -5180,8 +5180,6 @@ const struct StateEntryTemplate ffp_vertexstate_template[] = {
{
STATE_RENDER
(
WINED3DRS_FOGSTART
),
{
STATE_RENDER
(
WINED3DRS_FOGENABLE
),
state_fog
},
0
},
{
STATE_RENDER
(
WINED3DRS_FOGEND
),
{
STATE_RENDER
(
WINED3DRS_FOGENABLE
),
state_fog
},
0
},
{
STATE_RENDER
(
WINED3DRS_FOGVERTEXMODE
),
{
STATE_RENDER
(
WINED3DRS_FOGENABLE
),
state_fog
},
0
},
{
STATE_RENDER
(
WINED3DRS_FOGCOLOR
),
{
STATE_RENDER
(
WINED3DRS_FOGCOLOR
),
state_fogcolor
},
0
},
{
STATE_RENDER
(
WINED3DRS_FOGDENSITY
),
{
STATE_RENDER
(
WINED3DRS_FOGDENSITY
),
state_fogdensity
},
0
},
{
STATE_RENDER
(
WINED3DRS_RANGEFOGENABLE
),
{
STATE_RENDER
(
WINED3DRS_RANGEFOGENABLE
),
state_rangefog
},
NV_FOG_DISTANCE
},
{
STATE_RENDER
(
WINED3DRS_RANGEFOGENABLE
),
{
STATE_RENDER
(
WINED3DRS_RANGEFOGENABLE
),
state_rangefog_w
},
0
},
{
STATE_RENDER
(
WINED3DRS_CLIPPING
),
{
STATE_RENDER
(
WINED3DRS_CLIPPING
),
state_clipping
},
0
},
...
...
@@ -5328,6 +5326,8 @@ static const struct StateEntryTemplate ffp_fragmentstate_template[] = {
{
STATE_RENDER
(
WINED3DRS_SRGBWRITEENABLE
),
{
STATE_PIXELSHADER
,
apply_pixelshader
},
0
},
{
STATE_RENDER
(
WINED3DRS_BORDERCOLOR
),
{
STATE_RENDER
(
WINED3DRS_BORDERCOLOR
),
state_bordercolor
},
0
},
{
STATE_RENDER
(
WINED3DRS_TEXTUREFACTOR
),
{
STATE_RENDER
(
WINED3DRS_TEXTUREFACTOR
),
state_texfactor
},
0
},
{
STATE_RENDER
(
WINED3DRS_FOGCOLOR
),
{
STATE_RENDER
(
WINED3DRS_FOGCOLOR
),
state_fogcolor
},
0
},
{
STATE_RENDER
(
WINED3DRS_FOGDENSITY
),
{
STATE_RENDER
(
WINED3DRS_FOGDENSITY
),
state_fogdensity
},
0
},
{
STATE_SAMPLER
(
0
),
{
STATE_SAMPLER
(
0
),
sampler_texdim
},
0
},
{
STATE_SAMPLER
(
1
),
{
STATE_SAMPLER
(
1
),
sampler_texdim
},
0
},
{
STATE_SAMPLER
(
2
),
{
STATE_SAMPLER
(
2
),
sampler_texdim
},
0
},
...
...
dlls/wined3d/wined3d_private.h
View file @
2dd18635
...
...
@@ -2021,6 +2021,8 @@ void texture_activate_dimensions(DWORD stage, IWineD3DStateBlockImpl *stateblock
void
sampler_texdim
(
DWORD
state
,
IWineD3DStateBlockImpl
*
stateblock
,
WineD3DContext
*
context
);
void
tex_alphaop
(
DWORD
state
,
IWineD3DStateBlockImpl
*
stateblock
,
WineD3DContext
*
context
);
void
apply_pixelshader
(
DWORD
state
,
IWineD3DStateBlockImpl
*
stateblock
,
WineD3DContext
*
context
);
void
state_fogcolor
(
DWORD
state
,
IWineD3DStateBlockImpl
*
stateblock
,
WineD3DContext
*
context
);
void
state_fogdensity
(
DWORD
state
,
IWineD3DStateBlockImpl
*
stateblock
,
WineD3DContext
*
context
);
void
surface_force_reload
(
IWineD3DSurface
*
iface
);
GLenum
surface_get_gl_buffer
(
IWineD3DSurface
*
iface
,
IWineD3DSwapChain
*
swapchain
);
...
...
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