Commit 905261ab authored by Matteo Bruni's avatar Matteo Bruni Committed by Alexandre Julliard

wined3d: Cleanup extension check for shader model 4 support.

This essentially enables shader model 4 support with Mesa or OS X when using core profile. Signed-off-by: 's avatarMatteo Bruni <mbruni@codeweavers.com> Signed-off-by: 's avatarHenri Verbeet <hverbeet@codeweavers.com> Signed-off-by: 's avatarAlexandre Julliard <julliard@winehq.org>
parent bc9a95bb
......@@ -3553,6 +3553,8 @@ static BOOL wined3d_adapter_init_gl_caps(struct wined3d_adapter *adapter)
if (gl_version >= MAKEDWORD_VERSION(2, 0))
gl_info->supported[WINED3D_GL_VERSION_2_0] = TRUE;
if (gl_version >= MAKEDWORD_VERSION(3, 2))
gl_info->supported[WINED3D_GL_VERSION_3_2] = TRUE;
if (gl_info->supported[APPLE_FENCE])
{
......
......@@ -7761,10 +7761,8 @@ static void shader_glsl_get_caps(const struct wined3d_gl_info *gl_info, struct s
{
UINT shader_model;
if (gl_info->supported[EXT_GPU_SHADER4] && gl_info->supported[ARB_SHADER_BIT_ENCODING]
&& gl_info->supported[ARB_GEOMETRY_SHADER4] && gl_info->glsl_version >= MAKEDWORD_VERSION(1, 50)
&& gl_info->supported[ARB_DRAW_ELEMENTS_BASE_VERTEX] && gl_info->supported[ARB_DRAW_INSTANCED]
&& gl_info->supported[ARB_TEXTURE_RG] && gl_info->supported[ARB_SAMPLER_OBJECTS])
if (gl_info->glsl_version >= MAKEDWORD_VERSION(1, 50) && gl_info->supported[WINED3D_GL_VERSION_3_2]
&& gl_info->supported[ARB_SHADER_BIT_ENCODING] && gl_info->supported[ARB_SAMPLER_OBJECTS])
shader_model = 4;
/* ARB_shader_texture_lod or EXT_gpu_shader4 is required for the SM3
* texldd and texldl instructions. */
......
......@@ -165,6 +165,7 @@ enum wined3d_gl_extension
WINED3D_GL_NORMALIZED_TEXRECT,
WINED3D_GL_LEGACY_CONTEXT,
WINED3D_GL_VERSION_2_0,
WINED3D_GL_VERSION_3_2,
WINED3D_GL_EXT_COUNT,
};
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment