anv/pipeline: Add populate_tcs/tes_key helpers
They don't really do anything interesting, but it's more consistent this way. Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
This commit is contained in:
@@ -307,6 +307,27 @@ populate_vs_prog_key(const struct gen_device_info *devinfo,
|
|||||||
/* XXX: Handle sampler_prog_key */
|
/* XXX: Handle sampler_prog_key */
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static void
|
||||||
|
populate_tcs_prog_key(const struct gen_device_info *devinfo,
|
||||||
|
unsigned input_vertices,
|
||||||
|
struct brw_tcs_prog_key *key)
|
||||||
|
{
|
||||||
|
memset(key, 0, sizeof(*key));
|
||||||
|
|
||||||
|
populate_sampler_prog_key(devinfo, &key->tex);
|
||||||
|
|
||||||
|
key->input_vertices = input_vertices;
|
||||||
|
}
|
||||||
|
|
||||||
|
static void
|
||||||
|
populate_tes_prog_key(const struct gen_device_info *devinfo,
|
||||||
|
struct brw_tes_prog_key *key)
|
||||||
|
{
|
||||||
|
memset(key, 0, sizeof(*key));
|
||||||
|
|
||||||
|
populate_sampler_prog_key(devinfo, &key->tex);
|
||||||
|
}
|
||||||
|
|
||||||
static void
|
static void
|
||||||
populate_gs_prog_key(const struct gen_device_info *devinfo,
|
populate_gs_prog_key(const struct gen_device_info *devinfo,
|
||||||
struct brw_gs_prog_key *key)
|
struct brw_gs_prog_key *key)
|
||||||
@@ -629,9 +650,10 @@ anv_pipeline_compile_tcs_tes(struct anv_pipeline *pipeline,
|
|||||||
struct anv_shader_bin *tcs_bin = NULL;
|
struct anv_shader_bin *tcs_bin = NULL;
|
||||||
struct anv_shader_bin *tes_bin = NULL;
|
struct anv_shader_bin *tes_bin = NULL;
|
||||||
|
|
||||||
populate_sampler_prog_key(&pipeline->device->info, &tcs_key.tex);
|
populate_tcs_prog_key(&pipeline->device->info,
|
||||||
populate_sampler_prog_key(&pipeline->device->info, &tes_key.tex);
|
info->pTessellationState->patchControlPoints,
|
||||||
tcs_key.input_vertices = info->pTessellationState->patchControlPoints;
|
&tcs_key);
|
||||||
|
populate_tes_prog_key(&pipeline->device->info, &tes_key);
|
||||||
|
|
||||||
ANV_FROM_HANDLE(anv_pipeline_layout, layout, info->layout);
|
ANV_FROM_HANDLE(anv_pipeline_layout, layout, info->layout);
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user