[Mesa-dev] [PATCH 00/15] Add ARB_viewport_array extension

Courtney Goeltzenleuchter courtney at lunarg.com
Wed Nov 20 16:49:35 PST 2013


On Wed, Nov 20, 2013 at 5:06 PM, Ian Romanick <idr at freedesktop.org> wrote:

> On 11/20/2013 02:59 PM, Courtney Goeltzenleuchter wrote:
> > This series starts by updating the driver interface for
> > scissor, viewport and DepthRange. This includes removing
> > unused arguments from the Scissor, Viewport and DepthRange.
> > I kept the index argument, although it is not used, it may
> > be useful to the dri driver to know which array element
> > is being updated.
>
> For such a long series, could you also make a GIT tree available
> somewhere?  It makes it a lot easier to play with.
>

I've posted the branch corresponding to these comments on github:
https://github.com/courtney-lunarg/mesa.git


>
> I think I'll rebase your tree on top of some of my patches.  I think
> that will make the overall series a little cleaner and more compact.
> For example, I think removing the parameters from the dd functions
> should go first.  That would basically eliminate your patches 1, 2, and 3.
>

I deliberately put the remove arguments at the end in case someone raised a
complaint about the removal. It seemed easier to back out there.


>
> > I added things incrementally, each having no effect
> > on piglit. I tested the full series against the arb_viewport_array
> > piglit tests submitted by LunarG and a stubbed version of the
> > i965 driver that enables ARB_viewport_array. I've not
> > included that stub in this series.
>
> You can also do this with an environment variable:
>
> MESA_GL_EXTENSION_OVERRIDE=+GL_ARB_viewport_array
>

Cool!


>
> > I modeled the indexed Get functions off GL_COLOR_WRITEMASK.
> >
> > Since the removal of x, y, w, h touches the same files as
> > references to gl_context.Viewport it seemed just as easy to
> > convert those references to the array reference with index 0.
> > Should the driver add ARB_viewport_array support they would
> > simply put the right index value in place of 0.
> >
> >
> > Courtney Goeltzenleuchter (18):
> >   mesa: Change scissor dd interface for viewport_array
> >   mesa: Update viewport dd interface for viewport_array
> >   mesa: Change DepthRange dd interface
> >   mesa: Update gl_scissor_attrib to support ARB_viewport_array
> >   mesa: Update viewport driver args for ARB_viewport_array
> >   mesa: Update viewport state for viewport_array
> >   meta: Update meta driver to use API entry point
> >   mesa: Add indexed version of mesa_scissor
> >   mesa: Add new get entrypoints for ARB_viewport_array
> >   mesa: Add custom get function for SCISSOR
> >   mesa: Add ARB_viewport_array state to gl_context
> >   mesa: Add scissor entry points for viewport_array
> >   mesa: Add ARB_viewport_array viewport entry points
> >   mesa: Add gl_ViewportIndex variable to GLSL
> >   mesa: Add ARB_viewport_array plumbing
> >   mesa: Remove unused arguments from driver->Scissor
> >   mesa: Remove unused arguments from driver->Viewport
> >   mesa: Remove unused arguments from driver->DepthRange
> >
> >  src/glsl/builtin_variables.cpp                  |   2 +
> >  src/glsl/glsl_parser_extras.h                   |   1 +
> >  src/mapi/glapi/gen/ARB_viewport_array.xml       |  79 ++++++
> >  src/mapi/glapi/gen/Makefile.am                  |   1 +
> >  src/mapi/glapi/gen/gl_API.xml                   |   2 +-
> >  src/mesa/drivers/common/driverfuncs.c           |  11 +-
> >  src/mesa/drivers/common/meta.c                  |  52 ++--
> >  src/mesa/drivers/dri/i915/i830_state.c          |  26 +-
> >  src/mesa/drivers/dri/i915/i830_vtbl.c           |   5 +-
> >  src/mesa/drivers/dri/i915/i915_state.c          |  50 ++--
> >  src/mesa/drivers/dri/i915/i915_vtbl.c           |   5 +-
> >  src/mesa/drivers/dri/i915/intel_context.c       |  15 +-
> >  src/mesa/drivers/dri/i915/intel_fbo.c           |   2 +-
> >  src/mesa/drivers/dri/i965/brw_cc.c              |   4 +-
> >  src/mesa/drivers/dri/i965/brw_clear.c           |  12 +-
> >  src/mesa/drivers/dri/i965/brw_clip_state.c      |  12 +-
> >  src/mesa/drivers/dri/i965/brw_context.c         |   7 +-
> >  src/mesa/drivers/dri/i965/brw_sf_state.c        |   4 +-
> >  src/mesa/drivers/dri/i965/gen6_clip_state.c     |   8 +-
> >  src/mesa/drivers/dri/i965/gen6_sf_state.c       |   2 +-
> >  src/mesa/drivers/dri/i965/gen6_viewport_state.c |   6 +-
> >  src/mesa/drivers/dri/i965/gen7_sf_state.c       |   2 +-
> >  src/mesa/drivers/dri/i965/gen7_viewport_state.c |   6 +-
> >  src/mesa/drivers/dri/i965/intel_fbo.c           |   2 +-
> >  src/mesa/drivers/dri/nouveau/nouveau_util.h     |   4 +-
> >  src/mesa/drivers/dri/nouveau/nv10_state_fb.c    |   2 +-
> >  src/mesa/drivers/dri/r200/r200_state.c          |  15 +-
> >  src/mesa/drivers/dri/radeon/radeon_common.c     |  18 +-
> >  src/mesa/drivers/dri/radeon/radeon_common.h     |   2 +-
> >  src/mesa/drivers/dri/radeon/radeon_state.c      |  14 +-
> >  src/mesa/drivers/dri/swrast/swrast.c            |   8 +-
> >  src/mesa/main/attrib.c                          |  30 ++-
> >  src/mesa/main/config.h                          |   3 +
> >  src/mesa/main/context.c                         |  36 ++-
> >  src/mesa/main/dd.h                              |   6 +-
> >  src/mesa/main/enable.c                          |  36 ++-
> >  src/mesa/main/extensions.c                      |   1 +
> >  src/mesa/main/framebuffer.c                     |  19 +-
> >  src/mesa/main/get.c                             | 218 +++++++++++++++-
> >  src/mesa/main/get.h                             |   6 +
> >  src/mesa/main/get_hash_params.py                |  15 +-
> >  src/mesa/main/mtypes.h                          |  25 +-
> >  src/mesa/main/rastpos.c                         |   4 +-
> >  src/mesa/main/scissor.c                         | 157 ++++++++++--
> >  src/mesa/main/scissor.h                         |  10 +-
> >  src/mesa/main/state.c                           |  17 +-
> >  src/mesa/main/viewport.c                        | 314
> ++++++++++++++++++++----
> >  src/mesa/main/viewport.h                        |  22 +-
> >  src/mesa/math/m_matrix.c                        |   9 +-
> >  src/mesa/math/m_matrix.h                        |   4 +-
> >  src/mesa/program/prog_statevars.c               |   7 +-
> >  src/mesa/state_tracker/st_atom_rasterizer.c     |   2 +-
> >  src/mesa/state_tracker/st_atom_scissor.c        |  14 +-
> >  src/mesa/state_tracker/st_atom_viewport.c       |  12 +-
> >  src/mesa/state_tracker/st_cb_bitmap.c           |   2 +-
> >  src/mesa/state_tracker/st_cb_clear.c            |  10 +-
> >  src/mesa/state_tracker/st_cb_drawpixels.c       |   2 +-
> >  src/mesa/state_tracker/st_cb_viewport.c         |   3 +-
> >  src/mesa/swrast/s_context.c                     |  10 +-
> >  src/mesa/swrast/s_depth.c                       |  10 +-
> >  src/mesa/swrast_setup/ss_context.c              |   4 +-
> >  src/mesa/tnl/t_rasterpos.c                      |  16 +-
> >  62 files changed, 1057 insertions(+), 346 deletions(-)
> >  create mode 100644 src/mapi/glapi/gen/ARB_viewport_array.xml
> >
>
>


-- 
Courtney Goeltzenleuchter
LunarG
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/mesa-dev/attachments/20131120/d32a50fc/attachment-0001.html>


More information about the mesa-dev mailing list