mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-01-10 03:50:13 +01:00
nvc0: reset the instanced elements state when doing blit using 3d engine
Since we update num_vtxelts here, we could otherwise end up with stale
instancing information in the upper bits which wouldn't otherwise get
reset. (Also we run the risk of the previous draw having set the first
element as instanced.)
This appears as one of the causes for the test pointed out in fdo#90363
to fail on nvc0.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=90363
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
Cc: mesa-stable@lists.freedesktop.org
(cherry picked from commit 7892210400)
This commit is contained in:
parent
f3804a0051
commit
d47d799b5f
1 changed files with 6 additions and 0 deletions
|
|
@ -1152,6 +1152,12 @@ nvc0_blit_3d(struct nvc0_context *nvc0, const struct pipe_blit_info *info)
|
|||
NVC0_3D_VERTEX_ATTRIB_FORMAT_SIZE_32 |
|
||||
NVC0_3D_VERTEX_ATTRIB_FORMAT_CONST);
|
||||
}
|
||||
if (nvc0->state.instance_elts) {
|
||||
nvc0->state.instance_elts = 0;
|
||||
BEGIN_NVC0(push, NVC0_3D(MACRO_VERTEX_ARRAY_PER_INSTANCE), 2);
|
||||
PUSH_DATA (push, n);
|
||||
PUSH_DATA (push, 0);
|
||||
}
|
||||
nvc0->state.num_vtxelts = 2;
|
||||
|
||||
for (i = 0; i < info->dst.box.depth; ++i, z += dz) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue