docs,src: replace doc and comments for PIPE_CAP with pipe_caps

Use command:
  find . -type d \( -path "./.git" -o -path "./docs/relnotes" \) -prune -o -type f -exec sed -i 's/PIPE_CAP_\([A-Za-z0-9_]*\)/pipe_caps.\L\1/g' {} +
  find . -type d \( -path "./.git" -o -path "./docs/relnotes" \) -prune -o -type f -exec sed -i 's/PIPE_CAPF_\([A-Za-z0-9_]*\)/pipe_caps.\L\1/g' {} +

With manual adjustment for docs/gallium/screen.rst to merge
pipe_cap and pipe_capf section.

Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/32955>
This commit is contained in:
Qiang Yu
2025-01-08 17:35:26 +08:00
committed by Marge Bot
parent e7873a3abd
commit e5041ef036
47 changed files with 382 additions and 413 deletions

View File

@@ -90,7 +90,7 @@ target_to_index(const struct gl_query_object *q)
q->Target == GL_TRANSFORM_FEEDBACK_STREAM_OVERFLOW_ARB)
return q->Stream;
/* Drivers with PIPE_CAP_QUERY_PIPELINE_STATISTICS_SINGLE = 0 ignore the
/* Drivers with pipe_caps.query_pipeline_statistics_single = 0 ignore the
* index param so it should be useless; but radeonsi needs it in some cases,
* so pass the correct value.
*/

View File

@@ -184,7 +184,7 @@ blend_per_rt(const struct st_context *st, unsigned num_cb)
if (ctx->DrawBuffer->_BlendForceAlphaToOne) {
/* Overriding requires independent blend functions (not just enables),
* requiring drivers to expose PIPE_CAP_INDEP_BLEND_FUNC.
* requiring drivers to expose pipe_caps.indep_blend_func.
*/
assert(st->has_indep_blend_func);

View File

@@ -207,7 +207,7 @@ st_save_zombie_sampler_view(struct st_context *st,
* with variants of a shader created with different contexts.
* When we go to destroy a gallium shader, we want to free it with the
* same context that it was created with, unless the driver reports
* PIPE_CAP_SHAREABLE_SHADERS = TRUE.
* pipe_caps.shareable_shaders = TRUE.
*/
void
st_save_zombie_shader(struct st_context *st,

View File

@@ -331,7 +331,7 @@ struct st_context
void *upload_fs[5][2];
/**
* For drivers supporting formatless storing
* (PIPE_CAP_IMAGE_STORE_FORMATTED) it is a pointer to the download FS;
* (pipe_caps.image_store_formatted) it is a pointer to the download FS;
* for those not supporting it, it is a pointer to an array of
* PIPE_FORMAT_COUNT elements, where each element is a pointer to the
* download FS using that PIPE_FORMAT as the storing format.

View File

@@ -136,7 +136,7 @@ void st_init_limits(struct pipe_screen *screen,
/* Define max viewport size and max renderbuffer size in terms of
* max texture size (note: max tex RECT size = max tex 2D size).
* If this isn't true for some hardware we'll need new PIPE_CAP_ queries.
* If this isn't true for some hardware we'll need new pipe_caps. queries.
*/
c->MaxViewportWidth =
c->MaxViewportHeight =
@@ -571,7 +571,7 @@ void st_init_limits(struct pipe_screen *screen,
c->MaxFramebufferWidth = c->MaxViewportWidth;
c->MaxFramebufferHeight = c->MaxViewportHeight;
/* NOTE: we cheat here a little by assuming that
* PIPE_CAP_MAX_TEXTURE_ARRAY_LAYERS has the same
* pipe_caps.max_texture_array_layers has the same
* number of layers as we need, although we technically
* could have more the generality is not really useful
* in practicality.
@@ -749,7 +749,7 @@ get_max_samples_for_formats_advanced(struct pipe_screen *screen,
}
/**
* Use pipe_screen::get_param() to query PIPE_CAP_ values to determine
* Use pipe_screen::get_param() to query pipe_caps. values to determine
* which GL extensions are supported.
* Quite a few extensions are always supported because they are standard
* features or can be built on top of other gallium features.
@@ -1338,7 +1338,7 @@ void st_init_extensions(struct pipe_screen *screen,
extensions->ARB_draw_indirect = GL_TRUE;
}
/* Needs PIPE_CAP_SAMPLE_SHADING + all the sample-related bits of
/* Needs pipe_caps.sample_shading + all the sample-related bits of
* ARB_gpu_shader5. This enables all the per-sample shading ES extensions.
*/
extensions->OES_sample_variables = extensions->ARB_sample_shading &&

View File

@@ -62,7 +62,7 @@ type_size(const struct glsl_type *type)
return glsl_count_attribute_slots(type, false);
}
/* Depending on PIPE_CAP_TGSI_TEXCOORD (st->needs_texcoord_semantic) we
/* Depending on pipe_caps.tgsi_texcoord (st->needs_texcoord_semantic) we
* may need to fix up varying slots so the glsl->nir path is aligned
* with the anything->tgsi->nir path.
*/

View File

@@ -134,7 +134,7 @@ lower_tex_src_plane(nir_builder *b, nir_instr *instr, void *data)
BITSET_SET(state->shader->info.textures_used, u_v_samp);
BITSET_SET(state->shader->info.samplers_used, u_v_samp);
/* For drivers using PIPE_CAP_NIR_SAMPLERS_AS_DEREF, we need
/* For drivers using pipe_caps.nir_samplers_as_deref, we need
* to reference the correct sampler nir variable.
*/
int samp_index = nir_tex_instr_src_index(tex, nir_tex_src_sampler_deref);

View File

@@ -232,7 +232,7 @@ struct st_fp_variant_key
struct st_external_sampler_key external;
/* bitmask of sampler units; PIPE_CAP_GL_CLAMP */
/* bitmask of sampler units; pipe_caps.gl_clamp */
uint32_t gl_clamp[3];
/* bitmask of shadow samplers with depth textures in them for ARB programs; */
@@ -295,7 +295,7 @@ struct st_common_variant_key
*/
bool is_draw_shader;
/* bitmask of sampler units; PIPE_CAP_GL_CLAMP */
/* bitmask of sampler units; pipe_caps.gl_clamp */
uint32_t gl_clamp[3];
};