7 Replies Latest reply: Aug 8, 2011 7:40 AM by Nigel Pegg RSS

    Error With New SDK With Setting WebcamSubscriber.webcamPublisher

    l4nc3r Community Member

      I'm getting this error when setting the WebcamSubscriber.webcamPublisher in the flashOnly swc (happens in all versions):

       

      TypeError: Error #1009: Cannot access a property or method of a null object reference.
          at com.adobe.rtc.collaboration::WebcamSubscriber/computeArea_Rows()[/Users/arun/Work/aponnus a_theoden.corp.adobe.com_1666/depot/branches/connect/1010/SDKApp/payload/libs/flashOnly/pl ayer10/src/com/adobe/rtc/collaboration/WebcamSubscriber.as:1128]
          at com.adobe.rtc.collaboration::WebcamSubscriber/layoutCameraStreams()[/Users/arun/Work/apon nusa_theoden.corp.adobe.com_1666/depot/branches/connect/1010/SDKApp/payload/libs/flashOnly /player10/src/com/adobe/rtc/collaboration/WebcamSubscriber.as:1175]
          at com.adobe.rtc.collaboration::WebcamSubscriber/updateSubscribersDisplay()[/Users/arun/Work /aponnusa_theoden.corp.adobe.com_1666/depot/branches/connect/1010/SDKApp/payload/libs/flas hOnly/player10/src/com/adobe/rtc/collaboration/WebcamSubscriber.as:1422]
          at flash.events::EventDispatcher/dispatchEventFunction()
          at flash.events::EventDispatcher/dispatchEvent()
          at com.adobe.rtc.util::Invalidator/onInvalidationComplete()[/Users/arun/Work/aponnusa_theode n.corp.adobe.com_1666/depot/branches/connect/1010/SDKApp/payload/libs/flashOnly/player10/s rc/com/adobe/rtc/util/Invalidator.as:78]
          at flash.events::EventDispatcher/dispatchEventFunction()
          at flash.events::EventDispatcher/dispatchEvent()
          at flash.utils::Timer/tick()

       

      In the meantime, is there anywhere I can download the last SDK?

        • 1. Re: Error With New SDK With Setting WebcamSubscriber.webcamPublisher
          Hironmay Community Member

          Is this with the latest SDK that we released yesterday?

           

          Thanks

          Hironmay Basu

          • 2. Re: Error With New SDK With Setting WebcamSubscriber.webcamPublisher
            aponnusa Adobe Employee

            Hi,

             

            Can you share your code. I tried the FlashWebCamExample in the sample Apps, and nothing seems to be broken. Was your code ok with the previous SDK?

             

            Thanks

            Arun

            • 3. Re: Error With New SDK With Setting WebcamSubscriber.webcamPublisher
              l4nc3r Community Member

              Got it: apparently you need to tell the WebcamSubscriber to subscribe before setting the publisher.  You guys should have the class throw a relevant Error so users don't get confused.  Here's the code I used to find it:

               

              package com.ironcoding.videochat {
                 
                  import com.adobe.rtc.authentication.AdobeHSAuthenticator;
                  import com.adobe.rtc.collaboration.WebcamPublisher;
                  import com.adobe.rtc.collaboration.WebcamSubscriber;
                  import com.adobe.rtc.events.SessionEvent;
                  import com.adobe.rtc.session.ConnectSession;
                 
                  import flash.display.Sprite;
                 
                  public class WebcamTest extends Sprite {
                     
                      protected const USERNAME:String = "";
                      protected const PASSWORD:String = "";
                      protected const ROOM_URL:String = "";
                     
                      protected var _cSession:ConnectSession;
                     
                      protected var _webcamPublisher:WebcamPublisher;
                      protected var _localWebcamSubscriber:WebcamSubscriber;
                     
                      public function WebcamTest() {
                          var authenticator = new AdobeHSAuthenticator();
                          authenticator.userName = this.USERNAME;
                          authenticator.password = this.PASSWORD;
                         
                          this._cSession = new ConnectSession();
                          this._cSession.addEventListener(SessionEvent.SYNCHRONIZATION_CHANGE, this.onLogin);
                         
                          this._cSession.roomURL = this.ROOM_URL;
                          this._cSession.authenticator = authenticator;
                          this._cSession.login();
                      }
                     
                      public function onLogin(event:SessionEvent):void {
                         
                          this._webcamPublisher = new WebcamPublisher();
                          this._localWebcamSubscriber = new WebcamSubscriber();
                         
                          this._webcamPublisher.publish();

                          //Without this line, it crashes.  With it, it doesn't.
                          //this._localWebcamSubscriber.subscribe();
                          this._localWebcamSubscriber.webcamPublisher = this._webcamPublisher;
                      }
                  }
              }

              • 4. Re: Error With New SDK With Setting WebcamSubscriber.webcamPublisher
                aponnusa Adobe Employee

                Hi l4nc3r,

                 

                Thanks for reporting the issue. It would be fixed by next release.

                 

                Thanks

                Arun

                • 5. Re: Error With New SDK With Setting WebcamSubscriber.webcamPublisher
                  BARRYC16 Community Member

                  I still see this error but only on Safari browser.

                   

                  The workaround works fine for me but I have a question. If I call .subscribe() on my local subscriber am I still getting the cam feed locally if I set the .publisherIDs array to only have my own Id? Previously I wasn't calling subscribe() and I just want to make sure that I am not going out to the server to get my own feed if I call this method.

                   

                  Thanks,

                  Barry

                  • 6. Re: Error With New SDK With Setting WebcamSubscriber.webcamPublisher
                    BARRYC16 Community Member

                    Confirming that this is now fixed with Safari in the newly released 10.3 library. Was still seeing the problem only with Safari in the beta 10.3 swc release, but the issue is now completely fixed.

                    • 7. Re: Error With New SDK With Setting WebcamSubscriber.webcamPublisher
                      Nigel Pegg Community Member

                      Cool, thanks for the feedback!

                       

                        nigel