From bae90edfdae0eac6c844ede21285453ef96a4f6e Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Thu, 10 Jul 2008 14:23:27 -0600 Subject: gallium: check for FEATURE_feedback and FEATURE_drawpix when creating/using the aux draw module --- src/mesa/state_tracker/st_context.c | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/mesa/state_tracker/st_context.c') diff --git a/src/mesa/state_tracker/st_context.c b/src/mesa/state_tracker/st_context.c index bf78cacb8e..8b30e35684 100644 --- a/src/mesa/state_tracker/st_context.c +++ b/src/mesa/state_tracker/st_context.c @@ -98,6 +98,7 @@ st_create_context_priv( GLcontext *ctx, struct pipe_context *pipe ) /* state tracker needs the VBO module */ _vbo_CreateContext(ctx); +#if FEATURE_feedback || FEATURE_drawpix st->draw = draw_create(); /* for selection/feedback */ /* Disable draw options that might convert points/lines to tris, etc. @@ -107,6 +108,7 @@ st_create_context_priv( GLcontext *ctx, struct pipe_context *pipe ) draw_wide_point_threshold(st->draw, 1000.0f); draw_enable_line_stipple(st->draw, FALSE); draw_enable_point_sprites(st->draw, FALSE); +#endif st->dirty.mesa = ~0; st->dirty.st = ~0; @@ -164,7 +166,9 @@ static void st_destroy_context_priv( struct st_context *st ) { uint i; +#if FEATURE_feedback || FEATURE_drawpix draw_destroy(st->draw); +#endif st_destroy_atoms( st ); st_destroy_draw( st ); st_destroy_generate_mipmap(st); -- cgit v1.2.3