Re: Graphick++ version info etc

Bob Friesenhahn <[email protected]> Wed, 4 Mar 2020 13:30:31 -0600 (CST)
Newsgroups gmane.comp.video.graphicsmagick.apis
Message-ID <[email protected]>
On Wed, 4 Mar 2020, 10bxjfhf wrote:

> I have run into a very curious crash with my current app; for a specific TIFF 
> file, which according to DPF Manager has some issues, my app crashes, but 
> only if I run it outside of the debugger.

If you will email the problematic file to my bfriesen email address at 
simple.dallas.tx.us I will take a look at it.  If there is nothing 
proprietary about the file, then you could open an issue in the 
tracker at SourceForge, but be sure to put it in zip file so that 
SourceForge does not re-write the file that you upload.

> What I think would help myself, and anyone else who might eventually have to 
> work on the code, would be to be able to retrieve and display, say in an 
> 'About' dialog, the Magick library version and where it looks for its 
> configuration data. I have looked through a fair bit of the GM documentation, 
> but have not found anything which would help me.

What you are looking for can be found in magick/version.h:

extern MagickExport const char
   *GetMagickCopyright(void) MAGICK_FUNC_CONST,
   *GetMagickVersion(unsigned long *) MAGICK_FUNC_CONST,
   *GetMagickWebSite(void) MAGICK_FUNC_CONST;

Also notice that there are a documented set of pre-processor macros 
that you can use.  These could be used to support your own version 
formatter, or to make decisions in the code, or to check if the 
application is using the expected library at run-time.

Unfortunately, I don't think that there are Magick++ wrappers for the 
C functions, although they may be found in the MagickLib namespace.

Bob
-- 
Bob Friesenhahn
[email protected], http://www.simplesystems.org/users/bfriesen/
GraphicsMagick Maintainer,    http://www.GraphicsMagick.org/
Public Key,     http://www.simplesystems.org/users/bfriesen/public-key.txt