Show the Current Frames Per Second
Description: This box can be placed on your applets to show the actual frames per second (fps) your movie is running.
Author: John Bezanis
Added: April 18th 2007
Version: Flash 8
This applet demonstrates how load can cut down on frame rate. GlowFilter has been used because it is a resource hungry operation. The fps count will decrease when the glow size increases, indicating a higher cpu load. The fps counter is a good way to determine if your movies are too cpu intense for your system to handle at full framerate. To use the fps counter, simply copy the fps box in the main timeline and paste it into your applet. This applet will not be accurate if the FPS drops below 1. Commenting is included in the source file below.
Download the Source File
Comments
July 21st 2007 01:07PM - ivana ruseva
Great litte bit of code... Is there a more up to date way of doing this with AS3??
December 17th 2008 03:12PM - Office Chairs
could you possibly write below the flash how to code this FPS counter, this file keeps breaking flash for me which is annoying as I lost some work because of it, even more annoying because I lost the work for nothing as I caan't open this file.
thanks
thanks
May 15th 2009 03:05PM - me
I can't get it to work :( Anyone else having problems?
October 29th 2009 04:10AM - magnifying mirrors
Thanks for taking the time to discuss this, I feel strongly about it and love learning more on this topic. If possible, as you gain expertise, would you mind updating your blog with more information? It is extremely helpful and beneficial to your readers.
November 20th 2009 08:11AM - Torrent File
flash developers will love it.
Thanks.
Thanks.
December 6th 2009 01:12AM - seo
Thats incredible, and a useful visual aide. I can't wait to show this to the rest of my team.
December 8th 2009 10:12AM - Core Banking Solution
I have bookmarked your site. Thanks for sharing
December 13th 2009 08:12AM - dental
The neglect view is BitmapFilterQuality.LOW, which is equal to applying the filter once. The continuance BitmapFilterQuality.Substance applies the filter twice; the view BitmapFilterQuality.Piping applies it troika present. Filters with displace values are rendered more quickly.
For most applications, a grade see of low, matter, or overflowing is enough. Though you can use added numeric values up to 15 to achieve various effects, higher values are rendered many slowly. Instead of expanding the ideal of attribute, you can oft get a confusable essence, and with faster rendering, by but multiplicative the values of the blurX and blurY properties.
For most applications, a grade see of low, matter, or overflowing is enough. Though you can use added numeric values up to 15 to achieve various effects, higher values are rendered many slowly. Instead of expanding the ideal of attribute, you can oft get a confusable essence, and with faster rendering, by but multiplicative the values of the blurX and blurY properties.
December 15th 2009 07:12AM - sydney removalists
Cool stuff. FPS is the benchmark we all video game players live by.
December 17th 2009 03:12AM - Video games singles
Well, this is my first visit to your blog! But I admire time and effort you put into it, especially into interesting articles you share here!
December 22nd 2009 07:12AM - chat server software
Interesting article. Very useful. Thank you.
December 26th 2009 06:12AM - Website Templates
GlowFilter is great algorithm due to it the shining balls blinking very nicely.
December 27th 2009 11:12AM - drept
I can't get it to work :( Anyone else having problems?
January 1st 2010 09:01PM - Cialis
nice
January 4th 2010 01:01AM - cheap wedding dresses
Great work every buddy can get lots of interesting information, keep on posting this type of brilliant articles. I really like this keep it up again!
January 15th 2010 09:01PM - evening dresses
Showing current frames per second makes you think about the fact that colors are the backbone of any site.
January 20th 2010 08:01PM - Models Wanted
What is this cicles?
January 21st 2010 01:01PM - BMW Motorcycle show
great stuff what is it actually concerning
January 21st 2010 03:01PM - Cremation Urns
Special thank for good post.
February 5th 2010 08:02AM - โหลดเพลงà
Scociety appreciate your bring out! To <a href="http://www.essayslab.com">buy custom essay papers</a> or written essay about this topic will be enormous base of information!
February 5th 2010 06:02PM - KristingZ30
Thank
February 5th 2010 10:02PM - โหลดเพลงm
Special thank for good post.
February 10th 2010 03:02AM - โหลดเพลงà
Thanks for shearing such a chawal post. keep it up.
February 10th 2010 06:02AM - Road Trip
Special thank for good post.
February 10th 2010 08:02AM - โหลดเพลงà
This is the code
//initialize fps to 30
fps=20;
//initialize lasttime to the current time
var timeinit:Date = new Date;
var lasttime=timeinit.getMilliseconds();
onEnterFrame=function(){
var time:Date = new Date;
//on each frame, figure out how much time has passed by comparing the milliseconds of the last frame to
//the milliseconds of the current frame
timepassed=((time.getMilliseconds()-lasttime)>=0)?(time.getMilliseconds()-lasttime):(1000+(time.getMilliseconds()-lasttime));
//convert the time passed between frames to frames per second. Round it to the nearest tenth.
fps=Math.round(10000/timepassed)/10;
//set last time for the next frame.
lasttime=time.getMilliseconds();
}
put it in the first frame of the MC you want the counter in
and make a dynamic text with the variable fps
//initialize fps to 30
fps=20;
//initialize lasttime to the current time
var timeinit:Date = new Date;
var lasttime=timeinit.getMilliseconds();
onEnterFrame=function(){
var time:Date = new Date;
//on each frame, figure out how much time has passed by comparing the milliseconds of the last frame to
//the milliseconds of the current frame
timepassed=((time.getMilliseconds()-lasttime)>=0)?(time.getMilliseconds()-lasttime):(1000+(time.getMilliseconds()-lasttime));
//convert the time passed between frames to frames per second. Round it to the nearest tenth.
fps=Math.round(10000/timepassed)/10;
//set last time for the next frame.
lasttime=time.getMilliseconds();
}
put it in the first frame of the MC you want the counter in
and make a dynamic text with the variable fps
March 7th 2010 07:03PM - scuddle
Add a Comment






Please help me to put correctly the noscript tag in my site.Goggle cant read it. My e-mail is ivanna27@gmail.com
Thank you in advance