From bc739440c29c551fcc44e9e12d0d9c170d8d24fb Mon Sep 17 00:00:00 2001 From: Keith Whitwell Date: Wed, 2 Apr 2008 10:43:37 +0100 Subject: gallium: add temporary facility for rasterization-time clamping of point sizes --- src/mesa/state_tracker/st_atom_rasterizer.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_atom_rasterizer.c b/src/mesa/state_tracker/st_atom_rasterizer.c index 17d77f90aec..14c26c16c04 100644 --- a/src/mesa/state_tracker/st_atom_rasterizer.c +++ b/src/mesa/state_tracker/st_atom_rasterizer.c @@ -198,6 +198,10 @@ static void update_raster_state( struct st_context *st ) /* _NEW_POINT */ raster->point_size = ctx->Point.Size; + + raster->point_size_min = 0; /* temporary, will go away */ + raster->point_size_max = 1000; /* temporary, will go away */ + raster->point_smooth = ctx->Point.SmoothFlag; raster->point_sprite = ctx->Point.PointSprite; for (i = 0; i < MAX_TEXTURE_COORD_UNITS; i++) { -- cgit v1.2.3 From 8e33194837dd206d920889851d9cf22190100c99 Mon Sep 17 00:00:00 2001 From: Keith Whitwell Date: Wed, 2 Apr 2008 11:38:33 +0100 Subject: gallium: add a flag to turn on gl rasterization rules Use this to set up hardware rasterization (if your hardware can do it) or otherwise turn on various tweaks in the draw module. Currently only hooked up to point biasing code. --- src/gallium/auxiliary/draw/draw_wide_point.c | 19 +++++++++++++------ src/gallium/include/pipe/p_state.h | 1 + src/mesa/state_tracker/st_atom_rasterizer.c | 2 ++ 3 files changed, 16 insertions(+), 6 deletions(-) (limited to 'src/mesa') diff --git a/src/gallium/auxiliary/draw/draw_wide_point.c b/src/gallium/auxiliary/draw/draw_wide_point.c index 86281ca3d8c..6fc7c9fcd7a 100644 --- a/src/gallium/auxiliary/draw/draw_wide_point.c +++ b/src/gallium/auxiliary/draw/draw_wide_point.c @@ -41,6 +41,9 @@ struct widepoint_stage { float point_size_min; float point_size_max; + float xbias; + float ybias; + uint texcoord_slot[PIPE_MAX_SHADER_OUTPUTS]; uint texcoord_mode[PIPE_MAX_SHADER_OUTPUTS]; uint num_texcoords; @@ -126,8 +129,6 @@ static void widepoint_point( struct draw_stage *stage, float *pos2 = v2->data[0]; float *pos3 = v3->data[0]; - const float xbias = 0.0, ybias = -0.125; - /* point size is either per-vertex or fixed size */ if (wide->psize_slot >= 0) { half_size = header->v[0]->data[wide->psize_slot][0]; @@ -144,10 +145,10 @@ static void widepoint_point( struct draw_stage *stage, half_size = wide->half_point_size; } - left_adj = -half_size + xbias; - right_adj = half_size + xbias; - bot_adj = half_size + ybias; - top_adj = -half_size + ybias; + left_adj = -half_size + wide->xbias; + right_adj = half_size + wide->xbias; + bot_adj = half_size + wide->ybias; + top_adj = -half_size + wide->ybias; pos0[0] += left_adj; pos0[1] += top_adj; @@ -194,6 +195,12 @@ static void widepoint_first_point( struct draw_stage *stage, wide->half_point_size = 0.5f * draw->rasterizer->point_size; wide->point_size_min = draw->rasterizer->point_size_min; wide->point_size_max = draw->rasterizer->point_size_max; + wide->xbias = 0.0; + wide->ybias = 0.0; + + if (draw->rasterizer->gl_rasterization_rules) { + wide->ybias = -0.125; + } /* XXX we won't know the real size if it's computed by the vertex shader! */ if ((draw->rasterizer->point_size > draw->wide_point_threshold) || diff --git a/src/gallium/include/pipe/p_state.h b/src/gallium/include/pipe/p_state.h index e407e3bc725..3593446e1c4 100644 --- a/src/gallium/include/pipe/p_state.h +++ b/src/gallium/include/pipe/p_state.h @@ -115,6 +115,7 @@ struct pipe_rasterizer_state still needed though, to indicate inputs/outputs */ unsigned origin_lower_left:1; /**< Is (0,0) the lower-left corner? */ unsigned flatshade_first:1; /**< take color attribute from the first vertex of a primitive */ + unsigned gl_rasterization_rules:1; /**< enable tweaks for GL rasterization? */ float line_width; float point_size; /**< used when no per-vertex size */ diff --git a/src/mesa/state_tracker/st_atom_rasterizer.c b/src/mesa/state_tracker/st_atom_rasterizer.c index 14c26c16c04..bb14cf9045a 100644 --- a/src/mesa/state_tracker/st_atom_rasterizer.c +++ b/src/mesa/state_tracker/st_atom_rasterizer.c @@ -261,6 +261,8 @@ static void update_raster_state( struct st_context *st ) if (ctx->Scissor.Enabled) raster->scissor = 1; + raster->gl_rasterization_rules = 1; + cso_set_rasterizer(st->cso_context, raster); } -- cgit v1.2.3 From f07fe3c728aec5a715cf615822151e11a00cda44 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Thu, 3 Apr 2008 12:01:17 -0600 Subject: gallium: set gl_rasterization_rules --- src/mesa/state_tracker/st_cb_drawpixels.c | 1 + 1 file changed, 1 insertion(+) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_drawpixels.c b/src/mesa/state_tracker/st_cb_drawpixels.c index c181575f158..c7796cfb6aa 100644 --- a/src/mesa/state_tracker/st_cb_drawpixels.c +++ b/src/mesa/state_tracker/st_cb_drawpixels.c @@ -536,6 +536,7 @@ draw_textured_quad(GLcontext *ctx, GLint x, GLint y, GLfloat z, { struct pipe_rasterizer_state rasterizer; memset(&rasterizer, 0, sizeof(rasterizer)); + rasterizer.gl_rasterization_rules = 1; rasterizer.scissor = ctx->Scissor.Enabled; cso_set_rasterizer(cso, &rasterizer); } -- cgit v1.2.3 From 0bc2e2c9cd552e4187dd8a2250e350efcdc9aea1 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Thu, 3 Apr 2008 12:01:53 -0600 Subject: gallium: call st_flush_bitmap_cache() --- src/mesa/state_tracker/st_cb_readpixels.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_readpixels.c b/src/mesa/state_tracker/st_cb_readpixels.c index e9fcdf69a14..82df28b29a1 100644 --- a/src/mesa/state_tracker/st_cb_readpixels.c +++ b/src/mesa/state_tracker/st_cb_readpixels.c @@ -159,6 +159,8 @@ st_readpixels(GLcontext *ctx, GLint x, GLint y, GLsizei width, GLsizei height, if (!dest) return; + st_flush_bitmap_cache(ctx->st); + /* make sure rendering has completed */ pipe->flush(pipe, PIPE_FLUSH_RENDER_CACHE, NULL); -- cgit v1.2.3 From 4f67a3f7d3bdeaa8d16d877ce9b277c97bd2f6b4 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Thu, 3 Apr 2008 12:42:26 -0600 Subject: gallium: use identity viewport fix broken clear_with_quad() path Since bypass_clipping is set and we're specifying quad vertexes in window coords, setup identity viewport. --- src/mesa/state_tracker/st_cb_clear.c | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_clear.c b/src/mesa/state_tracker/st_cb_clear.c index ec8d3e10221..0c6f77bc82a 100644 --- a/src/mesa/state_tracker/st_cb_clear.c +++ b/src/mesa/state_tracker/st_cb_clear.c @@ -271,17 +271,15 @@ clear_with_quad(GLcontext *ctx, #endif #if !TEST_DRAW_PASSTHROUGH - /* viewport state: viewport matching window dims */ + /* viewport state: identity since we're drawing in window coords */ { - const float width = ctx->DrawBuffer->Width; - const float height = ctx->DrawBuffer->Height; struct pipe_viewport_state vp; - vp.scale[0] = 0.5 * width; - vp.scale[1] = -0.5 * height; + vp.scale[0] = 1.0; + vp.scale[1] = 1.0; vp.scale[2] = 1.0; vp.scale[3] = 1.0; - vp.translate[0] = 0.5 * width; - vp.translate[1] = 0.5 * height; + vp.translate[0] = 0.0; + vp.translate[1] = 0.0; vp.translate[2] = 0.0; vp.translate[3] = 0.0; cso_set_viewport(st->cso_context, &vp); -- cgit v1.2.3 From c4f8c8b304a47b2490fe5b1d133e314b045854df Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Thu, 3 Apr 2008 12:44:58 -0600 Subject: gallium: remove the temporary/test TEST_DRAW_PASSTHROUGH code --- src/mesa/state_tracker/st_cb_clear.c | 12 ------------ 1 file changed, 12 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_clear.c b/src/mesa/state_tracker/st_cb_clear.c index 0c6f77bc82a..041b9be2cc9 100644 --- a/src/mesa/state_tracker/st_cb_clear.c +++ b/src/mesa/state_tracker/st_cb_clear.c @@ -55,11 +55,6 @@ #include "cso_cache/cso_context.h" -/* XXX for testing draw module vertex passthrough: */ -/* XXX this hack is broken now */ -#define TEST_DRAW_PASSTHROUGH 0 - - void st_destroy_clear(struct st_context *st) { @@ -243,9 +238,6 @@ clear_with_quad(GLcontext *ctx, struct pipe_rasterizer_state raster; memset(&raster, 0, sizeof(raster)); raster.bypass_clipping = 1; -#if TEST_DRAW_PASSTHROUGH - raster.bypass_vs = 1; -#endif cso_set_rasterizer(st->cso_context, &raster); } @@ -256,7 +248,6 @@ clear_with_quad(GLcontext *ctx, pipe->bind_fs_state(pipe, st->clear.fs); -#if !TEST_DRAW_PASSTHROUGH /* vertex shader state: color/position pass-through */ if (!st->clear.vs) { const uint semantic_names[] = { TGSI_SEMANTIC_POSITION, @@ -268,9 +259,7 @@ clear_with_quad(GLcontext *ctx, &st->clear.vert_shader); } pipe->bind_vs_state(pipe, st->clear.vs); -#endif -#if !TEST_DRAW_PASSTHROUGH /* viewport state: identity since we're drawing in window coords */ { struct pipe_viewport_state vp; @@ -284,7 +273,6 @@ clear_with_quad(GLcontext *ctx, vp.translate[3] = 0.0; cso_set_viewport(st->cso_context, &vp); } -#endif /* draw quad matching scissor rect (XXX verify coord round-off) */ draw_quad(ctx, x0, y0, x1, y1, ctx->Depth.Clear, ctx->Color.ClearColor); -- cgit v1.2.3 From e8823bb7dfad7c6241da185cd0ac94ede42c33e5 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Thu, 3 Apr 2008 12:52:55 -0600 Subject: gallium: include st_cb_bitmap.h to silence warning --- src/mesa/state_tracker/st_cb_readpixels.c | 1 + 1 file changed, 1 insertion(+) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_readpixels.c b/src/mesa/state_tracker/st_cb_readpixels.c index 82df28b29a1..2bcc8c99fb7 100644 --- a/src/mesa/state_tracker/st_cb_readpixels.c +++ b/src/mesa/state_tracker/st_cb_readpixels.c @@ -43,6 +43,7 @@ #include "pipe/p_inlines.h" #include "util/p_tile.h" #include "st_context.h" +#include "st_cb_bitmap.h" #include "st_cb_readpixels.h" #include "st_cb_fbo.h" #include "st_format.h" -- cgit v1.2.3 From ce5c867cbb17b2444ebc3db5c6a03cee5e2edb8a Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Thu, 3 Apr 2008 12:54:32 -0600 Subject: gallium: streamline viewport/raster/shader state for clearing with quads Move init of these items to new st_init_clear(). --- src/mesa/state_tracker/st_cb_clear.c | 75 ++++++++++++++++++------------------ src/mesa/state_tracker/st_cb_clear.h | 4 ++ src/mesa/state_tracker/st_context.c | 1 + src/mesa/state_tracker/st_context.h | 2 + 4 files changed, 45 insertions(+), 37 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_clear.c b/src/mesa/state_tracker/st_cb_clear.c index 041b9be2cc9..b5e737e0d1f 100644 --- a/src/mesa/state_tracker/st_cb_clear.c +++ b/src/mesa/state_tracker/st_cb_clear.c @@ -55,6 +55,42 @@ #include "cso_cache/cso_context.h" +void +st_init_clear(struct st_context *st) +{ + struct pipe_context *pipe = st->pipe; + + /* rasterizer state: bypass clipping */ + memset(&st->clear.raster, 0, sizeof(st->clear.raster)); + st->clear.raster.bypass_clipping = 1; + + /* viewport state: identity since we're drawing in window coords */ + st->clear.viewport.scale[0] = 1.0; + st->clear.viewport.scale[1] = 1.0; + st->clear.viewport.scale[2] = 1.0; + st->clear.viewport.scale[3] = 1.0; + st->clear.viewport.translate[0] = 0.0; + st->clear.viewport.translate[1] = 0.0; + st->clear.viewport.translate[2] = 0.0; + st->clear.viewport.translate[3] = 0.0; + + /* fragment shader state: color pass-through program */ + st->clear.fs = + util_make_fragment_passthrough_shader(pipe, &st->clear.frag_shader); + + /* vertex shader state: color/position pass-through */ + { + const uint semantic_names[] = { TGSI_SEMANTIC_POSITION, + TGSI_SEMANTIC_COLOR }; + const uint semantic_indexes[] = { 0, 0 }; + st->clear.vs = util_make_vertex_passthrough_shader(pipe, 2, + semantic_names, + semantic_indexes, + &st->clear.vert_shader); + } +} + + void st_destroy_clear(struct st_context *st) { @@ -233,47 +269,12 @@ clear_with_quad(GLcontext *ctx, cso_set_depth_stencil_alpha(st->cso_context, &depth_stencil); } - /* rasterizer state: bypass clipping */ - { - struct pipe_rasterizer_state raster; - memset(&raster, 0, sizeof(raster)); - raster.bypass_clipping = 1; - cso_set_rasterizer(st->cso_context, &raster); - } + cso_set_rasterizer(st->cso_context, &st->clear.raster); + cso_set_viewport(st->cso_context, &st->clear.viewport); - /* fragment shader state: color pass-through program */ - if (!st->clear.fs) { - st->clear.fs = util_make_fragment_passthrough_shader(pipe, &st->clear.frag_shader); - } pipe->bind_fs_state(pipe, st->clear.fs); - - - /* vertex shader state: color/position pass-through */ - if (!st->clear.vs) { - const uint semantic_names[] = { TGSI_SEMANTIC_POSITION, - TGSI_SEMANTIC_COLOR }; - const uint semantic_indexes[] = { 0, 0 }; - st->clear.vs = util_make_vertex_passthrough_shader(pipe, 2, - semantic_names, - semantic_indexes, - &st->clear.vert_shader); - } pipe->bind_vs_state(pipe, st->clear.vs); - /* viewport state: identity since we're drawing in window coords */ - { - struct pipe_viewport_state vp; - vp.scale[0] = 1.0; - vp.scale[1] = 1.0; - vp.scale[2] = 1.0; - vp.scale[3] = 1.0; - vp.translate[0] = 0.0; - vp.translate[1] = 0.0; - vp.translate[2] = 0.0; - vp.translate[3] = 0.0; - cso_set_viewport(st->cso_context, &vp); - } - /* draw quad matching scissor rect (XXX verify coord round-off) */ draw_quad(ctx, x0, y0, x1, y1, ctx->Depth.Clear, ctx->Color.ClearColor); diff --git a/src/mesa/state_tracker/st_cb_clear.h b/src/mesa/state_tracker/st_cb_clear.h index dfa4033faa6..f49387747d6 100644 --- a/src/mesa/state_tracker/st_cb_clear.h +++ b/src/mesa/state_tracker/st_cb_clear.h @@ -30,6 +30,10 @@ #define ST_CB_CLEAR_H +extern void +st_init_clear(struct st_context *st); + + extern void st_destroy_clear(struct st_context *st); diff --git a/src/mesa/state_tracker/st_context.c b/src/mesa/state_tracker/st_context.c index a20195f2dea..7511c280740 100644 --- a/src/mesa/state_tracker/st_context.c +++ b/src/mesa/state_tracker/st_context.c @@ -110,6 +110,7 @@ st_create_context_priv( GLcontext *ctx, struct pipe_context *pipe ) st_init_atoms( st ); st_init_bitmap(st); + st_init_clear(st); st_init_draw( st ); st_init_generate_mipmap(st); st_init_blit(st); diff --git a/src/mesa/state_tracker/st_context.h b/src/mesa/state_tracker/st_context.h index 44705bc89a3..bcebbd49436 100644 --- a/src/mesa/state_tracker/st_context.h +++ b/src/mesa/state_tracker/st_context.h @@ -161,6 +161,8 @@ struct st_context struct { struct pipe_shader_state vert_shader; struct pipe_shader_state frag_shader; + struct pipe_rasterizer_state raster; + struct pipe_viewport_state viewport; void *vs; void *fs; float vertices[4][2][4]; /**< vertex pos + color */ -- cgit v1.2.3 From 124e1345c9ba4abe17bb04b8781ec0fe803eda7b Mon Sep 17 00:00:00 2001 From: Brian Date: Thu, 3 Apr 2008 13:16:37 -0600 Subject: gallium: set rasterizer.gl_rasterization_rules = 1 in a few more places --- src/mesa/state_tracker/st_cb_bitmap.c | 1 + src/mesa/state_tracker/st_cb_clear.c | 1 + 2 files changed, 2 insertions(+) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_cb_bitmap.c b/src/mesa/state_tracker/st_cb_bitmap.c index 975a55d6dc0..0872f2bd28a 100644 --- a/src/mesa/state_tracker/st_cb_bitmap.c +++ b/src/mesa/state_tracker/st_cb_bitmap.c @@ -754,6 +754,7 @@ st_init_bitmap(struct st_context *st) /* init baseline rasterizer state once */ memset(&st->bitmap.rasterizer, 0, sizeof(st->bitmap.rasterizer)); + st->bitmap.rasterizer.gl_rasterization_rules = 1; st->bitmap.rasterizer.bypass_vs = 1; init_bitmap_cache(st); diff --git a/src/mesa/state_tracker/st_cb_clear.c b/src/mesa/state_tracker/st_cb_clear.c index b5e737e0d1f..fa9f986f116 100644 --- a/src/mesa/state_tracker/st_cb_clear.c +++ b/src/mesa/state_tracker/st_cb_clear.c @@ -62,6 +62,7 @@ st_init_clear(struct st_context *st) /* rasterizer state: bypass clipping */ memset(&st->clear.raster, 0, sizeof(st->clear.raster)); + st->clear.raster.gl_rasterization_rules = 1; st->clear.raster.bypass_clipping = 1; /* viewport state: identity since we're drawing in window coords */ -- cgit v1.2.3 From 1307eebfa07e3440554eb2871e5dbd94e98ed7a8 Mon Sep 17 00:00:00 2001 From: Brian Date: Thu, 3 Apr 2008 16:37:30 -0600 Subject: gallium: test if PIPE_FORMAT_YCBCR[_REV] is supported and enable GL_MESA_ycbcr_texture Update texture format selection code too. --- src/mesa/state_tracker/st_extensions.c | 5 +++++ src/mesa/state_tracker/st_format.c | 25 +++++++++++++++++-------- 2 files changed, 22 insertions(+), 8 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_extensions.c b/src/mesa/state_tracker/st_extensions.c index 20f4652413d..47a50d40ca1 100644 --- a/src/mesa/state_tracker/st_extensions.c +++ b/src/mesa/state_tracker/st_extensions.c @@ -220,4 +220,9 @@ void st_init_extensions(struct st_context *st) ctx->Extensions.EXT_texture_compression_s3tc = GL_TRUE; } + if (screen->is_format_supported(screen, PIPE_FORMAT_YCBCR, PIPE_TEXTURE) || + screen->is_format_supported(screen, PIPE_FORMAT_YCBCR_REV, PIPE_TEXTURE)) { + ctx->Extensions.MESA_ycbcr_texture = GL_TRUE; + } + } diff --git a/src/mesa/state_tracker/st_format.c b/src/mesa/state_tracker/st_format.c index cb6fa9a573d..761645c1057 100644 --- a/src/mesa/state_tracker/st_format.c +++ b/src/mesa/state_tracker/st_format.c @@ -189,15 +189,14 @@ st_get_format_info(enum pipe_format format, struct pipe_format_info *pinfo) pinfo->base_format = GL_RGBA; } } + else if (pf_layout(format) == PIPE_FORMAT_LAYOUT_YCBCR) { + pinfo->base_format = GL_YCBCR_MESA; + pinfo->datatype = GL_UNSIGNED_SHORT; + pinfo->size = 2; /* two bytes per "texel" */ + } else { - pipe_format_ycbcr_t info; - - assert( pf_layout(format) == PIPE_FORMAT_LAYOUT_YCBCR ); - - info = format; - - /* TODO */ - assert( 0 ); + /* compressed format? */ + assert(0); } #if 0 @@ -275,6 +274,8 @@ st_mesa_format_to_pipe_format(GLuint mesaFormat) return PIPE_FORMAT_Z32_UNORM; case MESA_FORMAT_Z24_S8: return PIPE_FORMAT_Z24S8_UNORM; + case MESA_FORMAT_YCBCR: + return PIPE_FORMAT_YCBCR; default: assert(0); return 0; @@ -435,6 +436,14 @@ choose_format(struct pipe_context *pipe, GLint internalFormat, uint surfType) return default_rgba_format( screen, surfType ); case GL_YCBCR_MESA: + if (screen->is_format_supported(screen, PIPE_FORMAT_YCBCR, + PIPE_TEXTURE)) { + return PIPE_FORMAT_YCBCR; + } + if (screen->is_format_supported(screen, PIPE_FORMAT_YCBCR_REV, + PIPE_TEXTURE)) { + return PIPE_FORMAT_YCBCR_REV; + } return PIPE_FORMAT_NONE; case GL_RGB_S3TC: -- cgit v1.2.3 From c07d3f6a9e62bd88e05d4ebf72430139b0531be8 Mon Sep 17 00:00:00 2001 From: Michel Dänzer Date: Fri, 4 Apr 2008 09:06:13 +0100 Subject: gallium: Always allocate new const buffers instead of modifying existing ones. --- src/mesa/state_tracker/st_atom_constbuf.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) (limited to 'src/mesa') diff --git a/src/mesa/state_tracker/st_atom_constbuf.c b/src/mesa/state_tracker/st_atom_constbuf.c index cd7372902b8..03093579e15 100644 --- a/src/mesa/state_tracker/st_atom_constbuf.c +++ b/src/mesa/state_tracker/st_atom_constbuf.c @@ -71,13 +71,12 @@ void st_upload_constants( struct st_context *st, _mesa_load_state_parameters(st->ctx, params); - if (cbuf->buffer && cbuf->size != paramBytes) - pipe_buffer_reference( ws, &cbuf->buffer, NULL ); - - if (!cbuf->buffer) { - cbuf->buffer = ws->buffer_create(ws, 1, PIPE_BUFFER_USAGE_CONSTANT, - paramBytes); - } + /* We always need to get a new buffer, to keep the drivers simple and + * avoid gratuitous rendering synchronization. + */ + pipe_buffer_reference( ws, &cbuf->buffer, NULL ); + cbuf->buffer = ws->buffer_create( ws, 1, PIPE_BUFFER_USAGE_CONSTANT, + paramBytes ); if (0) { -- cgit v1.2.3