Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
Developer
Posts: 528
Registered: ‎10-06-2009
My Device: 9800,BB Dev Alpha,z10 limited edition
My Carrier: Vodafone

How to set frame rate of animated gif?

Hi,

I am disolaying one animated GIF. is there any method or way to set frame rate of that

Rujuta Trivedi
New Developer
Posts: 5
Registered: ‎12-17-2009
My Device: Blackberry BOLD 9000 OS 4.6.0.247
My Carrier: SFR

Re: How to set frame rate of animated gif?

How do you display your animated gif ? using a BitmapField ? a custom Field ?

 

Could you paste the code which is responsible for displaying yout gif?

 

 

Developer
Posts: 16,986
Registered: ‎07-29-2008
My Device: Z10 LE, Z30, Passport
My Carrier: O2 Germany

Re: How to set frame rate of animated gif?

the framerate is controlled by the gif itself (if you use the animatedgiffield from the KB). you should be able to edit the value in your picture editor of choice.

 

you can replace the code that reads the framerate and put in anything you want, of course. or replace the animation code with an own timertask or thread.

----------------------------------------------------------
feel free to press the like button on the right side to thank the user that helped you.
please mark posts as solved if you found a solution.
@SimonHain on twitter
Developer
Posts: 528
Registered: ‎10-06-2009
My Device: 9800,BB Dev Alpha,z10 limited edition
My Carrier: Vodafone

Re: How to set frame rate of animated gif?

I am displaying my animated gif using the code of animatedGIFfield of KB article

Rujuta Trivedi
Developer
Posts: 19,636
Registered: ‎07-14-2008
My Device: Not Specified

Re: How to set frame rate of animated gif?

In which case the delay between frames is specified by this value I think:

_image.getFrameDelay(_currentFrame)