Skip to content

Multitouch Emulation in Flash Using Goose Classes

December 7, 2009

With the freely distributed package of actionscript classes that are collectively called Goose (http://gooseflash.wordpress.com/), it is possible to emulate multitouch until multitouch support becomes available with the release of Adobe Flash Player 10.1.

Goose & Multitouch

Goose itself is set up to with the intention to use actual multitouch  input data (such as the coordinates of each touch point). Therefore as has been recently claimed in the blog for Goose,  Goose will still be able to use the input data when multitouch support arrives. As of now, the details of the new ActionScript 3 multitouch API’s are slim. However, I did read in this article that they will allow developers to access low-level input data (such as coordinates). This could mean that Goose’s aspirations to work with actually realistic. However, the question is if we will really need Goose…

The purpose of Goose seems to be to allow a Flash Developer the capability to easily work with input data from multitouch. It does this by creating its own set of of GooseEvents to recognize when events such as a Touch, Press or Move are occurring. Allowing the developers to call these different event listeners allows for functions to be triggered by these unique events. In the samples provided with Goose, the user is able to drag photos and scale them as well (rotation is not yet possible though).

At a superficial level, Goose appears to provide the ability to recognize common gestures. In the article I mentioned, it appears that the idea of gesture has already been considered by the people at Adobe. Apparently the option exists to use gestures recognized by the operating system with Flash, or to turn these gestures off and use the low-level input data in a manner similar to using a mouse.

This leaves the question of the utility of Goose in a multitouch supported world up in the air. I imagine the new additions coming for actionscript will incorporate Goose-like functionality. If Goose doesn’t adapt with the new changes, I can see it becoming obsolete. I also believe that it’s lifeline may lie in future upgrades to supply gestures that are uniquely different from the gestures recognized by operating systems.

Multitouch Emulator

A multitouch emulator is also included with Goose. This allows multiple cursors to exists in the same flash file. Each cursor used comes from a separate computer connecting to the emulator via the internet. Therefore,  unless you have two computers beside you, your emulated multitouch may seem more like multi-user. In addition, you don’t move your cursor directly within your flash file; you move it within the emulator open in a separate window. When you move your mouse around in the emulator, you see the cursor it creates come up in your flash file, it actually works quite well. Using the emulator still lacks the feel of true multitouch as using to hands to perform a gesture doesn’t have the intuitive feel you get when gesturing with your fingers on a touch screen.

How the Emulator Works

In order to use the emulator, you must have something running on the internet to pass information from the emulator to the flash file. In this case, Goose comes preconfigured to use another tool from the same series named Robin. I could write a whole post on Robin if I wanted to, but I’ll sum it up below. Needless to say, if you can get Robin up and running, you just open up your emulator, click, and you are connected to your swf that is using Robin!

Robin Class

Robin allows multi-user data exchange by having php script running to facilitate the exchange of data between users. When it works, it’s pretty awesome. In my use of it, I found the passing of coordinate data was quite quick! I was able to move something as one user, and seen it move (almost) instantaneously on the other user’s screen.

I however ran into a large issue in trying to get it working. This is because it had some issue running from an xampp server. However, my little issue which may have been as small as a typo somewhere ( I still have no clue) worked itself out after a couple stressful hours and my robin ended up working smoothly.

All I needed to do was follow the instructions to input my server information into two of the files in the Robin package. Then, as long as you have a particular .php page running in your browser, robin is able to pass data between users.

Conclusion

After the hardship Robin caused (though in fairness, it may have been my fault), I found using Goose to be quite the ordeal. Using it with actual Multitouch input might have appealed to me more, but multitouch through the  emulator was just not personally worth the effort to set up. The emulator does run great though. I’m more intrigued with the idea of using Robin for multiuser games.  However, I think I will wait to see what adobe offers us with adobe flash player 10.1 before investing more time to fully test the potentials of Goose.

Advertisements
No comments yet

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: