OLD | NEW |
(Empty) | |
| 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 |
| 3 // found in the LICENSE file. |
| 4 |
| 5 #ifndef CHROMECAST_RENDERER_MEDIA_CAST_MEDIA_CLIENT_H_ |
| 6 #define CHROMECAST_RENDERER_MEDIA_CAST_MEDIA_CLIENT_H_ |
| 7 |
| 8 #include "base/lazy_instance.h" |
| 9 #include "base/macros.h" |
| 10 #include "chromecast/media/base/supported_codec_profile_levels_memo.h" |
| 11 #include "content/public/renderer/content_media_client.h" |
| 12 |
| 13 namespace chromecast { |
| 14 namespace media { |
| 15 |
| 16 // Overrides ContentMediaClient::IsSupportedVideoConfig to call |
| 17 // MediaCapabilitiesShlib. Otherwise defers to content::ContentMediaClient. |
| 18 class CastMediaClient : public ::content::ContentMediaClient { |
| 19 public: |
| 20 CastMediaClient(content::ContentRendererClient* content_renderer_client, |
| 21 SupportedCodecProfileLevelsMemo* supported_profiles); |
| 22 ~CastMediaClient() override; |
| 23 |
| 24 // ContentMediaClient overrides. |
| 25 bool IsSupportedVideoConfig(const ::media::VideoConfig& config) override; |
| 26 |
| 27 private: |
| 28 friend struct base::LazyInstanceTraitsBase<CastMediaClient>; |
| 29 |
| 30 SupportedCodecProfileLevelsMemo* supported_profiles_; |
| 31 |
| 32 DISALLOW_COPY_AND_ASSIGN(CastMediaClient); |
| 33 }; |
| 34 |
| 35 } // namespace media |
| 36 } // namespace chromecast |
| 37 |
| 38 #endif // CHROMECAST_RENDERER_MEDIA_CAST_MEDIA_CLIENT_H_ |
OLD | NEW |