Package | fl.video |
Class | public final class VideoScaleMode |
Inheritance | VideoScaleMode Object |
Language Version: | ActionScript 3.0 |
Product Version: | Flash CS3 |
Runtime Versions: | Flash Player 9.0.28.0, AIR 1.0 |
FLVPlayback.scaleMode
and
VideoPlayer.scaleMode
properties.
Related API Elements
Constant | Defined By | ||
---|---|---|---|
EXACT_FIT : String = "exactFit" [static]
Specifies that the video be displayed at the
height and width specified by the registrationHeight
or height and registrationWidth or width
properties. | VideoScaleMode | ||
MAINTAIN_ASPECT_RATIO : String = "maintainAspectRatio" [static]
Specifies that the video be constrained within the
rectangle determined by the registrationX, registrationY,
registrationWidth, and registrationHeight properties but that its
original aspect ratio be preserved. | VideoScaleMode | ||
NO_SCALE : String = "noScale" [static]
Specifies that the video be displayed at exactly the
height and width of the source video. | VideoScaleMode |
EXACT_FIT | Constant |
public static const EXACT_FIT:String = "exactFit"
Language Version: | ActionScript 3.0 |
Product Version: | Flash CS3 |
Runtime Versions: | Flash Player 9.0.28.0, AIR 1.0 |
Specifies that the video be displayed at the
height and width specified by the registrationHeight
or height
and registrationWidth
or width
properties.
For example, if registrationWidth = width = 100
and
registrationHeight = height = 100
, if registrationX = 200
and
registrationY = 200
, and if an FLV file is loaded with a width
of 648 and
a height
of 480 (for an approximate aspect ratio of 4:3), and if
align = VideoAlign.CENTER
and scaleMode = EXACT_FIT
,
you end up with width = 100
, height = 100
, x = 200
,
and y = 200
.
MAINTAIN_ASPECT_RATIO | Constant |
public static const MAINTAIN_ASPECT_RATIO:String = "maintainAspectRatio"
Language Version: | ActionScript 3.0 |
Product Version: | Flash CS3 |
Runtime Versions: | Flash Player 9.0.28.0, AIR 1.0 |
Specifies that the video be constrained within the
rectangle determined by the registrationX
, registrationY
,
registrationWidth
, and registrationHeight
properties but that its
original aspect ratio be preserved.
For example, if registrationWidth = 100
and
registrationHeight = 100
, if registrationX = 200
and
registrationY = 200
, and if an FLV file is loaded with a width
of 648 and
a height
of 480 (for an approximate aspect ratio of 4:3), and if
align = VideoAlign.CENTER
and scaleMode =
MAINTAIN_ASPECT_RATIO
, you end up with width =
100
, and height = (100 * 480 / 648) = 74
, x = 10
, and
y = (10 + ((100 - 74) / 2)) = 23
.
NO_SCALE | Constant |
public static const NO_SCALE:String = "noScale"
Language Version: | ActionScript 3.0 |
Product Version: | Flash CS3 |
Runtime Versions: | Flash Player 9.0.28.0, AIR 1.0 |
Specifies that the video be displayed at exactly the height and width of the source video.
For example, if registrationWidth = 100
and
registrationHeight = 100
, if registrationX = 200
and
registrationY = 200
, and if an FLV file is loaded with a width
of 648 and
a height
of 480 (for an approximate aspect ratio of 4:3), and if
align = VideoAlign.CENTER
and scaleMode = NO_SCALE
,
you end up with width = 648
, height = 480
, x = (200 +
((100 - 648) / 2)) = -74
, and y = (200 + ((100 - 480) / 2)) =
10
.
Thu Dec 6 2018, 01:12 PM -08:00