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

Side by Side Diff: media/base/media_util.h

Issue 2846623003: Make autoplay policies no longer platform dependant. (Closed)
Patch Set: Created 3 years, 7 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
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 #ifndef MEDIA_BASE_MEDIA_UTIL_H_ 5 #ifndef MEDIA_BASE_MEDIA_UTIL_H_
6 #define MEDIA_BASE_MEDIA_UTIL_H_ 6 #define MEDIA_BASE_MEDIA_UTIL_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 #include <string>
9 #include <vector> 10 #include <vector>
10 11
11 #include "media/base/encryption_scheme.h" 12 #include "media/base/encryption_scheme.h"
12 #include "media/base/media_export.h" 13 #include "media/base/media_export.h"
13 14
15 namespace base {
16 class CommandLine;
17 }
18
14 namespace media { 19 namespace media {
15 20
16 // Simply returns an empty vector. {Audio|Video}DecoderConfig are often 21 // Simply returns an empty vector. {Audio|Video}DecoderConfig are often
17 // constructed with empty extra data. 22 // constructed with empty extra data.
18 MEDIA_EXPORT std::vector<uint8_t> EmptyExtraData(); 23 MEDIA_EXPORT std::vector<uint8_t> EmptyExtraData();
19 24
20 // The following helper functions return new instances of EncryptionScheme that 25 // The following helper functions return new instances of EncryptionScheme that
21 // indicate widely used settings. 26 // indicate widely used settings.
22 MEDIA_EXPORT EncryptionScheme Unencrypted(); 27 MEDIA_EXPORT EncryptionScheme Unencrypted();
23 MEDIA_EXPORT EncryptionScheme AesCtrEncryptionScheme(); 28 MEDIA_EXPORT EncryptionScheme AesCtrEncryptionScheme();
24 29
30 // Based on a |command_line| and the current platform, returns the effective
DaleCurtis 2017/04/27 18:59:39 Hmm, I didn't even know we had a media_util file,
mlamouri (slow - plz ping) 2017/04/27 21:34:14 I was considering having this in media_switches bu
31 // autoplay policy. In other words, it will take into account the default policy
32 // if none is specified via the command line and options passed for testing.
33 // Returns one of the possible autoplay policy switches from the
34 // switches::autoplay namespace.
35 MEDIA_EXPORT std::string GetEffectiveAutoplayPolicy(
36 const base::CommandLine& command_line);
37
25 } // namespace media 38 } // namespace media
26 39
27 #endif // MEDIA_BASE_MEDIA_UTIL_H_ 40 #endif // MEDIA_BASE_MEDIA_UTIL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698