AnimGif plug-in

From NSIS Wiki

Author: Takhir (talk, contrib)


Download: (45 KB) (63 KB)

Forum thread


AnimGif.dll is NSIS plug-in, displaying animated banner on the installer page. Based on the Juan Soulie code. Unfortunately, the base program fails on some images (very seldom): in this case, you can use variant based on the Oleg Bykov' PictureEx sample, which also supports static BMP and JPEG, but unpacks image very slowly. Plug-in not stops installer execution when banner is displayed. Banner is not clickable. May be used in the page custom show/leave functions and on other (not page) windows with possible transparency limitations.

Command line (NSIS script)

Plug-in DLL functions (entry points): play, stop

play DLL Function

image horizontal position in percents of width, default is 50 (center).
image vertical position in percents of height, default is 100 (bottom).
target window, default (no parameter) is "#32770" child of $HWNDPARENT .

color to use for image transparent areas. If not defined, plug-in attempts to extract value from target window, but this is not possible if window is hidden. Color value may be hex (starting with 0x) and decimal (first is not 0). Hex value will be used as RGB color, decimal - as Windows system color index in GetSysColor() API call, see MSDN. If value not specified and target window stays hidden (for example in custom 'Show' function), default COLOR_BTNFACE will be used.
image stretch to occupy window width or height. For Welcome page left logo and screen DPI 120 mainly. Default - no stretch.
Image file name.

stop DLL Function

Stops animation and clears the screen.


Package includes nsi script sample.

File sample.gif
AnimGif::play /NOUNLOAD '$PLUGINSDIR\sample.gif'
; Add your page code here
Delete '$PLUGINSDIR\sample.gif'
Personal tools