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()[/Use rs/arun/Work/aponnusa_theoden.corp.adobe.com_1666/depot/branches/conne ct/1010/SDKApp/payload/libs/flashOnly/player10/src/com/adobe/rtc/colla boration/WebcamSubscriber.as:1128]
at com.adobe.rtc.collaboration::WebcamSubscriber/layoutCameraStreams()[/ Users/arun/Work/aponnusa_theoden.corp.adobe.com_1666/depot/branches/co nnect/1010/SDKApp/payload/libs/flashOnly/player10/src/com/adobe/rtc/co llaboration/WebcamSubscriber.as:1175]
at com.adobe.rtc.collaboration::WebcamSubscriber/updateSubscribersDispla y()[/Users/arun/Work/aponnusa_theoden.corp.adobe.com_1666/depot/branch es/connect/1010/SDKApp/payload/libs/flashOnly/player10/src/com/adobe/r tc/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_theoden.corp.adobe.com_1666/depot/branches/connect/1010/ SDKApp/payload/libs/flashOnly/player10/src/com/adobe/rtc/util/Invalida tor.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?
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;
}
}
}
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
North America
Europe, Middle East and Africa
Asia Pacific