A Flash Developer Resource Site

Page 1 of 2 12 LastLast
Results 1 to 20 of 36

Thread: [RESOLVED] Streaming 5meg MP3 through 67k flash file

  1. #1
    cyberup
    Guest

    resolved [RESOLVED] Streaming 5meg MP3 through 67k flash file

    Can someone explain to me how this web site delivers it's streaming audio...I can only see it has a 67k flash file? is there a way to access an MP3 file that resides on the server through a flash movie?? I can't work out how this site has done it???
    http://www.4dspace.net/index.html
    Cheers
    Craig

  2. #2
    Senior Moderator ®
    FK´s Banning Machine ™
    GMF ™'s Avatar
    Join Date
    Feb 2000
    Location
    Oslo, Norway
    Posts
    5,697
    could be an external swf that has been loaded into the main movie , wich is the best way of doing it with a soundfile with that filesize .

  3. #3
    cyberup
    Guest

    Thanks for the response

    Could you explain how this is done please? how would I go about setting this up ? Can you suggest a method for me to try? will an external .swf file containing the MP3, stream like that I have tried a few different things and still can't get it to work? any help is good help , as always
    Cheers
    Craig

  4. #4
    Senior Moderator ®
    FK´s Banning Machine ™
    GMF ™'s Avatar
    Join Date
    Feb 2000
    Location
    Oslo, Norway
    Posts
    5,697
    OK , make a new movie with this size 18x18 pix .

    Import the mp3 and set it to loop 999 times . Publish and save as sound.swf .

    In the main movie , last keyframe you add this action : Load movie into location , level20 . This way your movie will load fully before the sound loads , if you place this action to the first one you will load it together with the main movie .

    Add a Off On button , Off action : Unload movie level20 , on action : Load movie sound.swf into location , level20 .

    Thats it Check out our open movies and look for sounds .

  5. #5
    cyberup
    Guest
    Sorry mate, I don't get it ...the user would still have to make the 5meg download of the MP3 before it would play..is that correct...the URL I listed had the music play almost instantly and continue to stream .. I am looking at it through a 56k connection, it would take me 10 minutes to download 5meg of sound...Thankyou for explaining how I can load my movie before loading the sound I have often wondered how that was done. My main movie is only 20k ..so it is quick to download, if I do as you suggest will the music play or hang?
    Thanx heaps for your time..I appreciate it.

  6. #6
    Senior Moderator ®
    FK´s Banning Machine ™
    GMF ™'s Avatar
    Join Date
    Feb 2000
    Location
    Oslo, Norway
    Posts
    5,697
    Oh... im sorry , set the sound to stream and add frames in the layer . this way it will play once it has load a little and enough to play . NOTE , this has something to do with the compression of the mp3 too , like quality .


  7. #7
    cyberup
    Guest

    Just another question if you have time>...

    when you said to load the particular action into the last frame ..I have done this but I was wondering what I should put as the url ..should it be http:// address online or a local address in the shared folder for the movie?
    sorry if I'm a little vague on that...

  8. #8
    Senior Moderator ®
    FK´s Banning Machine ™
    GMF ™'s Avatar
    Join Date
    Feb 2000
    Location
    Oslo, Norway
    Posts
    5,697
    If you have uploaded the sound.swf to thet root of your server you only need sound.swf . If your file is another folder set the path like this /sound/sound.swf

  9. #9
    cyberup
    Guest

    Thanks heaps mate!

    Thankyou you advice has been invaluable ...if I was closer I would by you a beer...LOL
    Cheers
    Craig

  10. #10
    Senior Moderator ®
    FK´s Banning Machine ™
    GMF ™'s Avatar
    Join Date
    Feb 2000
    Location
    Oslo, Norway
    Posts
    5,697
    ooooh... i love beer

  11. #11
    cyberup
    Guest

    Hi mate!

    I have been giving it a fair go ... but ... everytime I make the 18x18 sound movie of 40 frames and add the sound and then set it to stream it will only play till the 40 frame and then it loops at that point .. I can't seem to get it to stream the whole MP3 .. maybe I need to add more frames ..??
    If you have the time I would appreciate the help mate
    Cheers
    Craig

  12. #12
    Senior Moderator ®
    FK´s Banning Machine ™
    GMF ™'s Avatar
    Join Date
    Feb 2000
    Location
    Oslo, Norway
    Posts
    5,697

    yes

    you have to add framas all the way in the soundlayer

  13. #13
    cyberup
    Guest

    How many frames?

    Hi mate, I have added 40 frames to the 18x18 sound movie ..but everytime I play it , it loops at frame 40? How many frames should I put in? is this how it is done ..add 200 frame etc?

  14. #14
    Senior Moderator ®
    FK´s Banning Machine ™
    GMF ™'s Avatar
    Join Date
    Feb 2000
    Location
    Oslo, Norway
    Posts
    5,697
    All the way to the sound ends , you will see that the "wavs" will have an end . Try it with a short sound and you know what i mean.

  15. #15
    cyberup
    Guest

    That works......

    Thanks mate, That seems to work...what is the difference between 1 and 20 in the level box?

  16. #16
    Senior Moderator ®
    FK´s Banning Machine ™
    GMF ™'s Avatar
    Join Date
    Feb 2000
    Location
    Oslo, Norway
    Posts
    5,697
    GREAT !!! Glad you made it .

    Think of the levels like a tall building , you cannot access more levels than the level20 , so if you load your bg music into this level it will stay there. If you had loaded it into level 1 you could easy load another movie in the same level and unloaded the sound . Its just a rule i have for myself.

  17. #17
    cyberup
    Guest

    Oh OOOH

    LOL...I just uploaded the movie ..it calls the sound.swf ..but it loads the whole 500k before playing and I have 3,500 frames and the sound is looped 99 times and the sound is set to stream....sheesh, it is called from the last frame of the movie via the load movie command and is set to level twenty.
    Mate sorry for this, I have done everything suggested, I just don't want this one to beat me ..hahaha

  18. #18
    Senior Moderator ®
    FK´s Banning Machine ™
    GMF ™'s Avatar
    Join Date
    Feb 2000
    Location
    Oslo, Norway
    Posts
    5,697
    If you have set the sound to stream it playes atonce it has loaded alittle to play . To loop this you must set a goto frame 1 in the end of it . Not loop 99 times in the first frame .

    Please read http://board.flashkit.com/board/show...hreadid=126722

  19. #19
    cyberup
    Guest

    Smile That explains where i went wrong

    Cheers mate, i will rip over and have a look at the tut

  20. #20
    cyberup
    Guest

    Just a note

    I have set the sound to stream but it still waits till the whole thing is downloaded..???? I have done everything as mentioned above? the only difference is that now I have just added a goto and play 1 at the end of it and set the loops to 0 ... still it waits til it is all downloaded..I am using flash 5 and publishing to flash 4 specs, can't think of anything else I am doing wrong????????
    cheers Craig

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