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:
![]()
The project also supports more complex GIFs (such as those with partial frames, as well as frames with transparency):
![]()
Here is the demo project: GIFPlayer.zip (Updated!) - 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!)
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:

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

Here is the demo project: GIFPlayer.zip (Updated!) - 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!)