Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8848705
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T12:28:51+00:00 2026-06-14T12:28:51+00:00

I’m using Web Audio API with javascript. I create an oscillator, connect it to

  • 0

I’m using Web Audio API with javascript.

I create an oscillator, connect it to the volume (gainNode), connect it to a destination.

Ok. Nice.

I want a delay effect, I stick it between oscillator and volume.

Well, that doesn’t work, I only hear the delay. Although, it is clean.

Ok, so I connect the osc to the delay to the volume, and the osc to the volume, then the volume to the destination.

Now it seems to be distorted.

I tried osc to delay to volume to destination, with osc to destination so there are two connections to the destination. That too is distorted.

That’s on chrome.

In the little time I’ve had to try it, it seems to work right on iOS6. Don’t know about safari.

Try it by going to http://cloudmusiccompany.appspot.com/watch.jsp and clicking red and drawing. That’s a normal sine osc. Now click white and draw, that is the same withing with the delay, and on chrome (Ubuntu) it is distorted. Don’t know about Safar.

Obviously you can see the full source at the link because its javascript.

Relevant source:

function makeNewChannel(color){
  var info = getInstrumentInfo(color);
  var chan = {osc: acontext.createOscillator(),
    freqs: [],
    times: [],
    pxdata: [],
    i: 0,
    muted: true,
    finishedLoop: false, 
    volume: acontext.createGainNode(), 
    gate: acontext.createGainNode(), 
    delay: acontext.createDelayNode(),
    delayGain: acontext.createGainNode(), 
    mute: function(){
      this.muted = true;
      this.volume.gain.value = 0;
    },
    unmute: function(){
      this.muted = false;
      this.volume.gain.value = player.defaultGain / (info.soft ? 2 : 1);
    }
  }
  chan.osc.type = info.type;

  //        chan.osc.connect(chan.gate);
  chan.osc.connect(chan.volume);

  chan.delayGain.gain.value = player.defaultGain ;
  /* ugh , the wet sounds ok, but somehow its distorting or doubling the dry signal
   * although it seems ok on iphone?
   * */
  if (info.delay){
    chan.delay.delayTime.value = 0.5;
    chan.volume.connect(chan.delay)
    chan.delay.connect(chan.delayGain);

    chan.delayGain.connect(acontext.destination);

  }
  chan.volume.gain.value = 0; //player.defaultGain;
  chan.gate.gain.value = 0;
  chan.volume.connect(acontext.destination);
  chan.osc.frequency.value = 0;

  chan.osc.noteOn(0);
  return chan;
}
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T12:28:52+00:00Added an answer on June 14, 2026 at 12:28 pm

    I just had a chance to use it on Chrome on Windows, and it works fine. Delay sounds like it should.

    This must be a bug in the Linux version (of chrome)

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

That's pretty much it. I'm using Nokogiri to scrape a web page what has
I am reading a book about Javascript and jQuery and using one of the
I'm making a simple page using Google Maps API 3. My first. One marker
I'm new to using the Perl treebuilder module for HTML parsing and can't figure
I have a string like this: La Torre Eiffel paragonata all’Everest What PHP function
link Im having trouble converting the html entites into html characters, (&# 8217;) i
I want to count how many characters a certain string has in PHP, but
Seemingly simple, but I cannot find anything relevant on the web. What is the
I have a small JavaScript validation script that validates inputs based on Regex. I
I'm using v2.0 of ClassTextile.php, with the following call: $testimonial_text = $textile->TextileRestricted($_POST['testimonial']); ... and

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.