From be74e9ffaf9273322e5ff387996dd96f028d32c0 Mon Sep 17 00:00:00 2001 From: Erik Faye-Lund Date: Wed, 7 May 2025 21:44:28 +0200 Subject: [PATCH] pan/lib: wire up ASTC HDR formats This exposes GL_KHR_texture_compression_astc_hdr, which makes a few piglit tests go from fail to pass. Reviewed-by: Alyssa Rosenzweig Part-of: --- docs/features.txt | 2 +- docs/relnotes/new_features.txt | 1 + src/panfrost/ci/panfrost-g52-fails.txt | 8 -------- src/panfrost/ci/panfrost-g57-fails.txt | 8 -------- src/panfrost/lib/pan_format.c | 15 +++++++++++++++ 5 files changed, 17 insertions(+), 17 deletions(-) diff --git a/docs/features.txt b/docs/features.txt index 0ef9eb5dabb..1461733db98 100644 --- a/docs/features.txt +++ b/docs/features.txt @@ -340,7 +340,7 @@ Khronos, ARB, and OES extensions that are not part of any OpenGL or OpenGL ES ve GL_EXT_texture_view DONE (all drivers that support GL_OES_texture_view) GL_KHR_blend_equation_advanced_coherent DONE (freedreno/a6xx, panfrost, zink, asahi, iris/gen9+, v3d) GL_KHR_shader_subgroup DONE (radeonsi, zink) - GL_KHR_texture_compression_astc_hdr DONE (core only) + GL_KHR_texture_compression_astc_hdr DONE (panfrost) GL_KHR_texture_compression_astc_sliced_3d DONE (freedreno/a4xx+, r600, radeonsi, panfrost, softpipe, v3d, zink, lima, asahi, iris/gen9+) GL_OES_depth_texture_cube_map DONE (all drivers that support GLSL 1.30+) GL_OES_EGL_image DONE (all drivers) diff --git a/docs/relnotes/new_features.txt b/docs/relnotes/new_features.txt index cc525ebfc03..648365d8ea4 100644 --- a/docs/relnotes/new_features.txt +++ b/docs/relnotes/new_features.txt @@ -26,3 +26,4 @@ VK_EXT_primitive_topology_list_restart on panvk VK_EXT_image_2d_view_of_3d on panvk VK_EXT_texel_buffer_alignment on panvk cl_khr_kernel_clock on freedreno, iris, llvmpipe, nvc0, panfrost, radeonsi and zink with llvm-19 or newer +GL_KHR_texture_compression_astc_hdr on panfrost diff --git a/src/panfrost/ci/panfrost-g52-fails.txt b/src/panfrost/ci/panfrost-g52-fails.txt index ec227d29bb4..e81bdbd1a8d 100644 --- a/src/panfrost/ci/panfrost-g52-fails.txt +++ b/src/panfrost/ci/panfrost-g52-fails.txt @@ -215,20 +215,12 @@ spec@glsl-1.10@execution@varying-packing@simple vec4 array,Fail spec@glsl-1.10@execution@varying-packing@simple vec4 arrays_of_arrays,Fail spec@glsl-1.30@execution@tex-miplevel-selection texture() 2drect,Crash spec@glsl-1.30@execution@tex-miplevel-selection texture() 2drectshadow,Crash -spec@khr_texture_compression_astc@miptree-gles hdr,Fail -spec@khr_texture_compression_astc@miptree-gles hdr@HDR Profile,Fail spec@khr_texture_compression_astc@miptree-gles srgb-fp,Fail spec@khr_texture_compression_astc@miptree-gles srgb-fp@sRGB decode full precision,Fail -spec@khr_texture_compression_astc@miptree-gl hdr,Fail -spec@khr_texture_compression_astc@miptree-gl hdr@HDR Profile,Fail spec@khr_texture_compression_astc@miptree-gl srgb-fp,Fail spec@khr_texture_compression_astc@miptree-gl srgb-fp@sRGB decode full precision,Fail -spec@khr_texture_compression_astc@sliced-3d-miptree-gles hdr,Fail -spec@khr_texture_compression_astc@sliced-3d-miptree-gles hdr@HDR Profile,Fail spec@khr_texture_compression_astc@sliced-3d-miptree-gles srgb-fp,Fail spec@khr_texture_compression_astc@sliced-3d-miptree-gles srgb-fp@sRGB decode full precision,Fail -spec@khr_texture_compression_astc@sliced-3d-miptree-gl hdr,Fail -spec@khr_texture_compression_astc@sliced-3d-miptree-gl hdr@HDR Profile,Fail spec@khr_texture_compression_astc@sliced-3d-miptree-gl srgb-fp,Fail spec@khr_texture_compression_astc@sliced-3d-miptree-gl srgb-fp@sRGB decode full precision,Fail spec@!opengl 1.0@gl-1.0-edgeflag-const,Fail diff --git a/src/panfrost/ci/panfrost-g57-fails.txt b/src/panfrost/ci/panfrost-g57-fails.txt index f74879bd5a0..06e6d9b3163 100644 --- a/src/panfrost/ci/panfrost-g57-fails.txt +++ b/src/panfrost/ci/panfrost-g57-fails.txt @@ -159,20 +159,12 @@ spec@glsl-1.30@execution@tex-miplevel-selection textureprojgradoffset 2drectshad spec@glsl-1.30@execution@tex-miplevel-selection textureprojoffset 2drect,Crash spec@glsl-1.30@execution@tex-miplevel-selection textureprojoffset 2drect_projvec4,Crash spec@glsl-1.30@execution@tex-miplevel-selection textureprojoffset 2drectshadow,Crash -spec@khr_texture_compression_astc@miptree-gles hdr,Fail -spec@khr_texture_compression_astc@miptree-gles hdr@HDR Profile,Fail spec@khr_texture_compression_astc@miptree-gles srgb-fp,Fail spec@khr_texture_compression_astc@miptree-gles srgb-fp@sRGB decode full precision,Fail -spec@khr_texture_compression_astc@miptree-gl hdr,Fail -spec@khr_texture_compression_astc@miptree-gl hdr@HDR Profile,Fail spec@khr_texture_compression_astc@miptree-gl srgb-fp,Fail spec@khr_texture_compression_astc@miptree-gl srgb-fp@sRGB decode full precision,Fail -spec@khr_texture_compression_astc@sliced-3d-miptree-gles hdr,Fail -spec@khr_texture_compression_astc@sliced-3d-miptree-gles hdr@HDR Profile,Fail spec@khr_texture_compression_astc@sliced-3d-miptree-gles srgb-fp,Fail spec@khr_texture_compression_astc@sliced-3d-miptree-gles srgb-fp@sRGB decode full precision,Fail -spec@khr_texture_compression_astc@sliced-3d-miptree-gl hdr,Fail -spec@khr_texture_compression_astc@sliced-3d-miptree-gl hdr@HDR Profile,Fail spec@khr_texture_compression_astc@sliced-3d-miptree-gl srgb-fp,Fail spec@khr_texture_compression_astc@sliced-3d-miptree-gl srgb-fp@sRGB decode full precision,Fail spec@!opengl 1.0@gl-1.0-edgeflag-const,Fail diff --git a/src/panfrost/lib/pan_format.c b/src/panfrost/lib/pan_format.c index 38d398f6186..bf62ef9f513 100644 --- a/src/panfrost/lib/pan_format.c +++ b/src/panfrost/lib/pan_format.c @@ -277,6 +277,21 @@ const struct pan_format GENX(pan_pipe_format)[PIPE_FORMAT_COUNT] = { FMTC(ASTC_6x6x5_SRGB, ASTC_3D_LDR, RGBA8_UNORM, RGBA, S), FMTC(ASTC_6x6x6_SRGB, ASTC_3D_LDR, RGBA8_UNORM, RGBA, S), + FMTC(ASTC_4x4_FLOAT, ASTC_2D_HDR, RGBA16F, RGBA, L), + FMTC(ASTC_5x4_FLOAT, ASTC_2D_HDR, RGBA16F, RGBA, L), + FMTC(ASTC_5x5_FLOAT, ASTC_2D_HDR, RGBA16F, RGBA, L), + FMTC(ASTC_6x5_FLOAT, ASTC_2D_HDR, RGBA16F, RGBA, L), + FMTC(ASTC_6x6_FLOAT, ASTC_2D_HDR, RGBA16F, RGBA, L), + FMTC(ASTC_8x5_FLOAT, ASTC_2D_HDR, RGBA16F, RGBA, L), + FMTC(ASTC_8x6_FLOAT, ASTC_2D_HDR, RGBA16F, RGBA, L), + FMTC(ASTC_8x8_FLOAT, ASTC_2D_HDR, RGBA16F, RGBA, L), + FMTC(ASTC_10x5_FLOAT, ASTC_2D_HDR, RGBA16F, RGBA, L), + FMTC(ASTC_10x6_FLOAT, ASTC_2D_HDR, RGBA16F, RGBA, L), + FMTC(ASTC_10x8_FLOAT, ASTC_2D_HDR, RGBA16F, RGBA, L), + FMTC(ASTC_10x10_FLOAT, ASTC_2D_HDR, RGBA16F, RGBA, L), + FMTC(ASTC_12x10_FLOAT, ASTC_2D_HDR, RGBA16F, RGBA, L), + FMTC(ASTC_12x12_FLOAT, ASTC_2D_HDR, RGBA16F, RGBA, L), + FMT(R5G6B5_UNORM, RGB565, RGB1, L, VTR_I), FMT(B5G6R5_UNORM, RGB565, BGR1, L, VTR_I), FMT(R5G5B5X1_UNORM, RGB5_A1_UNORM, RGB1, L, VT__I),