Line data Source code
1 : /* This file has been generated by generate_character_set_conv_tables.c */
2 : /* DO NOT EDIT !*/
3 :
4 : /* clang-format off */
5 : #include "cpl_port.h"
6 : #include "cpl_character_sets.h"
7 :
8 : /* Character set of original IBM PC */
9 : static const CPLCodePageConvTable CPL_CP437_to_UTF8 = {
10 : {0xC3, 0x87, 0x00},
11 : {0xC3, 0xBC, 0x00},
12 : {0xC3, 0xA9, 0x00},
13 : {0xC3, 0xA2, 0x00},
14 : {0xC3, 0xA4, 0x00},
15 : {0xC3, 0xA0, 0x00},
16 : {0xC3, 0xA5, 0x00},
17 : {0xC3, 0xA7, 0x00},
18 : {0xC3, 0xAA, 0x00},
19 : {0xC3, 0xAB, 0x00},
20 : {0xC3, 0xA8, 0x00},
21 : {0xC3, 0xAF, 0x00},
22 : {0xC3, 0xAE, 0x00},
23 : {0xC3, 0xAC, 0x00},
24 : {0xC3, 0x84, 0x00},
25 : {0xC3, 0x85, 0x00},
26 : {0xC3, 0x89, 0x00},
27 : {0xC3, 0xA6, 0x00},
28 : {0xC3, 0x86, 0x00},
29 : {0xC3, 0xB4, 0x00},
30 : {0xC3, 0xB6, 0x00},
31 : {0xC3, 0xB2, 0x00},
32 : {0xC3, 0xBB, 0x00},
33 : {0xC3, 0xB9, 0x00},
34 : {0xC3, 0xBF, 0x00},
35 : {0xC3, 0x96, 0x00},
36 : {0xC3, 0x9C, 0x00},
37 : {0xC2, 0xA2, 0x00},
38 : {0xC2, 0xA3, 0x00},
39 : {0xC2, 0xA5, 0x00},
40 : {0xE2, 0x82, 0xA7},
41 : {0xC6, 0x92, 0x00},
42 : {0xC3, 0xA1, 0x00},
43 : {0xC3, 0xAD, 0x00},
44 : {0xC3, 0xB3, 0x00},
45 : {0xC3, 0xBA, 0x00},
46 : {0xC3, 0xB1, 0x00},
47 : {0xC3, 0x91, 0x00},
48 : {0xC2, 0xAA, 0x00},
49 : {0xC2, 0xBA, 0x00},
50 : {0xC2, 0xBF, 0x00},
51 : {0xE2, 0x8C, 0x90},
52 : {0xC2, 0xAC, 0x00},
53 : {0xC2, 0xBD, 0x00},
54 : {0xC2, 0xBC, 0x00},
55 : {0xC2, 0xA1, 0x00},
56 : {0xC2, 0xAB, 0x00},
57 : {0xC2, 0xBB, 0x00},
58 : {0xE2, 0x96, 0x91},
59 : {0xE2, 0x96, 0x92},
60 : {0xE2, 0x96, 0x93},
61 : {0xE2, 0x94, 0x82},
62 : {0xE2, 0x94, 0xA4},
63 : {0xE2, 0x95, 0xA1},
64 : {0xE2, 0x95, 0xA2},
65 : {0xE2, 0x95, 0x96},
66 : {0xE2, 0x95, 0x95},
67 : {0xE2, 0x95, 0xA3},
68 : {0xE2, 0x95, 0x91},
69 : {0xE2, 0x95, 0x97},
70 : {0xE2, 0x95, 0x9D},
71 : {0xE2, 0x95, 0x9C},
72 : {0xE2, 0x95, 0x9B},
73 : {0xE2, 0x94, 0x90},
74 : {0xE2, 0x94, 0x94},
75 : {0xE2, 0x94, 0xB4},
76 : {0xE2, 0x94, 0xAC},
77 : {0xE2, 0x94, 0x9C},
78 : {0xE2, 0x94, 0x80},
79 : {0xE2, 0x94, 0xBC},
80 : {0xE2, 0x95, 0x9E},
81 : {0xE2, 0x95, 0x9F},
82 : {0xE2, 0x95, 0x9A},
83 : {0xE2, 0x95, 0x94},
84 : {0xE2, 0x95, 0xA9},
85 : {0xE2, 0x95, 0xA6},
86 : {0xE2, 0x95, 0xA0},
87 : {0xE2, 0x95, 0x90},
88 : {0xE2, 0x95, 0xAC},
89 : {0xE2, 0x95, 0xA7},
90 : {0xE2, 0x95, 0xA8},
91 : {0xE2, 0x95, 0xA4},
92 : {0xE2, 0x95, 0xA5},
93 : {0xE2, 0x95, 0x99},
94 : {0xE2, 0x95, 0x98},
95 : {0xE2, 0x95, 0x92},
96 : {0xE2, 0x95, 0x93},
97 : {0xE2, 0x95, 0xAB},
98 : {0xE2, 0x95, 0xAA},
99 : {0xE2, 0x94, 0x98},
100 : {0xE2, 0x94, 0x8C},
101 : {0xE2, 0x96, 0x88},
102 : {0xE2, 0x96, 0x84},
103 : {0xE2, 0x96, 0x8C},
104 : {0xE2, 0x96, 0x90},
105 : {0xE2, 0x96, 0x80},
106 : {0xCE, 0xB1, 0x00},
107 : {0xC3, 0x9F, 0x00},
108 : {0xCE, 0x93, 0x00},
109 : {0xCF, 0x80, 0x00},
110 : {0xCE, 0xA3, 0x00},
111 : {0xCF, 0x83, 0x00},
112 : {0xC2, 0xB5, 0x00},
113 : {0xCF, 0x84, 0x00},
114 : {0xCE, 0xA6, 0x00},
115 : {0xCE, 0x98, 0x00},
116 : {0xCE, 0xA9, 0x00},
117 : {0xCE, 0xB4, 0x00},
118 : {0xE2, 0x88, 0x9E},
119 : {0xCF, 0x86, 0x00},
120 : {0xCE, 0xB5, 0x00},
121 : {0xE2, 0x88, 0xA9},
122 : {0xE2, 0x89, 0xA1},
123 : {0xC2, 0xB1, 0x00},
124 : {0xE2, 0x89, 0xA5},
125 : {0xE2, 0x89, 0xA4},
126 : {0xE2, 0x8C, 0xA0},
127 : {0xE2, 0x8C, 0xA1},
128 : {0xC3, 0xB7, 0x00},
129 : {0xE2, 0x89, 0x88},
130 : {0xC2, 0xB0, 0x00},
131 : {0xE2, 0x88, 0x99},
132 : {0xC2, 0xB7, 0x00},
133 : {0xE2, 0x88, 0x9A},
134 : {0xE2, 0x81, 0xBF},
135 : {0xC2, 0xB2, 0x00},
136 : {0xE2, 0x96, 0xA0},
137 : {0xC2, 0xA0, 0x00},
138 : };
139 :
140 : /* Central and eastern Europe languages */
141 : static const CPLCodePageConvTable CPL_CP1250_to_UTF8 = {
142 : {0xE2, 0x82, 0xAC},
143 : {0, 0, 0}, /* invalid */
144 : {0xE2, 0x80, 0x9A},
145 : {0, 0, 0}, /* invalid */
146 : {0xE2, 0x80, 0x9E},
147 : {0xE2, 0x80, 0xA6},
148 : {0xE2, 0x80, 0xA0},
149 : {0xE2, 0x80, 0xA1},
150 : {0, 0, 0}, /* invalid */
151 : {0xE2, 0x80, 0xB0},
152 : {0xC5, 0xA0, 0x00},
153 : {0xE2, 0x80, 0xB9},
154 : {0xC5, 0x9A, 0x00},
155 : {0xC5, 0xA4, 0x00},
156 : {0xC5, 0xBD, 0x00},
157 : {0xC5, 0xB9, 0x00},
158 : {0, 0, 0}, /* invalid */
159 : {0xE2, 0x80, 0x98},
160 : {0xE2, 0x80, 0x99},
161 : {0xE2, 0x80, 0x9C},
162 : {0xE2, 0x80, 0x9D},
163 : {0xE2, 0x80, 0xA2},
164 : {0xE2, 0x80, 0x93},
165 : {0xE2, 0x80, 0x94},
166 : {0, 0, 0}, /* invalid */
167 : {0xE2, 0x84, 0xA2},
168 : {0xC5, 0xA1, 0x00},
169 : {0xE2, 0x80, 0xBA},
170 : {0xC5, 0x9B, 0x00},
171 : {0xC5, 0xA5, 0x00},
172 : {0xC5, 0xBE, 0x00},
173 : {0xC5, 0xBA, 0x00},
174 : {0xC2, 0xA0, 0x00},
175 : {0xCB, 0x87, 0x00},
176 : {0xCB, 0x98, 0x00},
177 : {0xC5, 0x81, 0x00},
178 : {0xC2, 0xA4, 0x00},
179 : {0xC4, 0x84, 0x00},
180 : {0xC2, 0xA6, 0x00},
181 : {0xC2, 0xA7, 0x00},
182 : {0xC2, 0xA8, 0x00},
183 : {0xC2, 0xA9, 0x00},
184 : {0xC5, 0x9E, 0x00},
185 : {0xC2, 0xAB, 0x00},
186 : {0xC2, 0xAC, 0x00},
187 : {0xC2, 0xAD, 0x00},
188 : {0xC2, 0xAE, 0x00},
189 : {0xC5, 0xBB, 0x00},
190 : {0xC2, 0xB0, 0x00},
191 : {0xC2, 0xB1, 0x00},
192 : {0xCB, 0x9B, 0x00},
193 : {0xC5, 0x82, 0x00},
194 : {0xC2, 0xB4, 0x00},
195 : {0xC2, 0xB5, 0x00},
196 : {0xC2, 0xB6, 0x00},
197 : {0xC2, 0xB7, 0x00},
198 : {0xC2, 0xB8, 0x00},
199 : {0xC4, 0x85, 0x00},
200 : {0xC5, 0x9F, 0x00},
201 : {0xC2, 0xBB, 0x00},
202 : {0xC4, 0xBD, 0x00},
203 : {0xCB, 0x9D, 0x00},
204 : {0xC4, 0xBE, 0x00},
205 : {0xC5, 0xBC, 0x00},
206 : {0xC5, 0x94, 0x00},
207 : {0xC3, 0x81, 0x00},
208 : {0xC3, 0x82, 0x00},
209 : {0xC4, 0x82, 0x00},
210 : {0xC3, 0x84, 0x00},
211 : {0xC4, 0xB9, 0x00},
212 : {0xC4, 0x86, 0x00},
213 : {0xC3, 0x87, 0x00},
214 : {0xC4, 0x8C, 0x00},
215 : {0xC3, 0x89, 0x00},
216 : {0xC4, 0x98, 0x00},
217 : {0xC3, 0x8B, 0x00},
218 : {0xC4, 0x9A, 0x00},
219 : {0xC3, 0x8D, 0x00},
220 : {0xC3, 0x8E, 0x00},
221 : {0xC4, 0x8E, 0x00},
222 : {0xC4, 0x90, 0x00},
223 : {0xC5, 0x83, 0x00},
224 : {0xC5, 0x87, 0x00},
225 : {0xC3, 0x93, 0x00},
226 : {0xC3, 0x94, 0x00},
227 : {0xC5, 0x90, 0x00},
228 : {0xC3, 0x96, 0x00},
229 : {0xC3, 0x97, 0x00},
230 : {0xC5, 0x98, 0x00},
231 : {0xC5, 0xAE, 0x00},
232 : {0xC3, 0x9A, 0x00},
233 : {0xC5, 0xB0, 0x00},
234 : {0xC3, 0x9C, 0x00},
235 : {0xC3, 0x9D, 0x00},
236 : {0xC5, 0xA2, 0x00},
237 : {0xC3, 0x9F, 0x00},
238 : {0xC5, 0x95, 0x00},
239 : {0xC3, 0xA1, 0x00},
240 : {0xC3, 0xA2, 0x00},
241 : {0xC4, 0x83, 0x00},
242 : {0xC3, 0xA4, 0x00},
243 : {0xC4, 0xBA, 0x00},
244 : {0xC4, 0x87, 0x00},
245 : {0xC3, 0xA7, 0x00},
246 : {0xC4, 0x8D, 0x00},
247 : {0xC3, 0xA9, 0x00},
248 : {0xC4, 0x99, 0x00},
249 : {0xC3, 0xAB, 0x00},
250 : {0xC4, 0x9B, 0x00},
251 : {0xC3, 0xAD, 0x00},
252 : {0xC3, 0xAE, 0x00},
253 : {0xC4, 0x8F, 0x00},
254 : {0xC4, 0x91, 0x00},
255 : {0xC5, 0x84, 0x00},
256 : {0xC5, 0x88, 0x00},
257 : {0xC3, 0xB3, 0x00},
258 : {0xC3, 0xB4, 0x00},
259 : {0xC5, 0x91, 0x00},
260 : {0xC3, 0xB6, 0x00},
261 : {0xC3, 0xB7, 0x00},
262 : {0xC5, 0x99, 0x00},
263 : {0xC5, 0xAF, 0x00},
264 : {0xC3, 0xBA, 0x00},
265 : {0xC5, 0xB1, 0x00},
266 : {0xC3, 0xBC, 0x00},
267 : {0xC3, 0xBD, 0x00},
268 : {0xC5, 0xA3, 0x00},
269 : {0xCB, 0x99, 0x00},
270 : };
271 :
272 : /* Cyrillic script */
273 : static const CPLCodePageConvTable CPL_CP1251_to_UTF8 = {
274 : {0xD0, 0x82, 0x00},
275 : {0xD0, 0x83, 0x00},
276 : {0xE2, 0x80, 0x9A},
277 : {0xD1, 0x93, 0x00},
278 : {0xE2, 0x80, 0x9E},
279 : {0xE2, 0x80, 0xA6},
280 : {0xE2, 0x80, 0xA0},
281 : {0xE2, 0x80, 0xA1},
282 : {0xE2, 0x82, 0xAC},
283 : {0xE2, 0x80, 0xB0},
284 : {0xD0, 0x89, 0x00},
285 : {0xE2, 0x80, 0xB9},
286 : {0xD0, 0x8A, 0x00},
287 : {0xD0, 0x8C, 0x00},
288 : {0xD0, 0x8B, 0x00},
289 : {0xD0, 0x8F, 0x00},
290 : {0xD1, 0x92, 0x00},
291 : {0xE2, 0x80, 0x98},
292 : {0xE2, 0x80, 0x99},
293 : {0xE2, 0x80, 0x9C},
294 : {0xE2, 0x80, 0x9D},
295 : {0xE2, 0x80, 0xA2},
296 : {0xE2, 0x80, 0x93},
297 : {0xE2, 0x80, 0x94},
298 : {0, 0, 0}, /* invalid */
299 : {0xE2, 0x84, 0xA2},
300 : {0xD1, 0x99, 0x00},
301 : {0xE2, 0x80, 0xBA},
302 : {0xD1, 0x9A, 0x00},
303 : {0xD1, 0x9C, 0x00},
304 : {0xD1, 0x9B, 0x00},
305 : {0xD1, 0x9F, 0x00},
306 : {0xC2, 0xA0, 0x00},
307 : {0xD0, 0x8E, 0x00},
308 : {0xD1, 0x9E, 0x00},
309 : {0xD0, 0x88, 0x00},
310 : {0xC2, 0xA4, 0x00},
311 : {0xD2, 0x90, 0x00},
312 : {0xC2, 0xA6, 0x00},
313 : {0xC2, 0xA7, 0x00},
314 : {0xD0, 0x81, 0x00},
315 : {0xC2, 0xA9, 0x00},
316 : {0xD0, 0x84, 0x00},
317 : {0xC2, 0xAB, 0x00},
318 : {0xC2, 0xAC, 0x00},
319 : {0xC2, 0xAD, 0x00},
320 : {0xC2, 0xAE, 0x00},
321 : {0xD0, 0x87, 0x00},
322 : {0xC2, 0xB0, 0x00},
323 : {0xC2, 0xB1, 0x00},
324 : {0xD0, 0x86, 0x00},
325 : {0xD1, 0x96, 0x00},
326 : {0xD2, 0x91, 0x00},
327 : {0xC2, 0xB5, 0x00},
328 : {0xC2, 0xB6, 0x00},
329 : {0xC2, 0xB7, 0x00},
330 : {0xD1, 0x91, 0x00},
331 : {0xE2, 0x84, 0x96},
332 : {0xD1, 0x94, 0x00},
333 : {0xC2, 0xBB, 0x00},
334 : {0xD1, 0x98, 0x00},
335 : {0xD0, 0x85, 0x00},
336 : {0xD1, 0x95, 0x00},
337 : {0xD1, 0x97, 0x00},
338 : {0xD0, 0x90, 0x00},
339 : {0xD0, 0x91, 0x00},
340 : {0xD0, 0x92, 0x00},
341 : {0xD0, 0x93, 0x00},
342 : {0xD0, 0x94, 0x00},
343 : {0xD0, 0x95, 0x00},
344 : {0xD0, 0x96, 0x00},
345 : {0xD0, 0x97, 0x00},
346 : {0xD0, 0x98, 0x00},
347 : {0xD0, 0x99, 0x00},
348 : {0xD0, 0x9A, 0x00},
349 : {0xD0, 0x9B, 0x00},
350 : {0xD0, 0x9C, 0x00},
351 : {0xD0, 0x9D, 0x00},
352 : {0xD0, 0x9E, 0x00},
353 : {0xD0, 0x9F, 0x00},
354 : {0xD0, 0xA0, 0x00},
355 : {0xD0, 0xA1, 0x00},
356 : {0xD0, 0xA2, 0x00},
357 : {0xD0, 0xA3, 0x00},
358 : {0xD0, 0xA4, 0x00},
359 : {0xD0, 0xA5, 0x00},
360 : {0xD0, 0xA6, 0x00},
361 : {0xD0, 0xA7, 0x00},
362 : {0xD0, 0xA8, 0x00},
363 : {0xD0, 0xA9, 0x00},
364 : {0xD0, 0xAA, 0x00},
365 : {0xD0, 0xAB, 0x00},
366 : {0xD0, 0xAC, 0x00},
367 : {0xD0, 0xAD, 0x00},
368 : {0xD0, 0xAE, 0x00},
369 : {0xD0, 0xAF, 0x00},
370 : {0xD0, 0xB0, 0x00},
371 : {0xD0, 0xB1, 0x00},
372 : {0xD0, 0xB2, 0x00},
373 : {0xD0, 0xB3, 0x00},
374 : {0xD0, 0xB4, 0x00},
375 : {0xD0, 0xB5, 0x00},
376 : {0xD0, 0xB6, 0x00},
377 : {0xD0, 0xB7, 0x00},
378 : {0xD0, 0xB8, 0x00},
379 : {0xD0, 0xB9, 0x00},
380 : {0xD0, 0xBA, 0x00},
381 : {0xD0, 0xBB, 0x00},
382 : {0xD0, 0xBC, 0x00},
383 : {0xD0, 0xBD, 0x00},
384 : {0xD0, 0xBE, 0x00},
385 : {0xD0, 0xBF, 0x00},
386 : {0xD1, 0x80, 0x00},
387 : {0xD1, 0x81, 0x00},
388 : {0xD1, 0x82, 0x00},
389 : {0xD1, 0x83, 0x00},
390 : {0xD1, 0x84, 0x00},
391 : {0xD1, 0x85, 0x00},
392 : {0xD1, 0x86, 0x00},
393 : {0xD1, 0x87, 0x00},
394 : {0xD1, 0x88, 0x00},
395 : {0xD1, 0x89, 0x00},
396 : {0xD1, 0x8A, 0x00},
397 : {0xD1, 0x8B, 0x00},
398 : {0xD1, 0x8C, 0x00},
399 : {0xD1, 0x8D, 0x00},
400 : {0xD1, 0x8E, 0x00},
401 : {0xD1, 0x8F, 0x00},
402 : };
403 :
404 : /* Legacy Windows single-byte character set used in a lot of countries */
405 : static const CPLCodePageConvTable CPL_CP1252_to_UTF8 = {
406 : {0xE2, 0x82, 0xAC},
407 : {0, 0, 0}, /* invalid */
408 : {0xE2, 0x80, 0x9A},
409 : {0xC6, 0x92, 0x00},
410 : {0xE2, 0x80, 0x9E},
411 : {0xE2, 0x80, 0xA6},
412 : {0xE2, 0x80, 0xA0},
413 : {0xE2, 0x80, 0xA1},
414 : {0xCB, 0x86, 0x00},
415 : {0xE2, 0x80, 0xB0},
416 : {0xC5, 0xA0, 0x00},
417 : {0xE2, 0x80, 0xB9},
418 : {0xC5, 0x92, 0x00},
419 : {0, 0, 0}, /* invalid */
420 : {0xC5, 0xBD, 0x00},
421 : {0, 0, 0}, /* invalid */
422 : {0, 0, 0}, /* invalid */
423 : {0xE2, 0x80, 0x98},
424 : {0xE2, 0x80, 0x99},
425 : {0xE2, 0x80, 0x9C},
426 : {0xE2, 0x80, 0x9D},
427 : {0xE2, 0x80, 0xA2},
428 : {0xE2, 0x80, 0x93},
429 : {0xE2, 0x80, 0x94},
430 : {0xCB, 0x9C, 0x00},
431 : {0xE2, 0x84, 0xA2},
432 : {0xC5, 0xA1, 0x00},
433 : {0xE2, 0x80, 0xBA},
434 : {0xC5, 0x93, 0x00},
435 : {0, 0, 0}, /* invalid */
436 : {0xC5, 0xBE, 0x00},
437 : {0xC5, 0xB8, 0x00},
438 : {0xC2, 0xA0, 0x00},
439 : {0xC2, 0xA1, 0x00},
440 : {0xC2, 0xA2, 0x00},
441 : {0xC2, 0xA3, 0x00},
442 : {0xC2, 0xA4, 0x00},
443 : {0xC2, 0xA5, 0x00},
444 : {0xC2, 0xA6, 0x00},
445 : {0xC2, 0xA7, 0x00},
446 : {0xC2, 0xA8, 0x00},
447 : {0xC2, 0xA9, 0x00},
448 : {0xC2, 0xAA, 0x00},
449 : {0xC2, 0xAB, 0x00},
450 : {0xC2, 0xAC, 0x00},
451 : {0xC2, 0xAD, 0x00},
452 : {0xC2, 0xAE, 0x00},
453 : {0xC2, 0xAF, 0x00},
454 : {0xC2, 0xB0, 0x00},
455 : {0xC2, 0xB1, 0x00},
456 : {0xC2, 0xB2, 0x00},
457 : {0xC2, 0xB3, 0x00},
458 : {0xC2, 0xB4, 0x00},
459 : {0xC2, 0xB5, 0x00},
460 : {0xC2, 0xB6, 0x00},
461 : {0xC2, 0xB7, 0x00},
462 : {0xC2, 0xB8, 0x00},
463 : {0xC2, 0xB9, 0x00},
464 : {0xC2, 0xBA, 0x00},
465 : {0xC2, 0xBB, 0x00},
466 : {0xC2, 0xBC, 0x00},
467 : {0xC2, 0xBD, 0x00},
468 : {0xC2, 0xBE, 0x00},
469 : {0xC2, 0xBF, 0x00},
470 : {0xC3, 0x80, 0x00},
471 : {0xC3, 0x81, 0x00},
472 : {0xC3, 0x82, 0x00},
473 : {0xC3, 0x83, 0x00},
474 : {0xC3, 0x84, 0x00},
475 : {0xC3, 0x85, 0x00},
476 : {0xC3, 0x86, 0x00},
477 : {0xC3, 0x87, 0x00},
478 : {0xC3, 0x88, 0x00},
479 : {0xC3, 0x89, 0x00},
480 : {0xC3, 0x8A, 0x00},
481 : {0xC3, 0x8B, 0x00},
482 : {0xC3, 0x8C, 0x00},
483 : {0xC3, 0x8D, 0x00},
484 : {0xC3, 0x8E, 0x00},
485 : {0xC3, 0x8F, 0x00},
486 : {0xC3, 0x90, 0x00},
487 : {0xC3, 0x91, 0x00},
488 : {0xC3, 0x92, 0x00},
489 : {0xC3, 0x93, 0x00},
490 : {0xC3, 0x94, 0x00},
491 : {0xC3, 0x95, 0x00},
492 : {0xC3, 0x96, 0x00},
493 : {0xC3, 0x97, 0x00},
494 : {0xC3, 0x98, 0x00},
495 : {0xC3, 0x99, 0x00},
496 : {0xC3, 0x9A, 0x00},
497 : {0xC3, 0x9B, 0x00},
498 : {0xC3, 0x9C, 0x00},
499 : {0xC3, 0x9D, 0x00},
500 : {0xC3, 0x9E, 0x00},
501 : {0xC3, 0x9F, 0x00},
502 : {0xC3, 0xA0, 0x00},
503 : {0xC3, 0xA1, 0x00},
504 : {0xC3, 0xA2, 0x00},
505 : {0xC3, 0xA3, 0x00},
506 : {0xC3, 0xA4, 0x00},
507 : {0xC3, 0xA5, 0x00},
508 : {0xC3, 0xA6, 0x00},
509 : {0xC3, 0xA7, 0x00},
510 : {0xC3, 0xA8, 0x00},
511 : {0xC3, 0xA9, 0x00},
512 : {0xC3, 0xAA, 0x00},
513 : {0xC3, 0xAB, 0x00},
514 : {0xC3, 0xAC, 0x00},
515 : {0xC3, 0xAD, 0x00},
516 : {0xC3, 0xAE, 0x00},
517 : {0xC3, 0xAF, 0x00},
518 : {0xC3, 0xB0, 0x00},
519 : {0xC3, 0xB1, 0x00},
520 : {0xC3, 0xB2, 0x00},
521 : {0xC3, 0xB3, 0x00},
522 : {0xC3, 0xB4, 0x00},
523 : {0xC3, 0xB5, 0x00},
524 : {0xC3, 0xB6, 0x00},
525 : {0xC3, 0xB7, 0x00},
526 : {0xC3, 0xB8, 0x00},
527 : {0xC3, 0xB9, 0x00},
528 : {0xC3, 0xBA, 0x00},
529 : {0xC3, 0xBB, 0x00},
530 : {0xC3, 0xBC, 0x00},
531 : {0xC3, 0xBD, 0x00},
532 : {0xC3, 0xBE, 0x00},
533 : {0xC3, 0xBF, 0x00},
534 : };
535 :
536 : /* Central Europe languages */
537 : static const CPLCodePageConvTable CPL_ISO_8859_2_to_UTF8 = {
538 : {0xC2, 0x80, 0x00},
539 : {0xC2, 0x81, 0x00},
540 : {0xC2, 0x82, 0x00},
541 : {0xC2, 0x83, 0x00},
542 : {0xC2, 0x84, 0x00},
543 : {0xC2, 0x85, 0x00},
544 : {0xC2, 0x86, 0x00},
545 : {0xC2, 0x87, 0x00},
546 : {0xC2, 0x88, 0x00},
547 : {0xC2, 0x89, 0x00},
548 : {0xC2, 0x8A, 0x00},
549 : {0xC2, 0x8B, 0x00},
550 : {0xC2, 0x8C, 0x00},
551 : {0xC2, 0x8D, 0x00},
552 : {0xC2, 0x8E, 0x00},
553 : {0xC2, 0x8F, 0x00},
554 : {0xC2, 0x90, 0x00},
555 : {0xC2, 0x91, 0x00},
556 : {0xC2, 0x92, 0x00},
557 : {0xC2, 0x93, 0x00},
558 : {0xC2, 0x94, 0x00},
559 : {0xC2, 0x95, 0x00},
560 : {0xC2, 0x96, 0x00},
561 : {0xC2, 0x97, 0x00},
562 : {0xC2, 0x98, 0x00},
563 : {0xC2, 0x99, 0x00},
564 : {0xC2, 0x9A, 0x00},
565 : {0xC2, 0x9B, 0x00},
566 : {0xC2, 0x9C, 0x00},
567 : {0xC2, 0x9D, 0x00},
568 : {0xC2, 0x9E, 0x00},
569 : {0xC2, 0x9F, 0x00},
570 : {0xC2, 0xA0, 0x00},
571 : {0xC4, 0x84, 0x00},
572 : {0xCB, 0x98, 0x00},
573 : {0xC5, 0x81, 0x00},
574 : {0xC2, 0xA4, 0x00},
575 : {0xC4, 0xBD, 0x00},
576 : {0xC5, 0x9A, 0x00},
577 : {0xC2, 0xA7, 0x00},
578 : {0xC2, 0xA8, 0x00},
579 : {0xC5, 0xA0, 0x00},
580 : {0xC5, 0x9E, 0x00},
581 : {0xC5, 0xA4, 0x00},
582 : {0xC5, 0xB9, 0x00},
583 : {0xC2, 0xAD, 0x00},
584 : {0xC5, 0xBD, 0x00},
585 : {0xC5, 0xBB, 0x00},
586 : {0xC2, 0xB0, 0x00},
587 : {0xC4, 0x85, 0x00},
588 : {0xCB, 0x9B, 0x00},
589 : {0xC5, 0x82, 0x00},
590 : {0xC2, 0xB4, 0x00},
591 : {0xC4, 0xBE, 0x00},
592 : {0xC5, 0x9B, 0x00},
593 : {0xCB, 0x87, 0x00},
594 : {0xC2, 0xB8, 0x00},
595 : {0xC5, 0xA1, 0x00},
596 : {0xC5, 0x9F, 0x00},
597 : {0xC5, 0xA5, 0x00},
598 : {0xC5, 0xBA, 0x00},
599 : {0xCB, 0x9D, 0x00},
600 : {0xC5, 0xBE, 0x00},
601 : {0xC5, 0xBC, 0x00},
602 : {0xC5, 0x94, 0x00},
603 : {0xC3, 0x81, 0x00},
604 : {0xC3, 0x82, 0x00},
605 : {0xC4, 0x82, 0x00},
606 : {0xC3, 0x84, 0x00},
607 : {0xC4, 0xB9, 0x00},
608 : {0xC4, 0x86, 0x00},
609 : {0xC3, 0x87, 0x00},
610 : {0xC4, 0x8C, 0x00},
611 : {0xC3, 0x89, 0x00},
612 : {0xC4, 0x98, 0x00},
613 : {0xC3, 0x8B, 0x00},
614 : {0xC4, 0x9A, 0x00},
615 : {0xC3, 0x8D, 0x00},
616 : {0xC3, 0x8E, 0x00},
617 : {0xC4, 0x8E, 0x00},
618 : {0xC4, 0x90, 0x00},
619 : {0xC5, 0x83, 0x00},
620 : {0xC5, 0x87, 0x00},
621 : {0xC3, 0x93, 0x00},
622 : {0xC3, 0x94, 0x00},
623 : {0xC5, 0x90, 0x00},
624 : {0xC3, 0x96, 0x00},
625 : {0xC3, 0x97, 0x00},
626 : {0xC5, 0x98, 0x00},
627 : {0xC5, 0xAE, 0x00},
628 : {0xC3, 0x9A, 0x00},
629 : {0xC5, 0xB0, 0x00},
630 : {0xC3, 0x9C, 0x00},
631 : {0xC3, 0x9D, 0x00},
632 : {0xC5, 0xA2, 0x00},
633 : {0xC3, 0x9F, 0x00},
634 : {0xC5, 0x95, 0x00},
635 : {0xC3, 0xA1, 0x00},
636 : {0xC3, 0xA2, 0x00},
637 : {0xC4, 0x83, 0x00},
638 : {0xC3, 0xA4, 0x00},
639 : {0xC4, 0xBA, 0x00},
640 : {0xC4, 0x87, 0x00},
641 : {0xC3, 0xA7, 0x00},
642 : {0xC4, 0x8D, 0x00},
643 : {0xC3, 0xA9, 0x00},
644 : {0xC4, 0x99, 0x00},
645 : {0xC3, 0xAB, 0x00},
646 : {0xC4, 0x9B, 0x00},
647 : {0xC3, 0xAD, 0x00},
648 : {0xC3, 0xAE, 0x00},
649 : {0xC4, 0x8F, 0x00},
650 : {0xC4, 0x91, 0x00},
651 : {0xC5, 0x84, 0x00},
652 : {0xC5, 0x88, 0x00},
653 : {0xC3, 0xB3, 0x00},
654 : {0xC3, 0xB4, 0x00},
655 : {0xC5, 0x91, 0x00},
656 : {0xC3, 0xB6, 0x00},
657 : {0xC3, 0xB7, 0x00},
658 : {0xC5, 0x99, 0x00},
659 : {0xC5, 0xAF, 0x00},
660 : {0xC3, 0xBA, 0x00},
661 : {0xC5, 0xB1, 0x00},
662 : {0xC3, 0xBC, 0x00},
663 : {0xC3, 0xBD, 0x00},
664 : {0xC5, 0xA3, 0x00},
665 : {0xCB, 0x99, 0x00},
666 : };
667 :
668 : /* New Western Europe */
669 : static const CPLCodePageConvTable CPL_ISO_8859_15_to_UTF8 = {
670 : {0xC2, 0x80, 0x00},
671 : {0xC2, 0x81, 0x00},
672 : {0xC2, 0x82, 0x00},
673 : {0xC2, 0x83, 0x00},
674 : {0xC2, 0x84, 0x00},
675 : {0xC2, 0x85, 0x00},
676 : {0xC2, 0x86, 0x00},
677 : {0xC2, 0x87, 0x00},
678 : {0xC2, 0x88, 0x00},
679 : {0xC2, 0x89, 0x00},
680 : {0xC2, 0x8A, 0x00},
681 : {0xC2, 0x8B, 0x00},
682 : {0xC2, 0x8C, 0x00},
683 : {0xC2, 0x8D, 0x00},
684 : {0xC2, 0x8E, 0x00},
685 : {0xC2, 0x8F, 0x00},
686 : {0xC2, 0x90, 0x00},
687 : {0xC2, 0x91, 0x00},
688 : {0xC2, 0x92, 0x00},
689 : {0xC2, 0x93, 0x00},
690 : {0xC2, 0x94, 0x00},
691 : {0xC2, 0x95, 0x00},
692 : {0xC2, 0x96, 0x00},
693 : {0xC2, 0x97, 0x00},
694 : {0xC2, 0x98, 0x00},
695 : {0xC2, 0x99, 0x00},
696 : {0xC2, 0x9A, 0x00},
697 : {0xC2, 0x9B, 0x00},
698 : {0xC2, 0x9C, 0x00},
699 : {0xC2, 0x9D, 0x00},
700 : {0xC2, 0x9E, 0x00},
701 : {0xC2, 0x9F, 0x00},
702 : {0xC2, 0xA0, 0x00},
703 : {0xC2, 0xA1, 0x00},
704 : {0xC2, 0xA2, 0x00},
705 : {0xC2, 0xA3, 0x00},
706 : {0xE2, 0x82, 0xAC},
707 : {0xC2, 0xA5, 0x00},
708 : {0xC5, 0xA0, 0x00},
709 : {0xC2, 0xA7, 0x00},
710 : {0xC5, 0xA1, 0x00},
711 : {0xC2, 0xA9, 0x00},
712 : {0xC2, 0xAA, 0x00},
713 : {0xC2, 0xAB, 0x00},
714 : {0xC2, 0xAC, 0x00},
715 : {0xC2, 0xAD, 0x00},
716 : {0xC2, 0xAE, 0x00},
717 : {0xC2, 0xAF, 0x00},
718 : {0xC2, 0xB0, 0x00},
719 : {0xC2, 0xB1, 0x00},
720 : {0xC2, 0xB2, 0x00},
721 : {0xC2, 0xB3, 0x00},
722 : {0xC5, 0xBD, 0x00},
723 : {0xC2, 0xB5, 0x00},
724 : {0xC2, 0xB6, 0x00},
725 : {0xC2, 0xB7, 0x00},
726 : {0xC5, 0xBE, 0x00},
727 : {0xC2, 0xB9, 0x00},
728 : {0xC2, 0xBA, 0x00},
729 : {0xC2, 0xBB, 0x00},
730 : {0xC5, 0x92, 0x00},
731 : {0xC5, 0x93, 0x00},
732 : {0xC5, 0xB8, 0x00},
733 : {0xC2, 0xBF, 0x00},
734 : {0xC3, 0x80, 0x00},
735 : {0xC3, 0x81, 0x00},
736 : {0xC3, 0x82, 0x00},
737 : {0xC3, 0x83, 0x00},
738 : {0xC3, 0x84, 0x00},
739 : {0xC3, 0x85, 0x00},
740 : {0xC3, 0x86, 0x00},
741 : {0xC3, 0x87, 0x00},
742 : {0xC3, 0x88, 0x00},
743 : {0xC3, 0x89, 0x00},
744 : {0xC3, 0x8A, 0x00},
745 : {0xC3, 0x8B, 0x00},
746 : {0xC3, 0x8C, 0x00},
747 : {0xC3, 0x8D, 0x00},
748 : {0xC3, 0x8E, 0x00},
749 : {0xC3, 0x8F, 0x00},
750 : {0xC3, 0x90, 0x00},
751 : {0xC3, 0x91, 0x00},
752 : {0xC3, 0x92, 0x00},
753 : {0xC3, 0x93, 0x00},
754 : {0xC3, 0x94, 0x00},
755 : {0xC3, 0x95, 0x00},
756 : {0xC3, 0x96, 0x00},
757 : {0xC3, 0x97, 0x00},
758 : {0xC3, 0x98, 0x00},
759 : {0xC3, 0x99, 0x00},
760 : {0xC3, 0x9A, 0x00},
761 : {0xC3, 0x9B, 0x00},
762 : {0xC3, 0x9C, 0x00},
763 : {0xC3, 0x9D, 0x00},
764 : {0xC3, 0x9E, 0x00},
765 : {0xC3, 0x9F, 0x00},
766 : {0xC3, 0xA0, 0x00},
767 : {0xC3, 0xA1, 0x00},
768 : {0xC3, 0xA2, 0x00},
769 : {0xC3, 0xA3, 0x00},
770 : {0xC3, 0xA4, 0x00},
771 : {0xC3, 0xA5, 0x00},
772 : {0xC3, 0xA6, 0x00},
773 : {0xC3, 0xA7, 0x00},
774 : {0xC3, 0xA8, 0x00},
775 : {0xC3, 0xA9, 0x00},
776 : {0xC3, 0xAA, 0x00},
777 : {0xC3, 0xAB, 0x00},
778 : {0xC3, 0xAC, 0x00},
779 : {0xC3, 0xAD, 0x00},
780 : {0xC3, 0xAE, 0x00},
781 : {0xC3, 0xAF, 0x00},
782 : {0xC3, 0xB0, 0x00},
783 : {0xC3, 0xB1, 0x00},
784 : {0xC3, 0xB2, 0x00},
785 : {0xC3, 0xB3, 0x00},
786 : {0xC3, 0xB4, 0x00},
787 : {0xC3, 0xB5, 0x00},
788 : {0xC3, 0xB6, 0x00},
789 : {0xC3, 0xB7, 0x00},
790 : {0xC3, 0xB8, 0x00},
791 : {0xC3, 0xB9, 0x00},
792 : {0xC3, 0xBA, 0x00},
793 : {0xC3, 0xBB, 0x00},
794 : {0xC3, 0xBC, 0x00},
795 : {0xC3, 0xBD, 0x00},
796 : {0xC3, 0xBE, 0x00},
797 : {0xC3, 0xBF, 0x00},
798 : };
799 :
800 :
801 754667 : const CPLCodePageConvTable* CPLGetConversionTableToUTF8(const char* pszEncoding)
802 : {
803 754667 : if (EQUAL(pszEncoding, "CP437"))
804 29872 : return &CPL_CP437_to_UTF8;
805 724795 : if (EQUAL(pszEncoding, "CP1250"))
806 0 : return &CPL_CP1250_to_UTF8;
807 724795 : if (EQUAL(pszEncoding, "CP1251"))
808 7300 : return &CPL_CP1251_to_UTF8;
809 717495 : if (EQUAL(pszEncoding, "CP1252"))
810 3248 : return &CPL_CP1252_to_UTF8;
811 714247 : if (EQUAL(pszEncoding, "ISO-8859-2"))
812 1620 : return &CPL_ISO_8859_2_to_UTF8;
813 712627 : if (EQUAL(pszEncoding, "ISO-8859-15"))
814 0 : return &CPL_ISO_8859_15_to_UTF8;
815 712627 : return CPL_NULLPTR;
816 : }
817 :
818 : /* clang-format on */
|