title: Multiple NetStreams and performance
body: <p>I need to play multiple (66) synchronized .flv videos in flash. What I do:</p>
  
  <p>I create a new NetConnection  (one for all NetStreams)</p>
  
  <pre><code>var connection: NetConnection,
  clipper: MovieClip;
  connection = new NetConnection();
  connection.connect(null);
  </code></pre>
  
  <p>I have a function to create all the netstream</p>
  
  <pre><code>function addCamera(id, url, pos_x, pos_y) {
      var player: Video = new Video(stageSize.x, stageSize.y),
          stream: NetStream,
          clip: MovieClip;
      clip = new MovieClip();
      stage.addChildAt(clip, 0)
      stream = new NetStream(connection);
      stream.client = this;
      clip.addChild(player);
      player.attachNetStream(stream);
      stream.bufferTime = 1;
      stream.receiveAudio(false);
      stream.receiveVideo(true);
      stream.inBufferSeek = true;
      stream.play(url)
      player.visible = false;
  
      if (!camera[pos_x]) {
          camera[pos_x] = [];
          trace("new camera row:" + pos_x.toString());
          planeSize[0] = planeSize[0] + 1;
      }
      trace("new camera: [" + pos_x.toString() + ", " + pos_y.toString() + "]");
      camera[pos_x][pos_y] = {
          "stream": stream,
          "player": player,
          "pos_x": pos_x,
          "pos_y": pos_y,
          "buffered": false,
          "buffer": 0,
          "id": id
      }
  </code></pre>
  
  <p>Only one video is visible at a time:</p>
  
  <pre><code>camera[currentCamera[0]][currentCamera[1]].player.visible = true;
  </code></pre>
  
  <p>(rest has <code>.visible=false</code>)</p>
  
  <p>This works great for new computers, but on older ones it's a nightmare. Is it possible to have the hidden videos keep their timestamps going on, but for the flash not to render them? </p>
  
  <p>Also, when I seek:</p>
  
  <pre><code>function seekTo(time) {
      trace("Seek to: " + time.toString());
      for each(var pos_x in camera) {
          for each(var curCamera in pos_x) {
              seeking = true;
              curCamera.stream.seek(time);
          }
      }
  }
  </code></pre>
  
  <p>it takes a while. </p>