Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/garciat/js-flash-audio-input
A small ActionScript script that exposes microphone access to JavaScript.
https://github.com/garciat/js-flash-audio-input
Last synced: about 11 hours ago
JSON representation
A small ActionScript script that exposes microphone access to JavaScript.
- Host: GitHub
- URL: https://github.com/garciat/js-flash-audio-input
- Owner: Garciat
- Created: 2011-05-25T22:48:31.000Z (over 13 years ago)
- Default Branch: master
- Last Pushed: 2011-05-25T22:55:52.000Z (over 13 years ago)
- Last Synced: 2024-04-14T15:14:58.183Z (10 months ago)
- Language: ActionScript
- Homepage:
- Size: 97.7 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.markdown
Awesome Lists containing this project
README
Data passed to the dataCallback is in the form of an array of floats ranging between -1 and 1.
Your callback will be called many times as the output buffer is filled and needs to flush.Flash object methods:
---------------------Set the callback for status messages:
setStatusCallback(callbackName:String):void
Set the callback for data messages:
setDataCallback(callbackName:String):void
(Callbacks must be placed in the object (global namespace))
Get an array of input device names:
getInputArray():Array
Updates the array of device names:
updateInputArray():void
Selects an input device to work with:
selectInput(index:int=-1):void
("index" is the array index corresponding to a device in the getInputArray() array)
Requests the client for audio input permission:
askPermission():void
**The following methods must be called -after- having selected an input device with selectInput()**
Returns a boolean determining if the client has allowed access to the device:
getPermissionState():Boolean
Returns the name of the enabled device:
getInputName():String
Returns the index corressponding to a the current device's position in the getInputArray() array:
getInputIndex():int
Sets the device gain level (0-100; 50 is 1x multiplier):
setGainLevel(gain:Number):void
Returns the active device's gain level:
getGainLevel():Number
Sets the sample rate (5, 8, 11, 16, 22 or 44; value is in kHz):
setSampleRate(rate:int):void
Returns the sample rate:
getSampleRate():int
Enables/disables echo suppression:
setUseEchoSuppression(enable:Boolean):void
Returns a boolean determining whether echo suppression is turned on or off:
getUseEchoSuppression():Boolean
Returns the activity level the device is detecting (0-100):
getActivityLevel():Number
Returns a boolean determining whether the object is recording or not:
isRecording():Boolean
Starts the recording process:
recordStart():void
Stops recording:
recordStop():void