diff options
author | Eric Anholt <[email protected]> | 2017-07-25 16:13:57 -0700 |
---|---|---|
committer | Eric Anholt <[email protected]> | 2017-10-10 10:45:22 -0700 |
commit | e6764348564e2f865f382a81eae3ccfbf957d2fd (patch) | |
tree | 17e5dbddee4276d247d7df7fef4946ecfc96a8e4 /src/mesa/state_tracker | |
parent | 087b39a3460e796cee04b754d8cb08251c7a51bc (diff) |
mesa: Implement a new GL_MESA_tile_raster_order extension.
The intent is to use this extension on vc4 to allow X11 to do overlapping
CopyArea() within a pixmap without first blitting the pixmap to a
temporary. With associated glamor patches, improves x11perf
-copywinwin100 performance on a Raspberry Pi 3 from ~4700/sec to
~5130/sec, and is an even larger boost to uncomposited window movement
performance (most copywinwin100 copies don't overlap).
v2: Fix glIsEnabled() on the new enums.
v3: Drop the local spec since I'm upstreaming the spec.
Reviewed-by: Nicolai Hähnle <[email protected]>
Diffstat (limited to 'src/mesa/state_tracker')
-rw-r--r-- | src/mesa/state_tracker/st_atom_rasterizer.c | 5 | ||||
-rw-r--r-- | src/mesa/state_tracker/st_context.c | 1 | ||||
-rw-r--r-- | src/mesa/state_tracker/st_extensions.c | 1 |
3 files changed, 7 insertions, 0 deletions
diff --git a/src/mesa/state_tracker/st_atom_rasterizer.c b/src/mesa/state_tracker/st_atom_rasterizer.c index 39be6b15a70..4147340fd79 100644 --- a/src/mesa/state_tracker/st_atom_rasterizer.c +++ b/src/mesa/state_tracker/st_atom_rasterizer.c @@ -277,6 +277,11 @@ void st_update_rasterizer( struct st_context *st ) /* ST_NEW_RASTERIZER */ raster->rasterizer_discard = ctx->RasterDiscard; + if (ctx->TileRasterOrderFixed) { + raster->tile_raster_order_fixed = true; + raster->tile_raster_order_increasing_x = ctx->TileRasterOrderIncreasingX; + raster->tile_raster_order_increasing_y = ctx->TileRasterOrderIncreasingY; + } if (st->edgeflag_culls_prims) { /* All edge flags are FALSE. Cull the affected faces. */ diff --git a/src/mesa/state_tracker/st_context.c b/src/mesa/state_tracker/st_context.c index 9610ad30146..69dd396a1cb 100644 --- a/src/mesa/state_tracker/st_context.c +++ b/src/mesa/state_tracker/st_context.c @@ -489,6 +489,7 @@ static void st_init_driver_flags(struct st_context *st) f->NewArray = ST_NEW_VERTEX_ARRAYS; f->NewRasterizerDiscard = ST_NEW_RASTERIZER; + f->NewTileRasterOrder = ST_NEW_RASTERIZER; f->NewUniformBuffer = ST_NEW_UNIFORM_BUFFER; f->NewDefaultTessLevels = ST_NEW_TESS_STATE; diff --git a/src/mesa/state_tracker/st_extensions.c b/src/mesa/state_tracker/st_extensions.c index 1fbae9234e5..3dec5a87d73 100644 --- a/src/mesa/state_tracker/st_extensions.c +++ b/src/mesa/state_tracker/st_extensions.c @@ -651,6 +651,7 @@ void st_init_extensions(struct pipe_screen *screen, { o(AMD_seamless_cubemap_per_texture), PIPE_CAP_SEAMLESS_CUBE_MAP_PER_TEXTURE }, { o(ATI_separate_stencil), PIPE_CAP_TWO_SIDED_STENCIL }, { o(ATI_texture_mirror_once), PIPE_CAP_TEXTURE_MIRROR_CLAMP }, + { o(MESA_tile_raster_order), PIPE_CAP_TILE_RASTER_ORDER }, { o(NV_conditional_render), PIPE_CAP_CONDITIONAL_RENDER }, { o(NV_fill_rectangle), PIPE_CAP_POLYGON_MODE_FILL_RECTANGLE }, { o(NV_primitive_restart), PIPE_CAP_PRIMITIVE_RESTART }, |