Re: RegisterStaticModules depreciated -> how to register formats now?

Bob Friesenhahn <[email protected]> Mon, 10 Feb 2020 12:07:39 -0600 (CST)
Newsgroups gmane.comp.video.graphicsmagick.help
Message-ID <[email protected]>
On Mon, 10 Feb 2020, Pro Turm wrote:

> Thank you! But who calls OpenModule()? Do you have an example for a static app?

Cscope tells me this:

Functions calling this function: OpenModule

   File     Function      Line
0 magick.c GetMagickInfo  435 (void ) OpenModule(name,exception);
1 module.c OpenModules   1523 (void ) OpenModule(*p,exception);

So it can be seen that OpenModules() will open all modules, or 
GetMagickInfo() will open a module only when it is needed to do so.

If you are able to update static.c, then there should be nothing more 
you need to do.  Use a preprocessor condition to control use under 
Windows or Linux.

If a program is using the GraphicsMagick library, it should also be 
theoretically possible for it to explicitly insert its own 
registrations to extend the available coders without modifying the 
GraphicsMagick library.

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