Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(857)

Side by Side Diff: third_party/WebKit/Source/modules/webaudio/BaseAudioContext.cpp

Issue 2760353002: Define default values for options dictionaries for WebAudio (Closed)
Patch Set: Rebase Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010, Google Inc. All rights reserved. 2 * Copyright (C) 2010, Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 520 matching lines...) Expand 10 before | Expand all | Expand 10 after
531 return PeriodicWave::Create(*this, real, imag, false, exception_state); 531 return PeriodicWave::Create(*this, real, imag, false, exception_state);
532 } 532 }
533 533
534 PeriodicWave* BaseAudioContext::createPeriodicWave( 534 PeriodicWave* BaseAudioContext::createPeriodicWave(
535 DOMFloat32Array* real, 535 DOMFloat32Array* real,
536 DOMFloat32Array* imag, 536 DOMFloat32Array* imag,
537 const PeriodicWaveConstraints& options, 537 const PeriodicWaveConstraints& options,
538 ExceptionState& exception_state) { 538 ExceptionState& exception_state) {
539 DCHECK(IsMainThread()); 539 DCHECK(IsMainThread());
540 540
541 bool disable = options.hasDisableNormalization() 541 bool disable = options.disableNormalization();
542 ? options.disableNormalization()
543 : false;
544 542
545 return PeriodicWave::Create(*this, real, imag, disable, exception_state); 543 return PeriodicWave::Create(*this, real, imag, disable, exception_state);
546 } 544 }
547 545
548 IIRFilterNode* BaseAudioContext::createIIRFilter( 546 IIRFilterNode* BaseAudioContext::createIIRFilter(
549 Vector<double> feedforward_coef, 547 Vector<double> feedforward_coef,
550 Vector<double> feedback_coef, 548 Vector<double> feedback_coef,
551 ExceptionState& exception_state) { 549 ExceptionState& exception_state) {
552 DCHECK(IsMainThread()); 550 DCHECK(IsMainThread());
553 551
(...skipping 367 matching lines...) Expand 10 before | Expand all | Expand 10 after
921 } 919 }
922 920
923 SecurityOrigin* BaseAudioContext::GetSecurityOrigin() const { 921 SecurityOrigin* BaseAudioContext::GetSecurityOrigin() const {
924 if (GetExecutionContext()) 922 if (GetExecutionContext())
925 return GetExecutionContext()->GetSecurityOrigin(); 923 return GetExecutionContext()->GetSecurityOrigin();
926 924
927 return nullptr; 925 return nullptr;
928 } 926 }
929 927
930 } // namespace blink 928 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698