| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "media/remoting/remote_demuxer_stream_adapter.h" | 5 #include "media/remoting/remote_demuxer_stream_adapter.h" |
| 6 | 6 |
| 7 #include "base/base64.h" | 7 #include "base/base64.h" |
| 8 #include "base/bind.h" | 8 #include "base/bind.h" |
| 9 #include "media/base/bind_to_current_loop.h" | 9 #include "media/base/bind_to_current_loop.h" |
| 10 #include "media/base/decoder_buffer.h" | 10 #include "media/base/decoder_buffer.h" |
| (...skipping 215 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 226 return; | 226 return; |
| 227 } | 227 } |
| 228 | 228 |
| 229 switch (status) { | 229 switch (status) { |
| 230 case ::media::DemuxerStream::kAborted: | 230 case ::media::DemuxerStream::kAborted: |
| 231 DCHECK(!input); | 231 DCHECK(!input); |
| 232 SendReadAck(callback_handle); | 232 SendReadAck(callback_handle); |
| 233 return; | 233 return; |
| 234 case ::media::DemuxerStream::kConfigChanged: | 234 case ::media::DemuxerStream::kConfigChanged: |
| 235 // TODO(erickung): consider sending updated Audio/Video decoder config to | 235 // TODO(erickung): consider sending updated Audio/Video decoder config to |
| 236 // RemotingController. | 236 // RemotingRendererController. |
| 237 // Stores available audio/video decoder config and issues | 237 // Stores available audio/video decoder config and issues |
| 238 // RPC_DS_READUNTIL_CALLBACK RPC to notify receiver. | 238 // RPC_DS_READUNTIL_CALLBACK RPC to notify receiver. |
| 239 DCHECK(!input); | 239 DCHECK(!input); |
| 240 media_status_ = status; | 240 media_status_ = status; |
| 241 if (demuxer_stream_->type() == ::media::DemuxerStream::VIDEO) | 241 if (demuxer_stream_->type() == ::media::DemuxerStream::VIDEO) |
| 242 video_config_ = demuxer_stream_->video_decoder_config(); | 242 video_config_ = demuxer_stream_->video_decoder_config(); |
| 243 if (demuxer_stream_->type() == ::media::DemuxerStream::AUDIO) | 243 if (demuxer_stream_->type() == ::media::DemuxerStream::AUDIO) |
| 244 audio_config_ = demuxer_stream_->audio_decoder_config(); | 244 audio_config_ = demuxer_stream_->audio_decoder_config(); |
| 245 SendReadAck(callback_handle); | 245 SendReadAck(callback_handle); |
| 246 return; | 246 return; |
| (...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 384 } | 384 } |
| 385 | 385 |
| 386 if (write_watcher_.IsWatching()) { | 386 if (write_watcher_.IsWatching()) { |
| 387 VLOG(2) << "Cancel mojo data pipe watcher"; | 387 VLOG(2) << "Cancel mojo data pipe watcher"; |
| 388 write_watcher_.Cancel(); | 388 write_watcher_.Cancel(); |
| 389 } | 389 } |
| 390 } | 390 } |
| 391 | 391 |
| 392 } // namespace remoting | 392 } // namespace remoting |
| 393 } // namespace media | 393 } // namespace media |
| OLD | NEW |