Resources/Developer Info & Forums/Developing for Original Sifteo Cubes

Animation on Cubes

Sean Cogan
posted this on January 31, 2012 11:03 am

I was wondering if .png is the only accepted image type for the cubes. I'm working on a matching game, and the idea we had was to play a video if the correct group was matched together. As far as I know, video is out of the range of possibility, but would the cubes be able to handle a .gif? Looking forward to seeing your reponses, thank you.

 

Comments

User photo
Jochen Derwae

.gif is certainly supported. The Image helper converts the images in the assets/images directory to the native format of the cubes. I don't know from the top of my head what other formats it supports apart from .gif and .png.

Personally I tell the artist(s) to export their assets in .gif and doing the conversion to 8-bit image mode themselves before exporting the file from Photoshop. This gives them greater control over how their work will be displayed. Elsewhere on the forum you can find a zip-file with a Photoshop clut-file and swatches with the Sifteo native colors.

Video as such is not possible, but you could grab a bunch of frames, export them and load them onto the cubes. Play all the frames sequentially and you've got video playing. Place the different frames in one large column (see the developer documentation) to improve performance. Keep an eye on the size of the image/movie/animation though, storage on the cubes is limited.

 

February 01, 2012 07:19 am
User photo
Sean Cogan

Ok, thanks very much! I didn't think of just loading each frame and then playing them in sequence. That makes a lot of sense, thanks for your help.

February 01, 2012 11:41 am
User photo
Patrick vd Werf

As a followup question, is it possible to use animated gifs on the cubes or do we have to use sprites consisting of frames?

March 09, 2012 02:16 am
User photo
Sean Cogan

Patrick, that's actually the question I was asking. You can't use an animated gif, but you can load each frame of the gif and display them in sequence to achieve the same effect.

March 20, 2012 10:19 am
User photo
Patrick vd Werf

Thanks Sean and Jochen, wasnt sure what the final anwser was.

March 27, 2012 12:37 am