A Flash Developer Resource Site

Results 1 to 6 of 6

Thread: Streaming 4 Instances of 1 FLV?

  1. #1
    Senior Member
    Join Date
    Jul 2001
    Posts
    115

    Streaming 4 Instances of 1 FLV?

    As the subject states, I am trying to play four instances of the same FLV at once.

    The following code:

    Code:
    var stream_ns1:NetStream = new NetStream(conn_nc);
    var stream_ns2:NetStream = new NetStream(conn_nc);
    var stream_ns3:NetStream = new NetStream(conn_nc);
    var stream_ns4:NetStream = new NetStream(conn_nc);
    //
    // Attach the NetStream video feed to the Video object:
    tvHolder1.attachVideo(stream_ns1);
    tvHolder2.attachVideo(stream_ns2);
    tvHolder3.attachVideo(stream_ns3);
    tvHolder4.attachVideo(stream_ns4);
    //Play the video
    stream_ns1.play(itemToLoad);
    stream_ns2.play(itemToLoad);
    stream_ns3.play(itemToLoad);
    stream_ns4.play(itemToLoad);
    ...is not working because while Flash is only playing one FLV, it is loading the same one four times. This means a 3MB FLV is a 12MB load.

    Can anyone help? Even if I fail to be able to play the FLVs synchronously I'd still like to be able to bring them in and play random keyframes.

    FYI: I tried

    tvHolder1.attachVideo(stream_ns1);
    tvHolder2.attachVideo(stream_ns1);
    tvHolder3.attachVideo(stream_ns1);
    tvHolder4.attachVideo(stream_ns1);

    But that yielded only tvHolder4 playing the movie.
    ..[my site]..

  2. #2
    Flashmatics silentweed's Avatar
    Join Date
    Mar 2005
    Location
    London, UK
    Posts
    4,876
    Hi have a look at my footer..u can download a thumbnail flv gallery from there... when one flv is playing other flvs, the others do not continue downloading in the background
    Flashmatics | Flashmatics Library (free downloads)
    -----------------------------------------------------
    Latest Projects:
    The Dead Room | Are You Smarter | Prison Break (Frame A Friend) | Beck's Fusions | The 24 Experience

    -----------------------------------------------------
    Flash Certified Developer

  3. #3
    Senior Member
    Join Date
    Jul 2001
    Posts
    115
    Thanks silentweed. That may be useful to me in other ways but not in this respect. I need to load one FLV, not four, then either play it in four instances at once or grab keyframes for "thumbnails" such as yours.

    BTW, did you know that your Thumbnail Gallery causes Firefox to hang and Safari to crash?
    ..[my site]..

  4. #4
    Flashmatics silentweed's Avatar
    Join Date
    Mar 2005
    Location
    London, UK
    Posts
    4,876
    thats strange because i only use firefox and it doesnt freeze on my end... im on a PC, maybe its a mac thing then? Ill check into it..regarding what u wanna do ill try having a look into it tommorow..gonna hit the sack now lol ..quite late here...
    Flashmatics | Flashmatics Library (free downloads)
    -----------------------------------------------------
    Latest Projects:
    The Dead Room | Are You Smarter | Prison Break (Frame A Friend) | Beck's Fusions | The 24 Experience

    -----------------------------------------------------
    Flash Certified Developer

  5. #5
    FK Slacker
    Join Date
    Jun 2000
    Location
    vancouver
    Posts
    3,208
    If you're using Flash 8, you can use BitmapData.draw() to capture each frame of the FLV, and then attachBitmap to apply the frame to a movieclip...

    K.

  6. #6
    Senior Member
    Join Date
    Jul 2001
    Posts
    115
    Awesome! Thanks deadbeat!
    ..[my site]..

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