OLD | NEW |
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 * | 7 * |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. 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 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
115 | 115 |
116 if (hasRealtimeConstraint && !isBackgroundStage && fftSize > m_maxRealti
meFFTSize) | 116 if (hasRealtimeConstraint && !isBackgroundStage && fftSize > m_maxRealti
meFFTSize) |
117 fftSize = m_maxRealtimeFFTSize; | 117 fftSize = m_maxRealtimeFFTSize; |
118 if (fftSize > m_maxFFTSize) | 118 if (fftSize > m_maxFFTSize) |
119 fftSize = m_maxFFTSize; | 119 fftSize = m_maxFFTSize; |
120 } | 120 } |
121 | 121 |
122 // Start up background thread | 122 // Start up background thread |
123 // FIXME: would be better to up the thread priority here. It doesn't need t
o be real-time, but higher than the default... | 123 // FIXME: would be better to up the thread priority here. It doesn't need t
o be real-time, but higher than the default... |
124 if (useBackgroundThreads && m_backgroundStages.size() > 0) | 124 if (useBackgroundThreads && m_backgroundStages.size() > 0) |
125 m_backgroundThread = adoptPtr(blink::Platform::current()->createThread("
Reverb convolution background thread")); | 125 m_backgroundThread = adoptPtr(Platform::current()->createThread("Reverb
convolution background thread")); |
126 } | 126 } |
127 | 127 |
128 ReverbConvolver::~ReverbConvolver() | 128 ReverbConvolver::~ReverbConvolver() |
129 { | 129 { |
130 // Wait for background thread to stop | 130 // Wait for background thread to stop |
131 m_backgroundThread.clear(); | 131 m_backgroundThread.clear(); |
132 } | 132 } |
133 | 133 |
134 void ReverbConvolver::processInBackground() | 134 void ReverbConvolver::processInBackground() |
135 { | 135 { |
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
192 } | 192 } |
193 | 193 |
194 size_t ReverbConvolver::latencyFrames() const | 194 size_t ReverbConvolver::latencyFrames() const |
195 { | 195 { |
196 return 0; | 196 return 0; |
197 } | 197 } |
198 | 198 |
199 } // namespace blink | 199 } // namespace blink |
200 | 200 |
201 #endif // ENABLE(WEB_AUDIO) | 201 #endif // ENABLE(WEB_AUDIO) |
OLD | NEW |