New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
PhoneGap 3.x #4
Comments
I moved away from this plugin to a simpler solution. I don't need to record in WAV and then compress. Doing it in two steps was a hack. That two step process, for me, caused the UI to hang for ~250ms during the compress step which made running animations jump. For my application it is better to just record directly into a minimal format. Here is how I did that: note: This is the mod I made in Cordova 2.X but I imagine you could figure out how to patch this into 3.X easily Step 1: add this to the startRecordingAudio method on SDVSound.m before
Then I replaced:
With:
This records directly in M4A, mono in a relatively low fi (16K) format. For my application, which is just capturing words, not music this is just what I needed. Note: when you make this change I got an error until I changed the contained file to a M4A ( eg. it erred when trying to use these setting to record into a file named xxx.wav). |
Wow, that is so much better. I wonder why Cordova doesn't allow passing these settings in? Anyway, I will give it a shot; seems simple enough. |
I just wanted to follow up with one more change you left out, in case anyone else comes across this. I changed it to: Thanks again for pointing out this approach. |
record to m4a 16K mono to minimize file size based on keenan/cordova-phonegap-audio-encode#4
where do we find this SDVSound.m file please? |
OK nevermind! got it. |
Has anyone updated this plugin for PhoneGap 3.x? I understand it has a new plugin architecture. This plugin has been a lifesaver, and I'm still using it on PhoneGap 2.9, but thinking about upgrading.
The text was updated successfully, but these errors were encountered: