Animated GIF’s do not work natively in Processing.js. You will need the individual frames in separate images or use some form of spritesheet handling class function. -(source)
http://processingjs.org/learning/topic/animatedsprite/
http://processingjs.org/learning/topic/sequential/
But, you might be able to make use of: