Titanium JIRA Archive
Appcelerator Community (AC)

[AC-2268] Using Codeboxed module.. need Sampling Bitrate optimization

GitHub Issuen/a
TypeBug
Priorityn/a
StatusClosed
ResolutionNot Our Bug
Resolution Date2013-04-01T21:17:56.000+0000
Affected Version/sn/a
Fix Version/sn/a
ComponentsTitanium SDK & CLI
LabelsAndroid,, Bitrate, codeboxed, recording
ReporterPrashant Sheth
AssigneeShak Hossain
Created2012-10-11T18:06:27.000+0000
Updated2016-03-08T07:41:16.000+0000

Description

We are initiating a wav recording with the 8000Kpbs sampling rate. However the file size produced from this is too large (300KB) for the performance of the app. We need to be able to try 4000 and then 8000. But 4000 fails on some phones. In Native Android, there's a "minBufferSize" approach that provides the MinBufferSize, but this is not available to us in Titanium. How do we determine a device's minBuffersize that we can use? This is the code we are using in Codeboxed that fails. var recording = audioRecorder.createAudioRecord({ fileName : 'test1', //sampleRate : _OBJ.SUPPORTED_SAMPLE_RATE[count], sampleRate : 4000, audioEncoding : 16, audioChannel : 'STEREO', audioSource : 'MIC', audioFormat : 'WAV' }); try {   recording.start();   startAnimation();  } catch(e) {   recording.sampleRate = 8000;   recording.start();   startAnimation();  } This does't seem to catch the exception at 4000 and we get an "Exceeded Buffer Size" exception.

Comments

  1. Pedro Enrique 2013-04-01

    Please contact the module developer about issues and features with their module: https://marketplace.appcelerator.com/apps/1215?347726402#support

JSON Source