Chromium Code Reviews
DescriptionSlightly reduce memory usage in OscillatorNode
When an OscillatorNode is created, a PeriodicWave is created for a
"sine" oscillator. This is unavoidable when the factory method is
used. However, with the constructor, the type of oscillator can be
specified and there is no need to create both a "sine" PeriodicWave
and one for the specified type.
Thus, for the constructor, only create the wave table for the
specified type.
BUG=700175
TEST=not testable; manually verifed with prints/debugger that sine
table is not created unless needed.
Review-Url: https://codereview.chromium.org/2767623002
Cr-Commit-Position: refs/heads/master@{#466134}
Committed: https://chromium.googlesource.com/chromium/src/+/aa8cf68adc5654695f83f355d601eba127f16d75
Patch Set 1 #Patch Set 2 : Adjust setting of type in OscillatorHandler constructor #Patch Set 3 : Rebase #Patch Set 4 : Don't set the oscillator type twice. #Patch Set 5 : Rebase #
Messages
Total messages: 11 (7 generated)
|
|||||||||||||||||||||||||||||||||||||