diff options
author | Brian Paul <brianp@vmware.com> | 2010-04-23 14:00:50 -0600 |
---|---|---|
committer | Brian Paul <brianp@vmware.com> | 2010-04-23 15:41:49 -0600 |
commit | 76c7ad2e7d387feefe58dc2116b613fe11a8b273 (patch) | |
tree | 9ae2e05bb2f23c22134737a64213652c7a2c95e3 /src/mesa/state_tracker/st_format.c | |
parent | 57fc2e7802d1903848c2d7799f7e36308818b2e2 (diff) |
st/mesa: clean-up: use st_context() everywhere
Diffstat (limited to 'src/mesa/state_tracker/st_format.c')
-rw-r--r-- | src/mesa/state_tracker/st_format.c | 5 |
1 files changed, 3 insertions, 2 deletions
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); } |