Packagecom.adobe.rtc.pods
Classpublic class WebCamera
InheritanceWebCamera Inheritance mx.core.UIComponent
ImplementsISessionSubscriber

The WebCamera component is a high level "pod" component which allows multiple users to publish and display webcam video. In the MVC sense, the WebCamera is the view and controller to the NoteModel's model since it consumes user events, drives them to the model, accepts model events, and updates the view.

The component is comprised of a WebcamPublisher and one or more WebcamSubscribers, and resurfaces many of the features of these components. In general, users with publisher role and higher can publish their webcam streams users with a viewer role can display them. The WebCamera features synchronized quality, layout, and aspect ratio settings.

Like all stream components, WebCamera has an API for setting and getting a groupName. This property can be used to create multiple video groups each with separate and different access/publish models, thereby allowing for multiple private conversations. For a subscriber to listen to a particular video stream from a publisher, both should have the same assigned groupName. If no groupName is assigned, the WebCamera defaults to publishing and subscribing to the public group.

TODO: The layout modes are currently undergoing a rewrite.(yes, still)

See also

com.adobe.rtc.collaboration.WebcamPublisher
com.adobe.rtc.collaboration.WebcamSubscriber
com.adobe.rtc.sharedManagers.StreamManager
com.adobe.rtc.pods.cameraClasses.CameraModel


Public Properties
 PropertyDefined by
  amIsharingMyWebCam : Boolean
[read-only] Returns true if the current client has started their webcam (i.e.
WebCamera
  aspectRatio : String
Specifies the aspect ratio for video display from one of the aspect ratio constants provided on StreamManager.
WebCamera
  connectSession : IConnectSession
The IConnectSession with which this component is associated.
WebCamera
  currentPlayingStream : StreamDescriptor
[read-only] Returns the streamDescriptor for the video stream currently this is being published, if any.
WebCamera
  groupName : String
Components (pods) are assigned to a group via groupName; if not specified, the component is assigned to the default, public group (the room at large).
WebCamera
  imageQuality : String
Specifies the video quality settings for the camera from among the constants provided on CameraModel.
WebCamera
  isSynchronized : Boolean
[read-only] Returns whether or not the component is synchronized.
WebCamera
  layout : String
Specifies the video layout settings for the display from among the constants provided on CameraModel.
WebCamera
  model : CameraModel
[read-only] Returns the CameraModel associated with this pod.
WebCamera
  paused : Boolean
Specifies whether the published stream (if any) is paused (true) or playing (false).
WebCamera
  publisher : WebcamPublisher
[read-only] Returns the WebcamPublisher component used within this pod.
WebCamera
Public Methods
 MethodDefined by
  
WebCamera
  
close():void
Disposes all listeners to the network and framework classes.
WebCamera
  
getUserRole(p_userID:String):int
Returns the role of a given user for video streams that are within this component's assigned group.
WebCamera
  
setUserRole(p_userID:String, p_userRole:int):void
Sets the role of a given user for video streams that are within this component's assigned group.
WebCamera
  
startWebcam():void
Helper function which causes the webcamera to start publishing.
WebCamera
  
subscribe():void
Tells the component to begin synchronizing with the service.
WebCamera
Events
 EventSummaryDefined by
   Dispatched when the web camera's aspect ratio display changes.WebCamera
   Dispatched when the layout value changes.WebCamera
   Dispatched when the quality value changes.WebCamera
   Dispatched when a video stream is stopped and is no longer displayed.WebCamera
   Dispatched when a video stream is paused or unpaused.WebCamera
   Dispatched when a new video stream is received to display by the camera.WebCamera
   Dispatched when the NoteModel has fully connected and synchronized with the service or when it loses that connection.WebCamera
   Dispatched when the current user's role changes with respect to this component.WebCamera
Property detail
amIsharingMyWebCamproperty
amIsharingMyWebCam:Boolean  [read-only]

Returns true if the current client has started their webcam (i.e. has a widget showing in the pod).

Implementation
    public function get amIsharingMyWebCam():Boolean
aspectRatioproperty 
aspectRatio:String  [read-write]

Specifies the aspect ratio for video display from one of the aspect ratio constants provided on StreamManager.

Implementation
    public function get aspectRatio():String
    public function set aspectRatio(value:String):void

See also

connectSessionproperty 
connectSession:IConnectSession  [read-write]

The IConnectSession with which this component is associated. Note that this may only be set once before subscribe() is called; re-sessioning of components is not supported. Defaults to the first IConnectSession created in the application.

Implementation
    public function get connectSession():IConnectSession
    public function set connectSession(value:IConnectSession):void
currentPlayingStreamproperty 
currentPlayingStream:StreamDescriptor  [read-only]

Returns the streamDescriptor for the video stream currently this is being published, if any.

Implementation
    public function get currentPlayingStream():StreamDescriptor
groupNameproperty 
groupName:String  [read-write]

Components (pods) are assigned to a group via groupName; if not specified, the component is assigned to the default, public group (the room at large). Groups are like separate conversations within the room, but each conversation could employ one or more pods; for example, one "conversation" may use a web camera, chat, and whiteboard pod, with each pod using different access and publish models. Users are members of and can only see components within the group they are assigned. Room hosts can see all the groups and all the members in those groups.

Implementation
    public function get groupName():String
    public function set groupName(value:String):void
imageQualityproperty 
imageQuality:String  [read-write]

Specifies the video quality settings for the camera from among the constants provided on CameraModel.

Implementation
    public function get imageQuality():String
    public function set imageQuality(value:String):void

See also

isSynchronizedproperty 
isSynchronized:Boolean  [read-only]

Returns whether or not the component is synchronized.

This property can be used as the source for data binding.

Implementation
    public function get isSynchronized():Boolean
layoutproperty 
layout:String  [read-write]

Specifies the video layout settings for the display from among the constants provided on CameraModel.

TODO: Note that this functionality is undergoing a rewrite and results may vary. Implementation
    public function get layout():String
    public function set layout(value:String):void

See also

modelproperty 
model:CameraModel  [read-only]

Returns the CameraModel associated with this pod.

Implementation
    public function get model():CameraModel
pausedproperty 
paused:Boolean  [read-write]

Specifies whether the published stream (if any) is paused (true) or playing (false).

Implementation
    public function get paused():Boolean
    public function set paused(value:Boolean):void
publisherproperty 
publisher:WebcamPublisher  [read-only]

Returns the WebcamPublisher component used within this pod.

Implementation
    public function get publisher():WebcamPublisher
Constructor detail
WebCamera()constructor
public function WebCamera()
Method detail
close()method
public function close():void

Disposes all listeners to the network and framework classes. Recommended for proper garbage collection of the component.

getUserRole()method 
public function getUserRole(p_userID:String):int

Returns the role of a given user for video streams that are within this component's assigned group.

Parameters
p_userID:String — The user ID for the user being queried.

Returns
int
setUserRole()method 
public function setUserRole(p_userID:String, p_userRole:int):void

Sets the role of a given user for video streams that are within this component's assigned group.

Parameters
p_userID:String — The role value to set on the specified user.
 
p_userRole:int — The ID of the user whose role should be set.
startWebcam()method 
public function startWebcam():void

Helper function which causes the webcamera to start publishing.

subscribe()method 
public function subscribe():void

Tells the component to begin synchronizing with the service. For UIComponent-based components such as this one, subscribe() is called automatically upon being added to the displayList. For "headless" components, this method must be called explicitly.

Event detail
aspectRatioChangeevent 
Event object type: com.adobe.rtc.events.StreamEvent

Dispatched when the web camera's aspect ratio display changes.

layoutChangeevent  
Event object type: com.adobe.rtc.events.CameraModelEvent

Dispatched when the layout value changes.

qualityChangeevent  
Event object type: com.adobe.rtc.events.CameraModelEvent

Dispatched when the quality value changes.

streamDeleteevent  
Event object type: com.adobe.rtc.events.StreamEvent

Dispatched when a video stream is stopped and is no longer displayed.

streamPauseevent  
Event object type: com.adobe.rtc.events.StreamEvent

Dispatched when a video stream is paused or unpaused.

streamReceiveevent  
Event object type: com.adobe.rtc.events.StreamEvent

Dispatched when a new video stream is received to display by the camera.

synchronizationChangeevent  
Event object type: com.adobe.rtc.events.CollectionNodeEvent

Dispatched when the NoteModel has fully connected and synchronized with the service or when it loses that connection.

userRoleChangeevent  
Event object type: com.adobe.rtc.events.CollectionNodeEvent

Dispatched when the current user's role changes with respect to this component.





 

Send me an e-mail when comments are added to this page | Comment Report

Current page: http://livedocs.adobe.com/labs/acrobatcom/com/adobe/rtc/pods/WebCamera.html