diff --git a/Source/astcenc_compress_symbolic.cpp b/Source/astcenc_compress_symbolic.cpp index a93046a4551aa49ecde9beafbed61af4d0413e30..aa4341afdf2f4eeb2c8aad3f62053a17d13252b9 100644 --- a/Source/astcenc_compress_symbolic.cpp +++ b/Source/astcenc_compress_symbolic.cpp @@ -256,9 +256,8 @@ static bool realign_weights_undecimated( float error_base = dot_s(color_diff * color_diff, error_weight); float error_down = dot_s(color_diff_down * color_diff_down, error_weight); float error_up = dot_s(color_diff_up * color_diff_up, error_weight); - // Check if the prev or next error is better, and if so use it - if ((error_up < error_base) && (error_up < error_down) && (uqw < 64)) + if ((error_up < error_base) && (error_up < error_down) && (uqw < 64)) // 64 is the max uqw value { dec_weights_uquant[texel] = static_cast(uqw_up); adjustments = true; diff --git a/Source/astcenc_pick_best_endpoint_format.cpp b/Source/astcenc_pick_best_endpoint_format.cpp index d3b9f6c296efe2857e9ecfc941d9a59606e1c0e0..0612adf6cb022f2deb33e8f71c9d85bf5385d15d 100644 --- a/Source/astcenc_pick_best_endpoint_format.cpp +++ b/Source/astcenc_pick_best_endpoint_format.cpp @@ -317,7 +317,7 @@ static void compute_encoding_choice_errors( partition_metrics *pms = reinterpret_cast(&blk.pms[0]); - if (!blk.is_constant_channel(3) || (partition_count != 1 && privateProfile == HIGH_QUALITY_PROFILE)) + if (!blk.is_constant_channel(3) || (partition_count != 1 && privateProfile == HIGH_QUALITY_PROFILE)) //3:Alpha channel { compute_avgs_and_dirs_3_comp_rgb(pi, blk, pms); }