Skip to content


ShinyTouch is Complicated

This is a draft, and I just feel like publishing it cause I lost my train of thought.

So I totally super insanely over underestimated the complexity of the ShinyTouch project. It’s actually probably one of the most complicated projects I’ve ever attempted. And if all hardware related things are really this complicated, then I really applaud the efforts of all those people who work on this stuff. While ShinyTouch isn’t really large code-wise (currently less than 200 lines of Python), it’s not a very simple program.

And though the concept can be implemented as a simple thing, you would loose a lot of accuracy. The most basic possible implementation would be to search for a color matching the range for a finger (it does in fact stick out quite a bit) by searching pixel-by pixel from right-to-left (if the camera is mounted to the right of the monitor) and it will stop once it hits the fingertip, which is the first thing of skin that the camera sees since it’s mounted at an angle. After that, you would check if the color immediately next to the point and check if it fits in a range. Then if it matches, then you fix the distortion due to perception and send it to a app through something like TUIO.

With that being the most simple thing possible, everything else I’ve thought of builds on the second part: the reflection detection. This part is what I’ve discovered to be the most complicated. And the complexity of it isn’t totally unexpected. This detection is really all that is truly special about this project. Without it, it’s just finger tracking, something that’s been used for tons of projects.

Posted in ShinyTouch, Touchscreens.


New Feature: Delete Frame

Actually, it doesn’t delete frames quite yet, but only blank out keyframes and turn them back into tweens, but true deleting is in the works. So it’s actually toBlank, which is sort of a misnomer since it doesn’t make things blank, but rather to whatever state it feels like.

Edit: Okay, so now it has full deleting of keyframes, tweens, and not blanks cause there’s no point in deleting what doesn’t exist.

Posted in Ajax Animator.


How I Would Design The Browser 2: Addons

So I was watching Aza Raskin’s TechTalk on Jetpack, and I was thinking on how I would design an extension system. I would have to say to not have one, it’s just too complex, and why restrict the sound recording functionality to a taskbar. Even worse, why fragment the API and require someone to use Flash or <audio> in the page space and have a nice jetpack.future.import(“audio”) for a taskbar?

I think a good idea would to expose the power to web pages. The page could request special capabilities through a magical button dropdown or bouncy annoying notifier on a corner of the page saying permissions, populated by checkboxes of whatever features that the page wants to be able to use.

I think bookmarklets are almost perfect. Adding some more greasemonkey-like features would make it just about perfect. Scripts can run with the same permissions as the page, and the page’s permissions can be granted easily by the user (and the permissions persist through refreshes and browser restarts). Again, if functionality is not supported, things can gracefully degrade with partial functionality.

After that, is the idea of background tabs or alternatively, merging the statusbar type widgets into the tab bar. This is logical with everything merged into the page, and allows things to gracefully degrade if they don’t support the feature. You also get the benefits of being able to reorder remove, get info (which would be the contents of an extension page), etc. I think the interface for a plugin that operates in the background (like a gmail notifier) would be just a small tab that only has an icon, with special flag that makes it run on browser start (I think this could be one of the things for the permissions panel).

So one problem I see in the way Jetpack works, is that it doesn’t easily allow you to make a jetpack that hacks another running jetpack. Sure you can “fork” it, but that defeats the purpose of extensions, rather than having extensions only 1-level deep, make it work all the way down. The easy way I see is just to use the bookmarklet philosophy, and everything can mess around with anything within the page. So if you have a GMail notifier, that came out before the tab persist feature existed, you could just add a simple bookmarklet-type-greasemonkey thing that adds something to the permissions box that says “Persist Page” and then the user could check that in order to make a background GMail Notifier that runs on browser startup.

Malware is easy to fight now. Imagine if every application was forced to have a icon in the taskbar of windows at all times. Finding malware is as easy as looking for things you dont want running and closing it. And if some tab-bar autohide is to be implemented on the system, only people who are quite experienced would use 10+ extension/notifier pages and it would still be easier to recognize than finding some other strange wcultns.exe or whatever when half of the system things look like that.

With these features, Browser as an OS would really make sense. I wouldn’t be suprised if Google Chrome OS implements some stuff that are similar to what I’ve listed here.

Posted in Design, Other.

Tagged with , , , , , , .


WebWorkers + Canvas + Glif + GIFEncoder = Client Side Animated Gif Generation

With my super awesome PHP->JS compiler that I made for Freemovie/JS, I ported GIFEncoder (the second of 2 parts of the Ajax Animator which requires a server). So with this I’m really going to be “building on the shoulder’s of giants”, since all these individual components were made by other people, I’m just mixing them up in a somewhat creative manner.

Though since Glif only supports monochrome, and I’m not aware of any browser supporting canvas.toDataURL(“image/gif”).

So after this awesome experimentation and my system for merging multiple GIF images into a single animated gif which is yet to be tested for reasons I will detail later.

So I made it and it was cool, and then I added webworkers support, but then I realized the issue isn’t that you need webworkers, but that there was an infinite loop. Fixed it and then it works fine except for the fact that it doesn’t.

So if you want to rip it’s insides apart and try salvaging the disaster, go to http://antimatter15.com/misc/canvasfail/giftest.htm

Posted in Ajax Animator, Animated GIF Encoder, Multimedia Codecs.

Tagged with .


Wave2: A higher level Wave Gadget State API

I was working on a new little Wave State API update. It supports lists in the form of subkeys, and something very much like hierarchy and events on specific sub-nodes. This way you don’t have everything update (someone’s edits on frame 36 doesn’t matter if you’re on frame 42).

Everything is namespaced under a singleton global, wave2. It includes functions like

  • listen (execute a callback when something beginning with the prefix is changed)
  • ignore (un-listen),
  • keys (shortcut for wave.getState().getKeys()),
  • subkeys (get keys which begin with a certain prefix, important to the pseudo hierarchy),
  • set (submitdelta with first arg as name and second as value),
  • get (shortcut for wave.getState().get()
  • reset_gadget (a simple way to empty all the data in the store)

And since it’s quite short, I’m putting it under public domain at http://antimatter15.com/misc/wave/wave2.js

Posted in Ajax Animator, Other.

Tagged with , , , , , .


Ajax Animator Status

It’s certainly hit a milestone with the current set of modifications, IMO, it’s now, finally, after 3 years of development (Actually, nothing happened the past year), what I had envisioned.
The first parts of my April 7th, 2007 post on Liveswiffers.org.

I am working on a project to make an open-source browser based Flash Authoring system.

….. The idea is to make an animation on the site, save to the site’s server, and continue working on it later. Later being able to publish it and be sort of a YouTube for Flash Animations/Applications. Another aim of this project is to be next-gen software, sure there are about 10 open source multiplatform C++ based flash IDEs out there, but none of them truely [sic] represend [sic] the future of software, or true platform independence.

Another interesting fact is that I didn’t know what YouTube was until Google bought it. But with the idea for a “YouTube for animations”, is totally possible with the new infrastructure provided by Google Wave. People can mark their waves containing the gadget as with:public, and people could search, comment, and improve animations (Though I was thinking initially on a more opensource software-like fork system, than a wiki type system which Wave is, and I’m not certain how this will work out with in the evils called the “real world” since now, Wave is still just a theory).

What has it done which makes me think it’s reached this milestone? Well, finally, I can make stick figures and animate them as they were meant to be animated. Having multiple layers with visibility now works, and now it supports most of the beloved and mostly efficient workflow of the Flash IDE – or at least to a beginner like I was, and still am.

Posted in Ajax Animator.

Tagged with , , .


Freemovie/JS: Pure Javascript SWF Generator

I’m making a crude python script that translates PHP to JS rather hideously. It probably will not work on any other codebase. It was a script quickly hacked together to one purpose.

Freemovie is

FreeMovie is an SWF generator library written in PHP and ported to Ruby. FreeMovie can be used to develop Web and desktop aplications.

Speaking of the Ruby port, I can’t find it. So if anyone finds it, I think it might be useful somewhere. Found it in the CVS, it’s really incomplete compared to the PHP version.

The machine translated code (Not *entirely* autogenerated, I wrote a line or two of it) is not too hideous, the tabbing is slightly off, but it’s at least mostly readable. It was a lot worse 2 hours ago (half of the lines had indentation, other without any, debugging comments everywhere saying useless and distracting things).

The translator is only 107 lines of (hideous code, though the language is beautiful, I guess if you loved JS enough, you could try running the program though skulpt) python (+ 20 or so in another file to change chr() to String.fromCharCode, etc). After that, it uses 6 PHP compatibility functions and 5 from the PHP.js project to cover the features that I’m too lazy to  put in the compiler or are just not features in JS.

http://antimatter15.com/misc/freemovie/js/demo/fm-demo-0.htm

The above demo generates a flash image entirely client-side, though the resulting base64 encoded data is sent to be decoded on the server since you can’t load a SWF from a data-url. If someone finds out how, it would be cool to tell me.

A big issue though, is that for some odd reason half the shapes don’t work. The ones in the demo work, but all filled shapes, and the circles/arcs do not work.

Posted in Ajax Animator, Freemovie/JS.

Tagged with , , , .


Visible/Invisible Frames

New feature, only available at this random fork of the codebase as of yet.

Since Silk doesn’t have an icon for eye_closed.png, everyone has to suffer by seeing my artwork! muah ha ha ha….

Posted in Ajax Animator.

Tagged with , , .


Working on interface for Animator/Wave

Interface of Ajax Animator as Google Wave Gadget

The name field will be replaced with buttons, and zoom may or may not be scrapped. Since gadgets only take up a fraction of the page (usually) it’s designed with size in mind, which may help on other space-constrained devices like netbooks.

It may have a cool feature like VectorEditor’s demo where you can draw off the canvas area.

As for why the tabs are now on top and the timeline is on the bottom, there’s no reason, I just think that that layout is more aesthetic.

And I might name it something other than the ajax animator, something just like Animator or something

Posted in Ajax Animator.

Tagged with .


VectorEditor Ajax Animator

http://antimatter15.com/ajaxanimator/build/index.vectoreditor.htm

Posted in Ajax Animator.