diff options
author | Ilia Mirkin <[email protected]> | 2016-07-01 00:59:58 -0400 |
---|---|---|
committer | Ilia Mirkin <[email protected]> | 2016-07-01 01:04:10 -0400 |
commit | 51ca57df0196837e5ac754fd8e54e64205a5b957 (patch) | |
tree | e28f1819bdfc6fc87f78be82c5cc2bb86b71b866 /src/gallium/drivers/nouveau/nv30/nv30_draw.c | |
parent | 71609c99548ab3724e604d59b771ef1c83eac4fe (diff) |
nv30: go back to not using viewport validate function for swtnl
The output of draw requires a null viewport transform, which the regular
code is ill-equiped to do. Reinstate the original settings in the render
path, and add setting of the viewport clip polygon based on fb
width/height (as that is all taken care of by draw).
Signed-off-by: Ilia Mirkin <[email protected]>
Diffstat (limited to 'src/gallium/drivers/nouveau/nv30/nv30_draw.c')
-rw-r--r-- | src/gallium/drivers/nouveau/nv30/nv30_draw.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/gallium/drivers/nouveau/nv30/nv30_draw.c b/src/gallium/drivers/nouveau/nv30/nv30_draw.c index 041c73ca72a..10c9f56fad5 100644 --- a/src/gallium/drivers/nouveau/nv30/nv30_draw.c +++ b/src/gallium/drivers/nouveau/nv30/nv30_draw.c @@ -342,6 +342,22 @@ nv30_render_validate(struct nv30_context *nv30) for (; i < 16; i++) r->vtxfmt[i] = NV30_3D_VTXFMT_TYPE_V32_FLOAT; + BEGIN_NV04(push, NV30_3D(VIEWPORT_TRANSLATE_X), 8); + PUSH_DATAf(push, 0.0); + PUSH_DATAf(push, 0.0); + PUSH_DATAf(push, 0.0); + PUSH_DATAf(push, 0.0); + PUSH_DATAf(push, 1.0); + PUSH_DATAf(push, 1.0); + PUSH_DATAf(push, 1.0); + PUSH_DATAf(push, 1.0); + BEGIN_NV04(push, NV30_3D(DEPTH_RANGE_NEAR), 2); + PUSH_DATAf(push, 0.0); + PUSH_DATAf(push, 1.0); + BEGIN_NV04(push, NV30_3D(VIEWPORT_HORIZ), 2); + PUSH_DATA (push, nv30->framebuffer.width << 16); + PUSH_DATA (push, nv30->framebuffer.height << 16); + BEGIN_NV04(push, NV30_3D(VTXFMT(0)), 16); PUSH_DATAp(push, r->vtxfmt, 16); |