Trick: Auto-select mac iSight in flash.

If you’ve been messing around with Augmented Reality (or any webcam stuff in flash for that matter), you may have come to the realization that many mac users may not have their proper webcams (i.e. iSights) set by default. In a commercial setting, you want to avoid a person having to select their webcam at almost all costs — it’s another barrier to entry, and can be confusing, too. Especially if you have video editing software installed, there can be a lot of options, as you can see below.

camerasettings

However, it’s easy to check and see if the person has an iSight installed and, if so, automatically choose that one.

var index : int = 0;

for ( var i : int = 0 ; i < Camera.names.length ; i++ ) {

if ( Camera.names[ i ] == "USB Video Class Video" ) {

index = i;

}

}

//Oddly, Camera.getCamera needs a string of the camera index, NOT the name of the camera.

_webcam = Camera.getCamera( String( index ) );

Voilà. You’re now covered for mac users and windows users won’t notice a thing.

FLAR how-to: Multiple instances of multiple markers.

kingofthetinycubes

UPDATE: We’re be remiss not to also point you to Eric’s excellent FLARManager class. He took some of the stuff we’ve covered here and put a far more delicious topping on it.

One of the big things we’ve been wrasslin’ with recently here at Squidder is how to handle multiple instances of multiple markers using FLARToolKit. Well we haven’t totally nailed it — close, but there are still a few niggling issues. So we’re looking to you, dear Squiddite, to help us out.

Before reading on, you can get our source code here.

It contains all the libraries (FLARToolKit, Papervision, even some of our own) you need to get going, even if this your first FLAR project. It’s as simple as extending a single class, creating an array of the markers you want to load in, and rocking and rolling. It also works great even if you’re only dealing with a single symbol.

Read on for more thrilling details!

Read the rest of this entry »

For Nerds Only: Custom FLAR Markers Explained

nerd_marker1

Before we start this post, we ask that all non-nerds leave the room. Seriously, it’s for your own good.

Alright, now that we’re alone, let’s get down to business. When we first started messing with FLARToolkit, we were confused as hell about how to create our own markers, as were many other people we came across in our augmented reality induced travels. So now that we’ve got a grasp on it, let’s break it down so that future Magellans of the internet won’t make that stop in the Philippines.

Read the rest of this entry »

Augmented Reality Drum Kit

flardrums1

This actually came about as a happy little accident while trying to bend FLARToolkit to our will (tracking multiple instances of multiple symbols – a total pain in the ass. But that’s a story for another time). It just so happened that we were rocking out to Kiss’ “God Gave Rock & Roll To You” and it suddenly occurred to us that “Hey, it wouldn’t be so hard to make these things make sounds when they disappear.” So we did. And it was awesome.

We’ve (for once) posted a usable demo, so you too can rock out at your desk. Below is a quick video demo of all four sounds and after the break, you can see the demo of using multiple instances of the same drum.


Read the rest of this entry »

Driving Demo, part 2

We couldn’t help it. The XBOX Controller wasn’t enough. Had to hook it up to a wiimote too (big nod to the guys over at the WiiFlash project).

Desktop (literal) driving demo

driving1

It’s no secret that we’re obsessed with augmented reality. Using this fantastic car demo whipped up by John Lindquist over at pv3d.org, we added in some FLARToolkit love to create a cool experience of driving the car around on a table.

But we didn’t stop there. Using the mind blowing-ly good ControllerMate and some simple keyboard mapping classes, we hooked the car up to a wired xbox 360 controller for maximum nerd. Next step, get some shaders going on that sweet Ford Focus. Ah, we couldn’t resist, so we added a shader.

UPDATE: YouTube was being unhappy with our videos for some reason (we suspect it doesn’t get along with Snapz, but who knows), so we’re moving over to Vimeo. We’ve also updated our demo video here, too, to include a slight shadow under the car, as well as part where the car does it’s business without the flar symbol present. Enjoy!

PaperTweet3d: Augmented Reality T-shirts

eshirt2

So we here at squidder have been playing around with the FLARToolKit a lot recently. Pretty amazing stuff really. And while fooling around with it, something (perhaps obvious) occurred to us: We love flash. And we also love t-shirts. And Papervision. And Twitter.

And, suddenly, we had a way to combine them all together.

Below is an early technical demo, in which a barcode, containing a twitter username, is embedded within our FLAR pattern. This is important because you don’t need to create a new pattern for each username. Instead, the flash reads the person’s username (up to 8 characters, encoded in 6 bit chunks) and then pulls that person’s latest post from twitter. 

The source code is a mess, but we’ll be posting some more how-to details soon. In the meantime, enjoy the video demo below!

Update: YouTube drools, Vimeo rules.

Twitter