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
3ccb66f4
Commit
3ccb66f4
authored
Jan 08, 2015
by
Matteo Bruni
Committed by
Alexandre Julliard
Jan 09, 2015
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
wined3d: Use the core version of the glBlend* functions.
parent
993075cd
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
9 deletions
+17
-9
directx.c
dlls/wined3d/directx.c
+8
-0
state.c
dlls/wined3d/state.c
+9
-9
No files found.
dlls/wined3d/directx.c
View file @
3ccb66f4
...
...
@@ -2876,6 +2876,10 @@ static void load_gl_funcs(struct wined3d_gl_info *gl_info)
/* Newer core functions */
USE_GL_FUNC
(
glActiveTexture
)
/* OpenGL 1.3 */
USE_GL_FUNC
(
glBlendColor
)
/* OpenGL 1.4 */
USE_GL_FUNC
(
glBlendEquation
)
/* OpenGL 1.4 */
USE_GL_FUNC
(
glBlendEquationSeparate
)
/* OpenGL 2.0 */
USE_GL_FUNC
(
glBlendFuncSeparate
)
/* OpenGL 1.4 */
#undef USE_GL_FUNC
#ifndef USE_WIN32_OPENGL
...
...
@@ -2892,6 +2896,10 @@ static void load_gl_funcs(struct wined3d_gl_info *gl_info)
} while (0)
MAP_GL_FUNCTION
(
glActiveTexture
,
glActiveTextureARB
);
MAP_GL_FUNCTION
(
glBlendColor
,
glBlendColorEXT
);
MAP_GL_FUNCTION
(
glBlendEquation
,
glBlendEquationEXT
);
MAP_GL_FUNCTION
(
glBlendEquationSeparate
,
glBlendEquationSeparateEXT
);
MAP_GL_FUNCTION
(
glBlendFuncSeparate
,
glBlendFuncSeparateEXT
);
#undef MAP_GL_FUNCTION
}
...
...
dlls/wined3d/state.c
View file @
3ccb66f4
...
...
@@ -317,7 +317,7 @@ static void state_blendop(struct wined3d_context *context, const struct wined3d_
if
(
state
->
render_states
[
WINED3D_RS_BLENDOPALPHA
]
&&
!
gl_info
->
supported
[
EXT_BLEND_EQUATION_SEPARATE
])
{
WARN
(
"Unsupported in local OpenGL implementation: glBlendEquationSeparate
EXT
\n
"
);
WARN
(
"Unsupported in local OpenGL implementation: glBlendEquationSeparate
.
\n
"
);
return
;
}
...
...
@@ -327,12 +327,12 @@ static void state_blendop(struct wined3d_context *context, const struct wined3d_
if
(
state
->
render_states
[
WINED3D_RS_SEPARATEALPHABLENDENABLE
])
{
GL_EXTCALL
(
glBlendEquationSeparate
EXT
(
blend_equation
,
blend_equation_alpha
));
checkGLcall
(
"glBlendEquationSeparate
EXT
"
);
GL_EXTCALL
(
glBlendEquationSeparate
(
blend_equation
,
blend_equation_alpha
));
checkGLcall
(
"glBlendEquationSeparate"
);
}
else
{
GL_EXTCALL
(
glBlendEquation
EXT
(
blend_equation
));
GL_EXTCALL
(
glBlendEquation
(
blend_equation
));
checkGLcall
(
"glBlendEquation"
);
}
}
...
...
@@ -462,7 +462,7 @@ static void state_blend(struct wined3d_context *context, const struct wined3d_st
/* Separate alpha blending requires GL_EXT_blend_function_separate, so make sure it is around */
if
(
!
context
->
gl_info
->
supported
[
EXT_BLEND_FUNC_SEPARATE
])
{
WARN
(
"Unsupported in local OpenGL implementation: glBlendFuncSeparate
EXT
\n
"
);
WARN
(
"Unsupported in local OpenGL implementation: glBlendFuncSeparate
.
\n
"
);
return
;
}
...
...
@@ -486,8 +486,8 @@ static void state_blend(struct wined3d_context *context, const struct wined3d_st
dstBlendAlpha
=
gl_blend_factor
(
state
->
render_states
[
WINED3D_RS_DESTBLENDALPHA
],
rt_format
);
}
GL_EXTCALL
(
glBlendFuncSeparate
EXT
(
srcBlend
,
dstBlend
,
srcBlendAlpha
,
dstBlendAlpha
));
checkGLcall
(
"glBlendFuncSeparate
EXT
"
);
GL_EXTCALL
(
glBlendFuncSeparate
(
srcBlend
,
dstBlend
,
srcBlendAlpha
,
dstBlendAlpha
));
checkGLcall
(
"glBlendFuncSeparate"
);
}
else
{
...
...
@@ -504,7 +504,7 @@ static void state_blend(struct wined3d_context *context, const struct wined3d_st
static
void
state_blendfactor_w
(
struct
wined3d_context
*
context
,
const
struct
wined3d_state
*
state
,
DWORD
state_id
)
{
WARN
(
"Unsupported in local OpenGL implementation: glBlendColor
EXT
\n
"
);
WARN
(
"Unsupported in local OpenGL implementation: glBlendColor
.
\n
"
);
}
static
void
state_blendfactor
(
struct
wined3d_context
*
context
,
const
struct
wined3d_state
*
state
,
DWORD
state_id
)
...
...
@@ -515,7 +515,7 @@ static void state_blendfactor(struct wined3d_context *context, const struct wine
TRACE
(
"Setting blend factor to %#x.
\n
"
,
state
->
render_states
[
WINED3D_RS_BLENDFACTOR
]);
D3DCOLORTOGLFLOAT4
(
state
->
render_states
[
WINED3D_RS_BLENDFACTOR
],
col
);
GL_EXTCALL
(
glBlendColor
EXT
(
col
[
0
],
col
[
1
],
col
[
2
],
col
[
3
]));
GL_EXTCALL
(
glBlendColor
(
col
[
0
],
col
[
1
],
col
[
2
],
col
[
3
]));
checkGLcall
(
"glBlendColor"
);
}
...
...
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