diff options
author | Brian Paul <[email protected]> | 2016-02-15 17:27:15 -0700 |
---|---|---|
committer | Brian Paul <[email protected]> | 2016-02-17 11:25:02 -0700 |
commit | 5e52df21982eca6188c57f147ff6cc7361b3a61a (patch) | |
tree | 8190a959f82c365363d06a4eb81690deef1f15ad /src/mesa | |
parent | 9a939ebb47a0d37a6b29e3dbb1b20bdc9538a721 (diff) |
st/mesa: use cso_set_viewport_dims() in try_pbo_upload_common()
Note that this results in a different transformation for the viewport's
Z axis (depth range), but that doesn't matter for this case.
Reviewed-by: Roland Scheidegger <[email protected]>
Diffstat (limited to 'src/mesa')
-rw-r--r-- | src/mesa/state_tracker/st_cb_texture.c | 13 |
1 files changed, 1 insertions, 12 deletions
diff --git a/src/mesa/state_tracker/st_cb_texture.c b/src/mesa/state_tracker/st_cb_texture.c index a06cc72bdd2..d09c3609a9e 100644 --- a/src/mesa/state_tracker/st_cb_texture.c +++ b/src/mesa/state_tracker/st_cb_texture.c @@ -1474,18 +1474,7 @@ try_pbo_upload_common(struct gl_context *ctx, pipe_surface_reference(&fb.cbufs[0], NULL); } - /* Viewport state */ - { - struct pipe_viewport_state vp; - vp.scale[0] = 0.5f * surface->width; - vp.scale[1] = 0.5f * surface->height; - vp.scale[2] = 1.0f; - vp.translate[0] = 0.5f * surface->width; - vp.translate[1] = 0.5f * surface->height; - vp.translate[2] = 0.0f; - - cso_set_viewport(cso, &vp); - } + cso_set_viewport_dims(cso, surface->width, surface->height, FALSE); /* Blend state */ cso_set_blend(cso, &st->pbo_upload.blend); |