From f6fa546480a7aba960f19bc74427b272e3c031bb Mon Sep 17 00:00:00 2001 From: Thomas Bernard Date: Sun, 4 Feb 2018 01:13:52 +0100 Subject: [PATCH] Load_IFF() support ANNO chunks --- src/fileformats.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/src/fileformats.c b/src/fileformats.c index 6e2c1c87..d06aa550 100644 --- a/src/fileformats.c +++ b/src/fileformats.c @@ -816,6 +816,18 @@ printf("%d x %d = %d %d\n", tiny_width, tiny_height, tiny_width*tiny_height, s else fseek(IFF_file, (section_size+1)&~1, SEEK_CUR); } + else if (memcmp(section, "ANNO", 4) == 0) + { + dword length; + section_size = (section_size + 1) & ~1; + length = section_size; + if (length > COMMENT_SIZE) + length = COMMENT_SIZE; + Read_bytes(IFF_file,context->Comment,length); + context->Comment[length]='\0'; + section_size -= length; + fseek(IFF_file, section_size, SEEK_CUR); + } else if (memcmp(section, "BODY", 4) == 0) { Original_screen_X = header.X_screen;