| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2012, Google Inc. All rights reserved. | 2 * Copyright (C) 2012, 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 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 58 audio_sources.push_back(source_.Get()); | 58 audio_sources.push_back(source_.Get()); |
| 59 MediaStreamSourceVector video_sources; | 59 MediaStreamSourceVector video_sources; |
| 60 stream_ = MediaStream::Create( | 60 stream_ = MediaStream::Create( |
| 61 node.context()->GetExecutionContext(), | 61 node.context()->GetExecutionContext(), |
| 62 MediaStreamDescriptor::Create(audio_sources, video_sources)); | 62 MediaStreamDescriptor::Create(audio_sources, video_sources)); |
| 63 MediaStreamCenter::Instance().DidCreateMediaStreamAndTracks( | 63 MediaStreamCenter::Instance().DidCreateMediaStreamAndTracks( |
| 64 stream_->Descriptor()); | 64 stream_->Descriptor()); |
| 65 | 65 |
| 66 source_->SetAudioFormat(number_of_channels, node.context()->sampleRate()); | 66 source_->SetAudioFormat(number_of_channels, node.context()->sampleRate()); |
| 67 | 67 |
| 68 SetInternalChannelCountMode(kExplicit); |
| 68 Initialize(); | 69 Initialize(); |
| 69 } | 70 } |
| 70 | 71 |
| 71 PassRefPtr<MediaStreamAudioDestinationHandler> | 72 PassRefPtr<MediaStreamAudioDestinationHandler> |
| 72 MediaStreamAudioDestinationHandler::Create(AudioNode& node, | 73 MediaStreamAudioDestinationHandler::Create(AudioNode& node, |
| 73 size_t number_of_channels) { | 74 size_t number_of_channels) { |
| 74 return AdoptRef( | 75 return AdoptRef( |
| 75 new MediaStreamAudioDestinationHandler(node, number_of_channels)); | 76 new MediaStreamAudioDestinationHandler(node, number_of_channels)); |
| 76 } | 77 } |
| 77 | 78 |
| (...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 181 node->HandleChannelOptions(options, exception_state); | 182 node->HandleChannelOptions(options, exception_state); |
| 182 | 183 |
| 183 return node; | 184 return node; |
| 184 } | 185 } |
| 185 | 186 |
| 186 MediaStream* MediaStreamAudioDestinationNode::stream() const { | 187 MediaStream* MediaStreamAudioDestinationNode::stream() const { |
| 187 return static_cast<MediaStreamAudioDestinationHandler&>(Handler()).Stream(); | 188 return static_cast<MediaStreamAudioDestinationHandler&>(Handler()).Stream(); |
| 188 } | 189 } |
| 189 | 190 |
| 190 } // namespace blink | 191 } // namespace blink |
| OLD | NEW |