Author: solomax
Date: Tue Aug 23 04:26:06 2016
New Revision: 1757304

URL: http://svn.apache.org/viewvc?rev=1757304&view=rev
Log:
[OPENMEETINGS-1408] test recording/play works

Modified:
    
openmeetings/application/branches/3.1.x/openmeetings-flash/src/main/swf/base/mainMethods.lzx
    
openmeetings/application/branches/3.1.x/openmeetings-flash/src/main/swf/base/remote/baseVideoStream.lzx
    
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/mainMethods.lzx
    
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/remote/baseVideoStream.lzx

Modified: 
openmeetings/application/branches/3.1.x/openmeetings-flash/src/main/swf/base/mainMethods.lzx
URL: 
http://svn.apache.org/viewvc/openmeetings/application/branches/3.1.x/openmeetings-flash/src/main/swf/base/mainMethods.lzx?rev=1757304&r1=1757303&r2=1757304&view=diff
==============================================================================
--- 
openmeetings/application/branches/3.1.x/openmeetings-flash/src/main/swf/base/mainMethods.lzx
 (original)
+++ 
openmeetings/application/branches/3.1.x/openmeetings-flash/src/main/swf/base/mainMethods.lzx
 Tue Aug 23 04:26:06 2016
@@ -326,6 +326,10 @@
                                isSyncUpdate: true,
                                x: 0, y: 0, initY: 0
                                });
+                       var rtmpCon = new lz.rtmpConnection(canvas, {
+                                       src: hib.getUrl()
+                               });
+                       rtmpCon.connect();
                } else {
                        hib.userScope = canvas.wicketroomid;
                        var src = hib.getUrl();

Modified: 
openmeetings/application/branches/3.1.x/openmeetings-flash/src/main/swf/base/remote/baseVideoStream.lzx
URL: 
http://svn.apache.org/viewvc/openmeetings/application/branches/3.1.x/openmeetings-flash/src/main/swf/base/remote/baseVideoStream.lzx?rev=1757304&r1=1757303&r2=1757304&view=diff
==============================================================================
--- 
openmeetings/application/branches/3.1.x/openmeetings-flash/src/main/swf/base/remote/baseVideoStream.lzx
 (original)
+++ 
openmeetings/application/branches/3.1.x/openmeetings-flash/src/main/swf/base/remote/baseVideoStream.lzx
 Tue Aug 23 04:26:06 2016
@@ -8,8 +8,8 @@
   "License"); you may not use this file except in compliance
   with the License.  You may obtain a copy of the License at
   
-      http://www.apache.org/licenses/LICENSE-2.0
-         
+         http://www.apache.org/licenses/LICENSE-2.0
+                 
   Unless required by applicable law or agreed to in writing,
   software distributed under the License is distributed on an
   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@@ -25,41 +25,41 @@
 
 <class name="baseVideoStream" extends="baseVideoView">
 
-    <switch>
-    <when property="$as3">
-        <passthrough>
-               import flash.events.*;
-            import flash.net.*;
-            import flash.media.*
-        </passthrough>
-    </when>
-    </switch>
-    
-    <attribute name="yDebug" value="-20" type="number" />
-    
-    <method name="getYDebug">
-       this.yDebug += 20;
-       return this.yDebug;
-    </method>
+       <switch>
+       <when property="$as3">
+               <passthrough>
+                       import flash.events.*;
+                       import flash.net.*;
+                       import flash.media.*
+               </passthrough>
+       </when>
+       </switch>
+       
+       <attribute name="yDebug" value="-20" type="number" />
+       
+       <method name="getYDebug">
+               this.yDebug += 20;
+               return this.yDebug;
+       </method>
 
        <!--- the NetStream Object
-              @keywords final -->
+                         @keywords final -->
        <attribute name="_ns" value="null" />
 
        <!--- This value does indicate if this stream play or broadcasts
-              @keywords readonly -->
+                         @keywords readonly -->
        <attribute name="mode" value="play" type="string" />
 
        <!--- This is the current buffer used, in Live Streaming this MUST be 0
-              @keywords readonly -->
+                         @keywords readonly -->
        <attribute name="bufferTime" value="0" type="number" />
 
        <!--- This is a reference to the current microphone, only set if 
broadcasting
-              @keywords readonly -->
+                         @keywords readonly -->
        <attribute name="micro" value="null" />
 
        <!--- This is a reference to the current camara, only set if 
broadcasting
-              @keywords readonly -->
+                         @keywords readonly -->
        <attribute name="camera" value="null" />
 
        <!--- Reference To the Sound Object
@@ -69,10 +69,10 @@
                @keywords final -->
        <attribute name="soundRefMC" value="null" />
 
-    <!--- Default mic gain -->
-    <attribute name="micGain" value="50" type="number"/>
-    
-    <attribute name="micMuted" value="false" />
+       <!--- Default mic gain -->
+       <attribute name="micGain" value="50" type="number"/>
+       
+       <attribute name="micMuted" value="false" />
 
        <event name="onMetaDataEvent" />
        <event name="onPlayStatusEvent" />
@@ -82,18 +82,18 @@
        <event name="onIoError" />
 
        <!-- save value for restart -->
-        <attribute name="streamName" type="string"/>
-        <attribute name="delay" />
+               <attribute name="streamName" type="string"/>
+               <attribute name="delay" />
        <!--- @keywords private -->
        <method name="createStream">
                var tStream = this._findnc();
-        if (!tStream.connected) {
-               if ($debug) Debug.warn("NetConnection is not connected");
-        }
+               if (!tStream.connected) {
+                       if ($debug) Debug.warn("NetConnection is not 
connected");
+               }
                this._ns = new NetStream(tStream);
                //see: 
http://livedocs.adobe.com/flash/9.0_de/ActionScriptLangRefV3/flash/net/NetStream.html
-        //according to the docs the construct to catch event has to be 
implemented like this.
-        var t = this;
+               //according to the docs the construct to catch event has to be 
implemented like this.
+               var t = this;
                var clientObject = new Object();
                clientObject.onMetaData = function(metadata:Object):void {
                        t.onMetaData(metadata);
@@ -138,29 +138,29 @@
                this.onIoError.sendEvent(error);
        </method>
 
-    <method name="onCuePoint" args="info"><![CDATA[
-        if($debug) Debug.write("simpleNetStream onCuePoint",info);
-        this.onCuePointEvent.sendEvent(info);
-    ]]></method>
-
-    <method name="onPlayStatus" args="info"><![CDATA[
-        if($debug) Debug.write("simpleNetStream onPlayStatus",info);
-        this.onPlayStatusEvent.sendEvent(info);
-    ]]></method>
-
-    <method name="onMetaData" args="info"><![CDATA[
-        if($debug) Debug.write("simpleNetStream onMetaData",info);
-        this.onMetaDataEvent.sendEvent(info);
-    ]]></method>
-
-    <!--- Find the Flash NetConnection object.
-          @keywords private -->
-    <method name="_findnc">
-       if (canvas.currentNC == null) {
-               if ($debug) Debug.warn("canvas.currentNC is NULL, maybe 
connection did fail?");
-       }
-        return canvas.currentNC;
-    </method>
+       <method name="onCuePoint" args="info"><![CDATA[
+               if($debug) Debug.write("simpleNetStream onCuePoint",info);
+               this.onCuePointEvent.sendEvent(info);
+       ]]></method>
+
+       <method name="onPlayStatus" args="info"><![CDATA[
+               if($debug) Debug.write("simpleNetStream onPlayStatus",info);
+               this.onPlayStatusEvent.sendEvent(info);
+       ]]></method>
+
+       <method name="onMetaData" args="info"><![CDATA[
+               if($debug) Debug.write("simpleNetStream onMetaData",info);
+               this.onMetaDataEvent.sendEvent(info);
+       ]]></method>
+
+       <!--- Find the Flash NetConnection object.
+                 @keywords private -->
+       <method name="_findnc">
+               if (canvas.currentNC == null) {
+                       if ($debug) Debug.warn("canvas.currentNC is NULL, maybe 
connection did fail?");
+               }
+               return canvas.currentNC;
+       </method>
 
        <!---
                Plays a Video Stream, makes a new Instance of a NetStream, if 
previous NetStream
@@ -184,35 +184,35 @@
                //this.setBuffer(0.1);
                if ($debug) Debug.write("Play Stream '" + streamName + "'");
                if (delay == 0) {
-                   this._ns.play(streamName);
+                       this._ns.play(streamName);
                } else {
-                   this._ns.play(streamName,delay);
+                       this._ns.play(streamName,delay);
                }
        ]]>
        </method>
 
        <method name="justPlayStream" args="_streamName, delay">
-        <![CDATA[
-            this.streamName = "" + _streamName;
-            this.delay=delay;
-            if (this._ns!=null){
-               if ($debug) Debug.write("STOP NS is NOT null ")
-                this._stop();
-            }
-            this.mode = "play";
-            this.createStream();
-            //invokes Method in baseVideoView which shows the stream
-            this.attachVideo(this._ns);
-            //FIXME: Commented out, cause this leads to 
Buffer-Full/Buffer-Empty Events
-            //after re-syncing the stream
-
-            this.setBuffer(6);
-
-            if ($debug) Debug.write("Just Play Stream "+streamName);
-
-            this._ns.play(streamName,delay);
-        ]]>
-    </method>
+               <![CDATA[
+                       this.streamName = "" + _streamName;
+                       this.delay=delay;
+                       if (this._ns!=null){
+                               if ($debug) Debug.write("STOP NS is NOT null ")
+                               this._stop();
+                       }
+                       this.mode = "play";
+                       this.createStream();
+                       //invokes Method in baseVideoView which shows the stream
+                       this.attachVideo(this._ns);
+                       //FIXME: Commented out, cause this leads to 
Buffer-Full/Buffer-Empty Events
+                       //after re-syncing the stream
+
+                       this.setBuffer(6);
+
+                       if ($debug) Debug.write("Just Play Stream "+streamName);
+
+                       this._ns.play(streamName,delay);
+               ]]>
+       </method>
 
        <method name="prepare" args="mode, streamName, camReference, 
micReference">
                if (this._ns != null){
@@ -261,8 +261,8 @@
 
        <method name="record" args="streamName,camReference,micReference">
                prepare("record", streamName, camReference, micReference);
-    </method>
-    
+       </method>
+       
        <!---
                Stops playing or broadcasting a Stream and clears the 
Video-Object
         -->
@@ -273,7 +273,7 @@
                this.camera = null;
                this.micro = null;
                if (this.mode == "play") {
-            this.soundRefMC = null;
+                       this.soundRefMC = null;
                        this.soundRef = null;
                        this._ns.pause();
                        this._ns.close();
@@ -281,33 +281,33 @@
                        this.clear();
                        this._ns = null;
                } else if (this.mode == "broadcast") {
-            this._ns.publish(false);
-            //remove NetStream from Video-Object
-            this.clear();
-            this._ns.close();
-            this._ns = null;
-        } else if (this.mode == "record") {
-            this._ns.publish(false);
-            //remove NetStream from Video-Object
-            this.clear();
-            this._ns.close();
-            this._ns = null;
-        } else {
-            this.clear();
-            this._ns.close();
-            this._ns = null;
+                       this._ns.publish(false);
+                       //remove NetStream from Video-Object
+                       this.clear();
+                       this._ns.close();
+                       this._ns = null;
+               } else if (this.mode == "record") {
+                       this._ns.publish(false);
+                       //remove NetStream from Video-Object
+                       this.clear();
+                       this._ns.close();
+                       this._ns = null;
+               } else {
+                       this.clear();
+                       this._ns.close();
+                       this._ns = null;
                        if ($debug) Debug.warn("Not known Mode: 
",this.mode,this);
                }
        </method>
 
        <method name="restart">
-            this._stop();
-            this.playStream(this.streamName ,this.delay);
+                this._stop();
+                this.playStream(this.streamName ,this.delay);
        </method>
        
        <method name="setBuffer" args="time">
-           if ($debug) Debug.warn("setBuffer has no 1:1 equivalent in AS3 ");
-           return;
+               if ($debug) Debug.warn("setBuffer has no 1:1 equivalent in AS3 
");
+               return;
                if(this._ns!=null){
                        this.bufferTime = time;
                        this._ns.setBufferTime(time);
@@ -344,37 +344,37 @@
                        }
                }
        </method>
-    
-    <!---
-        pause or resumes the NetStream
-        @args pauseStatus true pause, false resume
-     -->
-    <method name="pause" args="pauseStatus">
-       if ($debug) Debug.write("do Pause",pauseStatus);
-       if (this._ns==null){
-               if ($debug) Debug.warn("No NetStream");
-               return;
-       }
-       if (pauseStatus) {
-               this._ns.pause();
-       } else {
-               this._ns.resume();
-       }
-    </method>
-    
-    <!---
-        Seek the stream to a flvTime
-        this might only work if there are keyframes in the FLV, normally it 
should 
-        try to use the nearest keyframe available for the specified time.
-     -->
-    <method name="seekStream" args="flvTime">
-       if ($debug) Debug.write("do seek",flvTime);
-        if (this._ns==null){
-            if ($debug) Debug.warn("No NetStream");
-            return;
-        }
-        this._ns.seek(flvTime);
-    </method>
+       
+       <!---
+               pause or resumes the NetStream
+               @args pauseStatus true pause, false resume
+        -->
+       <method name="pause" args="pauseStatus">
+               if ($debug) Debug.write("do Pause",pauseStatus);
+               if (this._ns==null){
+                       if ($debug) Debug.warn("No NetStream");
+                       return;
+               }
+               if (pauseStatus) {
+                       this._ns.pause();
+               } else {
+                       this._ns.resume();
+               }
+       </method>
+       
+       <!---
+               Seek the stream to a flvTime
+               this might only work if there are keyframes in the FLV, 
normally it should 
+               try to use the nearest keyframe available for the specified 
time.
+        -->
+       <method name="seekStream" args="flvTime">
+               if ($debug) Debug.write("do seek",flvTime);
+               if (this._ns==null){
+                       if ($debug) Debug.warn("No NetStream");
+                       return;
+               }
+               this._ns.seek(flvTime);
+       </method>
 
 </class>
 

Modified: 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/mainMethods.lzx
URL: 
http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/mainMethods.lzx?rev=1757304&r1=1757303&r2=1757304&view=diff
==============================================================================
--- 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/mainMethods.lzx
 (original)
+++ 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/mainMethods.lzx
 Tue Aug 23 04:26:06 2016
@@ -231,6 +231,10 @@
                                isSyncUpdate: true,
                                x: 0, y: 0, initY: 0
                                });
+                       var rtmpCon = new lz.rtmpConnection(canvas, {
+                                       src: hib.getUrl()
+                               });
+                       rtmpCon.connect();
                } else {
                        hib.userScope = canvas.wicketroomid;
                        var src = hib.getUrl();

Modified: 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/remote/baseVideoStream.lzx
URL: 
http://svn.apache.org/viewvc/openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/remote/baseVideoStream.lzx?rev=1757304&r1=1757303&r2=1757304&view=diff
==============================================================================
--- 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/remote/baseVideoStream.lzx
 (original)
+++ 
openmeetings/application/branches/3.2.x/openmeetings-flash/src/main/swf/base/remote/baseVideoStream.lzx
 Tue Aug 23 04:26:06 2016
@@ -8,8 +8,8 @@
   "License"); you may not use this file except in compliance
   with the License.  You may obtain a copy of the License at
   
-      http://www.apache.org/licenses/LICENSE-2.0
-         
+         http://www.apache.org/licenses/LICENSE-2.0
+                 
   Unless required by applicable law or agreed to in writing,
   software distributed under the License is distributed on an
   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@@ -25,41 +25,41 @@
 
 <class name="baseVideoStream" extends="baseVideoView">
 
-    <switch>
-    <when property="$as3">
-        <passthrough>
-               import flash.events.*;
-            import flash.net.*;
-            import flash.media.*
-        </passthrough>
-    </when>
-    </switch>
-    
-    <attribute name="yDebug" value="-20" type="number" />
-    
-    <method name="getYDebug">
-       this.yDebug += 20;
-       return this.yDebug;
-    </method>
+       <switch>
+       <when property="$as3">
+               <passthrough>
+                       import flash.events.*;
+                       import flash.net.*;
+                       import flash.media.*
+               </passthrough>
+       </when>
+       </switch>
+       
+       <attribute name="yDebug" value="-20" type="number" />
+       
+       <method name="getYDebug">
+               this.yDebug += 20;
+               return this.yDebug;
+       </method>
 
        <!--- the NetStream Object
-              @keywords final -->
+                         @keywords final -->
        <attribute name="_ns" value="null" />
 
        <!--- This value does indicate if this stream play or broadcasts
-              @keywords readonly -->
+                         @keywords readonly -->
        <attribute name="mode" value="play" type="string" />
 
        <!--- This is the current buffer used, in Live Streaming this MUST be 0
-              @keywords readonly -->
+                         @keywords readonly -->
        <attribute name="bufferTime" value="0" type="number" />
 
        <!--- This is a reference to the current microphone, only set if 
broadcasting
-              @keywords readonly -->
+                         @keywords readonly -->
        <attribute name="micro" value="null" />
 
        <!--- This is a reference to the current camara, only set if 
broadcasting
-              @keywords readonly -->
+                         @keywords readonly -->
        <attribute name="camera" value="null" />
 
        <!--- Reference To the Sound Object
@@ -69,10 +69,10 @@
                @keywords final -->
        <attribute name="soundRefMC" value="null" />
 
-    <!--- Default mic gain -->
-    <attribute name="micGain" value="50" type="number"/>
-    
-    <attribute name="micMuted" value="false" />
+       <!--- Default mic gain -->
+       <attribute name="micGain" value="50" type="number"/>
+       
+       <attribute name="micMuted" value="false" />
 
        <event name="onMetaDataEvent" />
        <event name="onPlayStatusEvent" />
@@ -82,18 +82,18 @@
        <event name="onIoError" />
 
        <!-- save value for restart -->
-        <attribute name="streamName" type="string"/>
-        <attribute name="delay" />
+               <attribute name="streamName" type="string"/>
+               <attribute name="delay" />
        <!--- @keywords private -->
        <method name="createStream">
                var tStream = this._findnc();
-        if (!tStream.connected) {
-               if ($debug) Debug.warn("NetConnection is not connected");
-        }
+               if (!tStream.connected) {
+                       if ($debug) Debug.warn("NetConnection is not 
connected");
+               }
                this._ns = new NetStream(tStream);
                //see: 
http://livedocs.adobe.com/flash/9.0_de/ActionScriptLangRefV3/flash/net/NetStream.html
-        //according to the docs the construct to catch event has to be 
implemented like this.
-        var t = this;
+               //according to the docs the construct to catch event has to be 
implemented like this.
+               var t = this;
                var clientObject = new Object();
                clientObject.onMetaData = function(metadata:Object):void {
                        t.onMetaData(metadata);
@@ -138,29 +138,29 @@
                this.onIoError.sendEvent(error);
        </method>
 
-    <method name="onCuePoint" args="info"><![CDATA[
-        if($debug) Debug.write("simpleNetStream onCuePoint",info);
-        this.onCuePointEvent.sendEvent(info);
-    ]]></method>
-
-    <method name="onPlayStatus" args="info"><![CDATA[
-        if($debug) Debug.write("simpleNetStream onPlayStatus",info);
-        this.onPlayStatusEvent.sendEvent(info);
-    ]]></method>
-
-    <method name="onMetaData" args="info"><![CDATA[
-        if($debug) Debug.write("simpleNetStream onMetaData",info);
-        this.onMetaDataEvent.sendEvent(info);
-    ]]></method>
-
-    <!--- Find the Flash NetConnection object.
-          @keywords private -->
-    <method name="_findnc">
-       if (canvas.currentNC == null) {
-               if ($debug) Debug.warn("canvas.currentNC is NULL, maybe 
connection did fail?");
-       }
-        return canvas.currentNC;
-    </method>
+       <method name="onCuePoint" args="info"><![CDATA[
+               if($debug) Debug.write("simpleNetStream onCuePoint",info);
+               this.onCuePointEvent.sendEvent(info);
+       ]]></method>
+
+       <method name="onPlayStatus" args="info"><![CDATA[
+               if($debug) Debug.write("simpleNetStream onPlayStatus",info);
+               this.onPlayStatusEvent.sendEvent(info);
+       ]]></method>
+
+       <method name="onMetaData" args="info"><![CDATA[
+               if($debug) Debug.write("simpleNetStream onMetaData",info);
+               this.onMetaDataEvent.sendEvent(info);
+       ]]></method>
+
+       <!--- Find the Flash NetConnection object.
+                 @keywords private -->
+       <method name="_findnc">
+               if (canvas.currentNC == null) {
+                       if ($debug) Debug.warn("canvas.currentNC is NULL, maybe 
connection did fail?");
+               }
+               return canvas.currentNC;
+       </method>
 
        <!---
                Plays a Video Stream, makes a new Instance of a NetStream, if 
previous NetStream
@@ -184,35 +184,35 @@
                //this.setBuffer(0.1);
                if ($debug) Debug.write("Play Stream '" + streamName + "'");
                if (delay == 0) {
-                   this._ns.play(streamName);
+                       this._ns.play(streamName);
                } else {
-                   this._ns.play(streamName,delay);
+                       this._ns.play(streamName,delay);
                }
        ]]>
        </method>
 
        <method name="justPlayStream" args="_streamName, delay">
-        <![CDATA[
-            this.streamName = "" + _streamName;
-            this.delay=delay;
-            if (this._ns!=null){
-               if ($debug) Debug.write("STOP NS is NOT null ")
-                this._stop();
-            }
-            this.mode = "play";
-            this.createStream();
-            //invokes Method in baseVideoView which shows the stream
-            this.attachVideo(this._ns);
-            //FIXME: Commented out, cause this leads to 
Buffer-Full/Buffer-Empty Events
-            //after re-syncing the stream
-
-            this.setBuffer(6);
-
-            if ($debug) Debug.write("Just Play Stream "+streamName);
-
-            this._ns.play(streamName,delay);
-        ]]>
-    </method>
+               <![CDATA[
+                       this.streamName = "" + _streamName;
+                       this.delay=delay;
+                       if (this._ns!=null){
+                               if ($debug) Debug.write("STOP NS is NOT null ")
+                               this._stop();
+                       }
+                       this.mode = "play";
+                       this.createStream();
+                       //invokes Method in baseVideoView which shows the stream
+                       this.attachVideo(this._ns);
+                       //FIXME: Commented out, cause this leads to 
Buffer-Full/Buffer-Empty Events
+                       //after re-syncing the stream
+
+                       this.setBuffer(6);
+
+                       if ($debug) Debug.write("Just Play Stream "+streamName);
+
+                       this._ns.play(streamName,delay);
+               ]]>
+       </method>
 
        <method name="prepare" args="mode, streamName, camReference, 
micReference">
                if (this._ns != null){
@@ -261,8 +261,8 @@
 
        <method name="record" args="streamName,camReference,micReference">
                prepare("record", streamName, camReference, micReference);
-    </method>
-    
+       </method>
+       
        <!---
                Stops playing or broadcasting a Stream and clears the 
Video-Object
         -->
@@ -273,7 +273,7 @@
                this.camera = null;
                this.micro = null;
                if (this.mode == "play") {
-            this.soundRefMC = null;
+                       this.soundRefMC = null;
                        this.soundRef = null;
                        this._ns.pause();
                        this._ns.close();
@@ -281,33 +281,33 @@
                        this.clear();
                        this._ns = null;
                } else if (this.mode == "broadcast") {
-            this._ns.publish(false);
-            //remove NetStream from Video-Object
-            this.clear();
-            this._ns.close();
-            this._ns = null;
-        } else if (this.mode == "record") {
-            this._ns.publish(false);
-            //remove NetStream from Video-Object
-            this.clear();
-            this._ns.close();
-            this._ns = null;
-        } else {
-            this.clear();
-            this._ns.close();
-            this._ns = null;
+                       this._ns.publish(false);
+                       //remove NetStream from Video-Object
+                       this.clear();
+                       this._ns.close();
+                       this._ns = null;
+               } else if (this.mode == "record") {
+                       this._ns.publish(false);
+                       //remove NetStream from Video-Object
+                       this.clear();
+                       this._ns.close();
+                       this._ns = null;
+               } else {
+                       this.clear();
+                       this._ns.close();
+                       this._ns = null;
                        if ($debug) Debug.warn("Not known Mode: 
",this.mode,this);
                }
        </method>
 
        <method name="restart">
-            this._stop();
-            this.playStream(this.streamName ,this.delay);
+                this._stop();
+                this.playStream(this.streamName ,this.delay);
        </method>
        
        <method name="setBuffer" args="time">
-           if ($debug) Debug.warn("setBuffer has no 1:1 equivalent in AS3 ");
-           return;
+               if ($debug) Debug.warn("setBuffer has no 1:1 equivalent in AS3 
");
+               return;
                if(this._ns!=null){
                        this.bufferTime = time;
                        this._ns.setBufferTime(time);
@@ -344,37 +344,37 @@
                        }
                }
        </method>
-    
-    <!---
-        pause or resumes the NetStream
-        @args pauseStatus true pause, false resume
-     -->
-    <method name="pause" args="pauseStatus">
-       if ($debug) Debug.write("do Pause",pauseStatus);
-       if (this._ns==null){
-               if ($debug) Debug.warn("No NetStream");
-               return;
-       }
-       if (pauseStatus) {
-               this._ns.pause();
-       } else {
-               this._ns.resume();
-       }
-    </method>
-    
-    <!---
-        Seek the stream to a flvTime
-        this might only work if there are keyframes in the FLV, normally it 
should 
-        try to use the nearest keyframe available for the specified time.
-     -->
-    <method name="seekStream" args="flvTime">
-       if ($debug) Debug.write("do seek",flvTime);
-        if (this._ns==null){
-            if ($debug) Debug.warn("No NetStream");
-            return;
-        }
-        this._ns.seek(flvTime);
-    </method>
+       
+       <!---
+               pause or resumes the NetStream
+               @args pauseStatus true pause, false resume
+        -->
+       <method name="pause" args="pauseStatus">
+               if ($debug) Debug.write("do Pause",pauseStatus);
+               if (this._ns==null){
+                       if ($debug) Debug.warn("No NetStream");
+                       return;
+               }
+               if (pauseStatus) {
+                       this._ns.pause();
+               } else {
+                       this._ns.resume();
+               }
+       </method>
+       
+       <!---
+               Seek the stream to a flvTime
+               this might only work if there are keyframes in the FLV, 
normally it should 
+               try to use the nearest keyframe available for the specified 
time.
+        -->
+       <method name="seekStream" args="flvTime">
+               if ($debug) Debug.write("do seek",flvTime);
+               if (this._ns==null){
+                       if ($debug) Debug.warn("No NetStream");
+                       return;
+               }
+               this._ns.seek(flvTime);
+       </method>
 
 </class>
 


Reply via email to