Quantcast
Viewing latest article 5
Browse Latest Browse All 1528

VB6 - Simple Animated GIF Player (supports transparency) using WinRT / BitmapDecoder

This project uses the BitmapDecoder WinRT class to decode a GIF file into its individual frames. These frames can then be rendered into any device context (Form, PictureBox, etc) using vanilla GDI functions.

A TypeLib with the required WinRT interface definitions is included in the ZIP archive, don't forget to set a reference to it.

Here's a classic GIF showing Commander Data losing his temper over the once ubiquitous blue screen of death:

Image may be NSFW.
Clik here to view.


The project also supports more complex GIFs (such as those with partial frames, as well as frames with transparency):

Image may be NSFW.
Clik here to view.


Here is the demo project: GIFPlayer.zip (Download the GIFs above and place them in the project folder as they were too big to include in the attachment or provide your own GIFs for testing).

Requirements: Windows 10 (fully updated!)
Attached Files

Viewing latest article 5
Browse Latest Browse All 1528

Trending Articles