| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/base/test_data_util.h" | 5 #include "media/base/test_data_util.h" |
| 6 | 6 |
| 7 #include "base/file_util.h" | 7 #include "base/file_util.h" |
| 8 #include "base/logging.h" | 8 #include "base/logging.h" |
| 9 #include "base/path_service.h" | 9 #include "base/path_service.h" |
| 10 #include "media/ffmpeg/ffmpeg_common.h" | 10 #include "media/ffmpeg/ffmpeg_common.h" |
| (...skipping 24 matching lines...) Expand all Loading... |
| 35 reinterpret_cast<char*>(buffer->get()), | 35 reinterpret_cast<char*>(buffer->get()), |
| 36 file_size)) | 36 file_size)) |
| 37 << "Failed to read '" << name << "'"; | 37 << "Failed to read '" << name << "'"; |
| 38 *size = file_size; | 38 *size = file_size; |
| 39 } | 39 } |
| 40 | 40 |
| 41 void ReadTestDataFile(const std::string& name, scoped_refptr<Buffer>* buffer) { | 41 void ReadTestDataFile(const std::string& name, scoped_refptr<Buffer>* buffer) { |
| 42 scoped_array<uint8> buf; | 42 scoped_array<uint8> buf; |
| 43 int buf_size; | 43 int buf_size; |
| 44 ReadTestDataFile(name, &buf, &buf_size); | 44 ReadTestDataFile(name, &buf, &buf_size); |
| 45 *buffer = new DataBuffer(buf.release(), buf_size); | 45 *buffer = new DataBuffer(buf.Pass(), buf_size); |
| 46 } | 46 } |
| 47 | 47 |
| 48 } // namespace media | 48 } // namespace media |
| OLD | NEW |