Class com.bumpslide.util.FramerateMonitor

com.bumpslide.util.FramerateMonitor

Description

Monitors actual framerate and dispatches it in an event every second Exampel Usage: FramerateMonitor.getInstance().addEventListener( FramerateMonitor.EVENT_FRAMERATE_UPDATE, Delegate.create(this, onFramerateUpdate) ); function onFramerateUpdate(e) { trace('fps: e.fps'); }

Field Index

addEventListener, dispatchEvent, display_mc, displayDelegate, EVENT_FRAMERATE_UPDATE, removeEventListener

Method Index

display(), getInstance(), hide(), onEnterFrame(), updateFrameRate()

Field Detail

display_mc

static display_mc:MovieClip

displayDelegate

static displayDelegate:Function

EVENT_FRAMERATE_UPDATE

static public EVENT_FRAMERATE_UPDATE

dispatchEvent

public dispatchEvent:Function

addEventListener

public addEventListener:Function

removeEventListener

public removeEventListener:Function

Method Detail

display

static public function display(host_clip:MovieClip, color:Number)

Displays an FPS counter in the top left corner of the stage

Parameters

host_clip

hide

static function hide()

Hides framerate monitor

getInstance

static public function getInstance():FramerateMonitor

onEnterFrame

function onEnterFrame()

updateFrameRate

function updateFrameRate()