| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #ifndef MEDIA_BASE_TEST_HELPERS_H_ | 5 #ifndef MEDIA_BASE_TEST_HELPERS_H_ |
| 6 #define MEDIA_BASE_TEST_HELPERS_H_ | 6 #define MEDIA_BASE_TEST_HELPERS_H_ |
| 7 | 7 |
| 8 #include <stddef.h> | 8 #include <stddef.h> |
| 9 #include <memory> | 9 #include <memory> |
| 10 | 10 |
| (...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 77 }; | 77 }; |
| 78 | 78 |
| 79 // Provides pre-canned VideoDecoderConfig. These types are used for tests that | 79 // Provides pre-canned VideoDecoderConfig. These types are used for tests that |
| 80 // don't care about detailed parameters of the config. | 80 // don't care about detailed parameters of the config. |
| 81 class TestVideoConfig { | 81 class TestVideoConfig { |
| 82 public: | 82 public: |
| 83 // Returns a configuration that is invalid. | 83 // Returns a configuration that is invalid. |
| 84 static VideoDecoderConfig Invalid(); | 84 static VideoDecoderConfig Invalid(); |
| 85 | 85 |
| 86 static VideoDecoderConfig Normal(); | 86 static VideoDecoderConfig Normal(); |
| 87 static VideoDecoderConfig NormalH264(); |
| 87 static VideoDecoderConfig NormalEncrypted(); | 88 static VideoDecoderConfig NormalEncrypted(); |
| 88 | 89 |
| 89 // Returns a configuration that is larger in dimensions than Normal(). | 90 // Returns a configuration that is larger in dimensions than Normal(). |
| 90 static VideoDecoderConfig Large(); | 91 static VideoDecoderConfig Large(); |
| 91 static VideoDecoderConfig LargeEncrypted(); | 92 static VideoDecoderConfig LargeEncrypted(); |
| 92 | 93 |
| 93 // Returns coded size for Normal and Large config. | 94 // Returns coded size for Normal and Large config. |
| 94 static gfx::Size NormalCodedSize(); | 95 static gfx::Size NormalCodedSize(); |
| 95 static gfx::Size LargeCodedSize(); | 96 static gfx::Size LargeCodedSize(); |
| 96 | 97 |
| (...skipping 146 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 243 return CONTAINS_STRING( | 244 return CONTAINS_STRING( |
| 244 arg, "Audio buffer splice at PTS=" + base::IntToString(splice_time_us) + | 245 arg, "Audio buffer splice at PTS=" + base::IntToString(splice_time_us) + |
| 245 "us. Trimmed tail of overlapped buffer (PTS=" + | 246 "us. Trimmed tail of overlapped buffer (PTS=" + |
| 246 base::IntToString(overlapped_start_us) + "us) by " + | 247 base::IntToString(overlapped_start_us) + "us) by " + |
| 247 base::IntToString(trim_duration_us)); | 248 base::IntToString(trim_duration_us)); |
| 248 } | 249 } |
| 249 | 250 |
| 250 } // namespace media | 251 } // namespace media |
| 251 | 252 |
| 252 #endif // MEDIA_BASE_TEST_HELPERS_H_ | 253 #endif // MEDIA_BASE_TEST_HELPERS_H_ |
| OLD | NEW |