-
Folks,
I've looked through all the Microphone and Camera related threads I could find and I didn't notice this little callback mentioned anywhere...
c.onActivity
m.onActivity
At Flashforward 2002 in S.F 2 weeks ago, somebody showed how you can trigger events in your movie based on microphone and camera activity level. Yes, that means we have a motion detector built into Flash!!!! You can imagine the applications. Similarly you could have animation triggered by clapping etc.
Well, I've played around with this but I didn't really get too far. The Microphone one seems to work once or twice and then stop working. I never got an event out of my camera.
I saw the code snippet only for a few seconds at Flashforward, so my hasty handwritten notes might be missing something. Can anybody help?
Camera:
c=Camera.get();
c.setMode(320,240,15); // 15 is the frame rate
c.setMotionLevel(30,500); // does anybody know what this does?
c.onActivity = function(mode) {
trace("You moved!!");
}
I'm also not sure what the mode parameter does in the callback
Microphone:
m=Microphone.get();
m.onActivity = function() {
trace("Hark, hark...: " + m.activityLevel());
}
I vaguely remember there is a property on the Microphone object that determines how long it will take to 'settle down' again after activity. I wonder if my problems have to do with that? (like that it's set to take 10 minutes before it registeres activity again).
So if anybody has any thoughts, comments or advice, I'd sure appreciate it!
Juggle5
-
just pulling this to the front again...
-
Well I don't know ANYTHING about this, but it sounds like it has some really cool potential! Flash 7 = Voice recognition? "Computer go to my home page..." hehehe
-
Wow Juggle,
Looks like you've stumbled on yet another cool, but completely undocumented feature of Flash MX. There seem to hundreds of things people are "finding" but can't use cause no one at MM is giving up their little secrets.
I guess what kind of cheeses me off is that I've seen alot of posts regarding these issue and the "official" MM response seems to be something akin to "these functions will be documented when our new server applications are released".
How many people would buy a new car if brake pedal was hidden and it's location wouldn't be revealed until the manufacturer released it's new windshield wiper blades?
Christ, just give me the list and let me start developing with these new features. I'm not going to be inclined to buy coldFusion just cause new flash MX information will be released then.
Who the hell comes up with these ingenious marketing schemes, and then who is the other genious who says, "wow, that's a great idea. Maybe I'll share it with my friend who works at ford!"
Skex
-
I'm guessing from looking at the bug reports around here (streaming issues/compiling etc.) that they just made it to the shipping date with the features they felt confident with.
Some of these (hidden) features were thought to be 'less important' than what we are told about in the documentation,
{rant/} so let's all quietly wait until they get time to check which ones work ? er right, I bet half the functions you like the best dont get unveiled with Neo...
It makes no sense, like you say. No-one would hide functions like these pending release of a completely different product. More like hiding the brake pedal until they release the carwash.{/rant}
I have total faith
-
Just a matter of time...
Well... it seems just a matter of time until all these nice (but hidden) features have been completely discovered -yepp, Macromedia Inc. -we're not half as silly as you may think
Mike
-
OK, figuring out the setMotionLevel function...
The first parameter seems to be a reference to the activityLevel property of the camera object.
When the detected activity of your camera goes above the first parameter, the onActivity function fires.
The second parameter is a time in milliseconds until the onActivity function fires again (or so it seems). If, at the end of that amount of time, the activityLevel is higher than the first parameter, it waits another amount of time equal to the second parameter.
This will allow for motion capture on activity (and will then allow for the motion capture to turn off... though you'll have to use some sort of toggle mechanism).
Interesting interesting...
-chicken
-
This reminds me of when I was a kid and it was christmas eve. I know all the presents are under the tree, but I have to wait till christmas. The only difference here is, I don't know when I get to open the presents!!!
Reading posts about the camera potential is kiling me...
jim
-
Any luck with this, Juggle5? I recall a presentation last Fall, where the presenter had a webcam mounted on his laptop... he moved his hand in front of the camera, which triggered an animated character in his Flash movie to wave his hand.
I have an application for this type of functionality right now and am trying to figure out how it was done. Has anyone found any documentation on this?
-
ive seen a computer screensaver which uses a webcam. on the screen there is a movie of what the webcam sees and a ball which bounces on the edges. if you move your hand infromt of the webcam, and the ball hits your moving hand, it will bounce in the other direction. if any of this could be done in flash, it would have been amazing...
btw, if you right click in a showing .swf file and click settings you can set the webcam and microphome settings.
btw, where did u find the camera and mic. codes. their not in the index list in flash?
i managed to get the microphone to notice my clapping, but i think you need to deActivate it or somethin. my mic. activation only works when i view the settings. any1 know y?
-
do u have the url to that page u spoke of Juggle 5? my mic only workswhen its activated, so ineed a script to activate it. this is y the script worked when i viewed the mic settings. anyone else get the same thing?
-
You guys know that this thread is over a year old. All the camera/mic stuff is explained throuout these forums and at Macromedia. Check out Flash Communication Server while your at it; it was just updated to version 1.5.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|