diff options
author | Tiziano Bacocco <[email protected]> | 2014-12-30 21:33:48 +0100 |
---|---|---|
committer | Ilia Mirkin <[email protected]> | 2014-12-30 20:11:55 -0500 |
commit | 609c3e51f5ca8abb15867537997369e7e8a678e3 (patch) | |
tree | efd5f64ddcac3a57a1aab2fb013ed08524840dec /src/gallium/drivers/nouveau/nvc0 | |
parent | 3ba57bae47666ada1145259755fc326b1b9f9463 (diff) |
nv50,nvc0: implement half_pixel_center
LAST_LINE_PIXEL has actually been renamed to PIXEL_CENTER_INTEGER in
rnndb; use that method to implement the rasterizer setting, used for
st/nine.
Signed-off-by: Tiziano Bacocco <[email protected]>
Reviewed-by: Ilia Mirkin <[email protected]>
Cc: "10.4" <[email protected]>
Diffstat (limited to 'src/gallium/drivers/nouveau/nvc0')
-rw-r--r-- | src/gallium/drivers/nouveau/nvc0/nvc0_3d.xml.h | 2 | ||||
-rw-r--r-- | src/gallium/drivers/nouveau/nvc0/nvc0_screen.c | 2 | ||||
-rw-r--r-- | src/gallium/drivers/nouveau/nvc0/nvc0_state.c | 4 | ||||
-rw-r--r-- | src/gallium/drivers/nouveau/nvc0/nvc0_stateobj.h | 2 |
4 files changed, 5 insertions, 5 deletions
diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_3d.xml.h b/src/gallium/drivers/nouveau/nvc0/nvc0_3d.xml.h index 5bd5e95370f..57407c5fa1b 100644 --- a/src/gallium/drivers/nouveau/nvc0/nvc0_3d.xml.h +++ b/src/gallium/drivers/nouveau/nvc0/nvc0_3d.xml.h @@ -1041,7 +1041,7 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. #define NVC0_3D_CULL_FACE_BACK 0x00000405 #define NVC0_3D_CULL_FACE_FRONT_AND_BACK 0x00000408 -#define NVC0_3D_LINE_LAST_PIXEL 0x00001924 +#define NVC0_3D_PIXEL_CENTER_INTEGER 0x00001924 #define NVC0_3D_VIEWPORT_TRANSFORM_EN 0x0000192c diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_screen.c b/src/gallium/drivers/nouveau/nvc0/nvc0_screen.c index 7f68236ad14..5032c7f8070 100644 --- a/src/gallium/drivers/nouveau/nvc0/nvc0_screen.c +++ b/src/gallium/drivers/nouveau/nvc0/nvc0_screen.c @@ -787,8 +787,6 @@ nvc0_screen_create(struct nouveau_device *dev) PUSH_DATA (push, 0); BEGIN_NVC0(push, NVC0_3D(LINE_WIDTH_SEPARATE), 1); PUSH_DATA (push, 1); - BEGIN_NVC0(push, NVC0_3D(LINE_LAST_PIXEL), 1); - PUSH_DATA (push, 0); BEGIN_NVC0(push, NVC0_3D(PRIM_RESTART_WITH_DRAW_ARRAYS), 1); PUSH_DATA (push, 1); BEGIN_NVC0(push, NVC0_3D(BLEND_SEPARATE_ALPHA), 1); diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_state.c b/src/gallium/drivers/nouveau/nvc0/nvc0_state.c index 54deb20cb0c..728618fdec3 100644 --- a/src/gallium/drivers/nouveau/nvc0/nvc0_state.c +++ b/src/gallium/drivers/nouveau/nvc0/nvc0_state.c @@ -204,7 +204,7 @@ nvc0_blend_state_delete(struct pipe_context *pipe, void *hwcso) FREE(hwcso); } -/* NOTE: ignoring line_last_pixel, using FALSE (set on screen init) */ +/* NOTE: ignoring line_last_pixel */ static void * nvc0_rasterizer_state_create(struct pipe_context *pipe, const struct pipe_rasterizer_state *cso) @@ -315,6 +315,8 @@ nvc0_rasterizer_state_create(struct pipe_context *pipe, SB_IMMED_3D(so, DEPTH_CLIP_NEGATIVE_Z, cso->clip_halfz); + SB_IMMED_3D(so, PIXEL_CENTER_INTEGER, !cso->half_pixel_center); + assert(so->size <= (sizeof(so->state) / sizeof(so->state[0]))); return (void *)so; } diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_stateobj.h b/src/gallium/drivers/nouveau/nvc0/nvc0_stateobj.h index 80c33424032..1d70b7c7b23 100644 --- a/src/gallium/drivers/nouveau/nvc0/nvc0_stateobj.h +++ b/src/gallium/drivers/nouveau/nvc0/nvc0_stateobj.h @@ -23,7 +23,7 @@ struct nvc0_blend_stateobj { struct nvc0_rasterizer_stateobj { struct pipe_rasterizer_state pipe; int size; - uint32_t state[43]; + uint32_t state[44]; }; struct nvc0_zsa_stateobj { |