GraphicsMagick: coders/wpg.c: Fix definition and use of LogHeade...
GraphicsMagick Commits <[email protected]>
| Newsgroups | gmane.comp.video.graphicsmagick.cvs |
|---|---|
| Message-ID | <mailman.19801.1668963646.1459.graphicsmagick-commit@lists.sourceforge.net> |
changeset 7b393efb50fa in /hg/GraphicsMagick details: http://hg.GraphicsMagick.org/hg/GraphicsMagick?cmd=changeset;node=7b393efb50fa summary: coders/wpg.c: Fix definition and use of LogHeaderWPG(), LogWPGBitmapType1(), and LogWPGBitmapType2() macros. diffstat: ChangeLog | 3 +++ coders/wpg.c | 50 +++++++++++++++++++++++++------------------------- www/Changelog.html | 2 ++ 3 files changed, 30 insertions(+), 25 deletions(-) diffs (112 lines): diff -r ba399a277070 -r 7b393efb50fa ChangeLog --- a/ChangeLog Sun Nov 20 16:57:06 2022 +0100 +++ b/ChangeLog Sun Nov 20 11:00:36 2022 -0600 @@ -1,5 +1,8 @@ 2022-11-20 Bob Friesenhahn <[email protected]> + * coders/wpg.c: Fix definition and use of LogHeaderWPG(), + LogWPGBitmapType1(), and LogWPGBitmapType2() macros. + * coders/heif.c (ReadColorProfile): Support reading ICC color profile. diff -r ba399a277070 -r 7b393efb50fa coders/wpg.c --- a/coders/wpg.c Sun Nov 20 16:57:06 2022 +0100 +++ b/coders/wpg.c Sun Nov 20 11:00:36 2022 -0600 @@ -1046,14 +1046,14 @@ " Version=%u.%u\n" \ " EncryptKey=%u\n" \ " Reserved=%u", \ - (unsigned int)_WPG_HEADER.FileId, \ - (unsigned int)_WPG_HEADER.DataOffset, \ - (unsigned int)_WPG_HEADER.ProductType, \ - (unsigned int)_WPG_HEADER.FileType, \ - (unsigned int)_WPG_HEADER.MajorVersion, \ - (unsigned int)_WPG_HEADER.MinorVersion, \ - (unsigned int)_WPG_HEADER.EncryptKey, \ - (unsigned int)_WPG_HEADER.Reserved) + (unsigned int)(_WPG_HEADER)->FileId, \ + (unsigned int)(_WPG_HEADER)->DataOffset, \ + (unsigned int)(_WPG_HEADER)->ProductType, \ + (unsigned int)(_WPG_HEADER)->FileType, \ + (unsigned int)(_WPG_HEADER)->MajorVersion, \ + (unsigned int)(_WPG_HEADER)->MinorVersion, \ + (unsigned int)(_WPG_HEADER)->EncryptKey, \ + (unsigned int)(_WPG_HEADER)->Reserved) #define LogWPGBitmapType1(_WPG_BITMAP_TYPE1) \ (void)LogMagickEvent(CoderEvent,GetMagickModule(), \ @@ -1063,11 +1063,11 @@ " Depth=%u\n" \ " HorzRes=%u\n" \ " VertRes=%u", \ - (unsigned int)_WPG_BITMAP_TYPE1.Width, \ - (unsigned int)_WPG_BITMAP_TYPE1.Heigth, \ - (unsigned int)_WPG_BITMAP_TYPE1.Depth, \ - (unsigned int)_WPG_BITMAP_TYPE1.HorzRes, \ - (unsigned int)_WPG_BITMAP_TYPE1.VertRes) + (unsigned int)(_WPG_BITMAP_TYPE1)->Width, \ + (unsigned int)(_WPG_BITMAP_TYPE1)->Heigth, \ + (unsigned int)(_WPG_BITMAP_TYPE1)->Depth, \ + (unsigned int)(_WPG_BITMAP_TYPE1)->HorzRes, \ + (unsigned int)(_WPG_BITMAP_TYPE1)->VertRes) #define LogWPGBitmapType2(_WPG_BITMAP_TYPE2) \ (void)LogMagickEvent(CoderEvent,GetMagickModule(), \ @@ -1082,16 +1082,16 @@ " Depth=%u\n" \ " HorzRes=%u\n" \ " VertRes=%u", \ - (unsigned int)_WPG_BITMAP_TYPE2.RotAngle, \ - (unsigned int)_WPG_BITMAP_TYPE2.LowLeftX, \ - (unsigned int)_WPG_BITMAP_TYPE2.LowLeftY, \ - (unsigned int)_WPG_BITMAP_TYPE2.UpRightX, \ - (unsigned int)_WPG_BITMAP_TYPE2.UpRightY, \ - (unsigned int)_WPG_BITMAP_TYPE2.Width, \ - (unsigned int)_WPG_BITMAP_TYPE2.Heigth, \ - (unsigned int)_WPG_BITMAP_TYPE2.Depth, \ - (unsigned int)_WPG_BITMAP_TYPE2.HorzRes, \ - (unsigned int)_WPG_BITMAP_TYPE2.VertRes) + (unsigned int)(_WPG_BITMAP_TYPE2)->RotAngle, \ + (unsigned int)(_WPG_BITMAP_TYPE2)->LowLeftX, \ + (unsigned int)(_WPG_BITMAP_TYPE2)->LowLeftY, \ + (unsigned int)(_WPG_BITMAP_TYPE2)->UpRightX, \ + (unsigned int)(_WPG_BITMAP_TYPE2)->UpRightY, \ + (unsigned int)(_WPG_BITMAP_TYPE2)->Width, \ + (unsigned int)(_WPG_BITMAP_TYPE2)->Heigth, \ + (unsigned int)(_WPG_BITMAP_TYPE2)->Depth, \ + (unsigned int)(_WPG_BITMAP_TYPE2)->HorzRes, \ + (unsigned int)(_WPG_BITMAP_TYPE2)->VertRes) /* @@ -1278,7 +1278,7 @@ Header.MinorVersion=ReadBlobByte(image); Header.EncryptKey=ReadBlobLSBShort(image); Header.Reserved=ReadBlobLSBShort(image); - if(logging) LogHeaderWPG(Header); + if(logging) LogHeaderWPG(&Header); if (Header.FileId!=0x435057FF || (Header.ProductType>>8)!=0x16) ThrowReaderException(CorruptImageError,ImproperImageHeader,image); @@ -1349,7 +1349,7 @@ BitmapHeader1.Depth=ReadBlobLSBShort(image); BitmapHeader1.HorzRes=ReadBlobLSBShort(image); BitmapHeader1.VertRes=ReadBlobLSBShort(image); - if(logging) LogWPGBitmapType1(BitmapHeader1); + if(logging) LogWPGBitmapType1(&BitmapHeader1); if(BitmapHeader1.HorzRes && BitmapHeader1.VertRes) { diff -r ba399a277070 -r 7b393efb50fa www/Changelog.html --- a/www/Changelog.html Sun Nov 20 16:57:06 2022 +0100 +++ b/www/Changelog.html Sun Nov 20 11:00:36 2022 -0600 @@ -40,6 +40,8 @@ <p>2022-11-20 Bob Friesenhahn <<a class="reference external" href="mailto:bfriesen%40simple.dallas.tx.us">bfriesen<span>@</span>simple<span>.</span>dallas<span>.</span>tx<span>.</span>us</a>></p> <blockquote> <ul class="simple"> +<li><p>coders/wpg.c: Fix definition and use of LogHeaderWPG(), +LogWPGBitmapType1(), and LogWPGBitmapType2() macros.</p></li> <li><p>coders/heif.c (ReadColorProfile): Support reading ICC color profile.</p></li> </ul>