| 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_VIDEO_DECODER_CONFIG_H_ | 5 #ifndef MEDIA_BASE_VIDEO_DECODER_CONFIG_H_ |
| 6 #define MEDIA_BASE_VIDEO_DECODER_CONFIG_H_ | 6 #define MEDIA_BASE_VIDEO_DECODER_CONFIG_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <string> | 10 #include <string> |
| (...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 92 | 92 |
| 93 // Region of |coded_size_| that is visible. | 93 // Region of |coded_size_| that is visible. |
| 94 gfx::Rect visible_rect() const { return visible_rect_; } | 94 gfx::Rect visible_rect() const { return visible_rect_; } |
| 95 | 95 |
| 96 // Final visible width and height of a video frame with aspect ratio taken | 96 // Final visible width and height of a video frame with aspect ratio taken |
| 97 // into account. | 97 // into account. |
| 98 gfx::Size natural_size() const { return natural_size_; } | 98 gfx::Size natural_size() const { return natural_size_; } |
| 99 | 99 |
| 100 // Optional byte data required to initialize video decoders, such as H.264 | 100 // Optional byte data required to initialize video decoders, such as H.264 |
| 101 // AVCC data. | 101 // AVCC data. |
| 102 void SetExtraData(const std::vector<uint8_t>& extra_data); |
| 102 const std::vector<uint8_t>& extra_data() const { return extra_data_; } | 103 const std::vector<uint8_t>& extra_data() const { return extra_data_; } |
| 103 | 104 |
| 104 // Whether the video stream is potentially encrypted. | 105 // Whether the video stream is potentially encrypted. |
| 105 // Note that in a potentially encrypted video stream, individual buffers | 106 // Note that in a potentially encrypted video stream, individual buffers |
| 106 // can be encrypted or not encrypted. | 107 // can be encrypted or not encrypted. |
| 107 bool is_encrypted() const { return encryption_scheme_.is_encrypted(); } | 108 bool is_encrypted() const { return encryption_scheme_.is_encrypted(); } |
| 108 | 109 |
| 109 // Encryption scheme used for encrypted buffers. | 110 // Encryption scheme used for encrypted buffers. |
| 110 const EncryptionScheme& encryption_scheme() const { | 111 const EncryptionScheme& encryption_scheme() const { |
| 111 return encryption_scheme_; | 112 return encryption_scheme_; |
| (...skipping 26 matching lines...) Expand all Loading... |
| 138 base::Optional<HDRMetadata> hdr_metadata_; | 139 base::Optional<HDRMetadata> hdr_metadata_; |
| 139 | 140 |
| 140 // Not using DISALLOW_COPY_AND_ASSIGN here intentionally to allow the compiler | 141 // Not using DISALLOW_COPY_AND_ASSIGN here intentionally to allow the compiler |
| 141 // generated copy constructor and assignment operator. Since the extra data is | 142 // generated copy constructor and assignment operator. Since the extra data is |
| 142 // typically small, the performance impact is minimal. | 143 // typically small, the performance impact is minimal. |
| 143 }; | 144 }; |
| 144 | 145 |
| 145 } // namespace media | 146 } // namespace media |
| 146 | 147 |
| 147 #endif // MEDIA_BASE_VIDEO_DECODER_CONFIG_H_ | 148 #endif // MEDIA_BASE_VIDEO_DECODER_CONFIG_H_ |
| OLD | NEW |