gainNodes = [context.createGain(), context.createGain()]; gainNodes[0].gain.value = 1 - $('.range1').val(); gainNodes[1].gain.value = $('.range1').val();