mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-26 23:40:10 +01:00
mesa/st: add context-flags for s3tc
Reviewed-by: Marek Olšák <marek.olsak@amd.com> Reviewed-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com> Acked-by: Eric Engestrom <eric@igalia.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/18180>
This commit is contained in:
parent
a321d157c6
commit
b02f1b0eba
3 changed files with 5 additions and 0 deletions
|
|
@ -584,6 +584,9 @@ st_create_context_priv(struct gl_context *ctx, struct pipe_context *pipe,
|
|||
st->has_astc_5x5_ldr =
|
||||
screen->is_format_supported(screen, PIPE_FORMAT_ASTC_5x5_SRGB,
|
||||
PIPE_TEXTURE_2D, 0, 0, PIPE_BIND_SAMPLER_VIEW);
|
||||
st->has_s3tc = screen->is_format_supported(screen, PIPE_FORMAT_DXT5_RGBA,
|
||||
PIPE_TEXTURE_2D, 0, 0,
|
||||
PIPE_BIND_SAMPLER_VIEW);
|
||||
st->has_bptc = screen->is_format_supported(screen, PIPE_FORMAT_BPTC_SRGBA,
|
||||
PIPE_TEXTURE_2D, 0, 0,
|
||||
PIPE_BIND_SAMPLER_VIEW);
|
||||
|
|
|
|||
|
|
@ -143,6 +143,7 @@ struct st_context
|
|||
boolean transcode_astc;
|
||||
boolean has_astc_2d_ldr;
|
||||
boolean has_astc_5x5_ldr;
|
||||
boolean has_s3tc;
|
||||
boolean has_bptc;
|
||||
boolean prefer_blit_based_texture_transfer;
|
||||
boolean allow_compute_based_texture_transfer;
|
||||
|
|
|
|||
|
|
@ -60,6 +60,7 @@ int main(int argc, char **argv)
|
|||
.has_etc2 = true,
|
||||
.has_astc_2d_ldr = true,
|
||||
.has_astc_5x5_ldr = true,
|
||||
.has_s3tc = true,
|
||||
.has_bptc = true,
|
||||
};
|
||||
struct st_context *st = &local_st;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue