fix an assert fail with libheif 1.10

if you built heifload with DEBUG it could ask for bpp for channels
which do not exist, triggering an assert fail in libheif 1.10
This commit is contained in:
John Cupitt 2020-12-23 19:24:53 +00:00
parent cbe9934e24
commit f853cfe464
1 changed files with 3 additions and 0 deletions

View File

@ -833,6 +833,9 @@ vips_foreign_load_heif_generate( VipsRegion *or,
printf( "vips_foreign_load_heif_generate:\n" );
for( i = 0; i < VIPS_NUMBER( channel ); i++ ) {
if( !heif_image_has_channel( heif->img, channel[i] ) )
continue;
printf( "\t%s:\n", channel_name[i] );
printf( "\t\twidth = %d\n",
heif_image_get_width( heif->img,