SET_BIT(ctx->fragment_shader_core.unknown2_4, MALI_NO_MSAA, !msaa);
}
- /* Enable job requirements at draw-time */
-
- if (msaa)
- job->requirements |= PAN_REQ_MSAA;
-
- if (ctx->depth_stencil->depth.writemask)
- job->requirements |= PAN_REQ_DEPTH_WRITE;
-
if (ctx->occlusion_query) {
ctx->payload_tiler.gl_enables |= MALI_OCCLUSION_QUERY | MALI_OCCLUSION_PRECISE;
ctx->payload_tiler.postfix.occlusion_counter = ctx->occlusion_query->transfer.gpu;
memcpy(&job->key, &key, sizeof(key));
_mesa_hash_table_insert(ctx->jobs, &job->key, job);
+ panfrost_job_set_requirements(ctx, job);
return job;
}
ctx->tiler_job_count = 0;
}
+void
+panfrost_job_set_requirements(struct panfrost_context *ctx,
+ struct panfrost_job *job)
+{
+ if (ctx->rasterizer && ctx->rasterizer->base.multisample)
+ job->requirements |= PAN_REQ_MSAA;
+
+ if (ctx->depth_stencil && ctx->depth_stencil->depth.writemask)
+ job->requirements |= PAN_REQ_DEPTH_WRITE;
+}
+
void
panfrost_flush_jobs_reading_resource(struct panfrost_context *panfrost,
struct pipe_resource *prsc)
void
panfrost_job_submit(struct panfrost_context *ctx, struct panfrost_job *job);
+
+void
+panfrost_job_set_requirements(struct panfrost_context *ctx,
+ struct panfrost_job *job);
#endif