From 76c7ad2e7d387feefe58dc2116b613fe11a8b273 Mon Sep 17 00:00:00 2001 From: Brian Paul Date: Fri, 23 Apr 2010 14:00:50 -0600 Subject: st/mesa: clean-up: use st_context() everywhere --- src/mesa/state_tracker/st_format.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/mesa/state_tracker/st_format.c') diff --git a/src/mesa/state_tracker/st_format.c b/src/mesa/state_tracker/st_format.c index fa6dd2d636..c149c5cf0b 100644 --- a/src/mesa/state_tracker/st_format.c +++ b/src/mesa/state_tracker/st_format.c @@ -650,6 +650,7 @@ gl_format st_ChooseTextureFormat(GLcontext *ctx, GLint internalFormat, GLenum format, GLenum type) { + struct pipe_screen *screen = st_context(ctx)->pipe->screen; enum pipe_format pFormat; uint bindings; @@ -665,12 +666,12 @@ st_ChooseTextureFormat(GLcontext *ctx, GLint internalFormat, else bindings = PIPE_BIND_SAMPLER_VIEW | PIPE_BIND_RENDER_TARGET; - pFormat = st_choose_format(ctx->st->pipe->screen, internalFormat, + pFormat = st_choose_format(screen, internalFormat, PIPE_TEXTURE_2D, bindings); if (pFormat == PIPE_FORMAT_NONE) { /* try choosing format again, this time without render target bindings */ - pFormat = st_choose_format(ctx->st->pipe->screen, internalFormat, + pFormat = st_choose_format(screen, internalFormat, PIPE_TEXTURE_2D, PIPE_BIND_SAMPLER_VIEW); } -- cgit v1.2.3