Problem with animated gif

Visuals, audio, animation. Blended, not stirred. If LiveCode is part of your rich media production toolbox, this is the forum for you.

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

andres
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 68
Joined: Thu Jan 04, 2007 2:24 am

Problem with animated gif

Post by andres » Tue Jun 03, 2008 3:22 pm

Hello

I am trying to use an animated gif but I am having four different problems:

1- The original file has 50 frames, but the imported one has only 38 frames.
2- The original movie plays good on Safari, but in Revolution the quality of some frames is horrible.
3- There is no way to control the framerate.
4- There is one white pixel on the upper left corner that does not come form the original file.

Help on any of these issues is greatly appreciated.

Thanks
Andres

Mark
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 5150
Joined: Thu Feb 23, 2006 9:24 pm
Contact:

Post by Mark » Tue Jun 03, 2008 9:08 pm

Hi Andres,

Revolution is not very good at playing GIFs, but GIF isn't a pretty format either. Can't you use separate pictures instead?

Best,

Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode

andres
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 68
Joined: Thu Jan 04, 2007 2:24 am

Post by andres » Tue Jun 03, 2008 9:17 pm

Hello Mark

We decided to go with the extra work of a flash animation using RevBrowser.

It finally works now with a workaround for the semi-transparent window shapes that prevents the Revbrowser to work in windows.

Thanks
Andres

Mark
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 5150
Joined: Thu Feb 23, 2006 9:24 pm
Contact:

Post by Mark » Tue Jun 03, 2008 9:19 pm

Hi Andres,

Do you mind to tell why you made this choice?

Best,

Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode

andres
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 68
Joined: Thu Jan 04, 2007 2:24 am

Post by andres » Tue Jun 03, 2008 9:28 pm

Hello Mark

Well, we started with a quicktime movie, which works beautiful, with a simple line of code. However, for an unknown reason, the movie (which is an intro movie) displays centered on the stack's top left corner and cropped showing only a quarter of the movie. I found this same problem posted here but no solution yet.

Unfortunately not all win computers have quicktime installed and we decided to move to animated gifs. Then, after experiencing all these problems we ended up with the only solution.

Andres

Mark
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 5150
Joined: Thu Feb 23, 2006 9:24 pm
Contact:

Post by Mark » Tue Jun 03, 2008 9:33 pm

Hi Andres,

Still, what's wrong with a bunch of pictures, displayed in a loop?

Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode

andres
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 68
Joined: Thu Jan 04, 2007 2:24 am

Post by andres » Tue Jun 03, 2008 9:41 pm

Ooops sorry

Well, a flash animation, when created in Flash, is by far smaller in size.

Andres

Mark
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 5150
Joined: Thu Feb 23, 2006 9:24 pm
Contact:

Post by Mark » Tue Jun 03, 2008 10:30 pm

Thanks for the clarification. File size must have been extremely important then.

Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode

andres
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 68
Joined: Thu Jan 04, 2007 2:24 am

Post by andres » Tue Jun 03, 2008 10:38 pm

Hello Mark

To our business model it is, since all our games are distributed as downloads from our website.

These numbers will be different for each particular case, but in this one the flash animation is 170K while all frames as images are 8.5M.

Andres

Mark
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 5150
Joined: Thu Feb 23, 2006 9:24 pm
Contact:

Post by Mark » Tue Jun 03, 2008 10:56 pm

Hi Andres,

I don't see why cool games have to be small, as long as they are worth downloading.

With some clever compression techniques, it should be possible to reduce the size of the pictures to less than 100K, even if it is a full-screen picture.

Best,

Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode

andres
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 68
Joined: Thu Jan 04, 2007 2:24 am

Post by andres » Tue Jun 03, 2008 11:02 pm

Hello Mark

Download size is very important.

All our frames are less than 100K, but they are almost a 100 frames.

If you know a better compression than jpg or png for photo-quality images I will give it a try.

Thanks
Andres

Mark
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 5150
Joined: Thu Feb 23, 2006 9:24 pm
Contact:

Post by Mark » Tue Jun 03, 2008 11:08 pm

Hi Andres,

Why is download size that important?

I don't know anything better then JPEG at the moment, but there might be other ways to get the filesize down. My first thought was to use JPEG, though.

Best,

Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode

andres
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 68
Joined: Thu Jan 04, 2007 2:24 am

Post by andres » Tue Jun 03, 2008 11:17 pm

Yes Mark

I wish we could just use a qt movie, like we wanted the first time.

But we have not been able to solve the corner position problem.

Andres

Mark
Livecode Opensource Backer
Livecode Opensource Backer
Posts: 5150
Joined: Thu Feb 23, 2006 9:24 pm
Contact:

Post by Mark » Tue Jun 03, 2008 11:23 pm

Andres,

Why is download size so important? It really fascinates me.

Mark
The biggest LiveCode group on Facebook: https://www.facebook.com/groups/livecode.developers
The book "Programming LiveCode for the Real Beginner"! Get it here! http://tinyurl.com/book-livecode

andres
VIP Livecode Opensource Backer
VIP Livecode Opensource Backer
Posts: 68
Joined: Thu Jan 04, 2007 2:24 am

Post by andres » Tue Jun 03, 2008 11:32 pm

Mark

The faster the download, the sooner the end user starts playing.

Is a matter of keeping the interest alive.

Andres

Post Reply