diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/mesa/state_tracker/st_atom.c | 23 | ||||
-rw-r--r-- | src/mesa/state_tracker/st_cb_blit.c | 4 | ||||
-rwxr-xr-x | src/mesa/state_tracker/st_manager.c | 7 | ||||
-rw-r--r-- | src/mesa/state_tracker/st_manager.h | 5 |
4 files changed, 37 insertions, 2 deletions
diff --git a/src/mesa/state_tracker/st_atom.c b/src/mesa/state_tracker/st_atom.c index df1a94e831e..fa4b82c08dd 100644 --- a/src/mesa/state_tracker/st_atom.c +++ b/src/mesa/state_tracker/st_atom.c @@ -36,6 +36,7 @@ #include "st_atom.h" #include "st_program.h" #include "st_manager.h" +#include "st_cb_fbo.h" typedef void (*update_func_t)(struct st_context *st); @@ -191,13 +192,26 @@ void st_validate_state( struct st_context *st, enum st_pipeline pipeline ) st->gfx_shaders_may_be_dirty = false; } +#ifdef HAVE_TIZEN_PLATFORM + struct st_framebuffer *stdraw = st_ws_framebuffer(st->ctx->DrawBuffer); + boolean valid = TRUE; + + if (stdraw && stdraw->iface->validate_drawable) + valid = stdraw->iface->validate_drawable(stdraw->iface); + st_manager_validate_framebuffers(st, valid); +#else st_manager_validate_framebuffers(st); +#endif pipeline_mask = ST_PIPELINE_RENDER_STATE_MASK; break; case ST_PIPELINE_CLEAR: +#ifdef HAVE_TIZEN_PLATFORM + st_manager_validate_framebuffers(st, TRUE); +#else st_manager_validate_framebuffers(st); +#endif pipeline_mask = ST_PIPELINE_CLEAR_STATE_MASK; break; @@ -206,13 +220,20 @@ void st_validate_state( struct st_context *st, enum st_pipeline pipeline ) check_program_state(st); st->gfx_shaders_may_be_dirty = false; } - +#ifdef HAVE_TIZEN_PLATFORM + st_manager_validate_framebuffers(st, TRUE); +#else st_manager_validate_framebuffers(st); +#endif pipeline_mask = ST_PIPELINE_META_STATE_MASK; break; case ST_PIPELINE_UPDATE_FRAMEBUFFER: +#ifdef HAVE_TIZEN_PLATFORM + st_manager_validate_framebuffers(st, TRUE); +#else st_manager_validate_framebuffers(st); +#endif pipeline_mask = ST_PIPELINE_UPDATE_FB_STATE_MASK; break; diff --git a/src/mesa/state_tracker/st_cb_blit.c b/src/mesa/state_tracker/st_cb_blit.c index 564ad666655..11d36e6af8c 100644 --- a/src/mesa/state_tracker/st_cb_blit.c +++ b/src/mesa/state_tracker/st_cb_blit.c @@ -64,7 +64,11 @@ st_BlitFramebuffer(struct gl_context *ctx, } clip; struct pipe_blit_info blit; +#ifdef HAVE_TIZEN_PLATFORM + st_manager_validate_framebuffers(st, TRUE); +#else st_manager_validate_framebuffers(st); +#endif /* Make sure bitmap rendering has landed in the framebuffers */ st_flush_bitmap_cache(st); diff --git a/src/mesa/state_tracker/st_manager.c b/src/mesa/state_tracker/st_manager.c index 40deb8b71a3..cf72ef27701 100755 --- a/src/mesa/state_tracker/st_manager.c +++ b/src/mesa/state_tracker/st_manager.c @@ -1176,15 +1176,20 @@ st_manager_flush_frontbuffer(struct st_context *st) /** * Re-validate the framebuffers. */ +#ifdef HAVE_TIZEN_PLATFORM +void +st_manager_validate_framebuffers(struct st_context *st, bool valid) +#else void st_manager_validate_framebuffers(struct st_context *st) +#endif { struct st_framebuffer *stdraw = st_ws_framebuffer(st->ctx->DrawBuffer); struct st_framebuffer *stread = st_ws_framebuffer(st->ctx->ReadBuffer); #ifdef HAVE_TIZEN_PLATFORM if (stdraw) - st_framebuffer_validate(stdraw, st, TRUE); + st_framebuffer_validate(stdraw, st, valid); if (stread && stread != stdraw) st_framebuffer_validate(stread, st, TRUE); #else diff --git a/src/mesa/state_tracker/st_manager.h b/src/mesa/state_tracker/st_manager.h index 581e858229b..aa8c1972524 100644 --- a/src/mesa/state_tracker/st_manager.h +++ b/src/mesa/state_tracker/st_manager.h @@ -41,8 +41,13 @@ struct pipe_surface; void st_manager_flush_frontbuffer(struct st_context *st); +#ifdef HAVE_TIZEN_PLATFORM +void +st_manager_validate_framebuffers(struct st_context *st, bool valid); +#else void st_manager_validate_framebuffers(struct st_context *st); +#endif boolean st_manager_add_color_renderbuffer(struct st_context *st, struct gl_framebuffer *fb, |