Skip to content
This repository has been archived by the owner on Jun 9, 2019. It is now read-only.

noisy interaction in three.js based app #27

Open
tperkis opened this issue Jun 25, 2014 · 10 comments
Open

noisy interaction in three.js based app #27

tperkis opened this issue Jun 25, 2014 · 10 comments

Comments

@tperkis
Copy link

tperkis commented Jun 25, 2014

hi, i'm developing a 3d app that involves live sound synthesis, and we would like to use timbre.js for the awesome range of programming affordances it offers. But we've found that simple sound synthesis with timbre.js is interrupted by noise when we do any manipulation of our 3d model.

We've tried a range of other (less capable) libraries wrapping the Web Audio API, and have not had this same problem with them, but we'd much prefer to use timbre.js if we can solve this noise problem!

Our animation rendering is run by recursive calls to requestAnimationFrame(); running the app in Chrome 37.0.2062.0 dev. The 3d code is using three.js, with WebGL rendering.

my simple synthesis test, triggered by a mouse click is:

    var sine1 = T("sin", {freq:vcs(x), mul:0.2});
    var sine2 = T("sin", {freq:vcs(y), mul:0.2});
    var sine3 = T("sin", {freq:vcs(z), mul:0.2});
    T("perc", {r:900}, sine1, sine2, sine3).on("ended", function() {
     this.pause();
    }).bang().play();
@dirkk0
Copy link

dirkk0 commented Jul 8, 2014

Your code works perfectly without any background noise here: http://jsfiddle.net/dirkk0/3Ze9C/2/

Whatever problem there is must have to do with the code you didn't post.

@avh4
Copy link

avh4 commented Aug 24, 2014

The jsfiddle provided by dirkk0 plays noisily for me.

@mohayonao
Copy link
Owner

Timbre.js has performance problem.
I think it is difficult to resolve without redesign ignoring the compatibility.

@bassnode
Copy link

Perhaps this should be mentioned in the readme so devs know the limitations before spending time on implementation.

@avh4
Copy link

avh4 commented Aug 27, 2014

Thanks for the info. It sounds like timbre currently has no plans to do such a redesign? Are there any recommended alternative libraries that might be a good starting point for higher-performance audio synthesis for web-browser javascript?

@mohayonao
Copy link
Owner

I'm engaged on designing a new specification recently.
It will be optimized on Web Audio API to solve performance problem.
But, I maybe create another project, if too big change is needed.

@avh4
Copy link

avh4 commented Aug 27, 2014

Cool, I'll look forward to it.

@JackCA
Copy link

JackCA commented Aug 27, 2014

@mohayonao sounds great!

@dirkk0
Copy link

dirkk0 commented Aug 27, 2014

yes, it does!

@glompix
Copy link

glompix commented Sep 5, 2014

I agree! This is an exciting project for me. 👍

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants