From bee0699e0e4eca18325d4d886d0590990ad51443 Mon Sep 17 00:00:00 2001 From: Dirk Farin Date: Tue, 22 Oct 2024 20:29:16 +0200 Subject: [PATCH] fix: set output grid image in heif_context_encode_grid() --- libheif/api/libheif/heif.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/libheif/api/libheif/heif.cc b/libheif/api/libheif/heif.cc index 9980058f77..57f574e611 100644 --- a/libheif/api/libheif/heif.cc +++ b/libheif/api/libheif/heif.cc @@ -3496,6 +3496,8 @@ struct heif_error heif_context_encode_grid(struct heif_context* ctx, return addGridResult.error.error_struct(ctx->context.get()); } + out_grid = addGridResult.value; + // Mark as primary image if (ctx->context->is_primary_image_set() == false) { ctx->context->set_primary_image(out_grid);