Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(182)

Side by Side Diff: chromecast/media/cma/base/cast_decrypt_config_impl.cc

Issue 1257013003: Load CMA backend from shared library (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #include "chromecast/media/cma/base/cast_decrypt_config_impl.h"
6
7 #include "media/base/decrypt_config.h"
8
9 namespace chromecast {
10 namespace media {
11
12 CastDecryptConfigImpl::CastDecryptConfigImpl(
13 const ::media::DecryptConfig& config)
14 : key_id_(config.key_id()), iv_(config.iv()) {
15 for (const auto& sample : config.subsamples()) {
16 subsamples_.push_back(
17 SubsampleEntry(sample.clear_bytes, sample.cypher_bytes));
18 }
19 }
20
21 CastDecryptConfigImpl::CastDecryptConfigImpl(
22 const std::string& key_id,
23 const std::string& iv,
24 const std::vector<SubsampleEntry>& subsamples)
25 : key_id_(key_id), iv_(iv), subsamples_(subsamples) {}
26
27 CastDecryptConfigImpl::~CastDecryptConfigImpl() {}
28
29 const std::string& CastDecryptConfigImpl::key_id() const {
30 return key_id_;
31 }
32
33 const std::string& CastDecryptConfigImpl::iv() const {
34 return iv_;
35 }
36
37 const std::vector<SubsampleEntry>& CastDecryptConfigImpl::subsamples() const {
38 return subsamples_;
39 }
40
41 } // namespace media
42 } // namespace chromecast
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698