audiocogs / ogg.js

An Ogg demuxer for aurora.js ported using emscripten

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Uncaught RangeError: Source is too large

pellaeon opened this issue · comments

On ogg.js#11494

Ogg.HEAPU8.set(this._stream.readBuffer(BUFFER_SIZE).data, this.buf);

(I beautified this for easy debugging)

I set breakpoint on that line and watched the variables:
BUFFER_SIZE:8192
this.buf:1802398516
Ogg.HEAPU8: Uint8Array[16777216]
(This was right before the error happened)

Stack trace:

Uncaught RangeError: Source is too large    ogg.js:11494
AV.Demuxer.extend.readChunk     ogg.js:11494
(anonymous function)    demuxer.coffee:18
EventEmitter.emit   events.coffee:25
(anonymous function)    http.coffee:51

Browser: Chromium 37

Hmm, haven't seen this before. Does this happen for all files for you, or just specific ones? If it's just a specific file, is it possible to upload somewhere so we can debug? Thanks!

I have tested a few files from different sources, all of them have the same problem.

Firefox also has this problem, the message is:

Error: invalid or out-of-range index

Any update on this? I followed your build instructions on OSX 10.9 (looks like your compileOgg.sh only works on OSX). I tried Emscripten 1.29 (latest) and 1.22, both of them produce the same error I described in this issue.

I have included aurora.js, vorbis.js, opus.js, flac.js and ogg.js

What is your build environment? Which version of Emscripten do you use?

This is one of the ogg files I tried (all of them produce the same error): http://upload.wikimedia.org/wikipedia/en/4/45/ACDC_-_Back_In_Black-sample.ogg