| 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/filters/memory_data_source.h" | 5 #include "media/filters/memory_data_source.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 | 8 |
| 9 #include "base/logging.h" | 9 #include "base/logging.h" |
| 10 | 10 |
| (...skipping 25 matching lines...) Expand all Loading... |
| 36 memcpy(data, data_ + position, clamped_size); | 36 memcpy(data, data_ + position, clamped_size); |
| 37 } | 37 } |
| 38 | 38 |
| 39 read_cb.Run(clamped_size); | 39 read_cb.Run(clamped_size); |
| 40 } | 40 } |
| 41 | 41 |
| 42 void MemoryDataSource::Stop() { | 42 void MemoryDataSource::Stop() { |
| 43 is_stopped_ = true; | 43 is_stopped_ = true; |
| 44 } | 44 } |
| 45 | 45 |
| 46 void MemoryDataSource::Abort() {} |
| 47 |
| 46 bool MemoryDataSource::GetSize(int64_t* size_out) { | 48 bool MemoryDataSource::GetSize(int64_t* size_out) { |
| 47 *size_out = size_; | 49 *size_out = size_; |
| 48 return true; | 50 return true; |
| 49 } | 51 } |
| 50 | 52 |
| 51 bool MemoryDataSource::IsStreaming() { | 53 bool MemoryDataSource::IsStreaming() { |
| 52 return false; | 54 return false; |
| 53 } | 55 } |
| 54 | 56 |
| 55 void MemoryDataSource::SetBitrate(int bitrate) {} | 57 void MemoryDataSource::SetBitrate(int bitrate) {} |
| 56 | 58 |
| 57 } // namespace media | 59 } // namespace media |
| OLD | NEW |