Jump to content

OpenG Read GIF File slow to execute?


Recommended Posts

Hello, I'm trying to display an animated GIF on the front panel. This gif should be loaded programmatically based on some user event. My google search led me to use the OpenG Read GIF File (Animated)__ogtk.vi file. However, loading a GIF is extremely slow. It takes almost 20 seconds to execute the vi when I load the attached GIF (I found randomly on the internet). Is this normal? And if so, is there a way to load a gif faster? Because I need to load several and I cannot afford to load maybe 2 minutes only for the gifs.

GIFexample.gif

Edited by Bas de Jong
Link to comment

The LWZ Unpack algorithm is very slow in the OpenG implementation.
I found this post over in the NI forums and tested it with your image... much faster.

https://forums.ni.com/t5/Example-Program-Drafts/Read-GIF-File/ta-p/3514726

Edit: Set image to "-1" to load them all:

 

Edited by Francois Normandin
  • Like 1
Link to comment
15 hours ago, Francois Normandin said:

The LWZ Unpack algorithm is very slow in the OpenG implementation.
I found this post over in the NI forums and tested it with your image... much faster.

https://forums.ni.com/t5/Example-Program-Drafts/Read-GIF-File/ta-p/3514726

Edit: Set image to "-1" to load them all:

Nice.

It's screaming out to be made into an xControl, IMO. 

Link to comment
43 minutes ago, ShaunR said:

It's screaming out to be made into an xControl

I said xControl first... 😏

 The solution of the Program Drafts above is for sure a lot more developed - all the decoding of gif in G, honouring the time lags between frames, etc. etc.

Link to comment
27 minutes ago, ensegre said:

I said xControl first... 😏

 The solution of the Program Drafts above is for sure a lot more developed - all the decoding of gif in G, honouring the time lags between frames, etc. etc.

Well done for volunteering I look forward do testing it :D

Edited by ShaunR
Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.