From 3da40343e1c06f1cf805d318b05576e6f27bb543 Mon Sep 17 00:00:00 2001 From: sahvx655-wq Date: Sat, 13 Jun 2026 13:20:02 +0530 Subject: [PATCH 1/3] use dim_x for ldr plane stride in store_dds_uncompressed_image --- Source/astcenccli_image_load_store.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Source/astcenccli_image_load_store.cpp b/Source/astcenccli_image_load_store.cpp index 2ee02ae1..9bbeb74a 100644 --- a/Source/astcenccli_image_load_store.cpp +++ b/Source/astcenccli_image_load_store.cpp @@ -2229,7 +2229,7 @@ static bool store_dds_uncompressed_image( for (unsigned int z = 1; z < dim_z; z++) { row_pointers8[z] = row_pointers8[0] + dim_y * z; - row_pointers8[z][0] = row_pointers8[0][0] + dim_y * dim_z * image_components * z; + row_pointers8[z][0] = row_pointers8[0][0] + dim_y * dim_x * image_components * z; } for (unsigned int z = 0; z < dim_z; z++) From 3a404173657007654099bdb7a1f9bc9967a4c168 Mon Sep 17 00:00:00 2001 From: Peter Harris Date: Sat, 13 Jun 2026 22:55:00 +0100 Subject: [PATCH 2/3] Avoid backwards ordering --- Source/astcenccli_image_load_store.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Source/astcenccli_image_load_store.cpp b/Source/astcenccli_image_load_store.cpp index 9bbeb74a..bada72ee 100644 --- a/Source/astcenccli_image_load_store.cpp +++ b/Source/astcenccli_image_load_store.cpp @@ -1550,7 +1550,7 @@ static bool store_ktx_uncompressed_image( for (unsigned int z = 1; z < dim_z; z++) { row_pointers8[z] = row_pointers8[0] + dim_y * z; - row_pointers8[z][0] = row_pointers8[0][0] + dim_y * dim_x * image_components * z; + row_pointers8[z][0] = row_pointers8[0][0] + dim_x * dim_y * image_components * z; } for (unsigned int z = 0; z < dim_z; z++) @@ -1615,7 +1615,7 @@ static bool store_ktx_uncompressed_image( for (unsigned int z = 1; z < dim_z; z++) { row_pointers16[z] = row_pointers16[0] + dim_y * z; - row_pointers16[z][0] = row_pointers16[0][0] + dim_y * dim_x * image_components * z; + row_pointers16[z][0] = row_pointers16[0][0] + dim_x * dim_y * image_components * z; } for (unsigned int z = 0; z < dim_z; z++) @@ -2229,7 +2229,7 @@ static bool store_dds_uncompressed_image( for (unsigned int z = 1; z < dim_z; z++) { row_pointers8[z] = row_pointers8[0] + dim_y * z; - row_pointers8[z][0] = row_pointers8[0][0] + dim_y * dim_x * image_components * z; + row_pointers8[z][0] = row_pointers8[0][0] + dim_x * dim_y * image_components * z; } for (unsigned int z = 0; z < dim_z; z++) @@ -2295,7 +2295,7 @@ static bool store_dds_uncompressed_image( for (unsigned int z = 1; z < dim_z; z++) { row_pointers16[z] = row_pointers16[0] + dim_y * z; - row_pointers16[z][0] = row_pointers16[0][0] + dim_y * dim_x * image_components * z; + row_pointers16[z][0] = row_pointers16[0][0] + dim_x * dim_y * image_components * z; } for (unsigned int z = 0; z < dim_z; z++) From 20e7816c8e6735ced64e510f1e40b84977a09f7a Mon Sep 17 00:00:00 2001 From: Peter Harris Date: Sat, 13 Jun 2026 23:00:13 +0100 Subject: [PATCH 3/3] Add changelog --- Docs/ChangeLog-5x.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/Docs/ChangeLog-5x.md b/Docs/ChangeLog-5x.md index 6cc68f6d..ede3e175 100644 --- a/Docs/ChangeLog-5x.md +++ b/Docs/ChangeLog-5x.md @@ -6,6 +6,17 @@ release of the 5.x series. All performance data on this page is measured on an Intel Core i5-9600K clocked at 4.2 GHz, running `astcenc` using AVX2 and 6 threads. + +## 5.6.0 + +**Status:** In development + +The 5.6.0 release is a minor maintenance release. + +* **Command line tool updates:** + * **Bug fix:** Fixed incorrect plane stride when writing an uncompressed 3D + LDR image to a DDS container. + ## 5.5.0