Nikon HEIFs from a camera or NX studio include a small jpeg thumbnail in 
addition to
the expected HEVC thumbnails; allowing jpegs allows all thumbnails to
have an associated stream for Nikon HEIF files.

With this, Nikon HEIFs can finally be decoded without failing and the
thumbnails can be extracted into their own files.

Signed-off-by: Eric Joyner <[email protected]>
---
 libavformat/mov.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/libavformat/mov.c b/libavformat/mov.c
index 7010e13b50..19b31b032d 100644
--- a/libavformat/mov.c
+++ b/libavformat/mov.c
@@ -8840,6 +8840,7 @@ static int mov_read_infe(MOVContext *c, AVIOContext *pb, 
MOVAtom atom, int idx)
 
     switch (item_type) {
     case MKTAG('a','v','0','1'):
+    case MKTAG('j','p','e','g'):
     case MKTAG('h','v','c','1'):
         ret = heif_add_stream(c, c->heif_item[idx]);
         if (ret < 0)
-- 
2.49.0.windows.1

_______________________________________________
ffmpeg-devel mailing list
[email protected]
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
[email protected] with subject "unsubscribe".

Reply via email to