Skip to content

Commit a3bf557

Browse files
committed
Fix compilation for gcc, use explicite constexpr
1 parent 0fef4d0 commit a3bf557

2 files changed

Lines changed: 3 additions & 2 deletions

File tree

avs_core/convert/intel/convert_planar_avx2.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -473,7 +473,7 @@ static void convert_yuv_to_planarrgb_avx2_internal(BYTE* (&dstp)[3], int(&dstPit
473473
constexpr bool need_int_conversion = conv_type == YuvRgbConversionType::BITCONV_INT_FULL || conv_type == YuvRgbConversionType::BITCONV_INT_LIMITED ||
474474
(conv_type == YuvRgbConversionType::FORCE_FLOAT && !final_is_float);
475475

476-
const bool float_matrix_workflow = force_float || need_int_conversion_full_range; // effectively full-float-inside for int full range conversion
476+
constexpr bool float_matrix_workflow = force_float || need_int_conversion_full_range; // effectively full-float-inside for int full range conversion
477477

478478
// quasi-constexpr, may help optimizer
479479
if constexpr (std::is_same<pixel_t, uint8_t>::value) bits_per_pixel = 8;

avs_core/convert/intel/convert_planar_sse.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -193,7 +193,8 @@ static void convert_yuv_to_planarrgb_sse2_internal(BYTE* (&dstp)[3], int(&dstPit
193193
constexpr bool need_int_conversion_full_range = conv_type == YuvRgbConversionType::BITCONV_INT_FULL;
194194
constexpr bool need_int_conversion = conv_type == YuvRgbConversionType::BITCONV_INT_FULL || conv_type == YuvRgbConversionType::BITCONV_INT_LIMITED ||
195195
(conv_type == YuvRgbConversionType::FORCE_FLOAT && !final_is_float);
196-
const bool float_matrix_workflow = force_float || need_int_conversion_full_range;
196+
197+
constexpr bool float_matrix_workflow = force_float || need_int_conversion_full_range;
197198

198199
// quasi-constexpr, may help optimizer
199200
if constexpr (std::is_same<pixel_t, uint8_t>::value) bits_per_pixel = 8;

0 commit comments

Comments
 (0)