annotate dnxhddata.c @ 9476:2b2bac59038e libavcodec

Remove 2 useless assignments from ff_rate_control_init() found by CSA.
author michael
date Fri, 17 Apr 2009 17:52:58 +0000
parents 04423b2f6e0b
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
5473
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
1 /*
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
2 * VC3/DNxHD data.
8629
04423b2f6e0b cosmetics: Remove pointless period after copyright statement non-sentences.
diego
parents: 8609
diff changeset
3 * Copyright (c) 2007 SmartJog S.A., Baptiste Coudurier <baptiste dot coudurier at smartjog dot com>
5473
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
4 *
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
5 * This file is part of FFmpeg.
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
6 *
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
7 * FFmpeg is free software; you can redistribute it and/or
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
8 * modify it under the terms of the GNU Lesser General Public
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
9 * License as published by the Free Software Foundation; either
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
10 * version 2.1 of the License, or (at your option) any later version.
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
11 *
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
12 * FFmpeg is distributed in the hope that it will be useful,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
15 * Lesser General Public License for more details.
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
16 *
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
17 * You should have received a copy of the GNU Lesser General Public
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
18 * License along with FFmpeg; if not, write to the Free Software
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
19 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
20 */
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
21
6041
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
22 #include "avcodec.h"
5473
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
23 #include "dnxhddata.h"
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
24
5795
8b6fe123be88 typo weigth->weight
bcoudurier
parents: 5794
diff changeset
25 static const uint8_t dnxhd_1237_luma_weight[] = {
5473
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
26 0, 32, 33, 34, 34, 36, 37, 36,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
27 36, 37, 38, 38, 38, 39, 41, 44,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
28 43, 41, 40, 41, 46, 49, 47, 46,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
29 47, 49, 51, 54, 60, 62, 59, 55,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
30 54, 56, 58, 61, 65, 66, 64, 63,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
31 66, 73, 78, 79, 80, 79, 78, 78,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
32 82, 87, 89, 90, 93, 95, 96, 97,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
33 97, 100, 104, 102, 98, 98, 99, 99,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
34 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
35
5795
8b6fe123be88 typo weigth->weight
bcoudurier
parents: 5794
diff changeset
36 static const uint8_t dnxhd_1237_chroma_weight[] = {
5473
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
37 0, 32, 36, 39, 39, 38, 39, 41,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
38 45, 51, 57, 58, 53, 48, 47, 51,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
39 55, 58, 66, 75, 81, 83, 82, 78,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
40 73, 72, 74, 77, 83, 85, 83, 82,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
41 89, 99, 96, 90, 94, 97, 99, 105,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
42 109, 105, 95, 89, 92, 95, 94, 93,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
43 92, 88, 89, 90, 93, 95, 96, 97,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
44 97, 100, 104, 102, 98, 98, 99, 99,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
45 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
46
5795
8b6fe123be88 typo weigth->weight
bcoudurier
parents: 5794
diff changeset
47 static const uint8_t dnxhd_1238_luma_weight[] = {
5473
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
48 0, 32, 32, 33, 34, 33, 33, 33,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
49 33, 33, 33, 33, 33, 35, 37, 37,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
50 36, 36, 35, 36, 38, 38, 36, 35,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
51 36, 37, 38, 41, 42, 41, 39, 38,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
52 38, 38, 39, 41, 42, 41, 39, 39,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
53 40, 41, 43, 44, 44, 44, 44, 44,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
54 45, 47, 47, 47, 49, 50, 51, 51,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
55 51, 53, 55, 57, 58, 59, 57, 57,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
56 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
57
5795
8b6fe123be88 typo weigth->weight
bcoudurier
parents: 5794
diff changeset
58 static const uint8_t dnxhd_1238_chroma_weight[] = {
5473
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
59 0, 32, 35, 35, 35, 34, 34, 35,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
60 39, 43, 45, 45, 41, 39, 40, 41,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
61 42, 44, 48, 55, 59, 63, 65, 59,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
62 53, 52, 52, 55, 61, 62, 58, 58,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
63 63, 66, 66, 65, 70, 74, 70, 66,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
64 65, 68, 75, 77, 74, 74, 77, 76,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
65 73, 73, 73, 73, 76, 80, 89, 90,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
66 82, 77, 80, 86, 84, 82, 82, 82,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
67 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
68
5794
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
69 static const uint8_t dnxhd_1241_luma_weight[] = {
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
70 0, 32, 33, 34, 34, 35, 36, 37,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
71 36, 37, 38, 38, 38, 39, 39, 40,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
72 40, 38, 38, 39, 38, 37, 39, 41,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
73 41, 42, 43, 45, 45, 46, 47, 46,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
74 45, 43, 39, 37, 37, 40, 44, 45,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
75 45, 46, 46, 46, 47, 47, 46, 44,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
76 42, 43, 45, 47, 48, 49, 50, 49,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
77 48, 46, 47, 48, 48, 49, 49, 49,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
78 };
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
79
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
80 static const uint8_t dnxhd_1241_chroma_weight[] = {
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
81 0, 32, 36, 38, 37, 37, 40, 41,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
82 40, 40, 42, 42, 41, 41, 41, 41,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
83 42, 43, 44, 44, 45, 46, 46, 45,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
84 44, 45, 45, 45, 45, 46, 47, 46,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
85 45, 44, 42, 41, 43, 45, 45, 47,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
86 48, 48, 48, 46, 47, 47, 46, 47,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
87 46, 45, 45, 47, 48, 49, 50, 49,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
88 48, 46, 48, 49, 48, 49, 49, 49,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
89 };
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
90
5795
8b6fe123be88 typo weigth->weight
bcoudurier
parents: 5794
diff changeset
91 static const uint8_t dnxhd_1242_luma_weight[] = {
5521
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
92 0, 32, 33, 33, 34, 35, 36, 35,
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
93 33, 33, 35, 36, 37, 37, 38, 37,
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
94 37, 37, 36, 37, 37, 37, 38, 39,
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
95 37, 36, 37, 40, 42, 45, 46, 44,
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
96 41, 42, 44, 45, 47, 49, 50, 48,
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
97 46, 48, 49, 50, 52, 52, 50, 49,
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
98 47, 48, 50, 50, 51, 51, 50, 49,
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
99 49, 51, 52, 51, 49, 47, 47, 47,
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
100 };
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
101
5795
8b6fe123be88 typo weigth->weight
bcoudurier
parents: 5794
diff changeset
102 static const uint8_t dnxhd_1242_chroma_weight[] = {
5521
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
103 0, 32, 37, 42, 45, 45, 45, 44,
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
104 38, 37, 40, 42, 44, 49, 51, 47,
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
105 41, 40, 43, 44, 46, 48, 51, 54,
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
106 51, 47, 47, 45, 47, 50, 51, 49,
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
107 46, 47, 49, 47, 50, 55, 55, 51,
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
108 48, 49, 51, 51, 52, 52, 54, 54,
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
109 49, 49, 52, 53, 54, 54, 53, 53,
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
110 55, 59, 63, 62, 60, 60, 60, 60,
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
111 };
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
112
5795
8b6fe123be88 typo weigth->weight
bcoudurier
parents: 5794
diff changeset
113 static const uint8_t dnxhd_1243_luma_weight[] = {
5473
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
114 0, 32, 32, 33, 33, 35, 35, 35,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
115 35, 35, 35, 35, 34, 35, 38, 40,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
116 39, 37, 37, 37, 36, 35, 36, 38,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
117 40, 41, 42, 44, 45, 44, 42, 41,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
118 40, 38, 36, 36, 37, 38, 40, 43,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
119 44, 45, 45, 45, 45, 45, 45, 41,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
120 39, 41, 45, 47, 47, 48, 48, 48,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
121 46, 44, 45, 47, 47, 48, 47, 47,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
122 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
123
5795
8b6fe123be88 typo weigth->weight
bcoudurier
parents: 5794
diff changeset
124 static const uint8_t dnxhd_1243_chroma_weight[] = {
5473
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
125 0, 32, 36, 37, 36, 37, 39, 39,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
126 41, 43, 43, 42, 41, 41, 41, 42,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
127 43, 43, 43, 44, 44, 44, 46, 47,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
128 46, 45, 45, 45, 45, 46, 44, 44,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
129 45, 44, 42, 41, 43, 46, 45, 44,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
130 45, 45, 45, 46, 46, 46, 45, 44,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
131 45, 44, 45, 47, 47, 48, 49, 48,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
132 46, 45, 46, 47, 47, 48, 47, 47,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
133 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
134
5971
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
135 static const uint8_t dnxhd_1251_luma_weight[] = {
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
136 0, 32, 32, 34, 34, 34, 34, 35,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
137 35, 35, 36, 37, 36, 36, 35, 36,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
138 38, 38, 38, 38, 38, 38, 38, 38,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
139 38, 38, 39, 41, 44, 43, 41, 40,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
140 40, 40, 40, 39, 40, 41, 40, 39,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
141 40, 43, 46, 46, 44, 44, 44, 42,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
142 41, 43, 46, 48, 50, 55, 58, 53,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
143 48, 50, 55, 58, 61, 62, 62, 62,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
144 };
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
145
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
146 static const uint8_t dnxhd_1251_chroma_weight[] = {
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
147 0, 32, 35, 36, 36, 35, 36, 39,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
148 41, 43, 45, 44, 41, 39, 40, 42,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
149 43, 43, 45, 48, 48, 48, 50, 50,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
150 50, 51, 51, 51, 51, 52, 53, 54,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
151 51, 49, 51, 52, 52, 56, 57, 55,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
152 54, 54, 55, 56, 55, 58, 58, 58,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
153 60, 61, 62, 62, 59, 57, 58, 58,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
154 61, 59, 59, 59, 61, 62, 62, 62,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
155 };
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
156
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
157 static const uint8_t dnxhd_1252_luma_weight[] = {
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
158 0, 32, 34, 35, 36, 36, 36, 37,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
159 36, 37, 39, 40, 41, 40, 40, 40,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
160 41, 41, 42, 41, 41, 43, 44, 44,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
161 45, 46, 48, 55, 60, 57, 52, 50,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
162 49, 49, 52, 52, 53, 55, 58, 62,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
163 65, 73, 82, 82, 80, 78, 73, 68,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
164 71, 82, 90, 90, 88, 87, 90, 95,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
165 100, 107, 103, 97, 95, 93, 99, 99,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
166 };
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
167 static const uint8_t dnxhd_1252_chroma_weight[] = {
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
168 0, 32, 35, 36, 37, 37, 38, 40,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
169 42, 46, 49, 50, 50, 49, 49, 53,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
170 56, 56, 57, 58, 60, 62, 64, 65,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
171 63, 64, 64, 65, 66, 65, 67, 71,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
172 72, 74, 74, 74, 74, 77, 81, 78,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
173 72, 73, 82, 85, 89, 88, 84, 80,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
174 90, 100, 90, 90, 88, 87, 90, 95,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
175 114, 128, 125, 129, 134, 125, 116, 116,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
176 };
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
177
5473
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
178 static const uint8_t dnxhd_1237_dc_codes[12] = {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
179 0, 12, 13, 1, 2, 3, 4, 5, 14, 30, 62, 63,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
180 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
181
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
182 static const uint8_t dnxhd_1237_dc_bits[12] = {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
183 3, 4, 4, 3, 3, 3, 3, 3, 4, 5, 6, 6,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
184 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
185
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
186 static const uint16_t dnxhd_1237_ac_codes[257] = {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
187 0, 1, 4, 5, 12, 26, 27, 56, 57, 58, 59, 120, 121, 244, 245, 246, 247, 248, 498, 499, 500, 501, 502, 1006, 1007, 1008, 1009, 1010, 1011, 2024, 2025, 2026, 2027, 2028, 2029, 2030, 2031, 4064, 4065, 4066, 4067, 4068, 4069, 4070, 4071, 4072, 4073, 8148, 8149, 8150, 8151, 8152, 8153, 8154, 8155, 8156, 8157, 8158, 16318, 16319, 16320, 16321, 16322, 16323, 16324, 16325, 16326, 16327, 16328, 16329, 16330, 16331, 16332, 16333, 32668, 32669, 32670, 32671, 32672, 32673, 32674, 32675, 32676, 32677, 32678, 32679, 32680, 32681, 32682, 32683, 32684, 65370, 65371, 65372, 65373, 65374, 65375, 65376, 65377, 65378, 65379, 65380, 65381, 65382, 65383, 65384, 65385, 65386, 65387, 65388, 65389, 65390, 65391, 65392, 65393, 65394, 65395, 65396, 65397, 65398, 65399, 65400, 65401, 65402, 65403, 65404, 65405, 65406, 65407, 65408, 65409, 65410, 65411, 65412, 65413, 65414, 65415, 65416, 65417, 65418, 65419, 65420, 65421, 65422, 65423, 65424, 65425, 65426, 65427, 65428, 65429, 65430, 65431, 65432, 65433, 65434, 65435, 65436, 65437, 65438, 65439, 65440, 65441, 65442, 65443, 65444, 65445, 65446, 65447, 65448, 65449, 65450, 65451, 65452, 65453, 65454, 65455, 65456, 65457, 65458, 65459, 65460, 65461, 65462, 65463, 65464, 65465, 65466, 65467, 65468, 65469, 65470, 65471, 65472, 65473, 65474, 65475, 65476, 65477, 65478, 65479, 65480, 65481, 65482, 65483, 65484, 65485, 65486, 65487, 65488, 65489, 65490, 65491, 65492, 65493, 65494, 65495, 65496, 65497, 65498, 65499, 65500, 65501, 65502, 65503, 65504, 65505, 65506, 65507, 65508, 65509, 65510, 65511, 65512, 65513, 65514, 65515, 65516, 65517, 65518, 65519, 65520, 65521, 65522, 65523, 65524, 65525, 65526, 65527, 65528, 65529, 65530, 65531, 65532, 65533, 65534, 65535,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
188 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
189
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
190 static const uint8_t dnxhd_1237_ac_bits[257] = {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
191 2, 2, 3, 3, 4, 5, 5, 6, 6, 6, 6, 7, 7, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
192 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
193
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
194 static const uint8_t dnxhd_1237_ac_level[257] = {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
195 1, 1, 2, 0, 3, 4, 2, 5, 6, 7, 3, 8, 9, 10, 11, 12, 4, 5, 13, 14, 15, 16, 6, 17, 18, 19, 20, 21, 7, 22, 23, 24, 25, 26, 27, 8, 9, 28, 29, 30, 31, 32, 33, 34, 10, 11, 12, 35, 36, 37, 38, 39, 40, 41, 13, 14, 15, 16, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 17, 18, 19, 20, 21, 53, 54, 55, 56, 57, 58, 59, 60, 61, 64, 1, 22, 23, 24, 25, 26, 27, 62, 63, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
196 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
197
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
198 static const uint8_t dnxhd_1237_ac_run_flag[257] = {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
199 0, 1, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
200 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
201
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
202 static const uint8_t dnxhd_1237_ac_index_flag[257] = {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
203 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
204 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
205
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
206 static const uint16_t dnxhd_1237_run_codes[62] = {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
207 0, 4, 10, 11, 24, 25, 26, 54, 55, 56, 57, 58, 118, 119, 240, 482, 483, 484, 485, 486, 487, 488, 489, 490, 491, 492, 493, 494, 990, 991, 992, 993, 994, 995, 996, 997, 998, 999, 1000, 1001, 1002, 1003, 1004, 1005, 1006, 1007, 1008, 1009, 1010, 1011, 1012, 1013, 1014, 1015, 1016, 1017, 1018, 1019, 1020, 1021, 1022, 1023,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
208 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
209
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
210 static const uint8_t dnxhd_1237_run_bits[62] = {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
211 1, 3, 4, 4, 5, 5, 5, 6, 6, 6, 6, 6, 7, 7, 8, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
212 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
213
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
214 static const uint8_t dnxhd_1237_run[62] = {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
215 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 53, 57, 58, 59, 60, 61, 62, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 54, 55, 56,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
216 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
217
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
218 static const uint8_t dnxhd_1238_dc_codes[12] = {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
219 0, 12, 13, 1, 2, 3, 4, 5, 14, 30, 62, 63,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
220 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
221
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
222 static const uint8_t dnxhd_1238_dc_bits[12] = {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
223 3, 4, 4, 3, 3, 3, 3, 3, 4, 5, 6, 6,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
224 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
225
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
226 static const uint16_t dnxhd_1238_ac_codes[257] = {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
227 0, 1, 4, 10, 11, 24, 25, 26, 54, 55, 56, 57, 116, 117, 118, 119, 240, 241, 242, 243, 244, 245, 492, 493, 494, 495, 496, 497, 498, 499, 1000, 1001, 1002, 1003, 1004, 1005, 1006, 1007, 1008, 2018, 2019, 2020, 2021, 2022, 2023, 2024, 2025, 2026, 2027, 4056, 4057, 4058, 4059, 4060, 4061, 4062, 4063, 4064, 4065, 4066, 4067, 4068, 4069, 8140, 8141, 8142, 8143, 8144, 8145, 8146, 8147, 8148, 8149, 8150, 8151, 8152, 8153, 8154, 8155, 8156, 16314, 16315, 16316, 16317, 16318, 16319, 16320, 16321, 16322, 16323, 16324, 16325, 16326, 16327, 16328, 16329, 16330, 16331, 16332, 16333, 16334, 16335, 16336, 16337, 16338, 32678, 32679, 32680, 32681, 32682, 32683, 32684, 32685, 32686, 32687, 32688, 32689, 32690, 32691, 32692, 32693, 32694, 32695, 32696, 32697, 32698, 32699, 32700, 32701, 32702, 32703, 32704, 32705, 65412, 65413, 65414, 65415, 65416, 65417, 65418, 65419, 65420, 65421, 65422, 65423, 65424, 65425, 65426, 65427, 65428, 65429, 65430, 65431, 65432, 65433, 65434, 65435, 65436, 65437, 65438, 65439, 65440, 65441, 65442, 65443, 65444, 65445, 65446, 65447, 65448, 65449, 65450, 65451, 65452, 65453, 65454, 65455, 65456, 65457, 65458, 65459, 65460, 65461, 65462, 65463, 65464, 65465, 65466, 65467, 65468, 65469, 65470, 65471, 65472, 65473, 65474, 65475, 65476, 65477, 65478, 65479, 65480, 65481, 65482, 65483, 65484, 65485, 65486, 65487, 65488, 65489, 65490, 65491, 65492, 65493, 65494, 65495, 65496, 65497, 65498, 65499, 65500, 65501, 65502, 65503, 65504, 65505, 65506, 65507, 65508, 65509, 65510, 65511, 65512, 65513, 65514, 65515, 65516, 65517, 65518, 65519, 65520, 65521, 65522, 65523, 65524, 65525, 65526, 65527, 65528, 65529, 65530, 65531, 65532, 65533, 65534, 65535,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
228 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
229
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
230 static const uint8_t dnxhd_1238_ac_bits[257] = {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
231 2, 2, 3, 4, 4, 5, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
232 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
233
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
234 static const uint8_t dnxhd_1238_ac_level[257] = {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
235 1, 1, 2, 3, 0, 4, 5, 2, 6, 7, 8, 3, 9, 10, 11, 4, 12, 13, 14, 15, 16, 5, 17, 18, 19, 20, 21, 22, 6, 7, 23, 24, 25, 26, 27, 28, 29, 8, 9, 30, 31, 32, 33, 34, 35, 36, 37, 10, 11, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 12, 13, 14, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 15, 16, 17, 18, 62, 63, 64, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 19, 20, 21, 22, 23, 24, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 40, 25, 26, 27, 28, 29, 30, 38, 39, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
236 }; /* 0 is EOB */
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
237
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
238 static const uint8_t dnxhd_1238_ac_run_flag[257] = {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
239 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
240 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
241
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
242 static const uint8_t dnxhd_1238_ac_index_flag[257] = {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
243 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
244 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
245
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
246 static const uint16_t dnxhd_1238_run_codes[62] = {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
247 0, 4, 10, 11, 24, 25, 26, 27, 56, 57, 58, 59, 120, 242, 486, 487, 488, 489, 980, 981, 982, 983, 984, 985, 986, 987, 988, 989, 990, 991, 992, 993, 994, 995, 996, 997, 998, 999, 1000, 1001, 1002, 1003, 1004, 1005, 1006, 1007, 1008, 1009, 1010, 1011, 1012, 1013, 1014, 1015, 1016, 1017, 1018, 1019, 1020, 1021, 1022, 1023,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
248 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
249
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
250 static const uint8_t dnxhd_1238_run_bits[62] = {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
251 1, 3, 4, 4, 5, 5, 5, 5, 6, 6, 6, 6, 7, 8, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
252 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
253
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
254 static const uint8_t dnxhd_1238_run[62] = {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
255 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 20, 21, 17, 18, 19, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
256 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
257
5794
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
258 static const uint8_t dnxhd_1241_dc_codes[14] = {
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
259 10, 62, 11, 12, 13, 0, 1, 2, 3, 4, 14, 30, 126, 127,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
260 };
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
261
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
262 static const uint8_t dnxhd_1241_dc_bits[14] = {
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
263 4, 6, 4, 4, 4, 3, 3, 3, 3, 3, 4, 5, 7, 7,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
264 };
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
265 static const uint16_t dnxhd_1241_ac_codes[257] = {
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
266 0, 1, 4, 10, 11, 24, 25, 26, 54, 55, 56, 57, 116, 117, 118, 119, 240, 241, 242, 243, 244, 245, 492, 493, 494, 495, 496, 497, 498, 998, 999, 1000, 1001, 1002, 1003, 1004, 1005, 1006, 1007, 2016, 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024, 2025, 2026, 4054, 4055, 4056, 4057, 4058, 4059, 4060, 4061, 4062, 4063, 4064, 4065, 4066, 4067, 4068, 4069, 8140, 8141, 8142, 8143, 8144, 8145, 8146, 8147, 8148, 8149, 8150, 8151, 8152, 8153, 8154, 8155, 8156, 8157, 16316, 16317, 16318, 16319, 16320, 16321, 16322, 16323, 16324, 16325, 16326, 16327, 16328, 16329, 16330, 16331, 16332, 16333, 16334, 16335, 16336, 16337, 32676, 32677, 32678, 32679, 32680, 32681, 32682, 32683, 32684, 32685, 32686, 32687, 32688, 32689, 32690, 32691, 32692, 32693, 32694, 32695, 32696, 32697, 32698, 32699, 32700, 32701, 32702, 32703, 32704, 32705, 32706, 32707, 32708, 65418, 65419, 65420, 65421, 65422, 65423, 65424, 65425, 65426, 65427, 65428, 65429, 65430, 65431, 65432, 65433, 65434, 65435, 65436, 65437, 65438, 65439, 65440, 65441, 65442, 65443, 65444, 65445, 65446, 65447, 65448, 65449, 65450, 65451, 65452, 65453, 65454, 65455, 65456, 65457, 65458, 65459, 65460, 65461, 65462, 65463, 65464, 65465, 65466, 65467, 65468, 65469, 65470, 65471, 65472, 65473, 65474, 65475, 65476, 65477, 65478, 65479, 65480, 65481, 65482, 65483, 65484, 65485, 65486, 65487, 65488, 65489, 65490, 65491, 65492, 65493, 65494, 65495, 65496, 65497, 65498, 65499, 65500, 65501, 65502, 65503, 65504, 65505, 65506, 65507, 65508, 65509, 65510, 65511, 65512, 65513, 65514, 65515, 65516, 65517, 65518, 65519, 65520, 65521, 65522, 65523, 65524, 65525, 65526, 65527, 65528, 65529, 65530, 65531, 65532, 65533, 65534, 65535,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
267 };
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
268
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
269 static const uint8_t dnxhd_1241_ac_bits[257] = {
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
270 2, 2, 3, 4, 4, 5, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
271 };
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
272
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
273 static const uint8_t dnxhd_1241_ac_level[257] = {
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
274 1, 1, 2, 3, 0, 4, 5, 2, 6, 7, 8, 3, 9, 10, 11, 4, 12, 13, 14, 15, 16, 5, 17, 18, 19, 20, 21, 6, 7, 22, 23, 24, 25, 26, 27, 28, 29, 8, 9, 30, 31, 32, 33, 34, 35, 36, 37, 38, 10, 11, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 12, 13, 14, 15, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 1, 16, 17, 18, 19, 64, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 20, 21, 22, 23, 24, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 25, 26, 27, 28, 29, 30, 31, 32, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
275 };
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
276
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
277 static const uint8_t dnxhd_1241_ac_run_flag[257] = {
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
278 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
279 };
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
280
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
281 static const uint8_t dnxhd_1241_ac_index_flag[257] = {
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
282 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
283 };
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
284
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
285 static const uint8_t dnxhd_1241_run[62] = {
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
286 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 18, 20, 17, 19, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
287 };
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
288
5971
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
289 static const uint8_t dnxhd_1251_dc_codes[12] = {
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
290 0, 12, 13, 1, 2, 3, 4, 5, 14, 30, 62, 63,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
291 };
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
292 static const uint8_t dnxhd_1251_dc_bits[12] = {
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
293 3, 4, 4, 3, 3, 3, 3, 3, 4, 5, 6, 6,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
294 };
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
295 static const uint16_t dnxhd_1251_ac_codes[257] = {
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
296 0, 1, 4, 10, 11, 24, 25, 26, 54, 55, 56, 57, 116, 117, 118, 119, 240, 241, 242, 243, 244, 245, 492, 493, 494, 495, 496, 497, 996, 997, 998, 999, 1000, 1001, 1002, 1003, 1004, 1005, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021, 2022, 2023, 2024, 2025, 4052, 4053, 4054, 4055, 4056, 4057, 4058, 4059, 4060, 4061, 4062, 4063, 4064, 4065, 4066, 8134, 8135, 8136, 8137, 8138, 8139, 8140, 8141, 8142, 8143, 8144, 8145, 8146, 8147, 8148, 8149, 8150, 8151, 8152, 8153, 8154, 8155, 8156, 16314, 16315, 16316, 16317, 16318, 16319, 16320, 16321, 16322, 16323, 16324, 16325, 16326, 16327, 16328, 16329, 16330, 16331, 16332, 16333, 16334, 16335, 16336, 16337, 16338, 16339, 32680, 32681, 32682, 32683, 32684, 32685, 32686, 32687, 32688, 32689, 32690, 32691, 32692, 32693, 32694, 32695, 32696, 32697, 32698, 32699, 32700, 32701, 32702, 32703, 32704, 32705, 32706, 32707, 32708, 32709, 32710, 32711, 32712, 32713, 32714, 65430, 65431, 65432, 65433, 65434, 65435, 65436, 65437, 65438, 65439, 65440, 65441, 65442, 65443, 65444, 65445, 65446, 65447, 65448, 65449, 65450, 65451, 65452, 65453, 65454, 65455, 65456, 65457, 65458, 65459, 65460, 65461, 65462, 65463, 65464, 65465, 65466, 65467, 65468, 65469, 65470, 65471, 65472, 65473, 65474, 65475, 65476, 65477, 65478, 65479, 65480, 65481, 65482, 65483, 65484, 65485, 65486, 65487, 65488, 65489, 65490, 65491, 65492, 65493, 65494, 65495, 65496, 65497, 65498, 65499, 65500, 65501, 65502, 65503, 65504, 65505, 65506, 65507, 65508, 65509, 65510, 65511, 65512, 65513, 65514, 65515, 65516, 65517, 65518, 65519, 65520, 65521, 65522, 65523, 65524, 65525, 65526, 65527, 65528, 65529, 65530, 65531, 65532, 65533, 65534, 65535,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
297 };
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
298 static const uint8_t dnxhd_1251_ac_bits[257] = {
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
299 2, 2, 3, 4, 4, 5, 5, 5, 6, 6, 6, 6, 7, 7, 7, 7, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
300 };
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
301 static const uint8_t dnxhd_1251_ac_level[257] = {
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
302 1, 1, 2, 3, 0, 4, 5, 2, 6, 7, 8, 3, 9, 10, 11, 4, 12, 13, 14, 15, 16, 5, 17, 18, 19, 20, 21, 6, 22, 23, 24, 25, 26, 27, 28, 29, 7, 8, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 9, 10, 11, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 12, 13, 14, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 1, 2, 3, 4, 5, 6, 7, 8, 15, 16, 17, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 18, 19, 20, 21, 22, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 23, 24, 25, 26, 27, 28, 59, 60, 61, 62, 63, 64, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
303 };
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
304 static const uint8_t dnxhd_1251_ac_run_flag[257] = {
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
305 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
306 };
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
307 static const uint8_t dnxhd_1251_ac_index_flag[257] = {
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
308 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
309 };
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
310 static const uint16_t dnxhd_1251_run_codes[62] = {
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
311 0, 4, 5, 12, 26, 27, 28, 58, 118, 119, 120, 242, 486, 487, 976, 977, 978, 979, 980, 981, 982, 983, 984, 985, 986, 987, 988, 989, 990, 991, 992, 993, 994, 995, 996, 997, 998, 999, 1000, 1001, 1002, 1003, 1004, 1005, 1006, 1007, 1008, 1009, 1010, 1011, 1012, 1013, 1014, 1015, 1016, 1017, 1018, 1019, 1020, 1021, 1022, 1023,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
312 };
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
313 static const uint8_t dnxhd_1251_run_bits[62] = {
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
314 1, 3, 3, 4, 5, 5, 5, 6, 7, 7, 7, 8, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10, 10,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
315 };
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
316 static const uint8_t dnxhd_1251_run[62] = {
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
317 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
318 };
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
319
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
320 static const uint8_t dnxhd_1252_dc_codes[12] = {
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
321 0, 12, 13, 1, 2, 3, 4, 5, 14, 30, 62, 63,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
322 };
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
323 static const uint8_t dnxhd_1252_dc_bits[12] = {
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
324 3, 4, 4, 3, 3, 3, 3, 3, 4, 5, 6, 6,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
325 };
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
326 static const uint16_t dnxhd_1252_ac_codes[257] = {
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
327 0, 1, 4, 10, 11, 12, 26, 27, 56, 57, 58, 118, 119, 120, 242, 243, 244, 245, 246, 247, 496, 497, 498, 499, 500, 1002, 1003, 1004, 1005, 1006, 1007, 1008, 1009, 2020, 2021, 2022, 2023, 2024, 2025, 2026, 2027, 2028, 2029, 4060, 4061, 4062, 4063, 4064, 4065, 4066, 4067, 4068, 4069, 4070, 4071, 8144, 8145, 8146, 8147, 8148, 8149, 8150, 8151, 8152, 8153, 8154, 8155, 8156, 8157, 8158, 16318, 16319, 16320, 16321, 16322, 16323, 16324, 16325, 16326, 16327, 16328, 16329, 16330, 16331, 16332, 16333, 16334, 16335, 32672, 32673, 32674, 32675, 32676, 32677, 32678, 32679, 32680, 32681, 32682, 32683, 32684, 32685, 32686, 32687, 32688, 32689, 32690, 32691, 32692, 32693, 32694, 65390, 65391, 65392, 65393, 65394, 65395, 65396, 65397, 65398, 65399, 65400, 65401, 65402, 65403, 65404, 65405, 65406, 65407, 65408, 65409, 65410, 65411, 65412, 65413, 65414, 65415, 65416, 65417, 65418, 65419, 65420, 65421, 65422, 65423, 65424, 65425, 65426, 65427, 65428, 65429, 65430, 65431, 65432, 65433, 65434, 65435, 65436, 65437, 65438, 65439, 65440, 65441, 65442, 65443, 65444, 65445, 65446, 65447, 65448, 65449, 65450, 65451, 65452, 65453, 65454, 65455, 65456, 65457, 65458, 65459, 65460, 65461, 65462, 65463, 65464, 65465, 65466, 65467, 65468, 65469, 65470, 65471, 65472, 65473, 65474, 65475, 65476, 65477, 65478, 65479, 65480, 65481, 65482, 65483, 65484, 65485, 65486, 65487, 65488, 65489, 65490, 65491, 65492, 65493, 65494, 65495, 65496, 65497, 65498, 65499, 65500, 65501, 65502, 65503, 65504, 65505, 65506, 65507, 65508, 65509, 65510, 65511, 65512, 65513, 65514, 65515, 65516, 65517, 65518, 65519, 65520, 65521, 65522, 65523, 65524, 65525, 65526, 65527, 65528, 65529, 65530, 65531, 65532, 65533, 65534, 65535,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
328 };
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
329 static const uint8_t dnxhd_1252_ac_bits[257] = {
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
330 2, 2, 3, 4, 4, 4, 5, 5, 6, 6, 6, 7, 7, 7, 8, 8, 8, 8, 8, 8, 9, 9, 9, 9, 9, 10, 10, 10, 10, 10, 10, 10, 10, 11, 11, 11, 11, 11, 11, 11, 11, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 13, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 14, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 15, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16, 16,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
331 };
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
332 static const uint8_t dnxhd_1252_ac_level[257] = {
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
333 1, 1, 2, 3, 2, 0, 4, 5, 6, 7, 3, 8, 9, 10, 11, 12, 13, 14, 4, 5, 15, 16, 17, 18, 6, 19, 20, 21, 22, 23, 24, 7, 8, 25, 26, 27, 28, 29, 30, 31, 32, 9, 10, 33, 34, 35, 36, 37, 38, 39, 40, 41, 11, 12, 13, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 14, 15, 16, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 1, 2, 3, 17, 18, 19, 20, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 21, 22, 23, 24, 25, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
334 };
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
335 static const uint8_t dnxhd_1252_ac_run_flag[257] = {
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
336 0, 1, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
337 };
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
338 static const uint8_t dnxhd_1252_ac_index_flag[257] = {
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
339 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
340 };
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
341
5473
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
342 const CIDEntry ff_dnxhd_cid_table[] = {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
343 { 1237, 1920, 1080, 0, 606208, 606208, 4, 8,
5795
8b6fe123be88 typo weigth->weight
bcoudurier
parents: 5794
diff changeset
344 dnxhd_1237_luma_weight, dnxhd_1237_chroma_weight,
5473
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
345 dnxhd_1237_dc_codes, dnxhd_1237_dc_bits,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
346 dnxhd_1237_ac_codes, dnxhd_1237_ac_bits, dnxhd_1237_ac_level,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
347 dnxhd_1237_ac_run_flag, dnxhd_1237_ac_index_flag,
6041
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
348 dnxhd_1237_run_codes, dnxhd_1237_run_bits, dnxhd_1237_run,
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
349 { 115, 120, 145, 240, 290 } },
5473
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
350 { 1238, 1920, 1080, 0, 917504, 917504, 4, 8,
5795
8b6fe123be88 typo weigth->weight
bcoudurier
parents: 5794
diff changeset
351 dnxhd_1238_luma_weight, dnxhd_1238_chroma_weight,
5473
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
352 dnxhd_1238_dc_codes, dnxhd_1238_dc_bits,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
353 dnxhd_1238_ac_codes, dnxhd_1238_ac_bits, dnxhd_1238_ac_level,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
354 dnxhd_1238_ac_run_flag, dnxhd_1238_ac_index_flag,
6041
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
355 dnxhd_1238_run_codes, dnxhd_1238_run_bits, dnxhd_1238_run,
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
356 { 175, 185, 220, 365, 440 } },
5794
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
357 { 1241, 1920, 1080, 1, 917504, 458752, 6, 10,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
358 dnxhd_1241_luma_weight, dnxhd_1241_chroma_weight,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
359 dnxhd_1241_dc_codes, dnxhd_1241_dc_bits,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
360 dnxhd_1241_ac_codes, dnxhd_1241_ac_bits, dnxhd_1241_ac_level,
8412118b41d3 preliminary 10 bit depth decoding support, still miss generic api to export picture, working on it
bcoudurier
parents: 5521
diff changeset
361 dnxhd_1241_ac_run_flag, dnxhd_1241_ac_index_flag,
8609
99bfffc29ab9 remove duplicate tables
stefang
parents: 8042
diff changeset
362 dnxhd_1238_run_codes, dnxhd_1238_run_bits, dnxhd_1241_run,
6041
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
363 { 185, 220 } },
5521
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
364 { 1242, 1920, 1080, 1, 606208, 303104, 4, 8,
5795
8b6fe123be88 typo weigth->weight
bcoudurier
parents: 5794
diff changeset
365 dnxhd_1242_luma_weight, dnxhd_1242_chroma_weight,
5521
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
366 dnxhd_1237_dc_codes, dnxhd_1237_dc_bits,
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
367 dnxhd_1237_ac_codes, dnxhd_1237_ac_bits, dnxhd_1237_ac_level,
6232e9874f46 dnxhd 120 interlaced support
bcoudurier
parents: 5473
diff changeset
368 dnxhd_1237_ac_run_flag, dnxhd_1237_ac_index_flag,
6041
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
369 dnxhd_1237_run_codes, dnxhd_1237_run_bits, dnxhd_1237_run,
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
370 { 120, 145 } },
5473
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
371 { 1243, 1920, 1080, 1, 917504, 458752, 4, 8,
5795
8b6fe123be88 typo weigth->weight
bcoudurier
parents: 5794
diff changeset
372 dnxhd_1243_luma_weight, dnxhd_1243_chroma_weight,
5473
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
373 dnxhd_1238_dc_codes, dnxhd_1238_dc_bits,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
374 dnxhd_1238_ac_codes, dnxhd_1238_ac_bits, dnxhd_1238_ac_level,
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
375 dnxhd_1238_ac_run_flag, dnxhd_1238_ac_index_flag,
6041
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
376 dnxhd_1238_run_codes, dnxhd_1238_run_bits, dnxhd_1238_run,
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
377 { 185, 220 } },
5971
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
378 { 1251, 1280, 720, 0, 458752, 458752, 4, 8,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
379 dnxhd_1251_luma_weight, dnxhd_1251_chroma_weight,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
380 dnxhd_1251_dc_codes, dnxhd_1251_dc_bits,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
381 dnxhd_1251_ac_codes, dnxhd_1251_ac_bits, dnxhd_1251_ac_level,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
382 dnxhd_1251_ac_run_flag, dnxhd_1251_ac_index_flag,
6041
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
383 dnxhd_1251_run_codes, dnxhd_1251_run_bits, dnxhd_1251_run,
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
384 { 90, 110, 175, 220 } },
5971
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
385 { 1252, 1280, 720, 0, 303104, 303104, 4, 8,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
386 dnxhd_1252_luma_weight, dnxhd_1252_chroma_weight,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
387 dnxhd_1252_dc_codes, dnxhd_1252_dc_bits,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
388 dnxhd_1252_ac_codes, dnxhd_1252_ac_bits, dnxhd_1252_ac_level,
405be936dac4 dnxhd 720p encoding and decoding support
bcoudurier
parents: 5796
diff changeset
389 dnxhd_1252_ac_run_flag, dnxhd_1252_ac_index_flag,
8609
99bfffc29ab9 remove duplicate tables
stefang
parents: 8042
diff changeset
390 dnxhd_1251_run_codes, dnxhd_1251_run_bits, dnxhd_1251_run,
6041
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
391 { 60, 75, 115, 145 } },
5796
5691b843e72a dnxhd 36mbit support
bcoudurier
parents: 5795
diff changeset
392 { 1253, 1920, 1080, 0, 188416, 188416, 4, 8,
5691b843e72a dnxhd 36mbit support
bcoudurier
parents: 5795
diff changeset
393 dnxhd_1237_luma_weight, dnxhd_1237_chroma_weight,
5691b843e72a dnxhd 36mbit support
bcoudurier
parents: 5795
diff changeset
394 dnxhd_1237_dc_codes, dnxhd_1237_dc_bits,
5691b843e72a dnxhd 36mbit support
bcoudurier
parents: 5795
diff changeset
395 dnxhd_1237_ac_codes, dnxhd_1237_ac_bits, dnxhd_1237_ac_level,
5691b843e72a dnxhd 36mbit support
bcoudurier
parents: 5795
diff changeset
396 dnxhd_1237_ac_run_flag, dnxhd_1237_ac_index_flag,
6041
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
397 dnxhd_1237_run_codes, dnxhd_1237_run_bits, dnxhd_1237_run,
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
398 { 36, 45, 75, 90 } },
5473
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
399 };
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
400
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
401 int ff_dnxhd_get_cid_table(int cid)
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
402 {
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
403 int i;
8042
e70975d5ff80 uses FF_ARRAY_ELEMS() where appropriate
aurel
parents: 6975
diff changeset
404 for (i = 0; i < FF_ARRAY_ELEMS(ff_dnxhd_cid_table); i++)
5473
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
405 if (ff_dnxhd_cid_table[i].cid == cid)
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
406 return i;
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
407 return -1;
a0d7ec11b87e move dnxhd data tables to separate file
bcoudurier
parents:
diff changeset
408 }
6041
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
409
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
410 int ff_dnxhd_find_cid(AVCodecContext *avctx)
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
411 {
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
412 int i, j;
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
413 int mbs = avctx->bit_rate/1000000;
6975
230d2edc5502 return if bitrate is not specified or too low
bcoudurier
parents: 6041
diff changeset
414 if (!mbs)
230d2edc5502 return if bitrate is not specified or too low
bcoudurier
parents: 6041
diff changeset
415 return 0;
8042
e70975d5ff80 uses FF_ARRAY_ELEMS() where appropriate
aurel
parents: 6975
diff changeset
416 for (i = 0; i < FF_ARRAY_ELEMS(ff_dnxhd_cid_table); i++) {
6041
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
417 const CIDEntry *cid = &ff_dnxhd_cid_table[i];
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
418 if (cid->width == avctx->width && cid->height == avctx->height &&
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
419 cid->interlaced == !!(avctx->flags & CODEC_FLAG_INTERLACED_DCT) &&
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
420 cid->bit_depth == 8) { // until 10 bit is supported
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
421 for (j = 0; j < sizeof(cid->bit_rates); j++) {
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
422 if (cid->bit_rates[j] == mbs)
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
423 return cid->cid;
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
424 }
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
425 }
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
426 }
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
427 return 0;
bb4b486c6775 add bitrate helper to choose all dnxhd variants
bcoudurier
parents: 5971
diff changeset
428 }