A Flash Developer Resource Site

Results 1 to 14 of 14

Thread: Why is it running so slow after publishing?!

  1. #1
    Junior Member
    Join Date
    Nov 2005
    Posts
    28

    Why is it running so slow after publishing?!

    Well my portfolio is being done from time to time with some animations from 3d max. I knew it would have to be optimized in the future because of that animations, but yesterday i realized that it was running too slow after publishing some test swf files onto my host.

    I have the terrible habit of overusing the timeline also. This site is being modularized by the loadmovieNum technique.

    The heaviest swf file is 4MB!! LOL! after compression it is 900Kb but that's not enough because i'm sure i didn't respected the basics in terms of site construction.

    But the problem is that, even if i remove the heavy animation from the file, the file gets 40Kb and when i upload it, it remains slow AGAIN. What's causing this? Here's an example (the bio section) but with a file of 150Kb so you can see (click on ENTRAR). Forget the jaggy background cus it is just a guideline from the container as well as the intro html page.

    Do i have to "break" the site even more? Is that going to improve it's speed? By using the loadmovieNum?

    Thanks in advance because i'm starting to become desperate!

    ps. The files are exported in 60FPS, flash 8, AS2.0.

  2. #2
    Actionscript 3, postproduction georgecalgary's Avatar
    Join Date
    Jun 2005
    Location
    Toronto
    Posts
    229
    What you mean as 'slow'? Too big?

    Though as I checked your bio section I think the first file could be under 1k and then the second 20k enough. I could only guess whether you have cleaned all useless assets from library.

  3. #3
    Junior Member
    Join Date
    Nov 2005
    Posts
    28
    Thanks for your quick reply georgecalgary!

    When i view it in my computer it runs smooth as supposed to in 60fps. The problem is that when i publish it, whether it has 40Kb or 900Kb it runs slow comparing with what it was supposed to.

    It appears that the frame rate changes to around 40fps. Just runs slow and not with the flowness that i wanted to.

    This test file that i put so that you could see it, not even it is published in my host. This .swf file is exactly 173Kb.

  4. #4
    Flash Gordon McUsher's Avatar
    Join Date
    Mar 2001
    Location
    Krautland
    Posts
    1,560
    Do you probably have a .swf where you load your other files into?

    Because the first swf defines the fps for all other loaded fps in it...

  5. #5
    Junior Member
    Join Date
    Nov 2005
    Posts
    28
    Yes, i do. The main swf has the loadmovie parameter to load the others. All files are exported to 60FPS. But again, when published they really slow down and that aggravates me...

    At first i would thought that it was because the files were heavy, but when i published a 40Kb version of the same, the results were the same...slow...

  6. #6
    Flash Gordon McUsher's Avatar
    Join Date
    Mar 2001
    Location
    Krautland
    Posts
    1,560
    I just created a simple MovieClip at 120fps and put:
    _root.loadMovie("http://tektest.com.sapo.pt/bio.swf");
    in it.. it just runs fast as hell...

    Please double-check that your main Movie is exported with 60fps.. i somehow doubt it.

    [edit] wait... still testing...
    Last edited by McUsher; 11-08-2005 at 06:02 AM.

  7. #7
    Flash Gordon McUsher's Avatar
    Join Date
    Mar 2001
    Location
    Krautland
    Posts
    1,560
    Ok.. it is only fast as hell when i run this in the flashplayer.exe
    or in my authoring environment, as soon, as i watch the swf in
    my browser it gets this slowdown.

    Must be one of these performance issues with the players for the browsers.
    And i tested both FireFox and IE players...

  8. #8
    Junior Member
    Join Date
    Nov 2005
    Posts
    28
    I really appreciate your replies McUsher, thaks a lot! I'm positive that the file is exported at 60FPS.

    So, in this case is there anything i can do to regain it's correct framerate upon publishing it? Maybe publishing it targeting flash 7?

    Thanks again McUsher!

  9. #9
    Junior Member
    Join Date
    Nov 2005
    Posts
    28
    Ok, i published targeting flash 6 and 7 but the slowness stays.

  10. #10
    Junior Member
    Join Date
    Nov 2005
    Posts
    28
    Upped the framerate to 80 and now when published it runs at around 60 and the file is the same 173Kb. Problem solved i guess. lol

  11. #11
    Flash Gordon McUsher's Avatar
    Join Date
    Mar 2001
    Location
    Krautland
    Posts
    1,560
    Thissis really weird ?!?!

    I have a class which i measure my FPS with.
    PHP Code:
    import ShowFPS;
    new 
    ShowFPS(mc,x_in_mc,y_in_mc); 
    Maybe you've got use for it...
    Attached Files Attached Files

  12. #12
    Junior Member
    Join Date
    Nov 2005
    Posts
    28
    Thanks again McUsher! But my programming knowledge is limited. How does this class work? What do i have to do to make it work?

    Thanks in advance!

  13. #13
    Flash Gordon McUsher's Avatar
    Join Date
    Mar 2001
    Location
    Krautland
    Posts
    1,560
    Oh..
    It is quite simple:
    - put the ShowFPS.as into the directory of your fla file,
    - add the following lines to your fla:
    PHP Code:
     import ShowFPS;
    new 
    ShowFPS(_root); 
    What the ShowFPS will do, is get the next free depth in _root, and
    put a small mc in there.. so you'd better put those 2 lines at the end
    of your code to make sure, the layer the fps shows up is not beeing
    overwritten.

    alternativly you could put it like this:
    PHP Code:
     import ShowFPS;
    _root.createEmptyMovieClip("fps",34454);
    new 
    ShowFPS(fps_mc); 
    to make sure, you'll get a layer (34454 i.E.) which
    isn't used

    Happy FPSing

  14. #14
    Senior Member Ray Beez's Avatar
    Join Date
    Jun 2000
    Posts
    2,793
    Yes, Flash Player is faster than the IE plugin. This is news to you? IE has always been a bit slower. Now it is ALOT slower. Netscape plugin is a little faster than IE's.

    Your movie filesize has nothing to do with it. It's the dimensions that do. For example, Flash can draw a 400x400 window much faster than a 800x800 window.

    Your site takes up the entire page, so you're gonna have slowdown no matter what.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  




Click Here to Expand Forum to Full Width

HTML5 Development Center