Comments (9)
+1
from aurora.js.
+1 - I don't usually post like this, but seeking, either in chunks (+/- 5 seconds) or in slider form would be extremely useful.
from aurora.js.
+1 me too
from aurora.js.
+1
:-)
from aurora.js.
+1
Would it be possible to somehow start decoding from a arbitrary position in an mp3 file. I'm trying to implement real time decoding of an mp3, so I can feed the decoded pcm data directly into a JavascriptAudioNode's output.
//example
var startTime = 5; // in seconds
var byteOffset = timeToByte(startTime); // convert seconds to byte location?
asset.on('decodeStart', function() {
var list = new BufferList;
asset.on('data', function(buffer) {
list.push(new Buffer(buffer));
asset.decoder.readChunk();
});
asset.decoder.readChunk();
}, byteOffset);
asset.start();
I'm fairly new to this type of low level audio programming, so if this is way off base please let me know. :)
from aurora.js.
+1
from aurora.js.
As of 2ec2d60, basic support for seeking has been added to the namespace branch. It works fairly well as long as you don't try seeking to part of a file that hasn't been loaded yet - still need to work on that.
Basically, uncompressed formats seek by using the format's bytesPerPacket
and framesPerPacket
properties, and compressed formats seek using a seek table generated by the demuxer. The player converts the timestamp from milliseconds to a sample number, and asks the decoder to seek to that sample number. In turn, the decoder asks the demuxer for a seek point closest to the given sample and jumps to that offset, and playback resumes at the new time.
Let me know if you have improvements or suggestions. Leaving this open for now. Cheers!
from aurora.js.
Will the changes for seeking be moved into master? I noticed that this project has been inactive for 3 months. Is there a reason development has fallen off?
from aurora.js.
Yes, they will. I've just been busy with other things lately. I'll get to it soon, but for now, I'd suggest just using the namespace
branch instead of master.
from aurora.js.
Related Issues (20)
- How do I decode to raw, resample to 44,1khz and split stereo into dual mono buffers?
- "Something is wrong in HTTPSource.loop" while using AV.Asset.fromURL(remoteUrl)
- [Solved]switch backend from Speaker to PortAudio(naudiodon)
- Aurora not playing certain flac files with no error
- Live decoding on Android
- Node example HOT 1
- No default jsDelivr CDN file set
- Problems with 24-bit WAV files
- Questions about memory manage.
- Is decoding a specific part of a gargantuan file supported efficiently? HOT 3
- HTTP requests still sending to server even if HTTP error is returned
- Unit tests fail on master branch
- Chrome browser change for same site cookies
- gyp build fail HOT 1
- build for browser
- m4a demuxer fails when processing a file with co64 atom
- Window Not Defined
- decode fail
- How to install additional codecs? HOT 1
- Uncaught SyntaxError: Unexpected identifier 'key'
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from aurora.js.