Packagecom.adobe.rtc.pods.cameraClasses
Classpublic class CameraModel
InheritanceCameraModel Inheritance flash.events.EventDispatcher
ImplementsISessionSubscriber

CameraModel is a model component which drives the WebCamera pod and keeps the shared properties of the WebCamera pod synchronized across multiple users. It exposes methods for manipulating that shared model and emits events indicating when that model changes. In general, users with a publisher role and higher can change camera settings, while those with the viewer role can see the results. The CameraModel features synchronized quality options and layout settings among web camera pods. The rest of the model for WebCamera comes from the StreamManager.

See also

com.adobe.rtc.pods.WebCamera
com.adobe.rtc.sharedModel.CollectionNode
com.adobe.rtc.sharedManagers.StreamManager


Public Properties
 PropertyDefined by
  connectSession : IConnectSession
The IConnectSession with which this component is associated.
CameraModel
  isSynchronized : Boolean
[read-only] Determines whether the CameraModel is connected and fully synchronized with the service.
CameraModel
  layoutSetting : String
Specifies the layout setting of the camera.
CameraModel
  videoSetting : String
Specifies the video quality settings which is selected from one of the setting constants belonging to this class.
CameraModel
  videoSettingString : String
[read-only] Returns a human-readable string for the selected video quality setting.
CameraModel
Public Methods
 MethodDefined by
  
Constructor.
CameraModel
  
close():void
Disposes all listeners to the network and framework classes.
CameraModel
  
Gets the NodeConfiguration on a specific node in the NodeModel.
CameraModel
  
getUserRole(p_userID:String):int
Returns the role of a given user for video streams, within the group this component is assigned to.
CameraModel
  
setNodeConfiguration(p_nodeName:String, p_nodeConfiguration:NodeConfiguration):void
Sets the NodeConfiguration on a already defined node.
CameraModel
  
setUserRole(p_userID:String, p_role:Number, p_nodeName:String = null):void
Sets the role of a given user for video streams, within the group this component is assigned to.
CameraModel
  
subscribe():void
Tells the component to begin synchronizing with the service.
CameraModel
Events
 EventSummaryDefined by
   Dispatched when the layout settings for the web camera change.CameraModel
   Dispatched when the user's role with respect to this component changes.CameraModel
   Dispatched when the quality settings for the web camera change.CameraModel
   Dispatched when the CameraModel has fully connected and synchronized with the service or when it loses that connection.CameraModel
Public Constants
 ConstantDefined by
  FAST_IMAGES : String = "fast"
[static] Constant value for the "fast images" quality setting for use when motion is more important than picture quality.
CameraModel
  HIGH_BW : String = "high_bw"
[static] Constant value for the "High Bandwidth" quality setting for use in high-bandwidth situations.
CameraModel
  HIGH_QUALITY : String = "high_q"
[static] Constant value for the "high quality" quality setting for use when picture quality is of the most importance.
CameraModel
  NEW_PICTURE_IN_PICTURE : String = "npip"
[static] Deprecated: Constant value for the "new picture in picture" layout setting.
CameraModel
  PICTURE_IN_PICTURE : String = "pip"
[static] Deprecated: Constant value for the "picture in picture" layout setting.
CameraModel
  SIDE_BY_SIDE : String = "sbs"
[static] Constant value for the "side by side" layout setting.
CameraModel
  SLOW_IMAGES : String = "slow"
[static] Constant value for the "slow images" quality setting for use in low-bandwidth situations.
CameraModel
Property detail
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
isSynchronizedproperty 
isSynchronized:Boolean  [read-only]

Determines whether the CameraModel is connected and fully synchronized with the service.

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

Implementation
    public function get isSynchronized():Boolean
layoutSettingproperty 
layoutSetting:String  [read-write]

Specifies the layout setting of the camera. It is chosen from among this class's layout setting constants. The following values are allowed:

The default value is sbs.

Implementation
    public function get layoutSetting():String
    public function set layoutSetting(value:String):void
videoSettingproperty 
videoSetting:String  [read-write]

Specifies the video quality settings which is selected from one of the setting constants belonging to this class.

Implementation
    public function get videoSetting():String
    public function set videoSetting(value:String):void
videoSettingStringproperty 
videoSettingString:String  [read-only]

Returns a human-readable string for the selected video quality setting.

Implementation
    public function get videoSettingString():String
Constructor detail
CameraModel()constructor
public function CameraModel()

Constructor.

Method detail
close()method
public function close():void

Disposes all listeners to the network and framework classes. Use of close() is recommended for proper component garbage collection.

getNodeConfiguration()method 
public function getNodeConfiguration(p_nodeName:String):NodeConfiguration

Gets the NodeConfiguration on a specific node in the NodeModel. If the node is not defined, it will return null

Parameters
p_nodeName:String — The node name of the Node Configuration.

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

Returns the role of a given user for video streams, within the group this component is assigned to.

Parameters
p_userID:String — UserID of the user in question

Returns
int
setNodeConfiguration()method 
public function setNodeConfiguration(p_nodeName:String, p_nodeConfiguration:NodeConfiguration):void

Sets the NodeConfiguration on a already defined node. If the node is not defined, it will not do anything.

Parameters
p_nodeName:String — The node Configuration on a node in the NodeConfiguration.
 
p_nodeConfiguration:NodeConfiguration — The node name of the Node Configuration.
setUserRole()method 
public function setUserRole(p_userID:String, p_role:Number, p_nodeName:String = null):void

Sets the role of a given user for video streams, within the group this component is assigned to.

Parameters
p_userID:String — UserID of the user whose role we are setting
 
p_role:Number — Role value we are setting
 
p_nodeName:String (default = null)
subscribe()method 
public function subscribe():void

Tells the component to begin synchronizing with the service. For "headless" components such as this one, this method must be called explicitly.

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

Dispatched when the layout settings for the web camera change.

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

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

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

Dispatched when the quality settings for the web camera change.

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

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

Constant detail
FAST_IMAGESconstant
public static const FAST_IMAGES:String = "fast"

Constant value for the "fast images" quality setting for use when motion is more important than picture quality.

HIGH_BWconstant 
public static const HIGH_BW:String = "high_bw"

Constant value for the "High Bandwidth" quality setting for use in high-bandwidth situations.

HIGH_QUALITYconstant 
public static const HIGH_QUALITY:String = "high_q"

Constant value for the "high quality" quality setting for use when picture quality is of the most importance.

NEW_PICTURE_IN_PICTUREconstant 
public static const NEW_PICTURE_IN_PICTURE:String = "npip"

Deprecated: Constant value for the "new picture in picture" layout setting. This functionality is scheduled to be reworked.

PICTURE_IN_PICTUREconstant 
public static const PICTURE_IN_PICTURE:String = "pip"

Deprecated: Constant value for the "picture in picture" layout setting. This functionality is scheduled to be reworked.

SIDE_BY_SIDEconstant 
public static const SIDE_BY_SIDE:String = "sbs"

Constant value for the "side by side" layout setting.

SLOW_IMAGESconstant 
public static const SLOW_IMAGES:String = "slow"

Constant value for the "slow images" quality setting for use in low-bandwidth situations.





 

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/cameraClasses/CameraModel.html