22
Client-Side ActionScript Language Reference
this.onEnterFrame = function() {
motion_pb.setProgress(my_cam.activityLevel, 100);
};
/* When the level of activity goes above or below
the number defined in Camera.motionLevel,
trigger the onActivity event handler. */
my_cam.onActivity = function(isActive:Boolean) {
/* If isActive equals true, set the themeColor variable to "haloGreen".
Otherwise set the themeColor to "haloOrange".*/
var themeColor:String = (isActive) ? "haloGreen" : "haloOrange";
motion_pb.setStyle("themeColor", themeColor);
};
function changeMotionLevel() {
/* Set the motionLevel property for my_cam Camera
instance to the value of the NumericStepper
component instance. Maintain the current
motionTimeOut value of the my_cam Camera instance.*/
my_cam.setMotionLevel(motionLevel_nstep.value, my_cam.motionTimeOut);
}
motionLevel_nstep.addEventListener("change", changeMotionLevel);
See also
Camera.activityLevel
,
Camera.onActivity
,
Camera.onStatus
,
Camera.setMotionLevel()
Camera.motionTimeOut
Availability
■
Flash Player 6.
■
Flash Media Server (not required).
Usage
public
motionTimeOut : Number [read-only]
Description
Property (read-only); the number of milliseconds between the time the camera stops detecting
motion and the time
Camera.onActivity(false)
is invoked. The default value is 2000
(2 seconds).
To set this value, use
Camera.setMotionLevel()
.
Содержание FLASH MEDIA SERVER 2-CLIENT-SIDE ACTIONSCRIPT LANGUAGE REFERENCE FOR FLASH MEDIA SERVER...
Страница 1: ...Client Side ActionScript Language Reference for Flash Media Server 2...
Страница 4: ...4 Contents...
Страница 148: ...148 Client Side ActionScript Language Reference...