You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cordova.apache.org by "James Collings (JIRA)" <ji...@apache.org> on 2015/12/11 14:38:11 UTC

[jira] [Created] (CB-10188) iOS Cordova Media Plugin reports wrong Subchunk2Size always 4044 when reading a recorded wav

James Collings created CB-10188:
-----------------------------------

             Summary: iOS Cordova Media Plugin reports wrong Subchunk2Size always 4044 when reading a recorded wav
                 Key: CB-10188
                 URL: https://issues.apache.org/jira/browse/CB-10188
             Project: Apache Cordova
          Issue Type: Bug
          Components: Plugin Media
         Environment: iOS Simulator and iOS Device
            Reporter: James Collings
            Priority: Minor


cordova-plugin-media: v1.0.1

I am using the cordova-plugin-media to record wav files, then i take that file and read the wav header this is what it reports:

{noformat}
[Log] ----debugWAVHeader---- (recorderDemo.js, line 485)
[Log] ChunkSize – 332748 (recorderDemo.js, line 488)
[Log] Subchunk1Size – 16 (recorderDemo.js, line 490)
[Log] AudioFormat – 1 (recorderDemo.js, line 492)
[Log] NumChannels – 2 (recorderDemo.js, line 494)
[Log] SampleRate – 44100 (recorderDemo.js, line 496)
[Log] ByteRate – 176400 (recorderDemo.js, line 498)
[Log] BlockAlign – 4 (recorderDemo.js, line 500)
[Log] BitsPerSample – 16 (recorderDemo.js, line 502)
[Log] Subchunk2Size – 4044 (recorderDemo.js, line 504)
{noformat}

The Subchunk2Size which is the 40th byte within the wav header, no matter the length of track the saved file always has a Subchunk2Size of 4044.

I am reading the header for the file as a blob, using a dataview to get the value.

{noformat}
var header = new DataView(this.result);
console.log('Subchunk2Size', header.getUint32(40, true) );
{noformat}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org