From 27a5186eef913520d46edab89c4411071ae5a4e2 Mon Sep 17 00:00:00 2001 From: Nicholas Frechette Date: Wed, 7 Feb 2024 21:34:56 -0500 Subject: [PATCH] docs(compression): clarify intent --- includes/acl/compression/impl/quantize.transform.h | 1 + 1 file changed, 1 insertion(+) diff --git a/includes/acl/compression/impl/quantize.transform.h b/includes/acl/compression/impl/quantize.transform.h index e052fc42..d8f05a84 100644 --- a/includes/acl/compression/impl/quantize.transform.h +++ b/includes/acl/compression/impl/quantize.transform.h @@ -1038,6 +1038,7 @@ namespace acl constexpr uint32_t increment_and_clamp_bit_rate(uint32_t bit_rate, uint32_t increment) { + // If the bit rate is already above highest (e.g 255 if constant), leave it as is otherwise increment and clamp return bit_rate >= k_highest_bit_rate ? bit_rate : std::min(bit_rate + increment, k_highest_bit_rate); }