A Flash Developer Resource Site

Results 1 to 7 of 7

Thread: stream sound pauses... can i do anything about it?

  1. #1
    user in A minor
    Join Date
    Jan 2005
    Location
    finland
    Posts
    121

    stream sound pauses... can i do anything about it?

    hi!
    a while back i asked here about preloading sounds, and got advice to learn more about streaming sounds, i did, and now the streaming seems to work ok, with nice sound quality and all. plus the music plays a lot sooner - bye bye preloaders. thanks iaskwhy!

    but i didn't find an answer to this despite the search: i am a bit worried about lower bandwidths. when simulating download, the music samples play for a while, then pause for some seconds, then go on playing again etc. i'm making a site for a band, so the music samples should be as good as possible. they are about 1 min long each. plus i have a lot of friends with quite low net speeds.

    is there anything i can do about the pauses..? or should the lower bandwidth guys just go on suffering?

    thanks again, a lot,
    mar

  2. #2
    Registered User Ask The Geezer's Avatar
    Join Date
    Jul 2002
    Location
    Out In The Pasture
    Posts
    20,488
    Use the _soundbuftime property. The default is 5 seconds, up it to 10 or 15 and test it. It's a global property, so just put that in frame 1 of the main timeline.

    _soundbuftime = 10;

  3. #3
    user in A minor
    Join Date
    Jan 2005
    Location
    finland
    Posts
    121
    hi there!

    all right. i tried: that does change things, yes. increasing the buffer time makes the music plays longer at one go. but the gaps still exist, and now they are as much longer... hmmm. i also have an animation elsewhere, that it supposed to start at the same time with the sound. it's an image of the band actually playing. now the animation starts earlier, according to the buffer size, which looks a bit funny, especially if one has to wait a long time for the sound... is there any way around that?

    i have the sound in main timeline, streched long enough so that i've been able to write start and stop commands at both ends of the music sample timeline.

    thanks again says mar

  4. #4
    user in A minor
    Join Date
    Jan 2005
    Location
    finland
    Posts
    121
    ...now that much wiser, i searched with key word 'buffer' and found looooots of answers. but one still remains: how to recognize when the sound actually starts, so that i could sync the animation? is this possible?
    asks mar

  5. #5
    Registered User Ask The Geezer's Avatar
    Join Date
    Jul 2002
    Location
    Out In The Pasture
    Posts
    20,488
    First off, you have to realize that sounds played in flash are about as trashy as it gets. No way is flash capabale of playing anywhere near the quality of sound that Quicktime or Real can play. It's just not made for it.

    Second, you can't sync a sound with an animation unless the sound Sync is set to Stream, and that further lowers the sound quality and prevents you from preloading it.

    If you want close syncing, then build it in a separate fla. Put the animation in one layer and the sound stretched out in another layer and set it to Stream. Then use loadMovie to play that swf in your main movie. This will play on any modem connection, even ones power by a Gerbil running in a wheel. But, you'll have to put up with lower quality sound.

    Another option is to buy some 3rd party software to create a QT movie that can use higher quality sounds and play that in a popup.

  6. #6
    user in A minor
    Join Date
    Jan 2005
    Location
    finland
    Posts
    121
    ok, got it... i won't be able to glue all into same swf, as the animation actually consists of swf's in layers, it'll be too big etc etc. plus the quality of the sound is important. anyway. i think i can make a compromise good enough for most viewers, and that'll just have to do.

    gerbils! sounds like you've seen my mom's computer...
    cheers mate *bobs a curtsy*

  7. #7
    Registered User Ask The Geezer's Avatar
    Join Date
    Jul 2002
    Location
    Out In The Pasture
    Posts
    20,488
    You might want to read and bookmark this thread from the Sound forum. There's more facts about sound quality there;

    http://www.flashkit.com/board/showthread.php?t=299918

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