diff options
author | Sybren A. Stüvel <sybren@stuvel.eu> | 2018-04-05 17:58:41 +0300 |
---|---|---|
committer | Sybren A. Stüvel <sybren@stuvel.eu> | 2018-04-05 17:58:41 +0300 |
commit | 57329304b061efe756e3a4ce1b828e9a7c7f7030 (patch) | |
tree | c4a3f9ec01c09314fac7bcb99b437bf0920d19a3 /source/blender/imbuf/intern/png.c | |
parent | 3eaf77fdd34bd9517b650cabde3574361bdc8d21 (diff) | |
parent | ea0e2f9bd3849b73a29ef1805988fdb0484bc9d4 (diff) |
Merge branch 'master' into blender2.8
Diffstat (limited to 'source/blender/imbuf/intern/png.c')
-rw-r--r-- | source/blender/imbuf/intern/png.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/imbuf/intern/png.c b/source/blender/imbuf/intern/png.c index 857f72e10eb..29fbe79d8db 100644 --- a/source/blender/imbuf/intern/png.c +++ b/source/blender/imbuf/intern/png.c @@ -759,8 +759,9 @@ ImBuf *imb_loadpng(const unsigned char *mem, size_t size, int flags, char colors if (flags & IB_metadata) { png_text *text_chunks; int count = png_get_text(png_ptr, info_ptr, &text_chunks, NULL); + IMB_metadata_ensure(&ibuf->metadata); for (int i = 0; i < count; i++) { - IMB_metadata_add_field(ibuf, text_chunks[i].key, text_chunks[i].text); + IMB_metadata_set_field(ibuf->metadata, text_chunks[i].key, text_chunks[i].text); ibuf->flags |= IB_metadata; } } |