Skip to content

Commit 630bf62

Browse files
tcl3pbrw
authored andcommitted
LibWeb: Set OscillatorNode type in the constructor
1 parent 1cb0515 commit 630bf62

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

Libraries/LibWeb/WebAudio/OscillatorNode.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ WebIDL::ExceptionOr<GC::Ref<OscillatorNode>> OscillatorNode::construct_impl(JS::
4343

4444
OscillatorNode::OscillatorNode(JS::Realm& realm, GC::Ref<BaseAudioContext> context, OscillatorOptions const& options)
4545
: AudioScheduledSourceNode(realm, context)
46+
, m_type(options.type)
4647
, m_frequency(AudioParam::create(realm, options.frequency, -context->nyquist_frequency(), context->nyquist_frequency(), Bindings::AutomationRate::ARate))
4748
, m_detune(AudioParam::create(realm, options.detune, -1200 * AK::log2(NumericLimits<float>::max()), 1200 * AK::log2(NumericLimits<float>::max()), Bindings::AutomationRate::ARate))
4849
{

0 commit comments

Comments
 (0)