| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2011, Google Inc. All rights reserved. | 2 * Copyright (C) 2011, 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 98 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 109 if (!channelsMatch) | 109 if (!channelsMatch) |
| 110 return; | 110 return; |
| 111 | 111 |
| 112 bool isRenderBusAllocated = m_renderBus->length() >= renderQuantumSize; | 112 bool isRenderBusAllocated = m_renderBus->length() >= renderQuantumSize; |
| 113 ASSERT(isRenderBusAllocated); | 113 ASSERT(isRenderBusAllocated); |
| 114 if (!isRenderBusAllocated) | 114 if (!isRenderBusAllocated) |
| 115 return; | 115 return; |
| 116 | 116 |
| 117 // Synchronize with HRTFDatabaseLoader. | 117 // Synchronize with HRTFDatabaseLoader. |
| 118 // The database must be loaded before we can proceed. | 118 // The database must be loaded before we can proceed. |
| 119 HRTFDatabaseLoader* loader = HRTFDatabaseLoader::loader(); | 119 HRTFDatabaseLoader* loader = context()->hrtfDatabaseLoader(); |
| 120 ASSERT(loader); | 120 ASSERT(loader); |
| 121 if (!loader) | 121 if (!loader) |
| 122 return; | 122 return; |
| 123 | 123 |
| 124 loader->waitForLoaderThreadCompletion(); | 124 loader->waitForLoaderThreadCompletion(); |
| 125 | 125 |
| 126 // Break up the render target into smaller "render quantize" sized pieces. | 126 // Break up the render target into smaller "render quantize" sized pieces. |
| 127 // Render until we're finished. | 127 // Render until we're finished. |
| 128 size_t framesToProcess = m_renderTarget->length(); | 128 size_t framesToProcess = m_renderTarget->length(); |
| 129 unsigned numberOfChannels = m_renderTarget->numberOfChannels(); | 129 unsigned numberOfChannels = m_renderTarget->numberOfChannels(); |
| (...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 161 } | 161 } |
| 162 | 162 |
| 163 void OfflineAudioDestinationNode::notifyComplete() | 163 void OfflineAudioDestinationNode::notifyComplete() |
| 164 { | 164 { |
| 165 context()->fireCompletionEvent(); | 165 context()->fireCompletionEvent(); |
| 166 } | 166 } |
| 167 | 167 |
| 168 } // namespace WebCore | 168 } // namespace WebCore |
| 169 | 169 |
| 170 #endif // ENABLE(WEB_AUDIO) | 170 #endif // ENABLE(WEB_AUDIO) |
| OLD | NEW |