[Mesa-dev] [PATCH 2/7] Define constants and functions for ARB_framebuffer_no_attachment extension

Rogovin, Kevin kevin.rogovin at intel.com
Tue Apr 28 05:52:08 PDT 2015


Hello,

> Hmmmm.... that's surprising.
>
> src/mesa/main/tests/dispatch_sanity.cpp:// {
>"glFramebufferParameteri", 43, -1 },               // XXX: Add to xml
>
>I thought it should detect that there's a new API and complain loudly.
> At least that's how I remembered it working, but that doesn't seem to be the case?
> Are you sure you had a clean build? Either way, those should probably get uncommented, 

The reason why there was no issue is because the entries for both glFramebufferParameteri 
and glGetFramebufferParameteriv are already commented out. Looking at the commit log, 
they have been commented out for quite some time. The commit from Jordan Justen
(dated Oct 24,2012) titled "dispatch sanity test: Add GL CORE 3.1 test" has the line added 
but commented out. In fact, looking at the commit log, with git log -p the only reference 
to those functions has both commented out.

> and there are probably interactions with ARB_dsa as well, should probably 
> figure out if you or Laura should add support for that (or perhaps you had it in your patches already).

The extension ARB_framebuffer_no_attachments does NOT define the DSA style functions 
for ARB_direct_state_access. Instead, it only defines for the EXT_direct_state_access. I think 
that the implementers of GL_ARB_direct_state_access are the ones that need to  define and 
implement gl[Get]NamedFraembufferParamteri. I wrote the patch 3 so that it is trivial to
implement the DSA function though.

-Kevin

On Fri, Apr 24, 2015 at 11:06 AM, Rogovin, Kevin <kevin.rogovin at intel.com> wrote:
> Hi,
>
>  I agree with the comments about the code (and when the last element of the series is reviewed I will submit the series with review comments taken into use), but when I applied just Patch 1 and Patch 2, and ran src/mesa/main/tests/main-test (after a git clean -dfx and all that cleaning) all test pass, in particular the 4 DispatchSanity_test's:  DispatchSanity_test.GL31_CORE ,  DispatchSanity_test.GLES11,  DispatchSanity_test.GLES2 and  DispatchSanity_test.GLES3. In addition, make check passes all test as well. If you are referring to another test, what test is that?
>
>  -Kevin
>
> -----Original Message-----
> From: ibmirkin at gmail.com [mailto:ibmirkin at gmail.com] On Behalf Of Ilia 
> Mirkin
> Sent: Friday, April 24, 2015 4:36 PM
> To: Matt Turner
> Cc: Rogovin, Kevin; mesa-dev at freedesktop.org
> Subject: Re: [Mesa-dev] [PATCH 2/7] Define constants and functions for 
> ARB_framebuffer_no_attachment extension
>
> This change will make the dispatch_sanity test fail.
>
> On Fri, Apr 24, 2015 at 3:05 AM, Matt Turner <mattst88 at gmail.com> wrote:
>> The subject should be prefixed with "mesa:"
>>
>> On Thu, Apr 23, 2015 at 11:59 PM,  <kevin.rogovin at intel.com> wrote:
>>> From: Kevin Rogovin <kevin.rogovin at intel.com>
>>>
>>> Define enumerations, functions and associated glGet's for extension 
>>> ARB_framebuffer_no_attachment.
>>>
>>> ---
>>>  .../glapi/gen/ARB_framebuffer_no_attachments.xml   | 33 ++++++++++++++++++
>>>  src/mapi/glapi/gen/Makefile.am                     |  1 +
>>>  src/mapi/glapi/gen/gl_API.xml                      |  1 +
>>>  src/mesa/main/fbobject.c                           | 12 +++++++
>>>  src/mesa/main/fbobject.h                           |  7 ++++
>>>  src/mesa/main/get.c                                |  3 ++
>>>  src/mesa/main/get_hash_params.py                   | 40 ++++++++++++++++++++++
>>>  7 files changed, 97 insertions(+)
>>>  create mode 100644
>>> src/mapi/glapi/gen/ARB_framebuffer_no_attachments.xml
>>>
>>> diff --git a/src/mapi/glapi/gen/ARB_framebuffer_no_attachments.xml
>>> b/src/mapi/glapi/gen/ARB_framebuffer_no_attachments.xml
>>> new file mode 100644
>>> index 0000000..60e40d0
>>> --- /dev/null
>>> +++ b/src/mapi/glapi/gen/ARB_framebuffer_no_attachments.xml
>>> @@ -0,0 +1,33 @@
>>> +<?xml version="1.0"?>
>>> +<!DOCTYPE OpenGLAPI SYSTEM "gl_API.dtd">
>>> +
>>> +<OpenGLAPI>
>>> +
>>> +<category name="GL_ARB_framebuffer_no_attachments" number="130">
>>> +
>>> +<enum name="FRAMEBUFFER_DEFAULT_WIDTH" value="0x9310" /> <enum 
>>> +name="FRAMEBUFFER_DEFAULT_HEIGHT" value="0x9311" /> <enum 
>>> +name="FRAMEBUFFER_DEFAULT_LAYERS" value="0x9312" /> <enum 
>>> +name="FRAMEBUFFER_DEFAULT_SAMPLES" value="0x9313" /> <enum 
>>> +name="FRAMEBUFFER_DEFAULT_FIXED_SAMPLE_LOCATIONS" value="0x9314" /> 
>>> +<enum name="MAX_FRAMEBUFFER_WIDTH" value="0x9315" /> <enum 
>>> +name="MAX_FRAMEBUFFER_HEIGHT" value="0x9316" /> <enum 
>>> +name="MAX_FRAMEBUFFER_LAYERS" value="0x9317" /> <enum 
>>> +name="MAX_FRAMEBUFFER_SAMPLES" value="0x9318" />
>>> +
>>> +
>>> +<function name="FramebufferParameteri" offset="assign">
>>> +    <param name="target" type="GLenum" />
>>> +    <param name="pname" type="GLenum" />
>>> +    <param name="param" type="GLint" /> </function>
>>> +
>>> +<function name="GetFramebufferParameteriv" offset="assign">
>>> +    <param name="target" type="GLenum" />
>>> +    <param name="pname" type="GLenum" />
>>> +    <param name="params" type="GLint *" /> </function>
>>> +
>>> +</category>
>>> +
>>> +</OpenGLAPI>
>>> diff --git a/src/mapi/glapi/gen/Makefile.am 
>>> b/src/mapi/glapi/gen/Makefile.am index 1c4b86a..9a0e944 100644
>>> --- a/src/mapi/glapi/gen/Makefile.am
>>> +++ b/src/mapi/glapi/gen/Makefile.am
>>> @@ -130,6 +130,7 @@ API_XML = \
>>>         ARB_ES2_compatibility.xml \
>>>         ARB_ES3_compatibility.xml \
>>>         ARB_framebuffer_object.xml \
>>> +       ARB_framebuffer_no_attachments.xml \
>>
>> This is an alphabetized list. Please keep it so.
>>
>>>         ARB_geometry_shader4.xml \
>>>         ARB_get_program_binary.xml \
>>>         ARB_gpu_shader_fp64.xml \
>>> diff --git a/src/mapi/glapi/gen/gl_API.xml 
>>> b/src/mapi/glapi/gen/gl_API.xml index a8a6db6..4eea396 100644
>>> --- a/src/mapi/glapi/gen/gl_API.xml
>>> +++ b/src/mapi/glapi/gen/gl_API.xml
>>> @@ -8325,6 +8325,7 @@
>>>  </category>
>>>
>>>  <!-- ARB extensions #130..#131 -->
>>> +<xi:include href="ARB_framebuffer_no_attachments.xml"
>>> +xmlns:xi="http://www.w3.org/2001/XInclude"/>
>
> This is extension #130, so it should go above the comment, and the comment should be changed to just say <!-- ARB extension #131 -->.
>
>   -ilia


More information about the mesa-dev mailing list