OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2010 The WebM project authors. All Rights Reserved. | 2 * Copyright (c) 2010 The WebM project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
11 #ifndef VP9_COMMON_VP9_ENUMS_H_ | 11 #ifndef VP9_COMMON_VP9_ENUMS_H_ |
12 #define VP9_COMMON_VP9_ENUMS_H_ | 12 #define VP9_COMMON_VP9_ENUMS_H_ |
13 | 13 |
14 #include "./vpx_config.h" | 14 #include "./vpx_config.h" |
15 | 15 |
16 #ifdef __cplusplus | 16 #ifdef __cplusplus |
17 extern "C" { | 17 extern "C" { |
18 #endif | 18 #endif |
19 | 19 |
20 #define MI_SIZE_LOG2 3 | 20 #define MI_SIZE_LOG2 3 |
21 #define MI_BLOCK_SIZE_LOG2 (6 - MI_SIZE_LOG2) // 64 = 2^6 | 21 #define MI_BLOCK_SIZE_LOG2 (6 - MI_SIZE_LOG2) // 64 = 2^6 |
22 | 22 |
23 #define MI_SIZE (1 << MI_SIZE_LOG2) // pixels per mi-unit | 23 #define MI_SIZE (1 << MI_SIZE_LOG2) // pixels per mi-unit |
24 #define MI_BLOCK_SIZE (1 << MI_BLOCK_SIZE_LOG2) // mi-units per max block | 24 #define MI_BLOCK_SIZE (1 << MI_BLOCK_SIZE_LOG2) // mi-units per max block |
25 | 25 |
26 #define MI_MASK (MI_BLOCK_SIZE - 1) | 26 #define MI_MASK (MI_BLOCK_SIZE - 1) |
27 | 27 |
| 28 // Bitstream profiles indicated by 2 bits in the uncompressed header. |
| 29 // 00: Profile 0. 4:2:0 only. |
| 30 // 10: Profile 1. adds 4:4:4, 4:2:2, alpha. |
| 31 // 01: Profile 2. Supports 10-bit and 12-bit color only. |
| 32 // 11: Undefined profile. |
| 33 typedef enum BITSTREAM_PROFILE { |
| 34 PROFILE_0, |
| 35 PROFILE_1, |
| 36 PROFILE_2, |
| 37 MAX_PROFILES |
| 38 } BITSTREAM_PROFILE; |
| 39 |
| 40 typedef enum BIT_DEPTH { |
| 41 BITS_8, |
| 42 BITS_10, |
| 43 BITS_12 |
| 44 } BIT_DEPTH; |
28 | 45 |
29 typedef enum BLOCK_SIZE { | 46 typedef enum BLOCK_SIZE { |
30 BLOCK_4X4, | 47 BLOCK_4X4, |
31 BLOCK_4X8, | 48 BLOCK_4X8, |
32 BLOCK_8X4, | 49 BLOCK_8X4, |
33 BLOCK_8X8, | 50 BLOCK_8X8, |
34 BLOCK_8X16, | 51 BLOCK_8X16, |
35 BLOCK_16X8, | 52 BLOCK_16X8, |
36 BLOCK_16X16, | 53 BLOCK_16X16, |
37 BLOCK_16X32, | 54 BLOCK_16X32, |
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
87 UNKNOWN = 0, | 104 UNKNOWN = 0, |
88 BT_601 = 1, // YUV | 105 BT_601 = 1, // YUV |
89 BT_709 = 2, // YUV | 106 BT_709 = 2, // YUV |
90 SMPTE_170 = 3, // YUV | 107 SMPTE_170 = 3, // YUV |
91 SMPTE_240 = 4, // YUV | 108 SMPTE_240 = 4, // YUV |
92 RESERVED_1 = 5, | 109 RESERVED_1 = 5, |
93 RESERVED_2 = 6, | 110 RESERVED_2 = 6, |
94 SRGB = 7 // RGB | 111 SRGB = 7 // RGB |
95 } COLOR_SPACE; | 112 } COLOR_SPACE; |
96 | 113 |
| 114 typedef enum { |
| 115 VP9_LAST_FLAG = 1 << 0, |
| 116 VP9_GOLD_FLAG = 1 << 1, |
| 117 VP9_ALT_FLAG = 1 << 2, |
| 118 } VP9_REFFRAME; |
| 119 |
97 #ifdef __cplusplus | 120 #ifdef __cplusplus |
98 } // extern "C" | 121 } // extern "C" |
99 #endif | 122 #endif |
100 | 123 |
101 #endif // VP9_COMMON_VP9_ENUMS_H_ | 124 #endif // VP9_COMMON_VP9_ENUMS_H_ |
OLD | NEW |