From 1fb5bc83f19cc87767f902b99e77b330258a69dd Mon Sep 17 00:00:00 2001 From: Marek Olšák Date: Sun, 9 Apr 2017 16:45:00 +0200 Subject: st/mesa: put the bitmap_cache structure inside st_context This is nicer on caches, and the next commit will need to access the structure from a different place. Reviewed-by: Ilia Mirkin Reviewed-by: Brian Paul --- src/mesa/state_tracker/st_context.h | 23 +++++++++++++++++++++-- 1 file changed, 21 insertions(+), 2 deletions(-) (limited to 'src/mesa/state_tracker/st_context.h') diff --git a/src/mesa/state_tracker/st_context.h b/src/mesa/state_tracker/st_context.h index dfee9275657..74ab43cfe9c 100644 --- a/src/mesa/state_tracker/st_context.h +++ b/src/mesa/state_tracker/st_context.h @@ -40,7 +40,6 @@ extern "C" { #endif -struct bitmap_cache; struct dd_function_table; struct draw_context; struct draw_stage; @@ -59,6 +58,26 @@ struct st_util_vertex float s, t; }; +struct st_bitmap_cache +{ + /** Window pos to render the cached image */ + GLint xpos, ypos; + /** Bounds of region used in window coords */ + GLint xmin, ymin, xmax, ymax; + + GLfloat color[4]; + + /** Bitmap's Z position */ + GLfloat zpos; + + struct pipe_resource *texture; + struct pipe_transfer *trans; + + GLboolean empty; + + /** An I8 texture image: */ + ubyte *buffer; +}; struct st_context { @@ -180,7 +199,7 @@ struct st_context struct pipe_sampler_state atlas_sampler; enum pipe_format tex_format; void *vs; - struct bitmap_cache *cache; + struct st_bitmap_cache cache; } bitmap; /** for glDraw/CopyPixels */ -- cgit v1.2.3