Re: [Mesa-dev] [PATCH 2/2] mesa: enable ARB_gpu_shader5 in compat

2018-05-18 Thread Marek Olšák
The extension requires GL 3.2 (actually just geometry shaders), but we don't have GS in the compatibility profile yet. Marek On Fri, May 18, 2018 at 3:06 AM, Timothy Arceri wrote: > With the previous commit everything we need should be there. > --- > src/mesa/main/extensions_table.h | 2 +- >

Re: [Mesa-dev] [PATCH 2/2] mesa: enable ARB_gpu_shader5 in compat

2018-05-18 Thread Ilia Mirkin
On Fri, May 18, 2018 at 2:27 PM, Benedikt Schemmer wrote: > > > Am 18.05.2018 um 20:05 schrieb Ilia Mirkin: >> On Fri, May 18, 2018 at 1:54 PM, Benedikt Schemmer wrote: >>> so the gll is ok? >>> >>> my idea with the glc is that this particular extension would no longer be >>> advertised as soon

Re: [Mesa-dev] [PATCH 2/2] mesa: enable ARB_gpu_shader5 in compat

2018-05-18 Thread Benedikt Schemmer
Am 18.05.2018 um 20:05 schrieb Ilia Mirkin: > On Fri, May 18, 2018 at 1:54 PM, Benedikt Schemmer wrote: >> so the gll is ok? >> >> my idea with the glc is that this particular extension would no longer be >> advertised as soon as the app >> request a context where the functionality is already p

Re: [Mesa-dev] [PATCH 2/2] mesa: enable ARB_gpu_shader5 in compat

2018-05-18 Thread Ilia Mirkin
On Fri, May 18, 2018 at 1:54 PM, Benedikt Schemmer wrote: > so the gll is ok? > > my idea with the glc is that this particular extension would no longer be > advertised as soon as the app > request a context where the functionality is already part of it (ie OpenGL >= > 4.0) Why is this desirabl

Re: [Mesa-dev] [PATCH 2/2] mesa: enable ARB_gpu_shader5 in compat

2018-05-18 Thread Benedikt Schemmer
so the gll is ok? my idea with the glc is that this particular extension would no longer be advertised as soon as the app request a context where the functionality is already part of it (ie OpenGL >= 4.0) Do you think a minimum GLSL version could be added to this table (maybe replacing the yea

Re: [Mesa-dev] [PATCH 2/2] mesa: enable ARB_gpu_shader5 in compat

2018-05-18 Thread Ilia Mirkin
On Fri, May 18, 2018 at 1:27 PM, Benedikt Schemmer wrote: > Am I on the right track to assume that Timothy's patch should read > > +EXT(ARB_gpu_shader5 , ARB_gpu_shader5 > , 32, 40, x , x , 2010) > > to give GL_ARB_gpu_shader5 a minimum required le

Re: [Mesa-dev] [PATCH 2/2] mesa: enable ARB_gpu_shader5 in compat

2018-05-18 Thread Benedikt Schemmer
Am I on the right track to assume that Timothy's patch should read +EXT(ARB_gpu_shader5 , ARB_gpu_shader5 , 32, 40, x , x , 2010) to give GL_ARB_gpu_shader5 a minimum required legacy OpenGL version of 3.2 and core 4.0 as per spec? I wanted to as

Re: [Mesa-dev] [PATCH 2/2] mesa: enable ARB_gpu_shader5 in compat

2018-05-18 Thread Timothy Arceri
On 18/05/18 22:20, Benedikt Schemmer wrote: Indeed it does, I've written a little test program where I can request specific OpenGL versions. I think that used to work, now if I request anything <= 3.1 I get 3.1 if request >= 3.2 I get 4.5. GL_ARB_gpu_shader5 is available in all of them. If I f

Re: [Mesa-dev] [PATCH 2/2] mesa: enable ARB_gpu_shader5 in compat

2018-05-18 Thread Ilia Mirkin
On Fri, May 18, 2018 at 8:20 AM, Benedikt Schemmer wrote: > Indeed it does, I've written a little test program where I can request > specific OpenGL versions. > I think that used to work, now if I request anything <= 3.1 I get 3.1 if > request >= 3.2 I get 4.5. > GL_ARB_gpu_shader5 is available

Re: [Mesa-dev] [PATCH 2/2] mesa: enable ARB_gpu_shader5 in compat

2018-05-18 Thread Benedikt Schemmer
Indeed it does, I've written a little test program where I can request specific OpenGL versions. I think that used to work, now if I request anything <= 3.1 I get 3.1 if request >= 3.2 I get 4.5. GL_ARB_gpu_shader5 is available in all of them. If I force the GL version the version string changes

Re: [Mesa-dev] [PATCH 2/2] mesa: enable ARB_gpu_shader5 in compat

2018-05-18 Thread Ilia Mirkin
The check is against what the driver max is, not what the application requested. Using overrides messes up this logic, it seems. On Fri, May 18, 2018, 06:14 Benedikt Schemmer wrote: > Yes its backwards and it seems it doesn't work anymore ;) > Seems the loophole I was using got removed. > > Pro

Re: [Mesa-dev] [PATCH 2/2] mesa: enable ARB_gpu_shader5 in compat

2018-05-18 Thread Benedikt Schemmer
Yes its backwards and it seems it doesn't work anymore ;) Seems the loophole I was using got removed. Problem remains that applications that could use an legacy extension are not aware of it and will simply/usually not request it: MESA_GL_VERSION_OVERRIDE=3.2 MESA_GLSL_VERSION_OVERRIDE=150 glxinf

Re: [Mesa-dev] [PATCH 2/2] mesa: enable ARB_gpu_shader5 in compat

2018-05-18 Thread Timothy Arceri
Hi Benedikt, I think you have this backwards. compute_version() computes the version of OpenGL supported by the driver by checking what extensions it advertises. See version 2 of my patch to see where the extensions are enabled. I don't think this is something that can be automated, it really

Re: [Mesa-dev] [PATCH 2/2] mesa: enable ARB_gpu_shader5 in compat

2018-05-18 Thread Benedikt Schemmer
A list of extension requirements and interactions extracted from the GL_* files on Khronos so this is messy but relatively complete I've started to introduce key phrases like "This extension requires" so that this could become machine readable in the future. --- ./WGL_ARB_make_current_read.txt

Re: [Mesa-dev] [PATCH 2/2] mesa: enable ARB_gpu_shader5 in compat

2018-05-18 Thread Benedikt Schemmer
Hi Timothy, I was looking into something similar myself. Great to see someone working on getting legacy extensions available to the applications that can actually use them! Another thing I noticed is that extensions aren't advertised at the correct feature level. The code below works and does a b

Re: [Mesa-dev] [PATCH 2/2] mesa: enable ARB_gpu_shader5 in compat

2018-05-18 Thread Timothy Arceri
Actually we need some GLSL Compat version checks before doing this. I'll send a patch 1.5 to do that. On 18/05/18 17:06, Timothy Arceri wrote: With the previous commit everything we need should be there. --- src/mesa/main/extensions_table.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(

[Mesa-dev] [PATCH 2/2] mesa: enable ARB_gpu_shader5 in compat

2018-05-18 Thread Timothy Arceri
With the previous commit everything we need should be there. --- src/mesa/main/extensions_table.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/mesa/main/extensions_table.h b/src/mesa/main/extensions_table.h index 945b462122c..86ce6ec2318 100644 --- a/src/mesa/main/extens