| 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 156 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 167 m_nodeType = type; | 167 m_nodeType = type; |
| 168 | 168 |
| 169 #if DEBUG_AUDIONODE_REFERENCES | 169 #if DEBUG_AUDIONODE_REFERENCES |
| 170 ++s_nodeCount[type]; | 170 ++s_nodeCount[type]; |
| 171 fprintf(stderr, "[%16p]: %16p: %2d: AudioHandler::AudioHandler [%3d]\n", | 171 fprintf(stderr, "[%16p]: %16p: %2d: AudioHandler::AudioHandler [%3d]\n", |
| 172 context(), this, getNodeType(), s_nodeCount[getNodeType()]); | 172 context(), this, getNodeType(), s_nodeCount[getNodeType()]); |
| 173 #endif | 173 #endif |
| 174 } | 174 } |
| 175 | 175 |
| 176 void AudioHandler::addInput() { | 176 void AudioHandler::addInput() { |
| 177 m_inputs.append(AudioNodeInput::create(*this)); | 177 m_inputs.push_back(AudioNodeInput::create(*this)); |
| 178 } | 178 } |
| 179 | 179 |
| 180 void AudioHandler::addOutput(unsigned numberOfChannels) { | 180 void AudioHandler::addOutput(unsigned numberOfChannels) { |
| 181 DCHECK(isMainThread()); | 181 DCHECK(isMainThread()); |
| 182 m_outputs.append(AudioNodeOutput::create(this, numberOfChannels)); | 182 m_outputs.push_back(AudioNodeOutput::create(this, numberOfChannels)); |
| 183 node()->didAddOutput(numberOfOutputs()); | 183 node()->didAddOutput(numberOfOutputs()); |
| 184 } | 184 } |
| 185 | 185 |
| 186 AudioNodeInput& AudioHandler::input(unsigned i) { | 186 AudioNodeInput& AudioHandler::input(unsigned i) { |
| 187 return *m_inputs[i]; | 187 return *m_inputs[i]; |
| 188 } | 188 } |
| 189 | 189 |
| 190 AudioNodeOutput& AudioHandler::output(unsigned i) { | 190 AudioNodeOutput& AudioHandler::output(unsigned i) { |
| 191 return *m_outputs[i]; | 191 return *m_outputs[i]; |
| 192 } | 192 } |
| (...skipping 743 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 936 | 936 |
| 937 const AtomicString& AudioNode::interfaceName() const { | 937 const AtomicString& AudioNode::interfaceName() const { |
| 938 return EventTargetNames::AudioNode; | 938 return EventTargetNames::AudioNode; |
| 939 } | 939 } |
| 940 | 940 |
| 941 ExecutionContext* AudioNode::getExecutionContext() const { | 941 ExecutionContext* AudioNode::getExecutionContext() const { |
| 942 return context()->getExecutionContext(); | 942 return context()->getExecutionContext(); |
| 943 } | 943 } |
| 944 | 944 |
| 945 void AudioNode::didAddOutput(unsigned numberOfOutputs) { | 945 void AudioNode::didAddOutput(unsigned numberOfOutputs) { |
| 946 m_connectedNodes.append(nullptr); | 946 m_connectedNodes.push_back(nullptr); |
| 947 DCHECK_EQ(numberOfOutputs, m_connectedNodes.size()); | 947 DCHECK_EQ(numberOfOutputs, m_connectedNodes.size()); |
| 948 m_connectedParams.append(nullptr); | 948 m_connectedParams.push_back(nullptr); |
| 949 DCHECK_EQ(numberOfOutputs, m_connectedParams.size()); | 949 DCHECK_EQ(numberOfOutputs, m_connectedParams.size()); |
| 950 } | 950 } |
| 951 | 951 |
| 952 } // namespace blink | 952 } // namespace blink |
| OLD | NEW |