Shaka Packager SDK
Loading...
Searching...
No Matches
webm_content_encodings.cc
1// Copyright 2014 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 <packager/media/formats/webm/webm_content_encodings.h>
6
7#include <absl/log/check.h>
8#include <absl/log/log.h>
9
10namespace shaka {
11namespace media {
12
13ContentEncoding::ContentEncoding()
14 : order_(kOrderInvalid),
15 scope_(kScopeInvalid),
16 type_(kTypeInvalid),
17 encryption_algo_(kEncAlgoInvalid),
18 cipher_mode_(kCipherModeInvalid) {}
19
20ContentEncoding::~ContentEncoding() {}
21
22void ContentEncoding::SetEncryptionKeyId(const uint8_t* encryption_key_id,
23 int size) {
24 DCHECK(encryption_key_id);
25 DCHECK_GT(size, 0);
26 encryption_key_id_.assign(reinterpret_cast<const char*>(encryption_key_id),
27 size);
28}
29
30} // namespace media
31} // namespace shaka
All the methods that are virtual are virtual for mocking.