Hi
Is it possible to record the end user by mic?
And what kid of actions can I do with the recording?
Can I get for example the volume of the sound (decibels) in real time?
Can I save the record on a file?
Thanks.
Hi
Is it possible to record the end user by mic?
And what kid of actions can I do with the recording?
Can I get for example the volume of the sound (decibels) in real time?
Can I save the record on a file?
Thanks.
There is a setting on the client side to turn on access to the webcam and Mic, but there is no way that you are going to have control of that in your application itself. The user would have to opt to have this turned on. If you must do something like this, you are better to implement an Active X control of some form, which the user might unwittingly accept access to this function.
Yes, Flash allows (with user permission) the ability to record from the microphone.
This is how countless sites like Stickam work to provide videoconferencing capability.
You cannot take actual (accurate) sound pressure readings in dB--that is an absolute measurement of sound pressure that would depend on a hundred factors you have no control of on the user's machine (mic type, location, positioning, trim, frequency response, A/D conversion, hardware compression, etc.). However, you can sample the relative amplitude of the incoming signal.
Yes, you can record audio, using the flash.media.Microphone class.
No, you can't save to a file from Flash, because Flash won't let you write to disk. Well, you could save to an LSO, but that's limited to 100 KB by default, and isn't a plain file anyway. You can probably do it with AIR. I see in the docs for the Microphone class that you can stream the audio back to a Flash Media Server (or compatible, as noted in comment below), but that's not exactly "saving to a file".
As for processing the audio, technically, yes you can do what you're proposing, but it may be impractical. ActionScript is an interpreted language, and doesn't have particularly strong numerical processing abilities. It would probably be 10-50x slower to do this in Flash than in native code. Accepting this speed hit would be like sending yourself back in time 10-15 years, and having to do this using the technology of the day. So, whatever you'd want to do, you'd have to ask yourself if they were doing it in real time in the mid to late 90's. If not, Flash will probably be too slow. Speaker-independent large-vocabulary speech recognition, for example, probably won't be practical.
ActionScript works best when you're only using it to script calls into the Flash Player, which is written in native code. Until Flash gets voice recognition (or whatever audio features you're looking to have), I'd give up on this project.
As far as I know, you can't access its waveform or volume... there is an activityLevel property with some kind of information on the activity levels, but you can't access the raw spectrum or anything similar. To record the audio file, you can send it to a server via FMS, and eventually you could proccess it there, but this would depend on the connection latency and such, so it would be quite hard to give accurate responses to the user... See this: http://theflashblog.com/?p=829