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

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

Issue 2908073002: Make OS audio buffer size limits visible. (Closed)
Patch Set: Remove pulse-related changes. Created 3 years, 5 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
« no previous file with comments | « media/base/audio_latency.cc ('k') | media/base/mac/audio_latency_mac.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 // Contains limit definition constants for the media subsystem. 5 // Contains limit definition constants for the media subsystem.
6 6
7 #ifndef MEDIA_BASE_LIMITS_H_ 7 #ifndef MEDIA_BASE_LIMITS_H_
8 #define MEDIA_BASE_LIMITS_H_ 8 #define MEDIA_BASE_LIMITS_H_
9 9
10 #include "build/build_config.h"
11
10 namespace media { 12 namespace media {
11 13
12 namespace limits { 14 namespace limits {
13 15
14 enum { 16 enum {
15 // Maximum possible dimension (width or height) for any video. 17 // Maximum possible dimension (width or height) for any video.
16 kMaxDimension = (1 << 15) - 1, // 32767 18 kMaxDimension = (1 << 15) - 1, // 32767
17 19
18 // Maximum possible canvas size (width multiplied by height) for any video. 20 // Maximum possible canvas size (width multiplied by height) for any video.
19 kMaxCanvas = (1 << (14 * 2)), // 16384 x 16384 21 kMaxCanvas = (1 << (14 * 2)), // 16384 x 16384
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
51 // lengths are somewhat arbitrary as the EME spec doesn't specify any limits. 53 // lengths are somewhat arbitrary as the EME spec doesn't specify any limits.
52 kMinCertificateLength = 128, 54 kMinCertificateLength = 128,
53 kMaxCertificateLength = 16 * 1024, 55 kMaxCertificateLength = 16 * 1024,
54 kMaxSessionIdLength = 512, 56 kMaxSessionIdLength = 512,
55 kMinKeyIdLength = 1, 57 kMinKeyIdLength = 1,
56 kMaxKeyIdLength = 512, 58 kMaxKeyIdLength = 512,
57 kMaxKeyIds = 128, 59 kMaxKeyIds = 128,
58 kMaxInitDataLength = 64 * 1024, // 64 KB 60 kMaxInitDataLength = 64 * 1024, // 64 KB
59 kMaxSessionResponseLength = 64 * 1024, // 64 KB 61 kMaxSessionResponseLength = 64 * 1024, // 64 KB
60 kMaxKeySystemLength = 256, 62 kMaxKeySystemLength = 256,
63
64 // Minimum and maximum buffer sizes for certain audio platforms.
65 #if defined(OS_MACOSX)
66 kMinAudioBufferSize = 128,
67 kMaxAudioBufferSize = 4096,
68 #elif defined(USE_CRAS)
69 // Though CRAS has different per-board defaults, allow explicitly requesting
70 // this buffer size on any board.
71 kMinAudioBufferSize = 256,
72 kMaxAudioBufferSize = 8192,
73 #endif
61 }; 74 };
62 75
63 } // namespace limits 76 } // namespace limits
64 77
65 } // namespace media 78 } // namespace media
66 79
67 #endif // MEDIA_BASE_LIMITS_H_ 80 #endif // MEDIA_BASE_LIMITS_H_
OLDNEW
« no previous file with comments | « media/base/audio_latency.cc ('k') | media/base/mac/audio_latency_mac.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698