<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:dc="http://purl.org/dc/elements/1.1/" version="2.0"><channel><atom:link rel="hub" href="http://tumblr.superfeedr.com/" xmlns:atom="http://www.w3.org/2005/Atom"/><description>A showcase of awesome JavaScript code that pushes the boundaries of what’s possible on the web.</description><title>Badass JavaScript</title><generator>Tumblr (3.0; @badassjs)</generator><link>http://badassjs.com/</link><item><title>The JSConf 2012 videos are being released!</title><description>&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m31mqmMk9u1qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;Well the title pretty much says it all, but I thought I&amp;#8217;d let everyone know that the JSConf 2012 videos are &lt;a href="http://2012.jsconf.us" target="_blank"&gt;beginning to be released&lt;/a&gt;.  JSConf is one of the premier JavaScript conferences that always sells out within a few seconds, so if you didn&amp;#8217;t make it this year, you&amp;#8217;re in luck because they always record the talks and release them for free after the event.  I wasn&amp;#8217;t there this year, but I heard excellent things about the talks and the rest of the event as well.  I&amp;#8217;m sure more videos will be released over the coming days and weeks so watch the &lt;a href="http://2012.jsconf.us" target="_blank"&gt;website&lt;/a&gt; and &lt;a href="http://twitter.com/jsconf" target="_blank"&gt;Twitter&lt;/a&gt; for details!&lt;/p&gt;
&lt;p&gt;&lt;iframe frameborder="0" height="346" src="http://blip.tv/play/g_MngvO9fwI.html?p=1" width="480"&gt;&lt;/iframe&gt;&lt;/p&gt;</description><link>http://badassjs.com/post/21787349913</link><guid>http://badassjs.com/post/21787349913</guid><pubDate>Wed, 25 Apr 2012 09:28:36 -0700</pubDate></item><item><title>WebKit.js: Yes it has finally happened! Browser Inception is now possible.</title><description>&lt;p&gt;I knew this was going to happen eventually, it was just a matter of time.  WebKit has been ported to JavaScript, and no, this is not just some Emscripten compile, it is a full hand port of the popular browser engine to JS.  &lt;a href="http://www.youtube.com/watch?v=dQw4w9WgXcQ&amp;amp;ob=av3e" target="_blank"&gt;WebKit.js&lt;/a&gt; uses WebGL as a rendering backend and basically enables developers to never worry about browser differences again since we can now control what browser our users are using on our site.  Of course, it includes fallback renderers in 2d canvas and by generating PNG images on the fly for older browsers as well.  The idea is a bit like Google Chrome Frame, except rather than a plugin that users need to install, it can be used by the developer to control the browsing environment of all users of a website - pretty neat.  With no more cross browser differences, no more different prefixes for each browser, no more worrying about old browsers, and no more testing in 17 different browsers, I think WebKit.js could perhaps be the future of the Internet.&lt;/p&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m1t8oaiPyn1qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;Of course, this has some standardistas on their soapboxes about why monoculture is bad for the web, but the ease of development that it enables for developers will probably win out in the long run.&lt;/p&gt;
&lt;p&gt;WebKit.js is a full browser engine with full support for everything in WebKit including HTML, CSS and even a full JavaScript engine - written in JavaScript of course.  Why do we need that?  The same reason why we need it for HTML and CSS - cross browser compatibility.  If the JavaScript engine is the same across all browsers, we won&amp;#8217;t need to worry about cross browser differences again.&lt;/p&gt;
&lt;p&gt;Of course, WebKit.js is fully &lt;a href="http://www.youtube.com/watch?v=dQw4w9WgXcQ&amp;amp;ob=av3e" target="_blank"&gt;opensource on Github&lt;/a&gt;, so you can go read its glorious 250,000 lines yourself.  And don&amp;#8217;t hesitate to start using it on all of your websites.  All you have to do is include a script tag at the top of your page and it will be rendered using WebKit.js instead of whatever browser the user visited your site with.  Enjoy!&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Update: &lt;/strong&gt;This was an April fools joke. Sorry if it got you. :)&lt;/p&gt;</description><link>http://badassjs.com/post/20294238453</link><guid>http://badassjs.com/post/20294238453</guid><pubDate>Sun, 01 Apr 2012 10:14:00 -0700</pubDate></item><item><title>SQL.js: SQLite Compiled to JavaScript via Emscripten</title><description>&lt;p&gt;Alon Zakai, the creator of &lt;a href="https://github.com/kripken/emscripten" target="_blank"&gt;Emscripten&lt;/a&gt; is back at it again, this time releasing &lt;a href="https://github.com/kripken/sql.js" target="_blank"&gt;SQL.js&lt;/a&gt;, which is a compilation of SQLite to JavaScript using his own tool.  The &lt;a href="http://syntensity.com/static/sql.html" target="_blank"&gt;demo page&lt;/a&gt; shows it in use, and if you view source, just how easy he&amp;#8217;s made it to use after it has been compiled.  &lt;/p&gt;
&lt;pre&gt;var db = SQL.open();
var data = db.exec(command);&lt;/pre&gt;
&lt;p&gt;You can run any SQL queries you can think of and it will work just like it does natively.  Pretty cool!  Perhaps he can even get it to work such that data is stored in IndexedDB, giving us a WebSQL polyfill at some point?  Anyway, I thought this was worth a quick mention!  Nice work.&lt;/p&gt;</description><link>http://badassjs.com/post/18857332551</link><guid>http://badassjs.com/post/18857332551</guid><pubDate>Tue, 06 Mar 2012 11:49:03 -0800</pubDate></item><item><title>First Look: Blossom - A SproutCore Spinoff Using Only HTML5 Canvas For Rendering</title><description>&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m09ls8ZvkQ1qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="http://sproutcore.com/" target="_blank"&gt;SproutCore&lt;/a&gt; has always been an interesting project.  It is the application framework behind Apple&amp;#8217;s impressive &lt;a href="http://icloud.com/" target="_blank"&gt;iCloud&lt;/a&gt; apps, and the MobileMe ones before that, as well as many other high profile projects.  The SproutCore view layer has gone through many revisions.  At one point it used Ruby templates combined with CSS, and then it switched to a JavaScript only system, which still used embedded HTML and CSS to layout and construct views.&lt;/p&gt;
&lt;p&gt;Erich Ocean, a SproutCore contributor since the early days, and others have been hard at work on a new fork of the SproutCore project called &lt;a href="https://github.com/fohr/blossom" target="_blank"&gt;Blossom&lt;/a&gt;, which reimagines the view layer without the use of any HTML or CSS.  How does it do this?  It renders the entire view structure of your application on a giant HTML5 canvas element.  Perhaps this seems crazy, but it has quite a few benefits over traditional HTML and CSS.&lt;/p&gt;
&lt;p&gt;Firstly, it abstracts all browser differences away at the lowest level and makes more complex views that were not possible or very difficult to create with HTML and CSS much more manageable.  Once this has been abstracted, building views on top of it can be much easier for both application developers as well as framework authors, leading to better, more maintainable applications.&lt;/p&gt;
&lt;p&gt;Secondly, it&amp;#8217;s fast.  Modifying the DOM is about the slowest thing you can do in the browser, and unfortunately it&amp;#8217;s probably the most common as well.  There are some performance issues with drawing everything to one huge canvas, so they have separate canvas contexts for each view that then get composited back together at the final step in rendering using drawImage.  This style is akin to the way Core Animation works in Apple&amp;#8217;s Cocoa framework, and in fact, GPU accelerated 3D transitions are possible in Blossom as well.&lt;/p&gt;
&lt;p&gt;Obviously, when not rendering to HTML and CSS, you have to manage everything yourself, from hit testing of views, to all the nuances of text handling including all the platform native keyboard shortcuts.&lt;/p&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m09la293Z51qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;This isn&amp;#8217;t the first time we&amp;#8217;ve seen an attempt to create an entirely canvas based view pipeline, but it certainly the most ambitious.  Back in 2009 when Dion Almaer and Ben Galbraith were working at Mozilla on the Bespin code editor (now Ace), they also started work on a framework they called &lt;a href="https://wiki.mozilla.org/Labs/Thunderhead/TheBook" target="_blank"&gt;Thunderhead&lt;/a&gt;, which worked like this.  Ultimately, they didn&amp;#8217;t get too far on it, so Blossom seems to be the next step in proving if this approach is viable.&lt;/p&gt;
&lt;p&gt;Of course, Blossom is a fork of the original SproutCore project, and so it brings over all the foundation frameworks that underly it including the famous support for bindings and observers that have now made the other more lightweight fork of SproutCore, &lt;a href="http://emberjs.com/" target="_blank"&gt;Ember.js&lt;/a&gt; popular as well.  It also contains the datastore frameworks as well as some new build tools written entirely in JavaScript using Node.js.&lt;/p&gt;
&lt;p&gt;The number one question people ask about creating applications in canvas is about accessibility.  Screen readers don&amp;#8217;t know what&amp;#8217;s going on within a canvas element, but luckily, the framework can take advantage of WAI ARIA by embedding a DOM subtree inside the canvas element specifically to enable this, however nothing is rendered via this DOM and it is invisible to the user.  I&amp;#8217;ve long thought that JavaScript needed an API to directly communicate with assistive technologies, and perhaps frameworks like this will shed light on a use case for that.&lt;/p&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m09m0jwWQU1qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;So how does this perform on mobile browsers?  Unfortunately, the answer is not so well, so mobile browsers are unsupported.  However, Blossom does have another strategy for mobile, which is to package up the applications as native iOS and Android apps.  This doesn&amp;#8217;t mean simply wrapping the application in a WebView and shipping.  For performance reasons, and since the canvas API is easily reproducible on these platforms, all rendering will use the native rendering pipeline on those platforms.  This is the result of not having any DOM to worry about, all you need is a JS engine, and seems like it could be pretty cool!&lt;/p&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m09nf0LRTN1qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;As for desktop browsers, Blossom will run on all modern browsers supporting the canvas element, which in practice means everything except IE8 and below.  IE9 is not currently working (IE10 is), but there is no reason why it couldn&amp;#8217;t in the future.&lt;/p&gt;
&lt;p&gt;SproutCore has turned into many things, and there are now at least 3 different frameworks based directly on it.  The original SproutCore 1.x line is still in use at Apple and many other places, but SproutCore 2.0, now Ember.js is perhaps gaining even more traction as a lightweight version of the framework with only the most powerful features baked in.  Blossom joins the party, staying much more heavyweight than say Ember, but also containing a lot more features and a powerful view layer for desktop-class applications in the browser - SproutCore&amp;#8217;s original goal.&lt;/p&gt;
&lt;p&gt;Blossom has just &lt;a href="https://gist.github.com/83ac249f80f3fbc12855" target="_blank"&gt;reached beta status&lt;/a&gt; and if you were a hardcore SproutCore 1.x developer you should definitely check it out.  There is also lots of cool code to read in the &lt;a href="https://github.com/fohr/blossom" target="_blank"&gt;Blossom repo&lt;/a&gt; on Github, and some demos to check out if you install it on your own machine.  A full release for end users is scheduled for May at JSConf.  There&amp;#8217;s lots of cool stuff coming down the pipeline for Blossom, including a &lt;a href="https://github.com/slightlyoff/cassowary-js-refactor" target="_blank"&gt;Cassowary constraint solver&lt;/a&gt; that will be useful for layout, so we&amp;#8217;ll be watching for sure!&lt;/p&gt;</description><link>http://badassjs.com/post/18610722419</link><guid>http://badassjs.com/post/18610722419</guid><pubDate>Fri, 02 Mar 2012 09:10:51 -0800</pubDate></item><item><title>CoffeePhysics: A Fast New Physics Engine Written in CoffeeScript</title><description>&lt;p&gt;Justin Windle has just released a new physics engine called CoffeePhysics, which as it&amp;#8217;s name states, is written in CoffeeScript.  It is quite lightweight (minified, it&amp;#8217;s just 8KB), but also very powerful.&lt;/p&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m05ymp3GtK1qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;There are a &lt;a href="http://soulwire.co.uk/coffeephysics/" target="_blank"&gt;number of demos&lt;/a&gt; that show the performance and features of the library, including attraction, collision, cloth simulation, a balloon of balls around your mouse, and a chain following the mouse.  I&amp;#8217;m getting around 60 frames per second or more in most of the demos in Firefox and Chrome, which is pretty darn impressive.&lt;/p&gt;
&lt;p&gt;The &lt;a href="https://github.com/soulwire/Coffee-Physics" target="_blank"&gt;source code&lt;/a&gt; is very readable, as CoffeeScript often is, and seems very modular and well architected.  There are multiple renderers available as well, the most important of these being WebGL, but there is also a canvas 2d renderer as a fallback, and perhaps a DOM renderer in the works (for really old IE?).  It sounds like 3D support is in the works as well.  In the demos posted online, only the WebGL renderer is used, so make sure you check those out in Chrome or Firefox (it does not appear to work in Safari).  The demo source code is all in the repo, so make sure to check that out as well!&lt;/p&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m05z79Qizl1qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;I reached out to Justin earlier this morning and asked a few quick questions.  Here are his responses:&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Did you have any particular reason for building CoffeePhysics, or was it just for fun?&lt;/strong&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;I was working on some visual demos of genetic algorithms for my presentation at FITC Amsterdam and found myself writing the same simple particle / spring physics over and over, so decided that abstracting it out to an engine would be a good idea. I&amp;#8217;ve been keeping an eye on CoffeeScript for some time now and had actually started using it to build the slide engine for the presentation. It felt like a good fit for the physics engine, mainly because of the ease with which I could implement classes and inheritance; allowing me to give the engine a more formal structure which would come in handy when extending the core functionality though new integrators, renderers and particle behaviours.&lt;/p&gt;
&lt;p&gt;I&amp;#8217;ve wanted a simple physics engine for JavaScript for some time. With a basic point-mass and spring system, it&amp;#8217;s possible to create a lot of different effects, all without the need for more complex, processor intensive features. I plan on extending the engine to 3D (it was designed with this in mind since all the math is done with vector operations and so swapping out the 2d vector class for a 3d one will be almost all that&amp;#8217;s required at first). I&amp;#8217;ll also work on performance (particularly in collision detection) and a more extensive library of particle behaviours, but the main philosophy was simplicity of use and a clean, intuitive API, so keeping it lean and nimble will remain the focus.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;strong&gt;What was the most fun/challenging part of building the library or related demos?&lt;/strong&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Designing the structure of the engine was the most interesting challenge. I&amp;#8217;d worked out most of the math required in previous experiments, so in this respect it was simply a matter of combining those techniques. The API and code structure on the other hand was something I wanted to focus on keeping clean, modular and easy to understand. CoffeeScript helped with this, since (much like writing Python) the syntax feels to me almost like writing pseudo-code - I can &amp;#8216;sketch&amp;#8217; out the class structures, logic and interfaces and then very little is required after that to actually have working code.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;strong&gt;How was your experience with performance? What challenges did you face in getting CoffeePhysics or its demos to run fast?&lt;/strong&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;I released it perhaps too early - I wanted to demo it at FITC and so what&amp;#8217;s out there now only amounts to the first draft. Therefore, performance hasn&amp;#8217;t yet been a huge priority; instead as I mentioned I wanted to create a stable, easy to use and simple engine first then worry about optimisations later. Currently there are a number of issues across browsers and for practical purposes during the (very quick) first development cycle I&amp;#8217;ve only been targeting and testing with Chrome.&lt;/p&gt;
&lt;p&gt;The physics though is generally very fast to calculate, especially in JavaScript engines like V8. Rendering is always the significant bottleneck and so I quickly moved from canvas to a simple WebGL renderer (with a canvas fallback). This is why (in Chrome at least) the demos run at a solid 60fps. The engine is also a fixed time step engine, meaning that it&amp;#8217;s accurate even if some frames are dropped, so unless there&amp;#8217;s a huge lag (something I&amp;#8217;m working to eradicate in some browsers) then the simulations will run smoothly and the interactions will feel responsive.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;strong&gt;There is a lot of controversy around CoffeeScript in the JS community.  How was your experience with it?&lt;/strong&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;I think that CoffeeScript does some important key things very well. Coding is fun and quick, which to me is very important. As I mentioned, easy classes with inheritance are great to have and the compiler is fast enough to make this intermediate step almost unnoticeable. The aspect I like the most though, is the ability to dive in and start writing logic without having to worry about some of those little JavaScript quirks we all code around on a daily basis. The less time between thought and working code, the easier it is to be creative and expressive; something which to me programming is largely about.&lt;/p&gt;
&lt;p&gt;I understand the reservations people have and I&amp;#8217;ve certainly come across aspects of the language I would like to be different, but when you consider the time and effort that goes into making JavaScript behave sometimes, I&amp;#8217;d happily trade that for ease and pleasure of use, in the right circumstances of course.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;strong&gt;Anything else you think we should know?&lt;/strong&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;CoffeePhysics is a personal project I decided to release somewhat prematurely and so is not yet in the state I want it to be in for version 1. That said, the whole point of opening it up to the community is to get early feedback and have help with tracking down issues, so I&amp;#8217;m not worried about it being unfit for immediate use. I&amp;#8217;m also keen to stress that it isn&amp;#8217;t intended to be a full blown engine. I&amp;#8217;ll be interested to see what I (and hopefully others) can eventually do with it, but my intention is to focus on doing a few basic things well, keeping it fun and easy to use and exchanging features for speed and usability.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Nice work, Justin! Now, go &lt;a href="https://github.com/soulwire/Coffee-Physics" target="_blank"&gt;check it out&lt;/a&gt; on Github, and play with the &lt;a href="http://soulwire.co.uk/coffeephysics/" target="_blank"&gt;demos&lt;/a&gt;!&lt;/p&gt;</description><link>http://badassjs.com/post/18503583619</link><guid>http://badassjs.com/post/18503583619</guid><pubDate>Wed, 29 Feb 2012 11:15:00 -0800</pubDate><category>webgl</category></item><item><title>Badass JavaScript Roundup #8: Mobile, mobile, mobile!</title><description>&lt;p&gt;Welcome back to the Badass JavaScript roundup series.  Been busy recently, so sorry about the lack of posts.  Let&amp;#8217;s jump right in!&lt;/p&gt;
&lt;ol&gt;&lt;li&gt;PhoneGap has become an Apache incubator project called &lt;a href="http://incubator.apache.org/cordova/" target="_blank"&gt;Cordova&lt;/a&gt;, with a nice website and everything.  Be sure to check that out if you&amp;#8217;re into developing mobile web apps.&lt;/li&gt;
&lt;li&gt;&lt;a href="http://towerjs.org/" target="_blank"&gt;Tower.js&lt;/a&gt; is an interesting take on frameworks for Node.js, and in fact looks almost exactly like Rails, but in CoffeeScript.  It is a full stack framework too, so it works on both the client and server sides.&lt;/li&gt;
&lt;li&gt;iPhone app Clear came out a few weeks ago, and it is a beautifully minimal todo list app.  Someone has taken a few days to port the entire thing &lt;a href="http://vimeo.com/37182785" target="_blank"&gt;to HTML5&lt;/a&gt;, and it is pretty impressive how realistic it is compared to the original.  Smooth touch gestures and everything!  &lt;a href="http://clear.youyuxi.com/" target="_blank"&gt;Try it here&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Microsoft, Google and Netflix have proposed an HTML5 video extension which would allow for a DRM of sorts for web video.  Of course, there has been a lot of backlash from the fans of the &amp;#8220;everything open&amp;#8221; nature of the web platform so far, but in my opinion something in this space will be necessary if we want big companies like Netflix and Hulu to switch to HTML5 from Flash.  You can read the &lt;a href="http://dvcs.w3.org/hg/html-media/raw-file/tip/encrypted-media/encrypted-media.html" target="_blank"&gt;proposal here&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;If you&amp;#8217;re using Amazon&amp;#8217;s DynamoDB service with Node.js, you&amp;#8217;ll want to check out &lt;a href="https://github.com/jed/dynamo" target="_blank"&gt;this module&lt;/a&gt; from Jed Schmidt which has a pretty nice API for it.&lt;/li&gt;
&lt;li&gt;Someone has &lt;a href="https://github.com/ttezel/anchor" target="_blank"&gt;implemented&lt;/a&gt; the rsync algorithm in JavaScript for Node.js.&lt;/li&gt;
&lt;li&gt;&lt;a href="http://groups.google.com/group/socket_io/browse_thread/thread/6e759a508b231b4?pli=1" target="_blank"&gt;Socket.io 0.9&lt;/a&gt; was released.&lt;/li&gt;
&lt;li&gt;Mathias Bynens has &lt;a href="http://mathiasbynens.be/notes/javascript-identifiers" target="_blank"&gt;written&lt;/a&gt; about what constitutes a valid variable name in JavaScript.  It turns out that &lt;code&gt; var π = Math.PI;&lt;/code&gt; is valid JavaScript!&lt;/li&gt;
&lt;li&gt;&lt;a href="http://humblesoftware.github.com/js-imagediff/" target="_blank"&gt;JS-Imagediff&lt;/a&gt; is a neat utility for diffing images written in JavaScript.&lt;/li&gt;
&lt;li&gt;And finally, this morning we had a ton of updates on Mozilla&amp;#8217;s &lt;a href="http://www.mozilla.org/en-US/b2g/" target="_blank"&gt;Boot2Gecko project&lt;/a&gt;, which aims to build an entire phone operating system using only web technologies, the Gecko rendering engine from Firefox, and a small linux kernel.  They have a &lt;a href="http://arstechnica.com/gadgets/news/2012/02/telefonica-working-with-mozilla-to-build-open-web-centric-smartphone.ars" target="_blank"&gt;partner in Teleónica&lt;/a&gt; and the &lt;a href="http://www.theverge.com/2012/2/27/2827659/mozillas-boot-to-gecko-project-the-internet-is-your-phone-hands-on" target="_blank"&gt;screenshots&lt;/a&gt; of the OS on actual devices show that it is starting to look pretty good!  Finally, check out the &lt;a href="http://hacks.mozilla.org/2012/02/mozillas-boot-to-gecko-the-web-is-the-platform/" target="_blank"&gt;Moz Hacks post&lt;/a&gt; for more developer-y info on B2G and a video demo.&lt;/li&gt;
&lt;/ol&gt;&lt;p class="center"&gt;&lt;img src="http://media.tumblr.com/tumblr_m02am5davR1qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;That&amp;#8217;s all for this time.  If you have something I missed, or something you think Badass JS should be covering, please don&amp;#8217;t hesitate to &lt;a href="http://badassjs.com/submit" target="_blank"&gt;let us know&lt;/a&gt;.  Have a good week!&lt;/p&gt;
&lt;ol&gt;&lt;/ol&gt;</description><link>http://badassjs.com/post/18384189844</link><guid>http://badassjs.com/post/18384189844</guid><pubDate>Mon, 27 Feb 2012 09:17:39 -0800</pubDate></item><item><title>Looking to move from Flash to WebGL? IvanK brings the Flash API to JavaScript</title><description>&lt;p&gt;Ivan Kuckir sent in a &lt;a href="http://lib.ivank.net/index.php" target="_blank"&gt;neat library&lt;/a&gt; to help Flash developers move to JavaScript.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;I have made a graphics library to help people move from Flash to Javascript.  It is something like &lt;a href="http://easeljs.com/" target="_blank"&gt;EaselJS&lt;/a&gt;, but unlike EaselJS, all the classes, methods and properties come from Flash and unlike EaselJS, it uses WebGL (GPU) for drawing graphics (it is fast). &lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;As he says, the API is heavily based on Flash so it will be very familiar to Flash developers.  The library supports many common things, including a scene graph for mouse events over individual elements (not possible with plain WebGL without lots of work), text rendering, images, vectors and more.  It&amp;#8217;s all 2d at the moment but rendered on WebGL for speed.  Perhaps it needs a 2d canvas fallback for IE9 though&amp;#8230;  The library touts its speed and mobile device support - things most Flash based apps can&amp;#8217;t.&lt;/p&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_lzcj7wRDI41qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;There are some &lt;a href="http://lib.ivank.net/index.php?p=demos" target="_blank"&gt;library demos&lt;/a&gt;, but Ivan has gone even farther and made &lt;a href="http://lib.ivank.net/index.php?p=projects" target="_blank"&gt;two fun games&lt;/a&gt; with it that certainly show the library&amp;#8217;s power and performance.  The first is &amp;#8220;&lt;a href="http://crazybugs.ivank.net/" target="_blank"&gt;Crazy Bugs&lt;/a&gt;&amp;#8221;, and it is a game where you must move a virtual net around to prevent the bugs from crossing paths.  The second is called &amp;#8220;&lt;a href="http://bigfish.ivank.net/" target="_blank"&gt;Big Fish&lt;/a&gt;&amp;#8221; and in this game you are a fish and you have to eat the smaller fish and avoid the bigger fish.  Both are worth a play!&lt;/p&gt;
&lt;p&gt;While the library is heavily based on Flash and he says Flash developers will have no trouble picking it up, it does have &lt;a href="http://lib.ivank.net/index.php?p=documentation" target="_blank"&gt;some documentation&lt;/a&gt; of its own for you to get started, and of course the &lt;a href="http://lib.ivank.net/index.php?p=demos" target="_blank"&gt;demo source code&lt;/a&gt;.  If you&amp;#8217;re a Flash developer looking to move to HTML5, this library is certainly worth a look!&lt;/p&gt;</description><link>http://badassjs.com/post/17561830502</link><guid>http://badassjs.com/post/17561830502</guid><pubDate>Mon, 13 Feb 2012 11:39:16 -0800</pubDate></item><item><title>WebM and WebP Hand Ported to JavaScript for All Browsers</title><description>&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_lz1cslKy0d1qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;Dominik Homberger has been very busy over the last few months working on porting first, Google&amp;#8217;s WebP image format to JS and today launching his WebM video decoder in JavaScript.  No, these are not Emscripten compiled versions - these are hand ports directly from the original C++ source code.  And yes, both of these ports work in all browsers, not just the latest Chrome and Firefox - all browsers.  The WebP port works in IE6+ with a flash fallback for the canvas element, as well as, of course, Chrome, Firefox, Safari and Opera and the mobile browsers on Android and iOS.  The WebM video port works in IE9+, as well as all the other browsers mentioned before including the mobile ones.  That is seriously impressive!&lt;/p&gt;
&lt;h2&gt;WebP Decoding and Encoding in JavaScript&lt;/h2&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_lz1ctwTVEO1qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;Let&amp;#8217;s first discuss the WebP image port to JavaScript.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;a href="http://code.google.com/speed/webp/" target="_blank"&gt;WebP&lt;/a&gt; is a new image format that provides lossless and lossy compression for images on the web. WebP lossless images are 28% smaller in size compared to PNGs. WebP lossy images are 25-34% smaller in size compared to JPEG images at equivalent SSIM index.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;Unfortunately, at the moment the only browser providing native support for WebP is Google&amp;#8217;s own Chrome, so if one wants to use WebP encoded images on the web they either have to encode PNGs or JPEGs as well, or use a library like &lt;a href="http://webpjs.appspot.com/" target="_blank"&gt;WebPJS&lt;/a&gt; to fill the gaps in browser support.  All one has to do to enable WebP support in all browsers is include WebPJS, and it takes care of replacing all the WebP images on the page with decoded equivalents on the fly.&lt;/p&gt;
&lt;p&gt;Dominik told me that he didn&amp;#8217;t know about Emscripten, the LLVM to JavaScript compiler at the time he started working on the project, so it is all hand ported, but that at one point he did try it just to see how it compared.  He told me that the Emscripten version was actually much slower than he expected, as well as being 600KB in size.  By comparison, the hand ported version is just 67KB minified, 27KB gzipped.&lt;/p&gt;
&lt;p&gt;If you want to use the decoder in a more direct fashion rather than automatically replacing your images, you can check out the library behind it called &lt;a href="http://libwebpjs.hohenlimburg.org/" target="_blank"&gt;LibWebPJS&lt;/a&gt;, which has a nice JavaScript API to the decoder.  He has also ported the encoder to JavaScript as well, so you can encode a WebP image from a PNG or JPEG, as well as support for the &lt;a href="http://libwebpjs.hohenlimburg.org/webp-experiment/lossless/libwebp-javascript-lossless-decoder.html" target="_blank"&gt;lossless version&lt;/a&gt; of WebP.&lt;/p&gt;
&lt;h2&gt;WebM Decoding in JS&lt;/h2&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_lz1efrCjlf1qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;Wow, that&amp;#8217;s a lot, but not enough it seems!  He also ported the &lt;a href="http://www.webmproject.org/" target="_blank"&gt;WebM&lt;/a&gt; video format to JS.  WebM is a bit more popular than WebP so far (it is also older), and is already supported natively in Chrome, Firefox, and Opera.  Dominik&amp;#8217;s &lt;a href="http://libwebpjs.hohenlimburg.org/vp8/webm-javascript-decoder/" target="_blank"&gt;WebM port to JavaScript&lt;/a&gt; works in all modern browsers including IE9+ and mobile browsers, however your results in terms of actual framerate may vary across browsers and platforms.  I get about 10fps in Safari and about 25-30 in Chrome and Firefox Aurora, so not too shabby for a first pass.  On my iPhone 4S by comparison, while the video does play, I get about 1 frame per second, so certainly room for improvement there, but who expected it to even work at all?&lt;/p&gt;
&lt;p&gt;We&amp;#8217;ve seen &lt;a href="https://github.com/mbebenita/Broadway" target="_blank"&gt;H.264&lt;/a&gt; and &lt;a href="https://github.com/bemasc/Broadway/tree/master/vp8" target="_blank"&gt;WebM&lt;/a&gt; playing in JavaScript before, but never hand ported - always Emscripten ports - and never working in all browsers.  This is seriously impressive stuff! There is still some work to be done in terms of performance on some browsers, but the proof of concept is here.  I can&amp;#8217;t wait to see what comes next!&lt;/p&gt;</description><link>http://badassjs.com/post/17218459521</link><guid>http://badassjs.com/post/17218459521</guid><pubDate>Tue, 07 Feb 2012 11:07:45 -0800</pubDate></item><item><title>JS1k is back! Awesome JavaScript demos in only 1KB</title><description>&lt;p&gt;I always enjoy watching &lt;a href="http://js1k.com/2012-love/" target="_blank"&gt;JS1k&lt;/a&gt;, which, if you haven&amp;#8217;t heard of it, is a JavaScript competition to make the best demo in under 1KB of code.  It has been running for a few years now, and every time, it gets better and better with cooler demos, more judges and of course better prizes.  This time, the theme of the contest is about love given that Valentines day is coming up soon, and we&amp;#8217;ve already got some pretty neat demos.  Here are my favorites so far.  You can expect us to post about more as they come in!&lt;/p&gt;
&lt;h2&gt;1K Procedural Rose&lt;/h2&gt;
&lt;p&gt;&lt;a href="http://js1k.com/2012-love/demo/1022" target="_blank"&gt;&lt;img src="http://media.tumblr.com/tumblr_lyzcw6U4bZ1qbis4g.jpg"/&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Román Cortés does it again, this time with a &lt;a href="http://js1k.com/2012-love/demo/1022" target="_blank"&gt;procedural rose rendering&lt;/a&gt; in just 1018 bytes.    Another of my favorite things about JS1k is all the learning and sharing that goes on.  Román has written a &lt;a href="http://www.romancortes.com/blog/1k-rose/" target="_blank"&gt;fantastic blog post&lt;/a&gt; about how he made the rose, including all the rendering techniques and more.  Definitely a must read!&lt;/p&gt;
&lt;h2&gt;Campsite Firefighter&lt;/h2&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_lyzdayRnAF1qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;Paul Milham made a &lt;a href="http://js1k.com/2012-love/demo/1004" target="_blank"&gt;neat demo&lt;/a&gt; that renders a fire with particles on a canvas, and if you mash the keyboard, you can pee on the fire to put it out.  Be careful where you aim though, as how much you mash controls how fast it comes out. :)&lt;/p&gt;
&lt;h2&gt;Tunnel of Love&lt;/h2&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_lyzdkuOXcR1qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;Alexander Prinzhorn brings us a nice demo showing a &lt;a href="http://js1k.com/2012-love/demo/1016" target="_blank"&gt;tunnel of love&lt;/a&gt; in just 535 bytes.  That&amp;#8217;s all there is to it!&lt;/p&gt;
&lt;h2&gt;&lt;strong&gt;Modern Art Generator&lt;/strong&gt;&lt;/h2&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_lyzdmqY5mV1qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;Clocking in at just 735 bytes, this is a procedural &lt;a href="http://js1k.com/2012-love/demo/1023" target="_blank"&gt;modern art generator&lt;/a&gt; for the canvas element.  Very neat!&lt;/p&gt;
&lt;h2&gt;Hidden Love&lt;/h2&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_lyze11vZzC1qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;Manel Villar made a &lt;a href="http://js1k.com/2012-love/demo/1025" target="_blank"&gt;neat demo&lt;/a&gt; that reveals a message as you move your mouse over it in 1017 bytes.  Can you read it?&lt;/p&gt;
&lt;h2&gt;The Love Helix&lt;/h2&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_lyze5ogEgQ1qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;Chris Heilmann submitted &lt;a href="http://js1k.com/2012-love/demo/1031" target="_blank"&gt;the love helix&lt;/a&gt; in just 459 bytes.  I could watch this all day!&lt;/p&gt;
&lt;p&gt;It is amazing to see what can be done in such a small amount of code.  I just love the creativity everyone brings to their demos!  We&amp;#8217;ve seen some great ones so far, and I can&amp;#8217;t wait to see more submissions as they come in.  Don&amp;#8217;t forget to check out the &lt;a href="http://js1k.com/2012-love/demos" target="_blank"&gt;whole list of demos&lt;/a&gt; on the JS1k website, and to &lt;a href="http://js1k.com/2012-love/submit" target="_blank"&gt;submit your own&lt;/a&gt; if you feel so called.  Enjoy!&lt;/p&gt;</description><link>http://badassjs.com/post/17158410075</link><guid>http://badassjs.com/post/17158410075</guid><pubDate>Mon, 06 Feb 2012 09:13:30 -0800</pubDate></item><item><title>Weekly Badass JS Roundup #7</title><description>&lt;p&gt;Welcome back to the weekly Badass JS roundup!  As always, there is lots of JavaScript news this week, so lets dive in.&lt;/p&gt;
&lt;ol&gt;&lt;li&gt;Ehsan Akhgari has a &lt;a href="http://ehsanakhgari.org/blog/2012-01-25/porting-opengl-application-web" target="_blank"&gt;neat blog post&lt;/a&gt; on automatically converting a native OpenGL application to run on the web via WebGL using Emscripten.&lt;/li&gt;
&lt;li&gt;&lt;a href="http://maxtaco.github.com/coffee-script/#iced" target="_blank"&gt;Iced CoffeeScript&lt;/a&gt; is a fork of CoffeeScript that brings two new keywords to the language: await and defer, which make asynchronous programming much easier.  It is certainly a neat idea, although it has yet to prove itself in practice!&lt;/li&gt;
&lt;li&gt;The prolific LearnBoost team has released two new modules for Node, &lt;a href="https://github.com/learnboost/up" target="_blank"&gt;up&lt;/a&gt; and &lt;a href="https://github.com/learnboost/distribute" target="_blank"&gt;distribute&lt;/a&gt; which make it possible to perform zero-downtime code updates in Node.js which is nice in development as well because it is annoying to have to start and restart your server all the time.  There&amp;#8217;s a &lt;a href="http://www.devthought.com/2012/01/29/staying-up-with-node-js/" target="_blank"&gt;blog post&lt;/a&gt; going into much more detail about it too.&lt;/li&gt;
&lt;li&gt;Jens Nockert is continuing his WebCL work, this time with a &lt;a href="https://github.com/JensNockert/hydra" target="_blank"&gt;JS library&lt;/a&gt; that bridges the gaps between the various WebCL prototypes that vendors have made.&lt;/li&gt;
&lt;li&gt;Jed Schmidt has released a &lt;a href="https://github.com/jed/dynamo" target="_blank"&gt;Amazon DynamoDB binding&lt;/a&gt; for Node.js that looks pretty nice.&lt;/li&gt;
&lt;li&gt;The 140bytes contest continues, this time with a &lt;a href="https://gist.github.com/1672254" target="_blank"&gt;version of Tetris&lt;/a&gt; in less than 140 bytes.  Wow!&lt;/li&gt;
&lt;li&gt;In case you&amp;#8217;ve ever wanted a workaround for the lack of tail call optimization in JavaScript, &lt;a href="https://gist.github.com/1697037" target="_blank"&gt;here you go&lt;/a&gt;!&lt;/li&gt;
&lt;li&gt;&lt;a href="http://backbonejs.org/#changelog" target="_blank"&gt;Backbone.js 0.9&lt;/a&gt; has been released and Jeremy says it should be considered a preview for 1.0!&lt;/li&gt;
&lt;li&gt;Twitter&amp;#8217;s Bootstrap library has been upgraded to 2.0 and it is just packed with awesome stuff. Go &lt;a href="http://twitter.github.com/bootstrap/" target="_blank"&gt;check it out!&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;If you missed it, Ryan Dahl has &lt;a href="http://groups.google.com/group/nodejs/browse_thread/thread/85f6a3829bc64cb6?pli=1" target="_blank"&gt;released the reigns&lt;/a&gt; of gatekeeper of the Node.js project to Isaac Schleuter, author of NPM so he can focus on research more.  He will still be involved with the project of course, just not in the day-to-day of deciding what goes into each release.&lt;/li&gt;
&lt;li&gt;Not sure if this is new, but Joseph Gentle who was an engineer on the Google Wave team has released &lt;a href="http://sharejs.org/" target="_blank"&gt;ShareJS&lt;/a&gt; which is an implementation of the Operational Transform algorithms for Node and the browser allowing one to make collaborative realtime editable applications.  The example shows how you could build an Etherpad clone in just 4 lines of code!   Of course, you can find the &lt;a href="https://github.com/josephg/ShareJS" target="_blank"&gt;source on Github&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;Firefox 10 now has some pretty awesome looking developer tools built right in.  Check out &lt;a href="http://functionsource.com/post/firefox-developer-tools-biggest-upgrade-since-firebug" target="_blank"&gt;this video&lt;/a&gt; for a nice walkthrough!&lt;/li&gt;
&lt;/ol&gt;&lt;p&gt;That&amp;#8217;s all for this week!  Did I miss something?  Did you make or find something that is Badass JS worthy?  Don&amp;#8217;t hesitate to &lt;a href="http://badassjs.com/submit" target="_blank"&gt;submit it&lt;/a&gt;.  I promise to read them all.  Have a nice week!&lt;/p&gt;</description><link>http://badassjs.com/post/16869678081</link><guid>http://badassjs.com/post/16869678081</guid><pubDate>Wed, 01 Feb 2012 09:30:00 -0800</pubDate></item><item><title>psd.js: You Guessed It - A Photoshop Document Parser in CoffeeScript</title><description>&lt;p&gt;Ryan LeFevre has been working on &lt;a href="http://meltingice.github.com/psd.js/" target="_blank"&gt;psd.js&lt;/a&gt;, which is as you might have already guessed, is a Photoshop Document parser that works in both the browser and Node.js.&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;psd.js is a general purpose file parser for PSD files created in Photoshop. Given a PSD file, it can parse out information such as image size and color modes, image resources, layer info, image contents, etc.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;&lt;img align="left" height="130" src="http://media.tumblr.com/tumblr_lyo6fxGkQp1qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;It is written in CoffeeScript and can currently be used to pull out all sorts of information from the file, such as its header, all of the embedded image resources, the structure of layers and groups in the file, layer masks and more.  It is early days for the project (only a few days old it appears), but it already has an impressive demo showing the ability to parse many PSDs, although there were a few that I tried that did not work.&lt;/p&gt;
&lt;p&gt;When you drop a PSD file onto the &lt;a href="http://meltingice.github.com/psd.js/" target="_blank"&gt;demo page&lt;/a&gt; (which mean&amp;#8217;s you&amp;#8217;ll need Chrome or Firefox), the structure of the entire PSD file is printed on the right. Here is an example of psd.js in use:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;{PSD} = require 'psd.js'
 
psd = PSD.fromFile './path/to/file.psd'
psd.parse()
 
for layer in psd.layerMask.layers
  console.log "Layer: #{layer.name}"
  console.log "Size: width=#{layer.cols}, height=#{layer.rows}"
  console.log "Position: top=#{layer.top}, left=#{layer.left}"&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;The goal of the project is to eventually be able to render the PSD to a canvas element, but that may be a little ways off since PSDs can have all sorts of layer effects, filters, and other complex things that one would need to implement.  For now, it is just a parser for you to get information about the structure of the PSD out, but I can&amp;#8217;t wait to be able to render the PSD directly in the browser and even perhaps get to turn on an off layers and maybe one day even perform Photoshop-like editing directly in the browser.&lt;/p&gt;
&lt;p&gt;No one likes Photoshop (am I wrong?) as it it crashy and bug-ridden, but there are so many existing Photoshop files out there that whatever the photo editor of the future is will need to support the format.  If that editor happens to be in the browser, it looks like psd.js will be there to help!&lt;/p&gt;
&lt;p&gt;As always, you can check out the &lt;a href="http://meltingice.github.com/psd.js/" target="_blank"&gt;demo here&lt;/a&gt;, and the &lt;a href="https://github.com/meltingice/psd.js" target="_blank"&gt;code on Github&lt;/a&gt;!&lt;/p&gt;
&lt;p&gt;&lt;img height="0" src="http://assets.tumblr.com/images/input_bg.gif" width="0"/&gt;&lt;/p&gt;</description><link>http://badassjs.com/post/16822405598</link><guid>http://badassjs.com/post/16822405598</guid><pubDate>Tue, 31 Jan 2012 08:38:42 -0800</pubDate></item><item><title>Morning Star: An Impressive Audio Synth in JavaScript</title><description>&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_lymd99z2KT1qbis4g.png"/&gt;&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;&lt;a href="http://bitterspring.net/ms/morningstar/" target="_blank"&gt;Morning Star&lt;/a&gt; is a monophonic bassline synthesizer controlled by a step sequencer, designed to run on Web browsers and made entirely with HTML5 and JavaScript (no Flash).&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;It uses Mozilla&amp;#8217;s Audio Data API, and Google&amp;#8217;s competing Web Audio API to produce sound in real time abstracting them with a library called &lt;a href="http://kievII.net/" target="_blank"&gt;KievII&lt;/a&gt;, which is a library containing both an audio DSP as well as various GUI elements that one might need in various audio applications.  These elements include knobs, sliders and more all build with HTML5 canvas as a rendering engine.&lt;/p&gt;
&lt;p&gt;The synth itself has many features including a step editor, piano roll, pattern control, recoding and playback, various effects and more.  Your changes automatically get saved into localStorage as you&amp;#8217;re editing so if you close your browser and reopen it your work will be just as you left it.  You can even export a URL to your song to share and collaborate with friends.&lt;/p&gt;
&lt;p&gt;Another interesting thing to note is that the &lt;em&gt;entire&lt;/em&gt; UI is a single canvas element, which is an interesting choice and certainly a good experiment.  Obviously there are accessibility problems with this approach since screen readers and other assistive technologies know nothing about what is in a canvas element, but otherwise it seems to perform pretty well.&lt;/p&gt;
&lt;p&gt;As usual, the source code for Morning Star is &lt;a href="https://github.com/janesconference/MorningStar" target="_blank"&gt;available on Github&lt;/a&gt;, there is a &lt;a href="http://bitterspring.net/blog/2012/01/25/morning-star-synth-0-1-released/" target="_blank"&gt;blog post&lt;/a&gt; that goes into great detail about each feature of the synthesizer, and if you haven&amp;#8217;t already, check out the &lt;a href="http://bitterspring.net/ms/morningstar/" target="_blank"&gt;demo&lt;/a&gt;.  Happy Monday!&lt;/p&gt;</description><link>http://badassjs.com/post/16764713909</link><guid>http://badassjs.com/post/16764713909</guid><pubDate>Mon, 30 Jan 2012 08:54:46 -0800</pubDate></item><item><title>Seriously.js: A Realtime, Node-Based Video Compositor for the Web</title><description>&lt;p&gt;We &lt;a href="http://badassjs.com/post/16472398856/photobooth-style-live-video-effects-in-javascript-and" target="_blank"&gt;covered a demo&lt;/a&gt; earlier this week showing real time video processing with WebGL, but &lt;a href="https://github.com/brianchirls/Seriously.js/tree/develop" target="_blank"&gt;Seriously.js&lt;/a&gt; taking this concept even further: seriously!&lt;/p&gt;
&lt;blockquote&gt;
&lt;p&gt;Seriously.js is a real-time, &lt;a href="http://en.wikipedia.org/wiki/Digital_compositing#Node-based_and_layer-based_compositing" target="_blank"&gt;node&lt;/a&gt;-based video compositor for the web. Inspired by professional software such as After Effects and Nuke, Seriously.js renders high-quality video effects, but allows them to be dynamic and interactive.&lt;/p&gt;
&lt;/blockquote&gt;
&lt;p&gt;It features an optimized rendering path that is built with WebGL making it entirely hardware accelerated at 60 frames per second.  You can use videos, images, canvases and pixel arrays as input sources to the compositor and then apply various video effects to the resulting image, and apply 2d transforms to any layer (3d is coming).  The available effects are numerous ranging from chroma key and night vision to edge detection and other common effects.  Additionally, and perhaps the best feature of the library is that you can add your own effects as plugins and use them just as you would the built in effects&amp;#8230; In fact, the built in effects are actually just plugins themselves!&lt;/p&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_lygt0dq2Pr1qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;The &lt;a href="http://seriouslyjs.org/" target="_blank"&gt;demo&lt;/a&gt; combines a number of different effects and sources.  The video is chroma-keyed so that you can actually change the background as it&amp;#8217;s playing in real time, and then various effects are applied on top of everything changing the feel of the music video dramatically.  There is a underwater scene, a night vision scene, and a creepy black one.  I think this idea of user modifiable music videos is a very neat one indeed!&lt;/p&gt;
&lt;p&gt;So want to get started with Seriously.js yourself?  Luckily for you, there is a &lt;a href="https://github.com/brianchirls/Seriously.js/wiki/Tutorial" target="_blank"&gt;tutorial&lt;/a&gt; to help you out and even some &lt;a href="https://github.com/brianchirls/Seriously.js/wiki" target="_blank"&gt;documentation&lt;/a&gt;!  So how easy is it to apply effects to an HTML5 video?  This easy:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;var seriously = new Seriously(),
    video = seriously.source('#myvideo'), // get video element by CSS selector
    target = seriously.target('#canvas'), // output canvas
    vignette = seriously.effect('vignette');

// connect all our nodes in the right order
vignette.source = video;
target.source = vignette;
seriously.go();&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Obviously you can connect multiple nodes together in a chain-like fashion, adjust effect parameters and more, so check out the tutorial for all of that!&lt;/p&gt;
&lt;p&gt;Who knew that JavaScript was going to be doing realtime video compositing and effects even a few years ago?  Seriously.js is seriously impressive, it is &lt;a href="https://github.com/brianchirls/Seriously.js/tree/develop" target="_blank"&gt;open source on Github&lt;/a&gt;, and you should check it out&amp;#8230; seriously!&lt;/p&gt;</description><link>http://badassjs.com/post/16583192105</link><guid>http://badassjs.com/post/16583192105</guid><pubDate>Fri, 27 Jan 2012 09:00:00 -0800</pubDate><category>webgl</category><category>javascript</category></item><item><title>Weekly Badass JS Roundup #6</title><description>&lt;p&gt;Welcome back to the weekly Badass JS roundup!  Lots of JavaScript news this week, so lets dive in.&lt;/p&gt;
&lt;ol&gt;&lt;li&gt;Adobe &lt;a href="http://blogs.adobe.com/webplatform/2012/01/13/html5-image-progress-events/" target="_blank"&gt;proposes&lt;/a&gt; events for monitoring the downloading of Image resources which could be quite useful in many circumstances.&lt;/li&gt;
&lt;li&gt;ES6, the next version of the EcmaScript standard that defines the JavaScript language has support for various types of collections beyond the standard Array and Object types.   ES6 adds support for Maps, WeakMaps and Sets to the language.  They aren&amp;#8217;t available for use yet, but luckily Andrea Giammarchi has taken the time to &lt;a href="https://github.com/WebReflection/es6-collections" target="_blank"&gt;shim them&lt;/a&gt; so you can use them today.&lt;/li&gt;
&lt;li&gt;&lt;a href="http://drumkitjs.com/" target="_blank"&gt;Drumkit.js&lt;/a&gt; looks like an interesting new framework for Node.js that allows you to share pieces of code between the server and client as well.  Neat idea!&lt;/li&gt;
&lt;li&gt;If you didn&amp;#8217;t hear about it already, &lt;a href="http://blog.chromium.org/2012/01/real-time-communications-in-chrome.html" target="_blank"&gt;WebRTC has landed&lt;/a&gt; in Chrome!  WebRTC is a new technology that brings realtime voice and video communication technologies to the web.  Ever imagined building the next Skype without any plugins?  Well now you can!  You can enable it in the latest Chrome Canary builds in about:flags and then check out &lt;a href="http://miketaylr.com/photobooth/" target="_blank"&gt;this demo&lt;/a&gt;!&lt;/li&gt;
&lt;li&gt;We&amp;#8217;ve been watching Mozilla&amp;#8217;s PDF.js project with much interest, and they continue to pump out the Badass JavaScript.  This time, it&amp;#8217;s support for JPEG 2000 images using a handwritten &lt;a href="https://github.com/mozilla/pdf.js/pull/1068/files" target="_blank"&gt;JPEG 2000 decoder&lt;/a&gt; written in JavaScript.  Very cool!&lt;/li&gt;
&lt;li&gt;There are a couple of new slide decks for you to check out relating to new HTML5 features.  Check out &lt;a href="http://html5-demos.appspot.com/static/html5-therealbleedingedge/template/index.html#1" target="_blank"&gt;&amp;#8220;The Edge of HTML5&amp;#8221; by Eric Bidelman&lt;/a&gt; and &lt;a href="http://kinlan-presentations.appspot.com/sfmediahtml/template/index.html#1" target="_blank"&gt;&amp;#8220;What&amp;#8217;s New in HTML5 Media&amp;#8221; by Paul Kinlan&lt;/a&gt; both of the Chrome dev relations team.&lt;/li&gt;
&lt;li&gt;&lt;a href="http://gildas-lormeau.github.com/zip.js/" target="_blank"&gt;Zip.js&lt;/a&gt; is a JavaScript library that allows you to zip and unzip files in modern browsers (Chrome and Firefox).&lt;/li&gt;
&lt;li&gt;&lt;a href="http://slexaxton.github.com/Jed/" target="_blank"&gt;Jed&lt;/a&gt; brings gettext style i18n localization support to JavaScript applications.&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/emberjs/ember.js/blob/master/CHANGELOG" target="_blank"&gt;Ember.js 0.9.4&lt;/a&gt; and &lt;a href="http://blog.nodejs.org/2012/01/23/node-v0-7-1/" target="_blank"&gt;Node.js 0.7.1&lt;/a&gt; were released.&lt;/li&gt;
&lt;li&gt;Mikeal Rogers of Node.js fame writes on &lt;a href="http://www.mikealrogers.com/posts/a-new-direction-for-web-applications-.html" target="_blank"&gt;&amp;#8220;A new direction for web applications&amp;#8221;&lt;/a&gt;, covering the history of the dynamic web and looking to the future of applications built with Node and other platforms.&lt;/li&gt;
&lt;li&gt;Jens Nockert wrote two blog posts about various upcoming features of browsers that will make your computationally intensive apps much faster. The first, &lt;a href="http://blog.aventine.se/post/16318162396/simd" target="_blank"&gt;&amp;#8220;Accelerating Javascript via SIMD&amp;#8221;&lt;/a&gt;, covers a pet feature of his that may go into Firefox at some point.  The second is an introduction to a series called &lt;a href="http://blog.aventine.se/post/16413173742/tools-for-the-next-generation-of-web-applications-introd" target="_blank"&gt;&amp;#8220;Tools for the next generation of Web Applications&amp;#8221;&lt;/a&gt; and it covers lots of different technologies including SIMD, WebCL, RiverTrail and more.&lt;/li&gt;
&lt;li&gt;&lt;a href="http://enyojs.com/" target="_blank"&gt;Enyo&lt;/a&gt;, the application framework behind webOS has been open sourced!&lt;/li&gt;
&lt;li&gt;&lt;a href="http://www.longtailvideo.com/html5/" target="_blank"&gt;The State of HTML5 Video&lt;/a&gt; is a nice site with various statistics about HTML5 video&amp;#8217;s availability across devices and browsers that details some sub-features as well.  Check it out if you do anything with HTML5 video!&lt;/li&gt;
&lt;li&gt;Finally, &lt;a href="http://javascriptjabber.com/" target="_blank"&gt;JavaScript Jabber&lt;/a&gt; is a new podcast about everyone&amp;#8217;s favorite language.  I haven&amp;#8217;t listened to it yet myself, but I&amp;#8217;ve heard good things and the first episode has an all star cast!&lt;/li&gt;
&lt;/ol&gt;&lt;p&gt;That’s it for this week!  As always if you have something you’d like to tell us about - something you think is Badass JS worthy - don’t hesitate to &lt;a href="http://badassjs.com/submit" target="_blank"&gt;let us know&lt;/a&gt;!&lt;/p&gt;
&lt;p&gt;&lt;img height="0" src="http://assets.tumblr.com/images/input_bg.gif" width="0"/&gt;&lt;/p&gt;</description><link>http://badassjs.com/post/16525690481</link><guid>http://badassjs.com/post/16525690481</guid><pubDate>Thu, 26 Jan 2012 08:53:05 -0800</pubDate><category>javascript</category><category>news</category></item><item><title>PhotoBooth Style Live Video Effects in JavaScript and WebGL</title><description>&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_ly8sf38BQr1qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;Ever spent hours in PhotoBooth just playing around with the cool live video filters and effects?  Now you can do that in your browser as well thanks to Paul Neave&amp;#8217;s cool &lt;a href="http://neave.com/webcam/html5/" target="_blank"&gt;HTML5 video effects demo&lt;/a&gt;!  While you can&amp;#8217;t yet use an actual webcam and perform the effects on your own image (although those APIs are coming - Chrome just &lt;a href="http://blog.chromium.org/2012/01/real-time-communications-in-chrome.html" target="_blank"&gt;released&lt;/a&gt; WebRTC and getUserMedia support a few days ago!), you can watch as the effects are applied to a prerecorded video using JavaScript and WebGL.  Each filter appears to be a WebGL shader applied to a canvas element that gets its contents from an HTML5 video element.  You can even take a snapshot, and just like in PhotoBooth there is a countdown, the screen flashes and you have your picture that you can download and share on various social networks.  Pretty cool!&lt;/p&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_lyd95xwtNb1qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;Perhaps the coolest part is that if you run the demo in the latest Chrome Canary build with the &lt;code&gt;--enable-media-stream&lt;/code&gt; flag, WebRTC and getUserMedia support (&lt;a href="http://blog.chromium.org/2012/01/real-time-communications-in-chrome.html" target="_blank"&gt;added&lt;/a&gt; just a few days ago) are enabled and you can actually use your own webcam to take pictures of yourself and see the effects applied in real time.  It is an impressive demo of the performance that WebGL gives us (I get over 100fps!) and the fact that soon we will be able to access the webcam in JavaScript without the use of any plugins like Flash!&lt;/p&gt;
&lt;p&gt;Although the code does not appear to be open source, it is still a cool demo of what web technology is becoming capable of and I highly recommend you &lt;a href="http://neave.com/webcam/html5/" target="_blank"&gt;check it out&lt;/a&gt; (Chrome or Firefox are best)!&lt;/p&gt;
&lt;p&gt;&lt;img height="0" src="http://assets.tumblr.com/images/input_bg.gif" width="0"/&gt;&lt;/p&gt;</description><link>http://badassjs.com/post/16472398856</link><guid>http://badassjs.com/post/16472398856</guid><pubDate>Wed, 25 Jan 2012 10:26:12 -0800</pubDate></item><item><title>Resumable.js: Fault Tolerant Resumable File Uploads in JavaScript</title><description>&lt;p&gt;Ever had an experience on a website where you&amp;#8217;re uploading a really big file and its taking a while, you&amp;#8217;re not quite sure how much its uploaded, and then after a few minutes of uploading, something fails and you have to start over again?  With the new HTML5 file APIs and &lt;a href="https://github.com/23/resumable.js" target="_blank"&gt;Resumable.js&lt;/a&gt;, this problem will be lessened thanks to our newfound ability to actually resume large file uploads where they left off if they fail rather than start over from the beginning.&lt;/p&gt;
&lt;p&gt;&lt;img align="left" src="http://media.tumblr.com/tumblr_ly8rrxSX7n1qbis4g.png"/&gt;Resumable.js works by splitting the file into multiple small chunks using the HTML5 file API and then uploads the chunks one at a time until the whole file has been sent.  If any of the chunks fail to upload correctly, only that chunk needs to be re-uploaded.  Additionally, it enables the user to pause and resume uploads without losing state, and even works if the user goes offline and then online again or even if the server crashes and restarts.  Pretty cool!  It supports both file inputs and drag and drop uploading, progress events, multiple simultaneous uploads and more.  And the best part is that it isn&amp;#8217;t some terrible flash uploader like we&amp;#8217;ve seen for years.  Awesome!&lt;/p&gt;
&lt;p&gt;Here&amp;#8217;s a video showing Resumable.js in use:&lt;/p&gt;
&lt;p&gt;&lt;iframe frameborder="0" height="293" scrolling="no" src="http://reinvent.23video.com/v.ihtml?photo%5fid=2333745" width="520"&gt;&lt;/iframe&gt;&lt;/p&gt;
&lt;p&gt;You can check out Resumable.js on &lt;a href="https://github.com/23/resumable.js" target="_blank"&gt;Github here&lt;/a&gt;.  Enjoy!&lt;/p&gt;</description><link>http://badassjs.com/post/16412147197</link><guid>http://badassjs.com/post/16412147197</guid><pubDate>Tue, 24 Jan 2012 09:00:06 -0800</pubDate></item><item><title>Font.js: A Powerful Font Toolkit for JavaScript</title><description>&lt;p&gt;&lt;img align="left" src="http://media.tumblr.com/tumblr_ly8r5sYoD71qbis4g.png"/&gt;Mike Kamermans has been working on a little &lt;a href="https://github.com/Pomax/Font.js" target="_blank"&gt;font toolkit&lt;/a&gt; for your JavaScript that is kind of akin to the built-in Image object but for Fonts.  It gives you font loading events using a technique perfected in Mozilla&amp;#8217;s &lt;a href="http://github.com/mozilla/pdf.js" target="_blank"&gt;pdf.js&lt;/a&gt; project, metrics information, and a better version of the canvas element&amp;#8217;s measureText method with additional information such as height, bounding box, and leading.&lt;/p&gt;
&lt;p&gt;A &lt;a href="http://pomax.nihongoresources.com/pages/Font.js/" target="_blank"&gt;demo&lt;/a&gt; of the library shows that it&amp;#8217;s pretty similar to the built in Image object in terms of usage.  Here&amp;#8217;s an example:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;var font = new Font();
font.onload = function() {
    // measure some text
    console.log(font.measureText("some text", 14));
    
    // style an element
    document.querySelector("p").style.fontFamily = "'" + font.fontFamily + "'";
}

font.onerror = function(e) {
   alert(e);
}

// kick off the actual loading
font.fontFamily = "My Font";
font.src = "acmesa.ttf";&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Feels right at home - a very nice API indeed!  It works by downloading the font data with an AJAX request, parsing out some metadata to determine that it is indeed a valid font file and to pull out the metrics information.  Then it inserts an @font-face rule into the page and a test DIV and polls the width of that DIV until it is no longer zero-width at which point it can determine that the browser has loaded the font and it is ready for use.  Finally it calls your onload handler.  See how much work you&amp;#8217;re avoiding? :)&lt;/p&gt;
&lt;p&gt;You check out the &lt;a href="https://github.com/Pomax/Font.js" target="_blank"&gt;source on Github&lt;/a&gt;, and a &lt;a href="http://pomax.nihongoresources.com/pages/Font.js/" target="_blank"&gt;demo here&lt;/a&gt;.  Enjoy!&lt;/p&gt;</description><link>http://badassjs.com/post/16355968400</link><guid>http://badassjs.com/post/16355968400</guid><pubDate>Mon, 23 Jan 2012 10:00:05 -0800</pubDate></item><item><title>jsday, A Conference Dedicated to JS in Italy</title><description>&lt;p&gt;Given the rising importance of JavaScript both in the development of web applications and as an all-purpose language, the Italian PHP user group GrUSP decided in 2010 to organize a conference fully dedicated to JavaScript, alongside the traditional phpDay conference. Much beyond any expectaion, the first edition has been incredibly successful, with over 300 visitors coming from all around Europe and sponsorship from big corporations and organizations, like Microsoft, Mozilla, Yahoo!, Opera and Sencha. The speaker list included Steve Souders (Google), Kyle Simpson (Mozilla), James Pearce (Sencha Touch, Facebook), Robert Nyman (Mozilla), Patrick Lauke (Opera) and many more. You can take a look at the videos of past talks at &lt;a href="http://vimeo.com/grusp" target="_blank"&gt;&lt;a href="http://vimeo.com/grusp" target="_blank"&gt;http://vimeo.com/grusp&lt;/a&gt;&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;The 2012 edition of the jsDay (&lt;a href="http://2012.jsday.it/presskit/" target="_blank"&gt;&lt;a href="http://2012.jsday.it/" target="_blank"&gt;http://2012.jsday.it/&lt;/a&gt;&lt;/a&gt;) will be held in Verona on May 16th-17th. The call for papers will close on February 28th and we are still accepting submissions at: &lt;a href="http://www.jsday.it/2012/call-for-papers" target="_blank"&gt;&lt;a href="http://www.jsday.it/2012/call-for-papers" target="_blank"&gt;http://www.jsday.it/2012/call-for-papers&lt;/a&gt;&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Editors note: &lt;/strong&gt;This was a guest post from the jsday organizers.  If you are in the U.S., be sure you &lt;a href="http://americancensorship.org/" target="_blank"&gt;call your congresspeople&lt;/a&gt; about SOPA and PIPA!&lt;/p&gt;</description><link>http://badassjs.com/post/16071339376</link><guid>http://badassjs.com/post/16071339376</guid><pubDate>Wed, 18 Jan 2012 11:27:00 -0800</pubDate></item><item><title>Weekly Badass JS Roundup #5</title><description>&lt;p&gt;Welcome back to the weekly Badass JS roundup!  Here is my link dump for this week.&lt;/p&gt;
&lt;ol&gt;&lt;li&gt;I&amp;#8217;m not sure this is new, but it was new to me&amp;#8230; Grant Galitz has released a full &lt;a href="http://www.grantgalitz.org/gamecenter/index.html" target="_blank"&gt;Gameboy Color Emulator&lt;/a&gt; in JavaScript using the canvas element for graphics and the Web Audio API for audio.  Pretty awesome.&lt;/li&gt;
&lt;li&gt;Popular iPhone game &lt;a href="http://www.cuttherope.ie/" target="_blank"&gt;Cut the Rope&lt;/a&gt; has been ported to JavaScript by Microsoft of all companies and it is pretty darn impressive.  They&amp;#8217;ve also &lt;a href="http://www.cuttherope.ie/dev/" target="_blank"&gt;written&lt;/a&gt; a little about their process and even open sourced a pretty cool looking &lt;a href="http://thinkpixellab.com/pxloader/" target="_blank"&gt;resource loader&lt;/a&gt; as well.  You can expect a more in depth analysis of the game and how it was made in a future post right here on Badass JavaScript!&lt;/li&gt;
&lt;li&gt;&lt;a href="http://peter.sh/2012/01/css-selector-profiler-source-mapping-and-software-rendering/" target="_blank"&gt;Source Maps&lt;/a&gt; appear to have finally landed in Chromium.&lt;/li&gt;
&lt;li&gt;&lt;a href="https://github.com/justinlatimer/node-midi" target="_blank"&gt;Node-midi&lt;/a&gt; allows Node.js to do realtime MIDI I/O, for example to talk to an electric guitar or a keyboard.  Very cool!&lt;/li&gt;
&lt;li&gt;I think I&amp;#8217;ve mentioned this before, but &lt;a href="https://github.com/kangax/fabric.js" target="_blank"&gt;Fabric.js&lt;/a&gt; from the widely known and prolific Kangax has gotten some updates.  It now supports both importing SVG to canvas and outputting back to SVG, some complex text effects and more.  One to watch!&lt;/li&gt;
&lt;li&gt;Someone has implemented a &lt;a href="http://smp.if.uj.edu.pl/~mkol/il2js/" target="_blank"&gt;.NET virtual machine&lt;/a&gt; in JavaScript.  Wow!&lt;/li&gt;
&lt;li&gt;Eric Bidelman of Google has released &lt;a href="http://ericbidelman.tumblr.com/post/14866798359/introducing-filer-js" target="_blank"&gt;Filer.js&lt;/a&gt;, which is a wrapper around the HTML5 filesystem API with a nice UNIX-like API.&lt;/li&gt;
&lt;li&gt;Yehuda Katz thinks &lt;a href="http://yehudakatz.com/2012/01/10/javascript-needs-blocks/" target="_blank"&gt;JavaScript needs blocks&lt;/a&gt;, as in the blocks that Ruby and other languages have.  I disagree, but it is an interesting article none the less!&lt;/li&gt;
&lt;li&gt;Google is working on a &lt;a href="http://lists.w3.org/Archives/Public/public-webapps/2011OctDec/att-1696/speechapi.html" target="_blank"&gt;Speech API&lt;/a&gt; spec that they have submitted to the W3C, which would allow JS developers to incorporate speech recognition and synthesis into their apps. Sounds good to me!&lt;/li&gt;
&lt;li&gt;I&amp;#8217;ll leave you with a few podcasts to listen to.  First we have Chris Williams and Matthew Podwysocki &lt;a href="http://herdingcode.com/?p=380" target="_blank"&gt;talking&lt;/a&gt; about the JS community and other cool stuff - a good listen.  Of course we have the &lt;a href="http://nodeup.com/eleven" target="_blank"&gt;latest NodeUp episode&lt;/a&gt; all about databases and how they relate to Node.  Finally Mikeal Rogers of Node fame has been interviewing other people of Node fame on &lt;a href="http://www.curlybracecast.com/" target="_blank"&gt;CurlyBraceCast&lt;/a&gt;.  The interviews are very in depth and highly worth a listen!&lt;/li&gt;
&lt;/ol&gt;&lt;p&gt;That’s it for this week!  As always if you have something you’d like to tell us about - something you think is Badass JS worthy - don’t hesitate to &lt;a href="http://badassjs.com/submit" target="_blank"&gt;let us know&lt;/a&gt;!&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;P.S.&lt;/strong&gt; JSConf tickets will go &lt;a href="http://jsconfus2012.eventbrite.com" target="_blank"&gt;on sale&lt;/a&gt; tomorrow at 3PM EST (UTC-5).  Don&amp;#8217;t miss them!&lt;/p&gt;</description><link>http://badassjs.com/post/16015645141</link><guid>http://badassjs.com/post/16015645141</guid><pubDate>Tue, 17 Jan 2012 10:59:00 -0800</pubDate><category>js</category><category>html5</category></item><item><title>2011: A Badass JavaScript Year In Review</title><description>&lt;p&gt;2011 has been a great year for JavaScript.  Web browsers have given us great new tools to use and we have taken web applications to new heights, competing with native applications and bringing sexy back to the web with countless impressive demos.  A week or so ago, we put out a survey to all of you asking what you thought the most badass JavaScript demo of 2011 was.  Of course, this would be a boring post if we just said what the outcome was, so we&amp;#8217;re going to list the top JavaScript accomplishments of 2011 here, from demos to libraries and applications themselves.  And to all of you in the JS community, Happy New Year and keep up the good work in 2012!&lt;/p&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_lx2qdhF8ox1qbis4g.png"/&gt;&lt;/p&gt;
&lt;p&gt;Coming in at the &lt;strong&gt;top voted JavaScript demo of 2011&lt;/strong&gt;, we have &lt;a href="http://bellard.org/jslinux/" target="_blank"&gt;JSLinux&lt;/a&gt;, the JavaScript PC emulator.  I have to agree, JSLinux deserves the prize as it &lt;em&gt;is&lt;/em&gt; very impressive.  It emulates PC hardware entirely in JavaScript and includes a terminal to enter and run common unix commands.  There is a file system as well, so creating directories works, as does writing text files with vi.  There is even a built-in C compiler, so you can run your own programs in JSLinux as well!  If you haven&amp;#8217;t already, go &lt;a href="http://bellard.org/jslinux/" target="_blank"&gt;check it out&lt;/a&gt;!&lt;/p&gt;
&lt;p&gt;In terms of &lt;strong&gt;JavaScript tooling&lt;/strong&gt;, &lt;a href="http://jshint.com/" target="_blank"&gt;JSHint&lt;/a&gt; has to get the award for this year.  JSHint is a &lt;a href="http://badassjs.com/post/3364925033/jshint-an-community-driven-fork-of-jslint" target="_blank"&gt;community driven fork&lt;/a&gt; of JSLint, Doug Crockford&amp;#8217;s very opinionated JavaScript linting tool.  Although Crockford may not like it very much, the rest of the JavaScript community has been very supportive of it, and I salute its developers for taking that risk to bring us great tools!&lt;/p&gt;
&lt;p&gt;&lt;img height="203" src="http://media.tumblr.com/tumblr_luntkzIyVk1qbis4g.png" width="500"/&gt;&lt;/p&gt;
&lt;p&gt;There have been many great &lt;strong&gt;WebGL demos&lt;/strong&gt; this year, and in fact WebGL is even starting to see production use by big companies with the release of &lt;a href="http://googleblog.blogspot.com/2011/10/step-inside-map-with-google-mapsgl.html" target="_blank"&gt;Google MapsGL&lt;/a&gt;.  We saw &lt;a href="http://evanw.github.com/glfx.js/" target="_blank"&gt;glfx.js&lt;/a&gt;, which implements Core Image like filters in the browser using WebGL, impressively realistic &lt;a href="http://madebyevan.com/webgl-water/" target="_blank"&gt;water simulations&lt;/a&gt;, great &lt;a href="http://lights.elliegoulding.com/" target="_blank"&gt;music visualizations&lt;/a&gt;, Google Earth style &lt;a href="http://maps3d.svc.nokia.com/webgl/" target="_blank"&gt;3d maps in the browser&lt;/a&gt; from Nokia, beautiful &lt;a href="http://alteredqualia.com/three/examples/webgl_terrain_dynamic.html" target="_blank"&gt;terrain generation&lt;/a&gt; demos and much much more.  Libraries like &lt;a href="https://github.com/mrdoob/three.js" target="_blank"&gt;Three.js&lt;/a&gt; and &lt;a href="http://evanw.github.com/csg.js/" target="_blank"&gt;CSG.js&lt;/a&gt; continue to be invaluable tools to make these demos possible, and tooling is even coming along as well, with &lt;a href="https://github.com/idflood/ThreeNodes.js" target="_blank"&gt;ThreeNodes.js&lt;/a&gt;, a visual WebGL scene editor in the browser.  WebGL is bringing a whole new class of graphics applications, from games to Photoshop in the browser, and I can&amp;#8217;t wait to see what 2012 will bring in this area!&lt;/p&gt;
&lt;p&gt;&lt;img height="300" src="http://media.tumblr.com/tumblr_lvhiidZ4RU1qbis4g.png" width="500"/&gt;&lt;/p&gt;
&lt;p&gt;Some of the most impressive demos of the year have been ported to the web using &lt;strong&gt;&lt;a href="https://github.com/kripken/emscripten" target="_blank"&gt;Emscripten&lt;/a&gt;&lt;/strong&gt;, the LLVM to JavaScript compiler.  This in and of itself is impressive, and shows that JavaScript is actually a pretty good compile target for the web.  Byte codes?  Who needs them!  Anyway, we&amp;#8217;ve seen some pretty awesome demos come out of this work including &lt;a href="https://github.com/mbebenita/Broadway" target="_blank"&gt;Broadway.js&lt;/a&gt; (H.264 in JavaScript at 30fps), &lt;a href="https://github.com/bemasc/Broadway/tree/master/vp8" target="_blank"&gt;Route9.js&lt;/a&gt; (WebM in JS), a &lt;a href="http://syntensity.com/static/espeak.html" target="_blank"&gt;speech-to-text&lt;/a&gt; engine, &lt;a href="http://www.syntensity.com/static/openjpeg.html" target="_blank"&gt;OpenJPEG&lt;/a&gt; (read: JPEG 2000 in the browser) and many more!  Emscripten has brought about some awesome stuff, and I can&amp;#8217;t wait to see what people do with it in 2012!&lt;/p&gt;
&lt;p&gt;Another impressive demo and ongoing project of 2011 has been &lt;a href="https://github.com/mozilla/pdf.js" target="_blank"&gt;PDF.js&lt;/a&gt; which implements a full PDF reader using only web technologies.  The PDF format is a conglomeration of many other formats, including image formats, font formats, compression and encryption algorithms and more, and thus PDF.js has become almost a repository of JavaScript implementations of these formats as well as just a PDF reader.  It has gone from barely working to very full featured this year, and is not only a good demo of what web technologies are capable of, but a great learning tool for browser makers on the missing features of web browsers as well!  Out of PDF.js, we have gotten dashed line support and even-odd fill rule support for canvas elements and probably even more bugs fixed, and coming down the pipeline are a better font loading API, and perhaps even a WebPrint API.  I can&amp;#8217;t wait to see what Mozilla does with PDF.js in 2012!&lt;/p&gt;
&lt;p&gt;&lt;img height="291" src="http://media.tumblr.com/tumblr_lwglt1ZmME1qbis4g.png" width="391"/&gt;&lt;/p&gt;
&lt;p&gt;On the &lt;strong&gt;web audio &lt;/strong&gt;front, we&amp;#8217;ve seen quite a few great things in 2011.  It all started with &lt;a href="http://jsmad.org/" target="_blank"&gt;JSMad&lt;/a&gt;, the hand ported JavaScript MP3 decoder using the new &lt;a href="http://chromium.googlecode.com/svn/trunk/samples/audio/index.html" target="_blank"&gt;Web Audio API&lt;/a&gt; from Google and the &lt;a href="https://wiki.mozilla.org/Audio_Data_API" target="_blank"&gt;Audio Data API&lt;/a&gt; from Mozilla.  After that, we saw an &lt;a href="https://github.com/cosinusoidally/mp2dec.js" target="_blank"&gt;MP2&lt;/a&gt; decoder, and the &lt;a href="http://areweplayingyet.org/" target="_blank"&gt;HTML5 Audio Test Suite&lt;/a&gt; from the fine folks at Soundcloud.  And we saw &lt;a href="https://github.com/oampo/Audiolet" target="_blank"&gt;Audiolet&lt;/a&gt;, which looks to be a very nice audio generation library, and &lt;a href="http://audiolibjs.org/" target="_blank"&gt;Audiolib.js&lt;/a&gt;, which is a nice audio effects library.  Finally, just recently my team at &lt;a href="http://ofmlabs.org/" target="_blank"&gt;ofmlabs&lt;/a&gt;, released &lt;a href="http://github.com/ofmlabs/alac.js" target="_blank"&gt;ALAC.js&lt;/a&gt;, the Apple Lossless decoder hand ported to JavaScript.  You can expect more great things from us and everyone in the Web Audio community in 2012!&lt;/p&gt;
&lt;p&gt;&lt;img height="100" src="http://media.tumblr.com/tumblr_ltj7t9qk9G1qbis4g.png" width="100"/&gt;&lt;/p&gt;
&lt;p&gt;Well, this post is getting kind of long now, so I&amp;#8217;ll try to summarize the remaining demos briefly though they are all super impressive and amazing!  &lt;a href="http://html2canvas.hertzen.com/" target="_blank"&gt;HTML2Canvas&lt;/a&gt; is a full HTML/CSS renderer in the canvas element which allows us to generate screenshots of live web pages for feedback purposes or otherwise.  There are now &lt;a href="http://engineering.linkedin.com/javascript/vncjs-how-build-javascript-vnc-client-24-hour-hackday" target="_blank"&gt;multiple&lt;/a&gt; JavaScript &lt;a href="https://github.com/kanaka/noVNC" target="_blank"&gt;VNC clients&lt;/a&gt;.  Many image formats have been implemented in JS: &lt;a href="http://github.com/devongovett/png.js" target="_blank"&gt;PNG&lt;/a&gt;, &lt;a href="https://github.com/notmasteryet/jpgjs" target="_blank"&gt;JPEG&lt;/a&gt;, &lt;a href="http://github.com/devongovett/bmp.js" target="_blank"&gt;BMP&lt;/a&gt;, and &lt;a href="http://slbkbs.org/jsgif/" target="_blank"&gt;GIF&lt;/a&gt;.  My own PDF generation library &lt;a href="http://pdfkit.org/" target="_blank"&gt;PDFKit&lt;/a&gt; was released this year.  A &lt;a href="https://github.com/nurv/BicaVM" target="_blank"&gt;JVM&lt;/a&gt; has been implemented in JavaScript.  Libraries like &lt;a href="http://documentcloud.github.com/backbone/" target="_blank"&gt;Backbone&lt;/a&gt;, &lt;a href="http://emberjs.com/" target="_blank"&gt;Ember.js&lt;/a&gt;, &lt;a href="http://sproutcore.com/" target="_blank"&gt;SproutCore&lt;/a&gt;, and &lt;a href="http://cappuccino.org/" target="_blank"&gt;Cappuccino&lt;/a&gt; have gotten a lot better.  The &lt;a href="http://icloud.com/" target="_blank"&gt;iCloud web apps&lt;/a&gt; have brought a high standard for native-like interfaces on the web.  There is so much to love about the JavaScript community and things it brings us every year.  You are the best.&lt;/p&gt;
&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_lx2qn9YkVX1qbis4g.jpg"/&gt;&lt;/p&gt;
&lt;p&gt;Finally, make it your New Years resolution to watch Chris Williams&amp;#8217; excellent video, &amp;#8220;&lt;a href="http://badassjs.com/post/11953296086/chris-williams-an-end-to-negativity-in-our-community" target="_blank"&gt;An End to Negativity&lt;/a&gt;&amp;#8221; and to better yourself and this community in 2012.  Happy New Year, thanks for all your hard work this year, and keep it up in 2012 and beyond!&lt;/p&gt;</description><link>http://badassjs.com/post/15082876071</link><guid>http://badassjs.com/post/15082876071</guid><pubDate>Sat, 31 Dec 2011 07:21:00 -0800</pubDate></item></channel></rss>

