Home > Design, Programming > Mr. Doobs Harmony project ported to Flash AS3

Mr. Doobs Harmony project ported to Flash AS3

August 9th, 2011 Leave a comment Go to comments

Some time ago I ported the great Harmony drawing app by Mr. Doob to Max/Msp. This Max/Msp Version I used for my media installation "Sound drawings". During the development and testing with the musicians I was not so happy with my workflow. Furthermore I felt that the Max/Msp environment causes some certain useless obstacles for me. Especially for the visual part of my work. Now I have time to check how useful Flash can be as a renderer. The first step was to port the drawing functions to ActionScript. Here is the result:

Get Adobe Flash player

For drawing in full size mode please visit the html File. The code is available on my Google project site. Before using the code in your projects, please check the requirements of the GPL license Version 3 and read Mr. Doobs blog post about using his code. The API is still the same as the orginial JavaScript version. Every brush has to implement the IBrush Interface methods:

Brushes are very easy to use, but for performance issues you have to consider, that the drawing commands are expensive for the computer. I already ran into some performance problems after a few seconds. For this reason, I decided to store the drawing result of each frame into a BitmapData object. The Hype Framework is using the same approach. Here you can see the most important code lines for the bitmap storing approach...

Nothing more I can say. Have fun and keep on coding!

 

Categories: Design, Programming Tags: , ,
  1. Yop
    August 11th, 2011 at 14:21 | #1

    cool thx a lot 🙂

  1. August 16th, 2011 at 12:39 | #1