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

Side by Side Diff: Source/platform/audio/AudioDSPKernel.h

Issue 906233002: Use nullptr instead of 0 in WebAudio (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: rebase Created 5 years, 10 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
« no previous file with comments | « Source/platform/audio/AudioChannel.h ('k') | Source/platform/audio/AudioDestination.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 28 matching lines...) Expand all
39 39
40 class PLATFORM_EXPORT AudioDSPKernel { 40 class PLATFORM_EXPORT AudioDSPKernel {
41 public: 41 public:
42 AudioDSPKernel(AudioDSPKernelProcessor* kernelProcessor) 42 AudioDSPKernel(AudioDSPKernelProcessor* kernelProcessor)
43 : m_kernelProcessor(kernelProcessor) 43 : m_kernelProcessor(kernelProcessor)
44 , m_sampleRate(kernelProcessor->sampleRate()) 44 , m_sampleRate(kernelProcessor->sampleRate())
45 { 45 {
46 } 46 }
47 47
48 AudioDSPKernel(float sampleRate) 48 AudioDSPKernel(float sampleRate)
49 : m_kernelProcessor(0) 49 : m_kernelProcessor(nullptr)
50 , m_sampleRate(sampleRate) 50 , m_sampleRate(sampleRate)
51 { 51 {
52 } 52 }
53 53
54 virtual ~AudioDSPKernel(); 54 virtual ~AudioDSPKernel();
55 55
56 // Subclasses must override process() to do the processing and reset() to re set DSP state. 56 // Subclasses must override process() to do the processing and reset() to re set DSP state.
57 virtual void process(const float* source, float* destination, size_t framesT oProcess) = 0; 57 virtual void process(const float* source, float* destination, size_t framesT oProcess) = 0;
58 virtual void reset() = 0; 58 virtual void reset() = 0;
59 59
(...skipping 14 matching lines...) Expand all
74 // do that because AudioDSPKernel can be allocated in audio threads 74 // do that because AudioDSPKernel can be allocated in audio threads
75 // (which are not registered to Oilpan). 75 // (which are not registered to Oilpan).
76 GC_PLUGIN_IGNORE("http://crbug.com/404578") 76 GC_PLUGIN_IGNORE("http://crbug.com/404578")
77 AudioDSPKernelProcessor* m_kernelProcessor; 77 AudioDSPKernelProcessor* m_kernelProcessor;
78 float m_sampleRate; 78 float m_sampleRate;
79 }; 79 };
80 80
81 } // namespace blink 81 } // namespace blink
82 82
83 #endif // AudioDSPKernel_h 83 #endif // AudioDSPKernel_h
OLDNEW
« no previous file with comments | « Source/platform/audio/AudioChannel.h ('k') | Source/platform/audio/AudioDestination.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698