live webcam video

I’m trying to develop an app that will display a live USB webcam feed using the macam Quicktime component. Is this possible with Applescript Studio? I’ve developed little apps that play Quicktime movies, but can’t figure out a way to do live video.

If not AppleScript, is there perhaps a tutorial or sample code somewhere for how to do it using Cocoa? I’m having trouble finding anything.