Skip to content

Commit

Permalink
custom recorder processor doc
Browse files Browse the repository at this point in the history
  • Loading branch information
ksyeo1010 committed Jun 10, 2024
1 parent dcdefa1 commit 0c3b3c6
Showing 1 changed file with 24 additions and 1 deletion.
25 changes: 24 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,30 @@ let options = {
frameLength: 512,
outputSampleRate: 16000,
deviceId: null,
filterOrder: 50
filterOrder: 50,
};

WebVoiceProcessor.setOptions(options);
```

### Custom Recorder Processor

**NOTE**: We won't be responsible for any bugs related to using custom-made recorder processor.

Take a look at [recorder_processor.js](src/audio_worklet/recorder_processor.js) in this repo as a reference
on how to create a simple recorder processor.

Add the option `customRecorderProcessorURL` to options object to use your own recorder processor.
Enter the string to the custom recorder processor URL or leave it blank to use the default recorder processor.

```javascript
// Override default options
let options = {
frameLength: 512,
outputSampleRate: 16000,
deviceId: null,
filterOrder: 50,
customRecorderProcessorURL: "${URL_PATH_TO_RECORDER_PROCESSOR}"
};

WebVoiceProcessor.setOptions(options);
Expand Down

0 comments on commit 0c3b3c6

Please sign in to comment.