From 41dd0a4260649f707dffec5d41924c444e0e9ffd Mon Sep 17 00:00:00 2001 From: Dirk Farin Date: Thu, 21 Dec 2023 11:47:12 +0100 Subject: [PATCH] fix lossless encoding of RGB input (#1039) --- examples/heif_enc.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/examples/heif_enc.cc b/examples/heif_enc.cc index f8d70a1693..617e102a89 100644 --- a/examples/heif_enc.cc +++ b/examples/heif_enc.cc @@ -794,8 +794,8 @@ int main(int argc, char** argv) heif_encoder_set_lossless(encoder, true); if (heif_image_get_colorspace(primary_image.get()) == heif_colorspace_RGB) { - nclx_matrix_coefficients = 0; - nclx_full_range = true; + nclx->matrix_coefficients = heif_matrix_coefficients_RGB_GBR; + nclx->full_range_flag = true; raw_params.emplace_back("chroma=444"); } else {