Devtools Addons: Framerate Monitor, Workspace

Rob Campbell

2

Last month at the All Hands meeting in Mountain View, we were lining up for tacos and Patrick Walton and I were chatting about some things. Specifically, about some of the interesting areas we could go with new developer tools.

The Framerate Monitor

“I think,” paraphrasing Patrick, “that it would be cool to have a tool to measure framerate in the browser.”

I said something like, “Hmm…” while looking at the increasingly deep line to get at the tacos.

“There’s no way to measure the performance of canvas animations… measuring framerates for games.”

“You should build that after we get a taco,” I suggested. Thinking it was a cool idea, but not really thinking it was possible to easily get the information from our various rendering systems.

About 3 weeks after that conversation, Patrick tweeted:

pcwalton
Wrote a simple framerate monitor for Firefox that displays a little graph: https://github.com/pcwalton/firefox-framerate-monitor
2011-01-04 22:43

Since then, he’s revved the version number a few times and added some basic profiling support that can stop the browser if the framerate drops below a certain threshhold. This, in short, is fantastic. It’s already been used to profile some hitching in the already impressive Flight of the Navigator demo. This has resulted in patches that further optimize our garbage collection and global cycle collector routines.

In short, it will make video and webgl better in Firefox 4. You can read the exciting analysis in bug 624549.

You can download and install the extension via the tweeted github link. We’ll get it up on AMO shortly.

Workspaces

My own holiday project was considerably less flashy, though it’s something I’ve wanted for quite some time.

Smalltalk has had the notion of a Workspace for decades and, as far as I know, it’s the first programming environment to really include these dynamic and simple code editors. Since then, they’ve been lifted into a number of different environments like Scheme and Eclipse, and applications like Mathematica. If you’ve used them before, you miss them in programming environments that don’t have them.

I’ve built a simple prototype that I’ve hosted on my blog. I’ve written about it here and here. Don’t get too attached to it though. In the grand Smalltalk tradition, we’re going to be throwing this one away and rebuilding it on top of the Add-on SDK.

I’m hoping we can distill it into a widget we can attach to all kinds of other pieces; object inspectors, consoles; if you can name it, you can execute JavaScript from it. We’re also talking about some experiments to see if we can macro-ize some of the functions we build up in these Workspaces and make their contents (and constructs) more persistable. Ultimately though, it’s all about writing and running code conveniently and I think we have to keep that in mind before we get too experimental with it.

Finally, if you want to help out, share ideas or report a bug, feel free to drop by and visit us in irc://irc.mozilla.org/#devtools.

– Rob Campbell, on behalf of the developer tools team

2 responses

  1. Pingback from Tweets that mention Devtools Addons: Framerate Monitor, Workspace « devtools -- Topsy.com on ::

    [...] This post was mentioned on Twitter by Christopher Blizzard, Kevin Dangoor. Kevin Dangoor said: @robcee has just posted on the Moz devtools blog about @pcwalton's framerate monitor and his own workspaces addon http://t.co/pz7SO4n [...]

  2. Pingback from Devtools Addons: Framerate Monitor, Workspace « devtools : : monitor on ::

    [...] Zobacz resztę artykułu: Devtools Addons: Framerate Monitor, Workspace « devtools [...]