clem
clem

Reputation: 3366

embedding a large flash file on an html page

I'm trying to embed several flash files (swf) into different html pages. these flash files vary in size between 6 and 20 MB.

I want these files to start playing immediately once the page is loaded. I'm aware that the file sizes aren't really small and so they will require some time to load. What I would like to know now is if flash will automatically stream these files from the server and will start playing them or if it has to download these files before it can play them?

I've only got a local dev environment atm so can't really test the behaviour on live.

Upvotes: 0

Views: 417

Answers (2)

Paul Macey
Paul Macey

Reputation: 113

It really depends on what those SWFs contain.

Browsers will wait until the whole element has downloaded. Ideally you want the SWF wrapper to be as small a filesize as possible, a few kb.

It is certainly not best practice to embed large elements, such as images and videos inside SWFs and instead stream those using content delivery applications.

For example, stream videos to flash using RTMP and Flash streaming server. I find using http://aws.amazon.com/ for storage and content delivery works well.

Upvotes: 1

Graeme Leighfield
Graeme Leighfield

Reputation: 3005

A flash file is a compiled object. It cant play everything straight away or "stream" unless told to do so.

Check out this article with regards to setting up a "pre-loader"

http://www.jacorre.com/tutorials/simple-flash-preloader/

This works by only progressing past the first keyframe when everything has loaded.

Another idea, which could perhapds improove loading, would be to split your big flash file, into smaller ones, and add a preloader for each one... However of course if you're dealing with lots of files, this might be quite a labourius task Im afraid...

Upvotes: 1

Related Questions