diff options
author | Jesse Barnes <[email protected]> | 2010-04-19 09:56:49 -0700 |
---|---|---|
committer | Jesse Barnes <[email protected]> | 2010-04-19 09:56:49 -0700 |
commit | 64644ec3b21884d4a974fa29087fa98c4ed9e112 (patch) | |
tree | d5752ba82220f9ebe5d61d7e98ecc27f331aa65c /src/mesa/state_tracker | |
parent | 4df3e76949e1ca7b29f844ad9a715b442396a024 (diff) | |
parent | 385e2896ebf54ac0b016132fe513f21a5b67ba4f (diff) |
Merge branch '7.8'
Diffstat (limited to 'src/mesa/state_tracker')
-rw-r--r-- | src/mesa/state_tracker/st_atom_scissor.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/src/mesa/state_tracker/st_atom_scissor.c b/src/mesa/state_tracker/st_atom_scissor.c index 5e0c51cff0a..56b1383ae39 100644 --- a/src/mesa/state_tracker/st_atom_scissor.c +++ b/src/mesa/state_tracker/st_atom_scissor.c @@ -72,12 +72,15 @@ update_scissor( struct st_context *st ) scissor.minx = scissor.miny = scissor.maxx = scissor.maxy = 0; } - /* Now invert Y. Pipe drivers use the convention Y=0=top for surfaces + /* Now invert Y if needed. + * Gallium drivers use the convention Y=0=top for surfaces. */ - miny = fb->Height - scissor.maxy; - maxy = fb->Height - scissor.miny; - scissor.miny = miny; - scissor.maxy = maxy; + if (st_fb_orientation(fb) == Y_0_TOP) { + miny = fb->Height - scissor.maxy; + maxy = fb->Height - scissor.miny; + scissor.miny = miny; + scissor.maxy = maxy; + } if (memcmp(&scissor, &st->state.scissor, sizeof(scissor)) != 0) { /* state has changed */ |