This page is Ready to Use

Notice: The WebPlatform project, supported by various stewards between 2012 and 2015, has been discontinued. This site is now available on github.

attack

Summary

The amount of time (in seconds) to reduce the gain by 10dB. Its default value is 0.003, with a nominal range of 0 to 1. This parameter is k-rate.

Property of apis/webaudio/DynamicsCompressorNodeapis/webaudio/DynamicsCompressorNode

Syntax

Note: This property is read-only.

var result = DynamicsCompressorNode.attack;

Return Value

Returns an object of type NumberNumber

Examples

var audioCtx = new AudioContext();
var compressor = audioCtx.createDynamicsCompressor();
compressor.attack.value = 0;

Related specifications

W3C Web Audio API
W3C Editor’s Draft