0 Replies Latest reply on Jun 3, 2009 12:36 PM by AqueleAquele

    Video Oject not display- Live Streaming

    AqueleAquele

      Hi every one.

       

      I'm trying to construc a flex/actionscript apllication plataform to receive and play live streaming.

       

      Something like this:

       

      public function callConnected(netConnection:NetConnection, playName:String, publishName:String):void {
                                      var vidPlayer:Video;

       

                                      incomingVideoNetStream = new NetStream(netConnection);
                                      incomingVideoNetStream.addEventListener(NetStatusEvent.NET_STATUS, netStatus);
                                      incomingVideoNetStream.addEventListener(AsyncErrorEvent.ASYNC_ERROR, asyncErrorHandler );

       

                                      vidPlayer = new Video();
                                      vidPlayer.x = 11;
                                      vidPlayer.y = 253;
                                      vidPlayer.attachNetStream(incomingVideoNetStream);
                                      incomingVideoNetStream.play(playVideoName);

                                      addChild(vidPlayer)

                                       //videoReceive.addChild(vidPlayer)

       

      }

       

      ........

       

      <mx:VideoDisplay x="10" y="253" width="176" height="144" id="videoReceive"/>

       

      If use the code up the Video Object, doesn't appear in the interface.(I try to create another object like Button, and works write, just in case.... )

       

      If i use this line ( //videoReceive.addChild(vidPlayer) ), I can see the image in interface, but a strange thing, it's apenning. The image it's appears very very small, in the top left of the videoDisplay and not in correct size (it should be 176x144).

       

       

      Any one knows if is the correct away to do this?

       

      where is my mistake???

       

      Thank you very much fo answers!

       

      Best Regards.

       

      Miguel Barros