Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_CHANNEL_LAYOUT_H_ | 5 #ifndef MEDIA_BASE_CHANNEL_LAYOUT_H_ |
| 6 #define MEDIA_BASE_CHANNEL_LAYOUT_H_ | 6 #define MEDIA_BASE_CHANNEL_LAYOUT_H_ |
| 7 | 7 |
| 8 #include "media/base/media_export.h" | 8 #include "media/base/media_export.h" |
| 9 | 9 |
| 10 namespace media { | 10 namespace media { |
| (...skipping 94 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 105 // of that. | 105 // of that. |
| 106 CHANNEL_LAYOUT_STEREO_AND_KEYBOARD_MIC = 30, | 106 CHANNEL_LAYOUT_STEREO_AND_KEYBOARD_MIC = 30, |
| 107 | 107 |
| 108 // Front L, Front R, Side L, Side R, LFE | 108 // Front L, Front R, Side L, Side R, LFE |
| 109 CHANNEL_LAYOUT_4_1_QUAD_SIDE = 31, | 109 CHANNEL_LAYOUT_4_1_QUAD_SIDE = 31, |
| 110 | 110 |
| 111 // Max value, must always equal the largest entry ever logged. | 111 // Max value, must always equal the largest entry ever logged. |
| 112 CHANNEL_LAYOUT_MAX = CHANNEL_LAYOUT_4_1_QUAD_SIDE | 112 CHANNEL_LAYOUT_MAX = CHANNEL_LAYOUT_4_1_QUAD_SIDE |
| 113 }; | 113 }; |
| 114 | 114 |
| 115 // Note: Do not reorder or reassign these values; other code depends on their | |
| 116 // ordering to operate correctly. E.g., OSX channel layout computations. | |
|
Avi (use Gerrit)
2017/02/09 02:44:38
macOS
DaleCurtis
2017/02/09 03:18:39
Switched in favor of CoreAudio.
| |
| 115 enum Channels { | 117 enum Channels { |
| 116 LEFT = 0, | 118 LEFT = 0, |
| 117 RIGHT, | 119 RIGHT, |
| 118 CENTER, | 120 CENTER, |
| 119 LFE, | 121 LFE, |
| 120 BACK_LEFT, | 122 BACK_LEFT, |
| 121 BACK_RIGHT, | 123 BACK_RIGHT, |
| 122 LEFT_OF_CENTER, | 124 LEFT_OF_CENTER, |
| 123 RIGHT_OF_CENTER, | 125 RIGHT_OF_CENTER, |
| 124 BACK_CENTER, | 126 BACK_CENTER, |
| (...skipping 13 matching lines...) Expand all Loading... | |
| 138 // Given the number of channels, return the best layout, | 140 // Given the number of channels, return the best layout, |
| 139 // or return CHANNEL_LAYOUT_UNSUPPORTED if there is no good match. | 141 // or return CHANNEL_LAYOUT_UNSUPPORTED if there is no good match. |
| 140 MEDIA_EXPORT ChannelLayout GuessChannelLayout(int channels); | 142 MEDIA_EXPORT ChannelLayout GuessChannelLayout(int channels); |
| 141 | 143 |
| 142 // Returns a string representation of the channel layout. | 144 // Returns a string representation of the channel layout. |
| 143 MEDIA_EXPORT const char* ChannelLayoutToString(ChannelLayout layout); | 145 MEDIA_EXPORT const char* ChannelLayoutToString(ChannelLayout layout); |
| 144 | 146 |
| 145 } // namespace media | 147 } // namespace media |
| 146 | 148 |
| 147 #endif // MEDIA_BASE_CHANNEL_LAYOUT_H_ | 149 #endif // MEDIA_BASE_CHANNEL_LAYOUT_H_ |
| OLD | NEW |