Package | flash.media |
Class | public class VideoStreamSettings |
Inheritance | VideoStreamSettings Object |
Subclasses | H264VideoStreamSettings, VP6VideoStreamSettings |
Language Version: | ActionScript 3.0 |
Runtime Versions: | Flash Player 11, AIR 3 |
Camera
capture parameters. You can use
methods (setMode()
, etc.) to specify desired encoder parameters and you can use
the properties (width
, etc.) to retrieve the actual compression parameters used.
Properties will be validated once Camera
is attached to NetStream
object
and compression has started.
Note Current implementation does not support setting properties per NetStream
and Camera
parameters will be used
instead for each publishing NetStream
.
Property | Defined By | ||
---|---|---|---|
bandwidth : int [read-only]
Retrieve the maximum amount of bandwidth that the current outgoing video feed can use, in bytes per second. | VideoStreamSettings | ||
codec : String [read-only]
Video codec used for compression. | VideoStreamSettings | ||
constructor : Object
A reference to the class object or constructor function for a given object instance. | Object | ||
fps : Number [read-only]
The maximum frame rate at which the video frames are encoded, in frames per second. | VideoStreamSettings | ||
height : int [read-only]
The current encoded height, in pixels. | VideoStreamSettings | ||
keyFrameInterval : int [read-only]
The number of video frames transmitted in full (called keyframes or IDR frames) instead of
being interpolated by the video compression algorithm. | VideoStreamSettings | ||
quality : int [read-only]
The required level of picture quality, as determined by the amount of compression being applied to each video
frame. | VideoStreamSettings | ||
width : int [read-only]
The current encoded width, in pixels. | VideoStreamSettings |
Method | Defined By | ||
---|---|---|---|
Creates a setting object that specifies to use Sorenson Spark video codec for compresion. | VideoStreamSettings | ||
Indicates whether an object has a specified property defined. | Object | ||
Indicates whether an instance of the Object class is in the prototype chain of the object specified
as the parameter. | Object | ||
Indicates whether the specified property exists and is enumerable. | Object | ||
The number of video frames transmitted in full (called keyframes or Instantaneous Decoding Refresh (IDR) frames) instead of being interpolated by the video compression algorithm. | VideoStreamSettings | ||
Sets the resolution and frame rate used for video encoding. | VideoStreamSettings | ||
Sets the availability of a dynamic property for loop operations. | Object | ||
Sets maximum amount of bandwidth per second or the required picture quality that the current
outgoing video feed can use. | VideoStreamSettings | ||
Returns the string representation of this object, formatted according to locale-specific conventions. | Object | ||
Returns the string representation of the specified object. | Object | ||
Returns the primitive value of the specified object. | Object |
bandwidth | property |
bandwidth:int
[read-only] Language Version: | ActionScript 3.0 |
Runtime Versions: | Flash Player 11, AIR 3 |
Retrieve the maximum amount of bandwidth that the current outgoing video feed can use, in bytes per second.
To set this property, use the setQuality()
method.
Implementation
public function get bandwidth():int
Related API Elements
codec | property |
fps | property |
fps:Number
[read-only] Language Version: | ActionScript 3.0 |
Runtime Versions: | Flash Player 11, AIR 3 |
The maximum frame rate at which the video frames are encoded, in frames per second.
To set a desired value for this property, use the setMode()
method.
This value is validated once Camera
is attached to NetStream
.
Implementation
public function get fps():Number
Related API Elements
height | property |
height:int
[read-only] Language Version: | ActionScript 3.0 |
Runtime Versions: | Flash Player 11, AIR 3 |
The current encoded height, in pixels. To set a desired value for this property,
use the setMode()
method. This value is validated once Camera
is attached
to NetStream
and compression has started.
Implementation
public function get height():int
Related API Elements
keyFrameInterval | property |
keyFrameInterval:int
[read-only] Language Version: | ActionScript #see |
Runtime Versions: | Flash Player 11, AIR 3 |
The number of video frames transmitted in full (called keyframes or IDR frames) instead of
being interpolated by the video compression algorithm. To set a value for
this property, use the setKeyFrameInterval()
method.
Implementation
public function get keyFrameInterval():int
quality | property |
quality:int
[read-only] Language Version: | ActionScript 3.0 |
Runtime Versions: | Flash Player 11, AIR 3 |
The required level of picture quality, as determined by the amount of compression being applied to each video
frame. This value ranges from 1 (lowest quality, maximum compression) to 100 (highest quality, small compression).
To set this property, use the setQuality()
method.
Implementation
public function get quality():int
Related API Elements
width | property |
width:int
[read-only] Language Version: | ActionScript 3.0 |
Runtime Versions: | Flash Player 11, AIR 3 |
The current encoded width, in pixels. To set a desired value for this property,
use the setMode()
method. This value is validated once Camera
is attached
to NetStream
and compression has started.
Implementation
public function get width():int
Related API Elements
VideoStreamSettings | () | Constructor |
public function VideoStreamSettings()
Language Version: | ActionScript 3.0 |
Runtime Versions: | Flash Player 11, AIR 3 |
Creates a setting object that specifies to use Sorenson Spark video codec for compresion.
setKeyFrameInterval | () | method |
public function setKeyFrameInterval(keyFrameInterval:int):void
Language Version: | ActionScript #see |
Runtime Versions: | Flash Player 11, AIR 3 |
The number of video frames transmitted in full (called keyframes or Instantaneous Decoding Refresh (IDR) frames) instead of being interpolated by the video compression algorithm.
The default value is 15, which means that every 15th frame is a keyframe. A value of 1 means that every frame is a keyframe.
The allowed values are 1 through 300. Set to -1 to use the same value as specified for Camera
object. This value
is capped by Camera
value.
Note This feature will be supported in future releases of Flash Player and AIR, for now, Camera
parameters are used.
Parameters
keyFrameInterval:int — A value that specifies which video frames are transmitted in full
(as keyframes or IDR frames) instead of being interpolated by the video compression algorithm.
|
setMode | () | method |
public function setMode(width:int, height:int, fps:Number):void
Language Version: | ActionScript 3.0 |
Runtime Versions: | Flash Player 11, AIR 3 |
Sets the resolution and frame rate used for video encoding. Set each parameter
to -1 to use same encoding value as capture value. Encoding values must be less
than equal than capture values specified on Camera
object. If invalid values are specified, capture values
will be used. Currently, only integer downsampling is supported for both resolution
and frame rate. Captured video is downsampled to desired resolution and frame rate.
The specified values are validated once Camera
is attached to NetStream
. You can use
width
, height
and fps
properties to retrieve
actual compressed width, height and frame rate, respectively.
Note This feature will be supported in future releases of Flash Player and AIR, for now, Camera
parameters are used.
Parameters
width:int — The requested encode width, in pixels. The default value is -1 (same as capture width).
| |
height:int — The requested encode height, in pixels. The default value is -1 (same as capture height).
| |
fps:Number — The requested frame rate at which frames should be encoded, in frames per second.
The default value is -1 (same as capture fps).
|
Related API Elements
setQuality | () | method |
public function setQuality(bandwidth:int, quality:int):void
Language Version: | ActionScript 3.0 |
Runtime Versions: | Flash Player 11, AIR 3 |
Sets maximum amount of bandwidth per second or the required picture quality that the current
outgoing video feed can use. To specify bandwidth, pass a value for
bandwidth and 0 for quality. To specify quality, pass 0 for bandwidth and
a value for quality. Both bandwidth and quality values are capped by Camera
parameters.
Note This feature will be supported in future releases of Flash Player and AIR, for now, Camera
parameters are used.
Parameters
bandwidth:int — Specifies the maximum amount of bandwidth that the current outgoing video feed can use,
in bytes per second. The default value is 16384 (128k bits-per-second (bps), which is very low for high quality video).
| |
quality:int — An integer that specifies the required level of picture quality, as determined
by the amount of compression being applied to each video frame. Acceptable values
range from 1 (lowest quality, maximum compression) to 100 (highest quality,
small compression). The default value is 0.
|
Related API Elements
Thu Dec 6 2018, 01:12 PM -08:00