Re: [PATCH 3/3] wined3d: Cleanup extension check for shader model 4 support.
On 28 October 2015 at 22:27, Matteo Bruni <mbruni(a)codeweavers.com> wrote:
- 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[ARB_SHADER_BIT_ENCODING] + && gl_info->supported[ARB_SAMPLER_OBJECTS]) Dropping EXT_gpu_shader4 is fine. Does GLSL 1.50 imply all the other extensions you're dropping here? They're not strictly required for compiling SM4 shaders, but they are for d3d10+ features like e.g. geometry shaders and instanced draws.
2015-10-29 12:54 GMT+01:00 Henri Verbeet <hverbeet(a)gmail.com>:
On 28 October 2015 at 22:27, Matteo Bruni <mbruni(a)codeweavers.com> wrote:
- 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[ARB_SHADER_BIT_ENCODING] + && gl_info->supported[ARB_SAMPLER_OBJECTS]) Dropping EXT_gpu_shader4 is fine. Does GLSL 1.50 imply all the other extensions you're dropping here? They're not strictly required for compiling SM4 shaders, but they are for d3d10+ features like e.g. geometry shaders and instanced draws.
Yes, GLSL 1.50 / OpenGL 3.2 imply geometry shaders (albeit in a somewhat different fashion compared to ARB_geometry_shader4 - mostly that you have to use layouts instead of OpenGL APIs to specify input / output topology), ARB_draw_elements_base_vertex, ARB_draw_instanced and ARB_texture_rg. ARB_shader_bit_encoding and ARB_sampler_objects are OpenGL 3.3 features instead. We might want to restore some of those checks for OpenGL ES but I'm not sure that we won't have a separate condition for that.
participants (2)
-
Henri Verbeet -
Matteo Bruni