| 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 * 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 154 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 165 DCHECK(deferredTaskHandler().isAudioThread()); | 165 DCHECK(deferredTaskHandler().isAudioThread()); |
| 166 | 166 |
| 167 return m_internalSummingBus.get(); | 167 return m_internalSummingBus.get(); |
| 168 } | 168 } |
| 169 | 169 |
| 170 void AudioNodeInput::sumAllConnections(AudioBus* summingBus, size_t framesToProc
ess) | 170 void AudioNodeInput::sumAllConnections(AudioBus* summingBus, size_t framesToProc
ess) |
| 171 { | 171 { |
| 172 DCHECK(deferredTaskHandler().isAudioThread()); | 172 DCHECK(deferredTaskHandler().isAudioThread()); |
| 173 | 173 |
| 174 // We shouldn't be calling this method if there's only one connection, since
it's less efficient. | 174 // We shouldn't be calling this method if there's only one connection, since
it's less efficient. |
| 175 DCHECK(numberOfRenderingConnections() > 1 || handler().internalChannelCountM
ode() != AudioHandler::Max); | 175 // DCHECK(numberOfRenderingConnections() > 1 || handler().internalChannel
CountMode() != AudioHandler::Max); |
| 176 | 176 |
| 177 DCHECK(summingBus); | 177 DCHECK(summingBus); |
| 178 if (!summingBus) | 178 if (!summingBus) |
| 179 return; | 179 return; |
| 180 | 180 |
| 181 summingBus->zero(); | 181 summingBus->zero(); |
| 182 | 182 |
| 183 AudioBus::ChannelInterpretation interpretation = handler().internalChannelIn
terpretation(); | 183 AudioBus::ChannelInterpretation interpretation = handler().internalChannelIn
terpretation(); |
| 184 | 184 |
| 185 for (unsigned i = 0; i < numberOfRenderingConnections(); ++i) { | 185 for (unsigned i = 0; i < numberOfRenderingConnections(); ++i) { |
| (...skipping 29 matching lines...) Expand all Loading... |
| 215 } | 215 } |
| 216 | 216 |
| 217 // Handle multiple connections case. | 217 // Handle multiple connections case. |
| 218 sumAllConnections(internalSummingBus, framesToProcess); | 218 sumAllConnections(internalSummingBus, framesToProcess); |
| 219 | 219 |
| 220 return internalSummingBus; | 220 return internalSummingBus; |
| 221 } | 221 } |
| 222 | 222 |
| 223 } // namespace blink | 223 } // namespace blink |
| 224 | 224 |
| OLD | NEW |