nv50: rename nv50_context::dirty to nv50_context::dirty_3d
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Reviewed-by: Pierre Moreau <pierre.morrow@free.fr> Tested-by: Pierre Moreau <pierre.morrow@free.fr>
This commit is contained in:
parent
9211b68ad3
commit
dedb46f582
|
@ -314,5 +314,5 @@ nv50_launch_grid(struct pipe_context *pipe, const struct pipe_grid_info *info)
|
|||
PUSH_DATA (push, 0);
|
||||
|
||||
/* bind a compute shader clobbers fragment shader state */
|
||||
nv50->dirty |= NV50_NEW_FRAGPROG;
|
||||
nv50->dirty_3d |= NV50_NEW_FRAGPROG;
|
||||
}
|
||||
|
|
|
@ -176,7 +176,7 @@ nv50_invalidate_resource_storage(struct nouveau_context *ctx,
|
|||
for (i = 0; i < nv50->framebuffer.nr_cbufs; ++i) {
|
||||
if (nv50->framebuffer.cbufs[i] &&
|
||||
nv50->framebuffer.cbufs[i]->texture == res) {
|
||||
nv50->dirty |= NV50_NEW_FRAMEBUFFER;
|
||||
nv50->dirty_3d |= NV50_NEW_FRAMEBUFFER;
|
||||
nouveau_bufctx_reset(nv50->bufctx_3d, NV50_BIND_FB);
|
||||
if (!--ref)
|
||||
return ref;
|
||||
|
@ -186,7 +186,7 @@ nv50_invalidate_resource_storage(struct nouveau_context *ctx,
|
|||
if (bind & PIPE_BIND_DEPTH_STENCIL) {
|
||||
if (nv50->framebuffer.zsbuf &&
|
||||
nv50->framebuffer.zsbuf->texture == res) {
|
||||
nv50->dirty |= NV50_NEW_FRAMEBUFFER;
|
||||
nv50->dirty_3d |= NV50_NEW_FRAMEBUFFER;
|
||||
nouveau_bufctx_reset(nv50->bufctx_3d, NV50_BIND_FB);
|
||||
if (!--ref)
|
||||
return ref;
|
||||
|
@ -202,7 +202,7 @@ nv50_invalidate_resource_storage(struct nouveau_context *ctx,
|
|||
assert(nv50->num_vtxbufs <= PIPE_MAX_ATTRIBS);
|
||||
for (i = 0; i < nv50->num_vtxbufs; ++i) {
|
||||
if (nv50->vtxbuf[i].buffer == res) {
|
||||
nv50->dirty |= NV50_NEW_ARRAYS;
|
||||
nv50->dirty_3d |= NV50_NEW_ARRAYS;
|
||||
nouveau_bufctx_reset(nv50->bufctx_3d, NV50_BIND_VERTEX);
|
||||
if (!--ref)
|
||||
return ref;
|
||||
|
@ -222,7 +222,7 @@ nv50_invalidate_resource_storage(struct nouveau_context *ctx,
|
|||
for (i = 0; i < nv50->num_textures[s]; ++i) {
|
||||
if (nv50->textures[s][i] &&
|
||||
nv50->textures[s][i]->texture == res) {
|
||||
nv50->dirty |= NV50_NEW_TEXTURES;
|
||||
nv50->dirty_3d |= NV50_NEW_TEXTURES;
|
||||
nouveau_bufctx_reset(nv50->bufctx_3d, NV50_BIND_TEXTURES);
|
||||
if (!--ref)
|
||||
return ref;
|
||||
|
@ -236,7 +236,7 @@ nv50_invalidate_resource_storage(struct nouveau_context *ctx,
|
|||
continue;
|
||||
if (!nv50->constbuf[s][i].user &&
|
||||
nv50->constbuf[s][i].u.buf == res) {
|
||||
nv50->dirty |= NV50_NEW_CONSTBUF;
|
||||
nv50->dirty_3d |= NV50_NEW_CONSTBUF;
|
||||
nv50->constbuf_dirty[s] |= 1 << i;
|
||||
nouveau_bufctx_reset(nv50->bufctx_3d, NV50_BIND_CB(s, i));
|
||||
if (!--ref)
|
||||
|
|
|
@ -115,7 +115,7 @@ struct nv50_context {
|
|||
struct nouveau_bufctx *bufctx;
|
||||
struct nouveau_bufctx *bufctx_cp;
|
||||
|
||||
uint32_t dirty;
|
||||
uint32_t dirty_3d; /* dirty flags for 3d state */
|
||||
uint32_t dirty_cp; /* dirty flags for compute state */
|
||||
bool cb_dirty;
|
||||
|
||||
|
|
|
@ -181,7 +181,7 @@ nv50_fragprog_validate(struct nv50_context *nv50)
|
|||
fp->fp.force_persample_interp = rast->force_persample_interp;
|
||||
}
|
||||
|
||||
if (fp->mem && !(nv50->dirty & (NV50_NEW_FRAGPROG | NV50_NEW_MIN_SAMPLES)))
|
||||
if (fp->mem && !(nv50->dirty_3d & (NV50_NEW_FRAGPROG | NV50_NEW_MIN_SAMPLES)))
|
||||
return;
|
||||
|
||||
if (!nv50_program_validate(nv50, fp))
|
||||
|
@ -309,7 +309,7 @@ nv50_validate_derived_rs(struct nv50_context *nv50)
|
|||
PUSH_DATA (push, !nv50->rast->pipe.rasterizer_discard);
|
||||
}
|
||||
|
||||
if (nv50->dirty & NV50_NEW_FRAGPROG)
|
||||
if (nv50->dirty_3d & NV50_NEW_FRAGPROG)
|
||||
return;
|
||||
psize = nv50->state.semantic_psize & ~NV50_3D_SEMANTIC_PTSZ_PTSZ_EN__MASK;
|
||||
color = nv50->state.semantic_color & ~NV50_3D_SEMANTIC_COLOR_CLMP_EN;
|
||||
|
@ -378,9 +378,9 @@ nv50_fp_linkage_validate(struct nv50_context *nv50)
|
|||
uint8_t map[64];
|
||||
uint8_t so_map[64];
|
||||
|
||||
if (!(nv50->dirty & (NV50_NEW_VERTPROG |
|
||||
NV50_NEW_FRAGPROG |
|
||||
NV50_NEW_GMTYPROG))) {
|
||||
if (!(nv50->dirty_3d & (NV50_NEW_VERTPROG |
|
||||
NV50_NEW_FRAGPROG |
|
||||
NV50_NEW_GMTYPROG))) {
|
||||
uint8_t bfc, ffc;
|
||||
ffc = (nv50->state.semantic_color & NV50_3D_SEMANTIC_COLOR_FFC0_ID__MASK);
|
||||
bfc = (nv50->state.semantic_color & NV50_3D_SEMANTIC_COLOR_BFC0_ID__MASK)
|
||||
|
|
|
@ -200,7 +200,7 @@ nv50_blend_state_bind(struct pipe_context *pipe, void *hwcso)
|
|||
struct nv50_context *nv50 = nv50_context(pipe);
|
||||
|
||||
nv50->blend = hwcso;
|
||||
nv50->dirty |= NV50_NEW_BLEND;
|
||||
nv50->dirty_3d |= NV50_NEW_BLEND;
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -337,7 +337,7 @@ nv50_rasterizer_state_bind(struct pipe_context *pipe, void *hwcso)
|
|||
struct nv50_context *nv50 = nv50_context(pipe);
|
||||
|
||||
nv50->rast = hwcso;
|
||||
nv50->dirty |= NV50_NEW_RASTERIZER;
|
||||
nv50->dirty_3d |= NV50_NEW_RASTERIZER;
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -426,7 +426,7 @@ nv50_zsa_state_bind(struct pipe_context *pipe, void *hwcso)
|
|||
struct nv50_context *nv50 = nv50_context(pipe);
|
||||
|
||||
nv50->zsa = hwcso;
|
||||
nv50->dirty |= NV50_NEW_ZSA;
|
||||
nv50->dirty_3d |= NV50_NEW_ZSA;
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -605,7 +605,7 @@ nv50_stage_sampler_states_bind(struct nv50_context *nv50, int s,
|
|||
|
||||
nv50->num_samplers[s] = nr;
|
||||
|
||||
nv50->dirty |= NV50_NEW_SAMPLERS;
|
||||
nv50->dirty_3d |= NV50_NEW_SAMPLERS;
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -700,7 +700,7 @@ nv50_stage_set_sampler_views(struct nv50_context *nv50, int s,
|
|||
|
||||
nouveau_bufctx_reset(nv50->bufctx_3d, NV50_BIND_TEXTURES);
|
||||
|
||||
nv50->dirty |= NV50_NEW_TEXTURES;
|
||||
nv50->dirty_3d |= NV50_NEW_TEXTURES;
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -776,7 +776,7 @@ nv50_vp_state_bind(struct pipe_context *pipe, void *hwcso)
|
|||
struct nv50_context *nv50 = nv50_context(pipe);
|
||||
|
||||
nv50->vertprog = hwcso;
|
||||
nv50->dirty |= NV50_NEW_VERTPROG;
|
||||
nv50->dirty_3d |= NV50_NEW_VERTPROG;
|
||||
}
|
||||
|
||||
static void *
|
||||
|
@ -792,7 +792,7 @@ nv50_fp_state_bind(struct pipe_context *pipe, void *hwcso)
|
|||
struct nv50_context *nv50 = nv50_context(pipe);
|
||||
|
||||
nv50->fragprog = hwcso;
|
||||
nv50->dirty |= NV50_NEW_FRAGPROG;
|
||||
nv50->dirty_3d |= NV50_NEW_FRAGPROG;
|
||||
}
|
||||
|
||||
static void *
|
||||
|
@ -808,7 +808,7 @@ nv50_gp_state_bind(struct pipe_context *pipe, void *hwcso)
|
|||
struct nv50_context *nv50 = nv50_context(pipe);
|
||||
|
||||
nv50->gmtyprog = hwcso;
|
||||
nv50->dirty |= NV50_NEW_GMTYPROG;
|
||||
nv50->dirty_3d |= NV50_NEW_GMTYPROG;
|
||||
}
|
||||
|
||||
static void *
|
||||
|
@ -882,7 +882,7 @@ nv50_set_constant_buffer(struct pipe_context *pipe, uint shader, uint index,
|
|||
}
|
||||
nv50->constbuf_dirty[s] |= 1 << i;
|
||||
|
||||
nv50->dirty |= NV50_NEW_CONSTBUF;
|
||||
nv50->dirty_3d |= NV50_NEW_CONSTBUF;
|
||||
}
|
||||
|
||||
/* =============================================================================
|
||||
|
@ -895,7 +895,7 @@ nv50_set_blend_color(struct pipe_context *pipe,
|
|||
struct nv50_context *nv50 = nv50_context(pipe);
|
||||
|
||||
nv50->blend_colour = *bcol;
|
||||
nv50->dirty |= NV50_NEW_BLEND_COLOUR;
|
||||
nv50->dirty_3d |= NV50_NEW_BLEND_COLOUR;
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -905,7 +905,7 @@ nv50_set_stencil_ref(struct pipe_context *pipe,
|
|||
struct nv50_context *nv50 = nv50_context(pipe);
|
||||
|
||||
nv50->stencil_ref = *sr;
|
||||
nv50->dirty |= NV50_NEW_STENCIL_REF;
|
||||
nv50->dirty_3d |= NV50_NEW_STENCIL_REF;
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -916,7 +916,7 @@ nv50_set_clip_state(struct pipe_context *pipe,
|
|||
|
||||
memcpy(nv50->clip.ucp, clip->ucp, sizeof(clip->ucp));
|
||||
|
||||
nv50->dirty |= NV50_NEW_CLIP;
|
||||
nv50->dirty_3d |= NV50_NEW_CLIP;
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -925,7 +925,7 @@ nv50_set_sample_mask(struct pipe_context *pipe, unsigned sample_mask)
|
|||
struct nv50_context *nv50 = nv50_context(pipe);
|
||||
|
||||
nv50->sample_mask = sample_mask;
|
||||
nv50->dirty |= NV50_NEW_SAMPLE_MASK;
|
||||
nv50->dirty_3d |= NV50_NEW_SAMPLE_MASK;
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -935,7 +935,7 @@ nv50_set_min_samples(struct pipe_context *pipe, unsigned min_samples)
|
|||
|
||||
if (nv50->min_samples != min_samples) {
|
||||
nv50->min_samples = min_samples;
|
||||
nv50->dirty |= NV50_NEW_MIN_SAMPLES;
|
||||
nv50->dirty_3d |= NV50_NEW_MIN_SAMPLES;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -949,7 +949,7 @@ nv50_set_framebuffer_state(struct pipe_context *pipe,
|
|||
|
||||
util_copy_framebuffer_state(&nv50->framebuffer, fb);
|
||||
|
||||
nv50->dirty |= NV50_NEW_FRAMEBUFFER;
|
||||
nv50->dirty_3d |= NV50_NEW_FRAMEBUFFER;
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -959,7 +959,7 @@ nv50_set_polygon_stipple(struct pipe_context *pipe,
|
|||
struct nv50_context *nv50 = nv50_context(pipe);
|
||||
|
||||
nv50->stipple = *stipple;
|
||||
nv50->dirty |= NV50_NEW_STIPPLE;
|
||||
nv50->dirty_3d |= NV50_NEW_STIPPLE;
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -977,7 +977,7 @@ nv50_set_scissor_states(struct pipe_context *pipe,
|
|||
continue;
|
||||
nv50->scissors[start_slot + i] = scissor[i];
|
||||
nv50->scissors_dirty |= 1 << (start_slot + i);
|
||||
nv50->dirty |= NV50_NEW_SCISSOR;
|
||||
nv50->dirty_3d |= NV50_NEW_SCISSOR;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -996,7 +996,7 @@ nv50_set_viewport_states(struct pipe_context *pipe,
|
|||
continue;
|
||||
nv50->viewports[start_slot + i] = vpt[i];
|
||||
nv50->viewports_dirty |= 1 << (start_slot + i);
|
||||
nv50->dirty |= NV50_NEW_VIEWPORT;
|
||||
nv50->dirty_3d |= NV50_NEW_VIEWPORT;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -1009,7 +1009,7 @@ nv50_set_vertex_buffers(struct pipe_context *pipe,
|
|||
unsigned i;
|
||||
|
||||
nouveau_bufctx_reset(nv50->bufctx_3d, NV50_BIND_VERTEX);
|
||||
nv50->dirty |= NV50_NEW_ARRAYS;
|
||||
nv50->dirty_3d |= NV50_NEW_ARRAYS;
|
||||
|
||||
util_set_vertex_buffers_count(nv50->vtxbuf, &nv50->num_vtxbufs, vb,
|
||||
start_slot, count);
|
||||
|
@ -1073,7 +1073,7 @@ nv50_vertex_state_bind(struct pipe_context *pipe, void *hwcso)
|
|||
struct nv50_context *nv50 = nv50_context(pipe);
|
||||
|
||||
nv50->vertex = hwcso;
|
||||
nv50->dirty |= NV50_NEW_VERTEX;
|
||||
nv50->dirty_3d |= NV50_NEW_VERTEX;
|
||||
}
|
||||
|
||||
static struct pipe_stream_output_target *
|
||||
|
@ -1181,7 +1181,7 @@ nv50_set_stream_output_targets(struct pipe_context *pipe,
|
|||
nv50->num_so_targets = num_targets;
|
||||
|
||||
if (nv50->so_targets_dirty)
|
||||
nv50->dirty |= NV50_NEW_STRMOUT;
|
||||
nv50->dirty_3d |= NV50_NEW_STRMOUT;
|
||||
}
|
||||
|
||||
static void
|
||||
|
|
|
@ -187,7 +187,7 @@ nv50_validate_scissor(struct nv50_context *nv50)
|
|||
#ifdef NV50_SCISSORS_CLIPPING
|
||||
int minx, maxx, miny, maxy, i;
|
||||
|
||||
if (!(nv50->dirty &
|
||||
if (!(nv50->dirty_3d &
|
||||
(NV50_NEW_SCISSOR | NV50_NEW_VIEWPORT | NV50_NEW_FRAMEBUFFER)) &&
|
||||
nv50->state.scissor == nv50->rast->pipe.scissor)
|
||||
return;
|
||||
|
@ -197,7 +197,7 @@ nv50_validate_scissor(struct nv50_context *nv50)
|
|||
|
||||
nv50->state.scissor = nv50->rast->pipe.scissor;
|
||||
|
||||
if ((nv50->dirty & NV50_NEW_FRAMEBUFFER) && !nv50->state.scissor)
|
||||
if ((nv50->dirty_3d & NV50_NEW_FRAMEBUFFER) && !nv50->state.scissor)
|
||||
nv50->scissors_dirty = (1 << NV50_MAX_VIEWPORTS) - 1;
|
||||
|
||||
for (i = 0; i < NV50_MAX_VIEWPORTS; i++) {
|
||||
|
@ -290,10 +290,10 @@ nv50_check_program_ucps(struct nv50_context *nv50,
|
|||
|
||||
vp->vp.clpd_nr = n;
|
||||
if (likely(vp == nv50->vertprog)) {
|
||||
nv50->dirty |= NV50_NEW_VERTPROG;
|
||||
nv50->dirty_3d |= NV50_NEW_VERTPROG;
|
||||
nv50_vertprog_validate(nv50);
|
||||
} else {
|
||||
nv50->dirty |= NV50_NEW_GMTYPROG;
|
||||
nv50->dirty_3d |= NV50_NEW_GMTYPROG;
|
||||
nv50_gmtyprog_validate(nv50);
|
||||
}
|
||||
nv50_fp_linkage_validate(nv50);
|
||||
|
@ -342,7 +342,7 @@ nv50_validate_clip(struct nv50_context *nv50)
|
|||
struct nv50_program *vp;
|
||||
uint8_t clip_enable;
|
||||
|
||||
if (nv50->dirty & NV50_NEW_CLIP) {
|
||||
if (nv50->dirty_3d & NV50_NEW_CLIP) {
|
||||
BEGIN_NV04(push, NV50_3D(CB_ADDR), 1);
|
||||
PUSH_DATA (push, (NV50_CB_AUX_UCP_OFFSET << 8) | NV50_CB_AUX);
|
||||
BEGIN_NI04(push, NV50_3D(CB_DATA(0)), PIPE_MAX_CLIP_PLANES * 4);
|
||||
|
@ -436,7 +436,7 @@ nv50_switch_pipe_context(struct nv50_context *ctx_to)
|
|||
else
|
||||
ctx_to->state = ctx_to->screen->save_state;
|
||||
|
||||
ctx_to->dirty = ~0;
|
||||
ctx_to->dirty_3d = ~0;
|
||||
ctx_to->viewports_dirty = ~0;
|
||||
ctx_to->scissors_dirty = ~0;
|
||||
|
||||
|
@ -445,23 +445,23 @@ nv50_switch_pipe_context(struct nv50_context *ctx_to)
|
|||
ctx_to->constbuf_dirty[2] = (1 << NV50_MAX_PIPE_CONSTBUFS) - 1;
|
||||
|
||||
if (!ctx_to->vertex)
|
||||
ctx_to->dirty &= ~(NV50_NEW_VERTEX | NV50_NEW_ARRAYS);
|
||||
ctx_to->dirty_3d &= ~(NV50_NEW_VERTEX | NV50_NEW_ARRAYS);
|
||||
|
||||
if (!ctx_to->vertprog)
|
||||
ctx_to->dirty &= ~NV50_NEW_VERTPROG;
|
||||
ctx_to->dirty_3d &= ~NV50_NEW_VERTPROG;
|
||||
if (!ctx_to->fragprog)
|
||||
ctx_to->dirty &= ~NV50_NEW_FRAGPROG;
|
||||
ctx_to->dirty_3d &= ~NV50_NEW_FRAGPROG;
|
||||
|
||||
if (!ctx_to->blend)
|
||||
ctx_to->dirty &= ~NV50_NEW_BLEND;
|
||||
ctx_to->dirty_3d &= ~NV50_NEW_BLEND;
|
||||
if (!ctx_to->rast)
|
||||
#ifdef NV50_SCISSORS_CLIPPING
|
||||
ctx_to->dirty &= ~(NV50_NEW_RASTERIZER | NV50_NEW_SCISSOR);
|
||||
ctx_to->dirty_3d &= ~(NV50_NEW_RASTERIZER | NV50_NEW_SCISSOR);
|
||||
#else
|
||||
ctx_to->dirty &= ~NV50_NEW_RASTERIZER;
|
||||
ctx_to->dirty_3d &= ~NV50_NEW_RASTERIZER;
|
||||
#endif
|
||||
if (!ctx_to->zsa)
|
||||
ctx_to->dirty &= ~NV50_NEW_ZSA;
|
||||
ctx_to->dirty_3d &= ~NV50_NEW_ZSA;
|
||||
|
||||
ctx_to->screen->cur_ctx = ctx_to;
|
||||
}
|
||||
|
@ -518,7 +518,7 @@ nv50_state_validate(struct nv50_context *nv50, uint32_t mask)
|
|||
if (nv50->screen->cur_ctx != nv50)
|
||||
nv50_switch_pipe_context(nv50);
|
||||
|
||||
state_mask = nv50->dirty & mask;
|
||||
state_mask = nv50->dirty_3d & mask;
|
||||
|
||||
if (state_mask) {
|
||||
for (i = 0; i < ARRAY_SIZE(validate_list); ++i) {
|
||||
|
@ -527,7 +527,7 @@ nv50_state_validate(struct nv50_context *nv50, uint32_t mask)
|
|||
if (state_mask & validate->states)
|
||||
validate->func(nv50);
|
||||
}
|
||||
nv50->dirty &= ~state_mask;
|
||||
nv50->dirty_3d &= ~state_mask;
|
||||
|
||||
if (nv50->state.rt_serialize) {
|
||||
nv50->state.rt_serialize = false;
|
||||
|
|
|
@ -353,7 +353,7 @@ nv50_clear_render_target(struct pipe_context *pipe,
|
|||
BEGIN_NV04(push, NV50_3D(COND_MODE), 1);
|
||||
PUSH_DATA (push, nv50->cond_condmode);
|
||||
|
||||
nv50->dirty |= NV50_NEW_FRAMEBUFFER | NV50_NEW_SCISSOR;
|
||||
nv50->dirty_3d |= NV50_NEW_FRAMEBUFFER | NV50_NEW_SCISSOR;
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -436,7 +436,7 @@ nv50_clear_depth_stencil(struct pipe_context *pipe,
|
|||
BEGIN_NV04(push, NV50_3D(COND_MODE), 1);
|
||||
PUSH_DATA (push, nv50->cond_condmode);
|
||||
|
||||
nv50->dirty |= NV50_NEW_FRAMEBUFFER | NV50_NEW_SCISSOR;
|
||||
nv50->dirty_3d |= NV50_NEW_FRAMEBUFFER | NV50_NEW_SCISSOR;
|
||||
}
|
||||
|
||||
void
|
||||
|
@ -798,7 +798,7 @@ nv50_clear_buffer(struct pipe_context *pipe,
|
|||
data, data_size);
|
||||
}
|
||||
|
||||
nv50->dirty |= NV50_NEW_FRAMEBUFFER | NV50_NEW_SCISSOR;
|
||||
nv50->dirty_3d |= NV50_NEW_FRAMEBUFFER | NV50_NEW_SCISSOR;
|
||||
}
|
||||
|
||||
/* =============================== BLIT CODE ===================================
|
||||
|
@ -834,7 +834,7 @@ struct nv50_blitctx
|
|||
struct pipe_sampler_view *texture[2];
|
||||
struct nv50_tsc_entry *sampler[2];
|
||||
unsigned min_samples;
|
||||
uint32_t dirty;
|
||||
uint32_t dirty_3d;
|
||||
} saved;
|
||||
struct nv50_rasterizer_stateobj rast;
|
||||
};
|
||||
|
@ -1253,12 +1253,12 @@ nv50_blitctx_pre_blit(struct nv50_blitctx *ctx)
|
|||
|
||||
nv50->min_samples = 1;
|
||||
|
||||
ctx->saved.dirty = nv50->dirty;
|
||||
ctx->saved.dirty_3d = nv50->dirty_3d;
|
||||
|
||||
nouveau_bufctx_reset(nv50->bufctx_3d, NV50_BIND_FB);
|
||||
nouveau_bufctx_reset(nv50->bufctx_3d, NV50_BIND_TEXTURES);
|
||||
|
||||
nv50->dirty =
|
||||
nv50->dirty_3d =
|
||||
NV50_NEW_FRAMEBUFFER | NV50_NEW_MIN_SAMPLES |
|
||||
NV50_NEW_VERTPROG | NV50_NEW_FRAGPROG | NV50_NEW_GMTYPROG |
|
||||
NV50_NEW_TEXTURES | NV50_NEW_SAMPLERS;
|
||||
|
@ -1305,7 +1305,7 @@ nv50_blitctx_post_blit(struct nv50_blitctx *blit)
|
|||
nouveau_bufctx_reset(nv50->bufctx_3d, NV50_BIND_FB);
|
||||
nouveau_bufctx_reset(nv50->bufctx_3d, NV50_BIND_TEXTURES);
|
||||
|
||||
nv50->dirty = blit->saved.dirty |
|
||||
nv50->dirty_3d = blit->saved.dirty_3d |
|
||||
(NV50_NEW_FRAMEBUFFER | NV50_NEW_SCISSOR | NV50_NEW_SAMPLE_MASK |
|
||||
NV50_NEW_RASTERIZER | NV50_NEW_ZSA | NV50_NEW_BLEND |
|
||||
NV50_NEW_TEXTURES | NV50_NEW_SAMPLERS |
|
||||
|
|
|
@ -779,9 +779,9 @@ nv50_draw_vbo(struct pipe_context *pipe, const struct pipe_draw_info *info)
|
|||
nv50->vbo_push_hint = /* the 64 is heuristic */
|
||||
!(info->indexed && ((nv50->vb_elt_limit + 64) < info->count));
|
||||
|
||||
if (nv50->vbo_user && !(nv50->dirty & (NV50_NEW_ARRAYS | NV50_NEW_VERTEX))) {
|
||||
if (nv50->vbo_user && !(nv50->dirty_3d & (NV50_NEW_ARRAYS | NV50_NEW_VERTEX))) {
|
||||
if (!!nv50->vbo_fifo != nv50->vbo_push_hint)
|
||||
nv50->dirty |= NV50_NEW_ARRAYS;
|
||||
nv50->dirty_3d |= NV50_NEW_ARRAYS;
|
||||
else
|
||||
if (!nv50->vbo_fifo)
|
||||
nv50_update_user_vbufs(nv50);
|
||||
|
|
Loading…
Reference in New Issue