| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 "chromecast/media/cma/base/decoder_config_adapter.h" | 5 #include "chromecast/media/cma/base/decoder_config_adapter.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "chromecast/media/base/media_codec_support.h" | 8 #include "chromecast/media/base/media_codec_support.h" |
| 9 #include "media/base/channel_layout.h" | 9 #include "media/base/channel_layout.h" |
| 10 | 10 |
| (...skipping 215 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 226 // static | 226 // static |
| 227 VideoConfig DecoderConfigAdapter::ToCastVideoConfig( | 227 VideoConfig DecoderConfigAdapter::ToCastVideoConfig( |
| 228 StreamId id, | 228 StreamId id, |
| 229 const ::media::VideoDecoderConfig& config) { | 229 const ::media::VideoDecoderConfig& config) { |
| 230 VideoConfig video_config; | 230 VideoConfig video_config; |
| 231 if (!config.IsValidConfig()) { | 231 if (!config.IsValidConfig()) { |
| 232 return video_config; | 232 return video_config; |
| 233 } | 233 } |
| 234 | 234 |
| 235 video_config.id = id; | 235 video_config.id = id; |
| 236 video_config.codec = ToCastVideoCodec(config.codec()); | 236 video_config.codec = ToCastVideoCodec(config.codec(), config.profile()); |
| 237 video_config.profile = ToCastVideoProfile(config.profile()); | 237 video_config.profile = ToCastVideoProfile(config.profile()); |
| 238 video_config.extra_data = config.extra_data(); | 238 video_config.extra_data = config.extra_data(); |
| 239 video_config.encryption_scheme = ToEncryptionScheme( | 239 video_config.encryption_scheme = ToEncryptionScheme( |
| 240 config.encryption_scheme()); | 240 config.encryption_scheme()); |
| 241 | 241 |
| 242 // TODO(servolk): gfx::ColorSpace currently doesn't provide getters for color | 242 // TODO(servolk): gfx::ColorSpace currently doesn't provide getters for color |
| 243 // space components. We'll need to way to fix this. crbug.com/649758 | 243 // space components. We'll need to way to fix this. crbug.com/649758 |
| 244 // video_config.primaries = | 244 // video_config.primaries = |
| 245 // static_cast<PrimaryID>(config.color_space_info().primaries()); | 245 // static_cast<PrimaryID>(config.color_space_info().primaries()); |
| 246 // video_config.transfer = | 246 // video_config.transfer = |
| (...skipping 78 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 325 STATIC_ASSERT_ENUM(MatrixID::BT2020_NCL, MatrixID::BT2020_NCL); | 325 STATIC_ASSERT_ENUM(MatrixID::BT2020_NCL, MatrixID::BT2020_NCL); |
| 326 STATIC_ASSERT_ENUM(MatrixID::BT2020_CL, MatrixID::BT2020_CL); | 326 STATIC_ASSERT_ENUM(MatrixID::BT2020_CL, MatrixID::BT2020_CL); |
| 327 | 327 |
| 328 STATIC_ASSERT_ENUM(RangeID::UNSPECIFIED, RangeID::UNSPECIFIED); | 328 STATIC_ASSERT_ENUM(RangeID::UNSPECIFIED, RangeID::UNSPECIFIED); |
| 329 STATIC_ASSERT_ENUM(RangeID::LIMITED, RangeID::LIMITED); | 329 STATIC_ASSERT_ENUM(RangeID::LIMITED, RangeID::LIMITED); |
| 330 STATIC_ASSERT_ENUM(RangeID::FULL, RangeID::FULL); | 330 STATIC_ASSERT_ENUM(RangeID::FULL, RangeID::FULL); |
| 331 STATIC_ASSERT_ENUM(RangeID::DERIVED, RangeID::DERIVED); | 331 STATIC_ASSERT_ENUM(RangeID::DERIVED, RangeID::DERIVED); |
| 332 | 332 |
| 333 } // namespace media | 333 } // namespace media |
| 334 } // namespace chromecast | 334 } // namespace chromecast |
| OLD | NEW |