summaryrefslogtreecommitdiff
path: root/src/VideoMetadata.c
blob: 722884991990a30e034195a3bd44e9bd0fcdb960 (plain)
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
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
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
1024
1025
1026
1027
1028
1029
1030
1031
1032
1033
1034
1035
1036
1037
1038
1039
1040
1041
1042
1043
1044
1045
1046
1047
1048
1049
1050
1051
1052
1053
1054
1055
1056
1057
1058
1059
1060
1061
1062
1063
1064
1065
1066
1067
1068
1069
1070
1071
1072
1073
1074
1075
1076
1077
1078
1079
1080
1081
1082
1083
1084
1085
1086
1087
1088
1089
1090
1091
1092
1093
1094
1095
1096
1097
1098
1099
1100
1101
1102
1103
1104
1105
1106
1107
1108
1109
1110
1111
1112
1113
1114
1115
1116
1117
1118
1119
1120
1121
1122
1123
1124
1125
1126
1127
1128
1129
1130
1131
1132
1133
1134
1135
1136
1137
1138
1139
1140
1141
1142
1143
1144
1145
1146
1147
1148
1149
1150
1151
1152
1153
1154
1155
1156
1157
1158
1159
1160
1161
1162
1163
1164
1165
1166
1167
1168
1169
1170
1171
1172
1173
1174
1175
1176
1177
1178
1179
1180
1181
1182
1183
1184
1185
1186
1187
1188
1189
1190
1191
1192
1193
1194
1195
1196
1197
1198
1199
1200
1201
1202
1203
1204
1205
1206
1207
1208
1209
1210
1211
1212
1213
1214
1215
1216
1217
1218
1219
1220
1221
1222
1223
1224
1225
1226
1227
1228
1229
1230
1231
1232
1233
1234
1235
1236
1237
1238
1239
1240
1241
1242
1243
1244
1245
1246
1247
1248
1249
1250
1251
1252
1253
1254
1255
1256
1257
1258
1259
1260
1261
1262
1263
1264
1265
1266
1267
1268
1269
1270
1271
1272
1273
1274
1275
1276
1277
1278
1279
1280
1281
1282
1283
1284
1285
1286
1287
1288
1289
1290
1291
1292
1293
1294
1295
1296
1297
1298
1299
1300
1301
1302
1303
1304
1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
1521
1522
1523
1524
1525
1526
1527
1528
1529
1530
1531
1532
1533
1534
1535
1536
1537
1538
1539
1540
1541
1542
1543
1544
1545
1546
1547
1548
1549
1550
1551
1552
1553
1554
1555
1556
1557
1558
1559
1560
1561
1562
1563
1564
1565
1566
1567
1568
1569
1570
1571
1572
1573
1574
1575
1576
1577
1578
1579
1580
1581
1582
1583
1584
1585
1586
1587
1588
1589
1590
1591
1592
1593
1594
1595
1596
1597
1598
1599
1600
1601
1602
1603
1604
1605
1606
1607
1608
1609
1610
1611
1612
1613
1614
1615
1616
1617
1618
1619
1620
1621
1622
1623
1624
1625
1626
1627
1628
1629
1630
1631
1632
1633
1634
1635
1636
1637
1638
1639
1640
1641
1642
1643
1644
1645
1646
1647
1648
1649
1650
1651
1652
1653
1654
1655
1656
1657
1658
1659
1660
1661
1662
1663
1664
1665
1666
1667
1668
1669
1670
1671
1672
1673
1674
1675
1676
1677
1678
1679
1680
1681
1682
1683
1684
1685
1686
1687
1688
1689
1690
1691
1692
1693
1694
1695
1696
1697
1698
1699
1700
1701
1702
1703
1704
1705
1706
1707
1708
1709
1710
1711
1712
1713
1714
1715
1716
1717
1718
1719
1720
1721
1722
1723
1724
1725
1726
1727
1728
1729
1730
1731
1732
1733
1734
1735
1736
1737
1738
1739
1740
1741
1742
1743
1744
1745
1746
1747
1748
1749
1750
1751
1752
1753
1754
1755
1756
1757
1758
1759
1760
1761
1762
1763
1764
1765
1766
1767
1768
1769
1770
1771
1772
1773
1774
1775
1776
1777
1778
1779
1780
1781
1782
1783
1784
1785
1786
1787
1788
1789
1790
1791
1792
1793
1794
1795
1796
1797
1798
1799
1800
1801
1802
1803
1804
1805
1806
1807
1808
1809
1810
1811
1812
1813
1814
1815
1816
1817
1818
1819
1820
1821
1822
1823
1824
1825
1826
1827
1828
1829
1830
1831
1832
1833
1834
1835
1836
1837
1838
1839
1840
1841
1842
1843
1844
1845
1846
1847
1848
1849
1850
1851
1852
1853
1854
1855
1856
1857
1858
1859
1860
1861
1862
1863
1864
1865
1866
1867
1868
1869
1870
1871
1872
1873
1874
1875
1876
1877
1878
1879
1880
1881
1882
1883
1884
1885
1886
1887
1888
1889
1890
1891
1892
1893
1894
1895
1896
1897
1898
1899
1900
1901
1902
1903
1904
1905
1906
1907
1908
1909
1910
1911
1912
1913
1914
1915
1916
1917
1918
1919
1920
1921
1922
1923
1924
1925
1926
1927
1928
1929
1930
1931
1932
1933
1934
1935
1936
1937
1938
1939
1940
1941
1942
1943
1944
1945
1946
1947
1948
1949
1950
1951
1952
1953
1954
1955
1956
1957
1958
1959
1960
1961
1962
1963
1964
1965
1966
1967
1968
1969
1970
1971
1972
1973
1974
1975
1976
1977
1978
1979
1980
1981
1982
1983
1984
1985
1986
1987
1988
1989
1990
1991
1992
1993
1994
1995
1996
1997
1998
1999
2000
2001
2002
2003
2004
2005
2006
2007
2008
2009
2010
2011
2012
2013
2014
2015
2016
2017
2018
2019
2020
2021
2022
2023
2024
2025
2026
2027
2028
2029
2030
2031
2032
2033
2034
2035
2036
2037
2038
2039
2040
2041
2042
2043
2044
2045
2046
2047
2048
2049
2050
2051
2052
2053
2054
2055
2056
2057
2058
2059
2060
2061
2062
2063
2064
2065
2066
2067
2068
2069
2070
2071
2072
2073
2074
2075
2076
2077
2078
2079
2080
2081
2082
2083
2084
2085
2086
2087
2088
2089
2090
2091
2092
2093
2094
2095
2096
2097
2098
2099
2100
2101
2102
2103
2104
2105
2106
2107
2108
2109
2110
2111
2112
2113
2114
2115
2116
2117
2118
2119
2120
2121
2122
2123
2124
2125
2126
2127
2128
2129
2130
2131
2132
2133
2134
2135
2136
2137
2138
2139
2140
2141
2142
2143
2144
2145
2146
2147
2148
2149
2150
2151
2152
2153
2154
2155
2156
2157
2158
2159
2160
2161
2162
2163
2164
2165
2166
2167
2168
2169
2170
2171
2172
2173
2174
2175
2176
2177
2178
2179
2180
2181
2182
2183
2184
2185
2186
2187
2188
2189
2190
2191
2192
2193
2194
2195
2196
2197
2198
2199
2200
2201
2202
2203
2204
2205
2206
2207
2208
2209
2210
2211
2212
2213
2214
2215
2216
2217
2218
2219
2220
2221
2222
2223
2224
2225
2226
2227
2228
2229
2230
2231
2232
2233
2234
2235
2236
2237
2238
2239
2240
2241
2242
2243
2244
2245
2246
2247
2248
2249
2250
2251
2252
2253
2254
2255
2256
2257
2258
2259
2260
2261
2262
2263
2264
2265
2266
2267
2268
2269
2270
2271
2272
2273
2274
2275
2276
2277
2278
2279
2280
2281
2282
2283
2284
2285
2286
2287
2288
2289
2290
2291
2292
2293
2294
2295
2296
2297
2298
2299
2300
2301
2302
2303
2304
2305
2306
2307
2308
2309
2310
2311
2312
2313
2314
2315
2316
2317
2318
2319
2320
2321
2322
2323
2324
2325
2326
2327
2328
2329
2330
2331
2332
2333
2334
2335
2336
2337
2338
2339
2340
2341
2342
2343
2344
2345
2346
2347
2348
2349
2350
2351
2352
2353
2354
2355
2356
2357
2358
2359
2360
2361
2362
2363
2364
2365
2366
2367
2368
2369
2370
2371
2372
2373
2374
2375
2376
2377
2378
2379
2380
2381
2382
2383
2384
2385
2386
2387
2388
2389
2390
2391
2392
2393
2394
2395
2396
2397
2398
2399
2400
2401
2402
2403
2404
2405
2406
2407
2408
2409
2410
2411
2412
2413
2414
2415
2416
2417
2418
2419
2420
2421
2422
2423
2424
2425
2426
2427
2428
2429
2430
2431
2432
2433
2434
2435
2436
2437
2438
2439
2440
2441
2442
2443
2444
2445
2446
2447
2448
2449
2450
2451
2452
2453
2454
2455
2456
2457
2458
2459
2460
2461
2462
2463
2464
2465
2466
2467
2468
2469
2470
2471
2472
2473
2474
2475
2476
2477
2478
2479
2480
2481
2482
2483
2484
2485
2486
2487
2488
2489
2490
2491
2492
2493
2494
2495
2496
2497
2498
2499
2500
2501
2502
2503
2504
2505
2506
2507
2508
2509
2510
2511
2512
2513
2514
2515
2516
2517
2518
2519
2520
2521
2522
2523
2524
2525
2526
2527
2528
2529
2530
2531
2532
2533
2534
2535
2536
2537
2538
2539
2540
2541
2542
2543
2544
2545
2546
2547
2548
2549
2550
2551
2552
2553
2554
2555
2556
2557
2558
2559
2560
2561
2562
2563
2564
2565
2566
2567
2568
2569
2570
2571
2572
2573
2574
2575
2576
2577
2578
2579
2580
2581
2582
2583
2584
2585
2586
2587
2588
2589
2590
2591
2592
2593
2594
2595
2596
2597
2598
2599
2600
2601
2602
2603
2604
2605
2606
2607
2608
2609
2610
2611
2612
2613
2614
2615
2616
2617
2618
2619
2620
2621
2622
2623
2624
2625
2626
2627
2628
2629
2630
2631
2632
2633
2634
2635
2636
2637
2638
2639
2640
2641
2642
2643
2644
2645
2646
2647
2648
2649
2650
2651
2652
2653
2654
2655
2656
2657
2658
2659
2660
2661
2662
2663
2664
2665
2666
2667
2668
2669
2670
2671
2672
2673
2674
2675
2676
2677
2678
2679
2680
2681
2682
2683
2684
2685
2686
2687
2688
2689
2690
2691
2692
2693
2694
2695
2696
2697
2698
2699
2700
2701
2702
2703
2704
2705
2706
2707
2708
2709
2710
2711
2712
2713
2714
2715
2716
2717
2718
2719
2720
2721
2722
2723
2724
2725
2726
2727
2728
2729
2730
2731
2732
2733
2734
2735
2736
2737
2738
2739
2740
2741
2742
2743
2744
2745
2746
2747
2748
2749
2750
2751
2752
2753
2754
2755
2756
2757
2758
2759
2760
2761
2762
2763
2764
2765
2766
2767
2768
2769
2770
2771
2772
2773
2774
2775
2776
2777
2778
2779
2780
2781
2782
2783
2784
2785
2786
2787
2788
2789
2790
2791
2792
2793
2794
2795
2796
2797
2798
2799
2800
2801
2802
2803
2804
2805
2806
2807
2808
2809
2810
2811
2812
2813
2814
2815
2816
2817
2818
2819
2820
2821
2822
2823
2824
2825
2826
2827
2828
2829
2830
2831
2832
2833
2834
2835
2836
2837
2838
2839
2840
2841
2842
2843
2844
2845
2846
2847
2848
2849
2850
2851
2852
2853
2854
2855
2856
2857
2858
2859
2860
2861
2862
2863
2864
2865
2866
2867
2868
2869
2870
2871
2872
2873
2874
2875
2876
2877
2878
2879
2880
2881
2882
2883
2884
2885
2886
2887
2888
2889
2890
2891
2892
2893
2894
2895
2896
2897
2898
2899
2900
2901
2902
2903
2904
2905
2906
2907
2908
2909
2910
2911
2912
2913
2914
2915
2916
2917
2918
2919
2920
2921
2922
2923
2924
2925
2926
2927
2928
2929
2930
2931
2932
2933
2934
2935
2936
2937
2938
2939
2940
2941
2942
2943
2944
2945
2946
2947
2948
2949
2950
2951
2952
2953
2954
2955
2956
2957
2958
2959
2960
2961
2962
2963
2964
2965
2966
2967
2968
2969
2970
2971
2972
2973
2974
2975
2976
2977
2978
2979
2980
2981
2982
2983
2984
2985
2986
2987
2988
2989
2990
2991
2992
2993
2994
2995
2996
2997
2998
2999
3000
3001
3002
3003
3004
3005
3006
3007
3008
3009
3010
3011
3012
3013
3014
3015
3016
3017
3018
3019
3020
3021
3022
3023
3024
3025
3026
3027
3028
3029
3030
3031
3032
3033
3034
3035
3036
3037
3038
3039
3040
3041
3042
3043
3044
3045
3046
3047
3048
3049
3050
3051
3052
3053
3054
3055
3056
3057
3058
3059
3060
3061
3062
3063
3064
3065
3066
3067
3068
3069
3070
3071
3072
3073
3074
3075
3076
3077
3078
3079
3080
3081
3082
3083
3084
3085
3086
3087
3088
3089
3090
3091
3092
3093
3094
3095
3096
3097
3098
3099
3100
3101
3102
3103
3104
3105
3106
3107
3108
3109
3110
3111
3112
3113
3114
3115
3116
3117
3118
3119
3120
3121
3122
3123
3124
3125
3126
3127
3128
3129
3130
3131
3132
3133
3134
3135
3136
3137
3138
3139
3140
3141
3142
3143
3144
3145
3146
3147
3148
3149
3150
3151
3152
3153
3154
3155
3156
3157
3158
3159
3160
3161
3162
3163
3164
3165
3166
3167
3168
3169
3170
3171
3172
3173
3174
3175
3176
3177
3178
3179
3180
3181
3182
3183
3184
3185
3186
3187
3188
3189
3190
3191
3192
3193
3194
3195
3196
3197
3198
3199
3200
3201
3202
3203
3204
3205
3206
3207
3208
3209
3210
3211
3212
3213
3214
3215
3216
3217
3218
3219
3220
3221
3222
3223
3224
3225
3226
3227
3228
3229
3230
3231
3232
3233
3234
3235
3236
3237
3238
3239
3240
3241
3242
3243
3244
3245
3246
3247
3248
3249
3250
3251
3252
3253
3254
3255
3256
3257
3258
3259
3260
3261
3262
3263
3264
3265
3266
3267
3268
3269
3270
3271
3272
3273
3274
3275
3276
3277
3278
3279
3280
3281
3282
3283
3284
3285
3286
3287
3288
3289
3290
3291
3292
3293
3294
3295
3296
3297
3298
3299
3300
3301
3302
3303
3304
3305
3306
3307
3308
3309
3310
3311
3312
3313
3314
3315
3316
3317
3318
3319
3320
3321
3322
3323
3324
3325
3326
3327
3328
3329
3330
3331
3332
3333
3334
3335
3336
3337
3338
3339
3340
3341
3342
3343
3344
3345
3346
3347
3348
3349
3350
3351
3352
3353
3354
3355
3356
3357
3358
3359
3360
3361
3362
3363
3364
3365
3366
3367
3368
3369
3370
3371
3372
3373
3374
3375
3376
3377
3378
3379
3380
3381
3382
3383
3384
3385
3386
3387
3388
3389
3390
3391
3392
3393
3394
3395
3396
3397
3398
3399
3400
3401
3402
3403
3404
3405
3406
3407
3408
3409
3410
3411
3412
3413
3414
3415
3416
3417
3418
3419
3420
3421
3422
3423
3424
3425
3426
3427
3428
3429
3430
3431
3432
3433
3434
3435
3436
3437
3438
3439
3440
3441
3442
3443
3444
3445
3446
3447
3448
3449
3450
3451
3452
3453
3454
3455
3456
3457
3458
3459
3460
3461
3462
3463
3464
3465
3466
3467
3468
3469
3470
3471
3472
3473
3474
3475
3476
3477
3478
3479
3480
3481
3482
3483
3484
3485
3486
3487
3488
3489
3490
3491
3492
3493
3494
3495
3496
3497
3498
3499
3500
3501
3502
3503
3504
3505
3506
3507
3508
3509
3510
3511
3512
3513
3514
3515
3516
3517
3518
3519
3520
3521
3522
3523
3524
3525
3526
3527
3528
3529
3530
3531
3532
3533
3534
3535
3536
3537
3538
3539
3540
3541
3542
3543
3544
3545
3546
3547
3548
3549
3550
3551
3552
3553
3554
3555
3556
3557
3558
3559
3560
3561
3562
3563
3564
3565
3566
3567
3568
3569
3570
3571
3572
3573
3574
3575
3576
3577
3578
3579
3580
3581
3582
3583
3584
3585
3586
3587
3588
3589
3590
3591
3592
3593
3594
3595
3596
3597
3598
3599
3600
3601
3602
3603
3604
3605
3606
3607
3608
3609
3610
3611
3612
3613
3614
3615
3616
3617
3618
3619
3620
3621
3622
3623
3624
3625
3626
3627
3628
3629
3630
3631
3632
3633
3634
3635
3636
3637
3638
3639
3640
3641
3642
3643
3644
3645
3646
3647
3648
3649
3650
3651
3652
3653
3654
3655
3656
3657
3658
3659
3660
3661
3662
3663
3664
3665
3666
3667
3668
3669
3670
3671
3672
3673
3674
3675
3676
3677
3678
3679
3680
3681
3682
3683
3684
3685
3686
3687
3688
3689
3690
3691
3692
3693
3694
3695
3696
3697
3698
3699
3700
3701
3702
3703
3704
3705
3706
3707
3708
3709
3710
3711
3712
3713
3714
3715
3716
3717
3718
3719
3720
3721
3722
3723
3724
3725
3726
3727
3728
3729
3730
3731
3732
3733
3734
3735
3736
3737
3738
3739
3740
3741
3742
3743
3744
3745
3746
3747
3748
3749
3750
3751
3752
3753
3754
3755
3756
3757
3758
3759
3760
3761
3762
3763
3764
3765
3766
3767
3768
3769
3770
3771
3772
3773
3774
3775
3776
3777
3778
3779
3780
3781
3782
3783
3784
3785
3786
3787
3788
3789
3790
3791
3792
3793
3794
3795
3796
3797
3798
3799
3800
3801
3802
3803
3804
3805
3806
3807
3808
3809
3810
3811
3812
3813
3814
3815
3816
3817
3818
3819
3820
3821
3822
3823
3824
3825
3826
3827
3828
3829
3830
3831
3832
3833
3834
3835
3836
3837
3838
3839
3840
3841
3842
3843
3844
3845
3846
3847
3848
3849
3850
3851
3852
3853
3854
3855
3856
3857
3858
3859
3860
3861
3862
3863
3864
3865
3866
3867
3868
3869
3870
3871
3872
3873
3874
3875
3876
3877
3878
3879
3880
3881
3882
3883
3884
3885
3886
3887
3888
3889
3890
3891
3892
3893
3894
3895
3896
3897
3898
3899
3900
3901
3902
3903
3904
3905
3906
3907
3908
3909
3910
3911
3912
3913
3914
3915
3916
3917
3918
3919
3920
3921
3922
3923
3924
3925
3926
3927
3928
3929
3930
3931
3932
3933
3934
3935
3936
3937
3938
3939
3940
3941
3942
3943
3944
3945
3946
3947
3948
3949
3950
3951
3952
3953
3954
3955
3956
3957
3958
3959
3960
3961
3962
3963
3964
3965
3966
3967
3968
3969
3970
3971
3972
3973
3974
3975
3976
3977
3978
3979
3980
3981
3982
3983
3984
3985
3986
3987
3988
3989
3990
3991
3992
3993
3994
3995
3996
3997
3998
3999
4000
4001
4002
4003
4004
4005
4006
4007
4008
4009
4010
4011
4012
4013
4014
4015
4016
4017
4018
4019
4020
4021
4022
4023
4024
4025
4026
4027
4028
4029
4030
4031
4032
4033
4034
4035
4036
4037
4038
4039
4040
4041
4042
4043
4044
4045
4046
4047
4048
4049
4050
4051
4052
4053
4054
4055
4056
4057
4058
4059
4060
4061
4062
4063
4064
4065
4066
4067
4068
4069
4070
4071
4072
4073
4074
4075
4076
4077
4078
4079
4080
4081
4082
4083
4084
4085
4086
4087
4088
4089
4090
4091
4092
4093
4094
4095
4096
4097
4098
4099
4100
4101
4102
4103
4104
4105
4106
4107
4108
4109
4110
4111
4112
4113
4114
4115
4116
4117
4118
4119
4120
4121
4122
4123
4124
4125
4126
4127
4128
4129
4130
4131
4132
4133
4134
4135
4136
4137
4138
4139
4140
4141
4142
4143
4144
4145
4146
4147
4148
4149
4150
4151
4152
4153
4154
4155
4156
4157
4158
4159
4160
4161
4162
4163
4164
4165
4166
4167
4168
4169
4170
4171
4172
4173
4174
4175
4176
4177
4178
4179
4180
4181
4182
4183
4184
4185
4186
4187
4188
4189
4190
4191
4192
4193
4194
4195
4196
4197
4198
4199
4200
4201
4202
4203
4204
4205
4206
4207
4208
4209
4210
4211
4212
4213
4214
4215
4216
4217
4218
4219
4220
4221
4222
4223
4224
4225
4226
4227
4228
4229
4230
4231
4232
4233
4234
4235
4236
4237
4238
4239
4240
4241
4242
4243
4244
4245
4246
4247
4248
4249
4250
4251
4252
4253
4254
4255
4256
4257
4258
4259
4260
4261
4262
4263
4264
4265
4266
4267
4268
4269
4270
4271
4272
4273
4274
4275
4276
4277
4278
4279
4280
4281
4282
4283
4284
4285
4286
4287
4288
4289
4290
4291
4292
4293
4294
4295
4296
4297
4298
4299
4300
4301
4302
4303
4304
4305
4306
4307
4308
4309
4310
4311
4312
4313
4314
4315
4316
4317
4318
4319
4320
4321
4322
4323
4324
4325
4326
4327
4328
4329
4330
4331
4332
4333
4334
4335
4336
4337
4338
4339
4340
4341
4342
4343
4344
4345
4346
4347
4348
4349
4350
4351
4352
4353
4354
4355
4356
4357
4358
4359
4360
4361
4362
4363
4364
4365
4366
4367
4368
4369
4370
4371
4372
4373
4374
4375
4376
4377
4378
4379
4380
4381
4382
4383
4384
4385
4386
4387
4388
4389
4390
4391
4392
4393
4394
4395
4396
4397
4398
4399
4400
4401
4402
4403
4404
4405
4406
4407
4408
4409
4410
4411
4412
4413
4414
4415
4416
4417
4418
4419
4420
4421
4422
4423
4424
4425
4426
4427
4428
4429
4430
4431
4432
4433
4434
4435
4436
4437
4438
4439
4440
4441
4442
4443
4444
4445
4446
4447
4448
4449
4450
4451
4452
4453
4454
4455
4456
4457
4458
4459
4460
4461
4462
4463
4464
4465
4466
4467
4468
4469
4470
4471
4472
4473
4474
4475
4476
4477
4478
4479
4480
4481
4482
4483
4484
4485
4486
4487
4488
4489
4490
4491
4492
4493
4494
4495
4496
4497
4498
4499
4500
4501
4502
4503
4504
4505
4506
4507
4508
4509
4510
4511
4512
4513
4514
4515
4516
4517
4518
4519
4520
4521
4522
4523
4524
4525
4526
4527
4528
4529
4530
4531
4532
4533
4534
4535
4536
4537
4538
4539
4540
4541
4542
4543
4544
4545
4546
4547
4548
4549
4550
4551
4552
4553
4554
4555
4556
4557
4558
4559
4560
4561
4562
4563
4564
4565
4566
4567
4568
4569
4570
4571
4572
4573
4574
4575
4576
4577
4578
4579
4580
4581
4582
4583
4584
4585
4586
4587
4588
4589
4590
4591
4592
4593
4594
4595
4596
4597
4598
4599
4600
4601
4602
4603
4604
4605
4606
4607
4608
4609
4610
4611
4612
4613
4614
4615
4616
4617
4618
4619
4620
4621
4622
4623
4624
4625
4626
4627
4628
4629
4630
4631
4632
4633
4634
4635
4636
4637
4638
4639
4640
4641
4642
4643
4644
4645
4646
4647
4648
4649
4650
4651
4652
4653
4654
4655
4656
4657
4658
4659
4660
4661
4662
4663
4664
4665
4666
4667
4668
4669
4670
4671
4672
4673
4674
4675
4676
4677
4678
4679
4680
4681
4682
4683
4684
4685
4686
4687
4688
4689
4690
4691
4692
4693
4694
4695
4696
4697
4698
4699
4700
4701
4702
4703
4704
4705
4706
4707
4708
4709
4710
4711
4712
4713
4714
4715
4716
4717
4718
4719
4720
4721
4722
4723
4724
4725
4726
4727
4728
4729
4730
4731
4732
4733
4734
4735
4736
4737
4738
4739
4740
4741
4742
4743
4744
4745
4746
4747
4748
4749
4750
4751
4752
4753
4754
4755
4756
4757
4758
4759
4760
4761
4762
4763
4764
4765
4766
4767
4768
4769
4770
4771
4772
4773
4774
4775
4776
4777
4778
4779
4780
4781
4782
4783
4784
4785
4786
4787
4788
4789
4790
4791
4792
4793
4794
4795
4796
4797
4798
4799
4800
4801
4802
4803
4804
4805
4806
4807
4808
4809
4810
4811
4812
4813
4814
4815
4816
4817
4818
4819
4820
4821
4822
4823
4824
4825
4826
4827
4828
4829
4830
4831
4832
4833
4834
4835
4836
4837
4838
4839
4840
4841
4842
4843
4844
4845
4846
4847
4848
4849
4850
4851
4852
4853
4854
4855
4856
4857
4858
4859
4860
4861
4862
4863
4864
4865
4866
4867
4868
4869
4870
4871
4872
4873
4874
4875
4876
4877
4878
4879
4880
4881
4882
4883
4884
4885
4886
4887
4888
4889
4890
4891
4892
4893
4894
4895
4896
4897
4898
4899
4900
4901
4902
4903
4904
4905
4906
4907
4908
4909
4910
4911
4912
4913
4914
4915
4916
4917
4918
4919
4920
4921
4922
4923
4924
4925
4926
4927
4928
4929
4930
4931
4932
4933
4934
4935
4936
4937
4938
4939
4940
4941
4942
4943
4944
4945
4946
4947
4948
4949
4950
4951
4952
4953
4954
4955
4956
4957
4958
4959
4960
4961
4962
4963
4964
4965
4966
4967
4968
4969
4970
4971
4972
4973
4974
4975
4976
4977
4978
4979
4980
4981
4982
4983
4984
4985
4986
4987
4988
4989
4990
4991
4992
4993
4994
4995
4996
4997
4998
4999
5000
5001
5002
5003
5004
5005
5006
5007
5008
5009
5010
5011
5012
5013
5014
5015
5016
5017
5018
5019
5020
5021
5022
5023
5024
5025
5026
5027
5028
5029
5030
5031
5032
5033
5034
5035
5036
5037
5038
5039
5040
5041
5042
5043
5044
5045
5046
5047
5048
5049
5050
5051
5052
5053
5054
5055
5056
5057
5058
5059
5060
5061
5062
5063
5064
5065
5066
5067
5068
5069
5070
5071
5072
5073
5074
5075
5076
5077
5078
5079
5080
5081
5082
5083
5084
5085
5086
5087
5088
5089
5090
5091
5092
5093
5094
5095
5096
5097
5098
5099
5100
5101
5102
5103
5104
5105
5106
5107
5108
5109
5110
5111
5112
5113
5114
5115
5116
5117
5118
5119
5120
5121
5122
5123
5124
5125
5126
5127
5128
5129
5130
5131
5132
5133
5134
5135
5136
5137
5138
5139
5140
5141
5142
5143
5144
5145
5146
5147
5148
5149
5150
5151
5152
5153
5154
5155
5156
5157
5158
5159
5160
5161
5162
5163
5164
5165
5166
5167
5168
5169
5170
5171
5172
5173
5174
5175
5176
5177
5178
5179
5180
5181
5182
5183
5184
5185
5186
5187
5188
5189
5190
5191
5192
5193
5194
5195
5196
5197
5198
5199
5200
5201
5202
5203
5204
5205
5206
5207
5208
5209
5210
5211
5212
5213
5214
5215
5216
5217
5218
5219
5220
5221
5222
5223
5224
5225
5226
5227
5228
5229
5230
5231
5232
5233
5234
5235
5236
5237
5238
5239
5240
5241
5242
5243
5244
5245
5246
5247
5248
5249
5250
5251
5252
5253
5254
5255
5256
5257
5258
5259
5260
5261
5262
5263
5264
5265
5266
5267
5268
5269
5270
5271
5272
5273
5274
5275
5276
5277
5278
5279
5280
5281
5282
5283
5284
5285
5286
5287
5288
5289
5290
5291
5292
5293
5294
5295
5296
5297
5298
5299
5300
5301
5302
5303
5304
5305
5306
5307
5308
5309
5310
5311
5312
5313
5314
5315
5316
5317
5318
5319
5320
5321
5322
5323
5324
5325
5326
5327
5328
5329
5330
5331
5332
5333
5334
5335
5336
5337
5338
5339
5340
5341
5342
5343
5344
5345
5346
5347
5348
5349
5350
5351
5352
5353
5354
5355
5356
5357
5358
5359
5360
5361
5362
5363
5364
5365
5366
5367
5368
5369
5370
5371
5372
5373
5374
5375
5376
5377
5378
5379
5380
5381
5382
5383
5384
5385
5386
5387
5388
5389
5390
5391
5392
5393
5394
5395
5396
5397
5398
5399
5400
5401
5402
5403
5404
5405
5406
5407
5408
5409
5410
5411
5412
5413
5414
5415
5416
5417
5418
5419
5420
5421
5422
5423
5424
5425
5426
5427
5428
5429
5430
5431
5432
5433
5434
5435
5436
5437
5438
5439
5440
5441
5442
5443
5444
5445
5446
5447
5448
5449
5450
5451
5452
5453
5454
5455
5456
5457
5458
5459
5460
5461
5462
5463
5464
5465
5466
5467
5468
5469
5470
5471
5472
5473
5474
5475
5476
5477
5478
5479
5480
5481
5482
5483
5484
5485
5486
5487
5488
5489
5490
5491
5492
5493
5494
5495
5496
5497
5498
5499
5500
5501
5502
5503
5504
5505
5506
5507
5508
5509
5510
5511
5512
5513
5514
5515
5516
5517
5518
5519
5520
5521
5522
5523
5524
5525
5526
5527
5528
5529
5530
5531
/* VideoMetadata.c generated by valac 0.34.4, the Vala compiler
 * generated from VideoMetadata.vala, do not modify */

/* Copyright 2016 Software Freedom Conservancy Inc.
 *
 * This software is licensed under the GNU Lesser General Public License
 * (version 2.1 or later).  See the COPYING file in this distribution.
 */

#include <glib.h>
#include <glib-object.h>
#include <gio/gio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include <stdio.h>
#include <gobject/gvaluecollector.h>


#define TYPE_MEDIA_METADATA (media_metadata_get_type ())
#define MEDIA_METADATA(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_MEDIA_METADATA, MediaMetadata))
#define MEDIA_METADATA_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_MEDIA_METADATA, MediaMetadataClass))
#define IS_MEDIA_METADATA(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_MEDIA_METADATA))
#define IS_MEDIA_METADATA_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_MEDIA_METADATA))
#define MEDIA_METADATA_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_MEDIA_METADATA, MediaMetadataClass))

typedef struct _MediaMetadata MediaMetadata;
typedef struct _MediaMetadataClass MediaMetadataClass;
typedef struct _MediaMetadataPrivate MediaMetadataPrivate;

#define TYPE_METADATA_DATE_TIME (metadata_date_time_get_type ())
#define METADATA_DATE_TIME(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_METADATA_DATE_TIME, MetadataDateTime))
#define METADATA_DATE_TIME_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_METADATA_DATE_TIME, MetadataDateTimeClass))
#define IS_METADATA_DATE_TIME(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_METADATA_DATE_TIME))
#define IS_METADATA_DATE_TIME_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_METADATA_DATE_TIME))
#define METADATA_DATE_TIME_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_METADATA_DATE_TIME, MetadataDateTimeClass))

typedef struct _MetadataDateTime MetadataDateTime;
typedef struct _MetadataDateTimeClass MetadataDateTimeClass;

#define TYPE_VIDEO_METADATA (video_metadata_get_type ())
#define VIDEO_METADATA(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_VIDEO_METADATA, VideoMetadata))
#define VIDEO_METADATA_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_VIDEO_METADATA, VideoMetadataClass))
#define IS_VIDEO_METADATA(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_VIDEO_METADATA))
#define IS_VIDEO_METADATA_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_VIDEO_METADATA))
#define VIDEO_METADATA_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_VIDEO_METADATA, VideoMetadataClass))

typedef struct _VideoMetadata VideoMetadata;
typedef struct _VideoMetadataClass VideoMetadataClass;
typedef struct _VideoMetadataPrivate VideoMetadataPrivate;
#define _metadata_date_time_unref0(var) ((var == NULL) ? NULL : (var = (metadata_date_time_unref (var), NULL)))
#define _g_free0(var) (var = (g_free (var), NULL))

#define TYPE_QUICK_TIME_METADATA_LOADER (quick_time_metadata_loader_get_type ())
#define QUICK_TIME_METADATA_LOADER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_QUICK_TIME_METADATA_LOADER, QuickTimeMetadataLoader))
#define QUICK_TIME_METADATA_LOADER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_QUICK_TIME_METADATA_LOADER, QuickTimeMetadataLoaderClass))
#define IS_QUICK_TIME_METADATA_LOADER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_QUICK_TIME_METADATA_LOADER))
#define IS_QUICK_TIME_METADATA_LOADER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_QUICK_TIME_METADATA_LOADER))
#define QUICK_TIME_METADATA_LOADER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_QUICK_TIME_METADATA_LOADER, QuickTimeMetadataLoaderClass))

typedef struct _QuickTimeMetadataLoader QuickTimeMetadataLoader;
typedef struct _QuickTimeMetadataLoaderClass QuickTimeMetadataLoaderClass;
#define _quick_time_metadata_loader_unref0(var) ((var == NULL) ? NULL : (var = (quick_time_metadata_loader_unref (var), NULL)))

#define TYPE_AVI_METADATA_LOADER (avi_metadata_loader_get_type ())
#define AVI_METADATA_LOADER(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_AVI_METADATA_LOADER, AVIMetadataLoader))
#define AVI_METADATA_LOADER_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_AVI_METADATA_LOADER, AVIMetadataLoaderClass))
#define IS_AVI_METADATA_LOADER(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_AVI_METADATA_LOADER))
#define IS_AVI_METADATA_LOADER_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_AVI_METADATA_LOADER))
#define AVI_METADATA_LOADER_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_AVI_METADATA_LOADER, AVIMetadataLoaderClass))

typedef struct _AVIMetadataLoader AVIMetadataLoader;
typedef struct _AVIMetadataLoaderClass AVIMetadataLoaderClass;
#define _avi_metadata_loader_unref0(var) ((var == NULL) ? NULL : (var = (avi_metadata_loader_unref (var), NULL)))
typedef struct _QuickTimeMetadataLoaderPrivate QuickTimeMetadataLoaderPrivate;
#define _g_object_unref0(var) ((var == NULL) ? NULL : (var = (g_object_unref (var), NULL)))

#define TYPE_QUICK_TIME_ATOM (quick_time_atom_get_type ())
#define QUICK_TIME_ATOM(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_QUICK_TIME_ATOM, QuickTimeAtom))
#define QUICK_TIME_ATOM_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_QUICK_TIME_ATOM, QuickTimeAtomClass))
#define IS_QUICK_TIME_ATOM(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_QUICK_TIME_ATOM))
#define IS_QUICK_TIME_ATOM_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_QUICK_TIME_ATOM))
#define QUICK_TIME_ATOM_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_QUICK_TIME_ATOM, QuickTimeAtomClass))

typedef struct _QuickTimeAtom QuickTimeAtom;
typedef struct _QuickTimeAtomClass QuickTimeAtomClass;
#define _g_error_free0(var) ((var == NULL) ? NULL : (var = (g_error_free (var), NULL)))
#define _quick_time_atom_unref0(var) ((var == NULL) ? NULL : (var = (quick_time_atom_unref (var), NULL)))
typedef struct _ParamSpecQuickTimeMetadataLoader ParamSpecQuickTimeMetadataLoader;
typedef struct _QuickTimeAtomPrivate QuickTimeAtomPrivate;
#define _g_string_free0(var) ((var == NULL) ? NULL : (var = (g_string_free (var, TRUE), NULL)))
typedef struct _ParamSpecQuickTimeAtom ParamSpecQuickTimeAtom;
typedef struct _AVIMetadataLoaderPrivate AVIMetadataLoaderPrivate;

#define TYPE_AVI_CHUNK (avi_chunk_get_type ())
#define AVI_CHUNK(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), TYPE_AVI_CHUNK, AVIChunk))
#define AVI_CHUNK_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), TYPE_AVI_CHUNK, AVIChunkClass))
#define IS_AVI_CHUNK(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), TYPE_AVI_CHUNK))
#define IS_AVI_CHUNK_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), TYPE_AVI_CHUNK))
#define AVI_CHUNK_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), TYPE_AVI_CHUNK, AVIChunkClass))

typedef struct _AVIChunk AVIChunk;
typedef struct _AVIChunkClass AVIChunkClass;
#define _avi_chunk_unref0(var) ((var == NULL) ? NULL : (var = (avi_chunk_unref (var), NULL)))
typedef struct _ParamSpecAVIMetadataLoader ParamSpecAVIMetadataLoader;
typedef struct _AVIChunkPrivate AVIChunkPrivate;
typedef struct _ParamSpecAVIChunk ParamSpecAVIChunk;
#define _vala_assert(expr, msg) if G_LIKELY (expr) ; else g_assertion_message_expr (G_LOG_DOMAIN, __FILE__, __LINE__, G_STRFUNC, msg);
#define _vala_return_if_fail(expr, msg) if G_LIKELY (expr) ; else { g_return_if_fail_warning (G_LOG_DOMAIN, G_STRFUNC, msg); return; }
#define _vala_return_val_if_fail(expr, msg, val) if G_LIKELY (expr) ; else { g_return_if_fail_warning (G_LOG_DOMAIN, G_STRFUNC, msg); return val; }
#define _vala_warn_if_fail(expr, msg) if G_LIKELY (expr) ; else g_warn_message (G_LOG_DOMAIN, __FILE__, __LINE__, G_STRFUNC, msg);

struct _MediaMetadata {
	GTypeInstance parent_instance;
	volatile int ref_count;
	MediaMetadataPrivate * priv;
};

struct _MediaMetadataClass {
	GTypeClass parent_class;
	void (*finalize) (MediaMetadata *self);
	void (*read_from_file) (MediaMetadata* self, GFile* file, GError** error);
	MetadataDateTime* (*get_creation_date_time) (MediaMetadata* self);
	gchar* (*get_title) (MediaMetadata* self);
	gchar* (*get_comment) (MediaMetadata* self);
};

struct _VideoMetadata {
	MediaMetadata parent_instance;
	VideoMetadataPrivate * priv;
};

struct _VideoMetadataClass {
	MediaMetadataClass parent_class;
};

struct _VideoMetadataPrivate {
	MetadataDateTime* timestamp;
	gchar* title;
	gchar* comment;
};

struct _QuickTimeMetadataLoader {
	GTypeInstance parent_instance;
	volatile int ref_count;
	QuickTimeMetadataLoaderPrivate * priv;
};

struct _QuickTimeMetadataLoaderClass {
	GTypeClass parent_class;
	void (*finalize) (QuickTimeMetadataLoader *self);
};

struct _QuickTimeMetadataLoaderPrivate {
	GFile* file;
};

struct _ParamSpecQuickTimeMetadataLoader {
	GParamSpec parent_instance;
};

struct _QuickTimeAtom {
	GTypeInstance parent_instance;
	volatile int ref_count;
	QuickTimeAtomPrivate * priv;
};

struct _QuickTimeAtomClass {
	GTypeClass parent_class;
	void (*finalize) (QuickTimeAtom *self);
};

struct _QuickTimeAtomPrivate {
	GFile* file;
	gchar* section_name;
	guint64 section_size;
	guint64 section_offset;
	GDataInputStream* input;
	QuickTimeAtom* parent;
};

struct _ParamSpecQuickTimeAtom {
	GParamSpec parent_instance;
};

struct _AVIMetadataLoader {
	GTypeInstance parent_instance;
	volatile int ref_count;
	AVIMetadataLoaderPrivate * priv;
};

struct _AVIMetadataLoaderClass {
	GTypeClass parent_class;
	void (*finalize) (AVIMetadataLoader *self);
};

struct _AVIMetadataLoaderPrivate {
	GFile* file;
};

struct _ParamSpecAVIMetadataLoader {
	GParamSpec parent_instance;
};

struct _AVIChunk {
	GTypeInstance parent_instance;
	volatile int ref_count;
	AVIChunkPrivate * priv;
};

struct _AVIChunkClass {
	GTypeClass parent_class;
	void (*finalize) (AVIChunk *self);
};

struct _AVIChunkPrivate {
	GFile* file;
	gchar* section_name;
	guint64 section_size;
	guint64 section_offset;
	GDataInputStream* input;
	AVIChunk* parent;
};

struct _ParamSpecAVIChunk {
	GParamSpec parent_instance;
};


static gpointer video_metadata_parent_class = NULL;
static gpointer quick_time_metadata_loader_parent_class = NULL;
static gpointer quick_time_atom_parent_class = NULL;
static gpointer avi_metadata_loader_parent_class = NULL;
static gpointer avi_chunk_parent_class = NULL;

gpointer media_metadata_ref (gpointer instance);
void media_metadata_unref (gpointer instance);
GParamSpec* param_spec_media_metadata (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void value_set_media_metadata (GValue* value, gpointer v_object);
void value_take_media_metadata (GValue* value, gpointer v_object);
gpointer value_get_media_metadata (const GValue* value);
GType media_metadata_get_type (void) G_GNUC_CONST;
gpointer metadata_date_time_ref (gpointer instance);
void metadata_date_time_unref (gpointer instance);
GParamSpec* param_spec_metadata_date_time (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void value_set_metadata_date_time (GValue* value, gpointer v_object);
void value_take_metadata_date_time (GValue* value, gpointer v_object);
gpointer value_get_metadata_date_time (const GValue* value);
GType metadata_date_time_get_type (void) G_GNUC_CONST;
GType video_metadata_get_type (void) G_GNUC_CONST;
#define VIDEO_METADATA_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_VIDEO_METADATA, VideoMetadataPrivate))
enum  {
	VIDEO_METADATA_DUMMY_PROPERTY
};
VideoMetadata* video_metadata_new (void);
VideoMetadata* video_metadata_construct (GType object_type);
MediaMetadata* media_metadata_construct (GType object_type);
static void video_metadata_real_read_from_file (MediaMetadata* base, GFile* file, GError** error);
gpointer quick_time_metadata_loader_ref (gpointer instance);
void quick_time_metadata_loader_unref (gpointer instance);
GParamSpec* param_spec_quick_time_metadata_loader (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void value_set_quick_time_metadata_loader (GValue* value, gpointer v_object);
void value_take_quick_time_metadata_loader (GValue* value, gpointer v_object);
gpointer value_get_quick_time_metadata_loader (const GValue* value);
GType quick_time_metadata_loader_get_type (void) G_GNUC_CONST;
QuickTimeMetadataLoader* quick_time_metadata_loader_new (GFile* file);
QuickTimeMetadataLoader* quick_time_metadata_loader_construct (GType object_type, GFile* file);
gboolean quick_time_metadata_loader_is_supported (QuickTimeMetadataLoader* self);
MetadataDateTime* quick_time_metadata_loader_get_creation_date_time (QuickTimeMetadataLoader* self);
gchar* quick_time_metadata_loader_get_title (QuickTimeMetadataLoader* self);
gpointer avi_metadata_loader_ref (gpointer instance);
void avi_metadata_loader_unref (gpointer instance);
GParamSpec* param_spec_avi_metadata_loader (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void value_set_avi_metadata_loader (GValue* value, gpointer v_object);
void value_take_avi_metadata_loader (GValue* value, gpointer v_object);
gpointer value_get_avi_metadata_loader (const GValue* value);
GType avi_metadata_loader_get_type (void) G_GNUC_CONST;
AVIMetadataLoader* avi_metadata_loader_new (GFile* file);
AVIMetadataLoader* avi_metadata_loader_construct (GType object_type, GFile* file);
gboolean avi_metadata_loader_is_supported (AVIMetadataLoader* self);
MetadataDateTime* avi_metadata_loader_get_creation_date_time (AVIMetadataLoader* self);
gchar* avi_metadata_loader_get_title (AVIMetadataLoader* self);
static MetadataDateTime* video_metadata_real_get_creation_date_time (MediaMetadata* base);
static gchar* video_metadata_real_get_title (MediaMetadata* base);
static gchar* video_metadata_real_get_comment (MediaMetadata* base);
static void video_metadata_finalize (MediaMetadata* obj);
#define QUICK_TIME_METADATA_LOADER_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_QUICK_TIME_METADATA_LOADER, QuickTimeMetadataLoaderPrivate))
enum  {
	QUICK_TIME_METADATA_LOADER_DUMMY_PROPERTY
};
#define QUICK_TIME_METADATA_LOADER_QUICKTIME_EPOCH_ADJUSTMENT ((time_t) 2082844800)
static gulong quick_time_metadata_loader_get_creation_date_time_for_quicktime (QuickTimeMetadataLoader* self);
MetadataDateTime* metadata_date_time_new (time_t timestamp);
MetadataDateTime* metadata_date_time_construct (GType object_type, time_t timestamp);
gpointer quick_time_atom_ref (gpointer instance);
void quick_time_atom_unref (gpointer instance);
GParamSpec* param_spec_quick_time_atom (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void value_set_quick_time_atom (GValue* value, gpointer v_object);
void value_take_quick_time_atom (GValue* value, gpointer v_object);
gpointer value_get_quick_time_atom (const GValue* value);
GType quick_time_atom_get_type (void) G_GNUC_CONST;
QuickTimeAtom* quick_time_atom_new (GFile* file);
QuickTimeAtom* quick_time_atom_construct (GType object_type, GFile* file);
void quick_time_atom_open_file (QuickTimeAtom* self, GError** error);
void quick_time_atom_read_atom (QuickTimeAtom* self, GError** error);
gchar* quick_time_atom_get_current_atom_name (QuickTimeAtom* self);
void quick_time_atom_next_atom (QuickTimeAtom* self, GError** error);
gboolean quick_time_atom_is_last_atom (QuickTimeAtom* self);
void quick_time_atom_close_file (QuickTimeAtom* self, GError** error);
QuickTimeAtom* quick_time_atom_get_first_child_atom (QuickTimeAtom* self);
guint64 quick_time_atom_section_size_remaining (QuickTimeAtom* self);
guint32 quick_time_atom_read_uint32 (QuickTimeAtom* self, GError** error);
static void quick_time_metadata_loader_finalize (QuickTimeMetadataLoader* obj);
#define QUICK_TIME_ATOM_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_QUICK_TIME_ATOM, QuickTimeAtomPrivate))
enum  {
	QUICK_TIME_ATOM_DUMMY_PROPERTY
};
static QuickTimeAtom* quick_time_atom_new_with_input_stream (GDataInputStream* input, QuickTimeAtom* parent);
static QuickTimeAtom* quick_time_atom_construct_with_input_stream (GType object_type, GDataInputStream* input, QuickTimeAtom* parent);
static void quick_time_atom_advance_section_offset (QuickTimeAtom* self, guint64 amount);
guchar quick_time_atom_read_byte (QuickTimeAtom* self, GError** error);
guint64 quick_time_atom_read_uint64 (QuickTimeAtom* self, GError** error);
static void quick_time_atom_skip (QuickTimeAtom* self, guint64 skip_amount, GError** error);
void skip_uint64 (GInputStream* input, guint64 skip_amount, GError** error);
static void quick_time_atom_finalize (QuickTimeAtom* obj);
#define AVI_METADATA_LOADER_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_AVI_METADATA_LOADER, AVIMetadataLoaderPrivate))
enum  {
	AVI_METADATA_LOADER_DUMMY_PROPERTY
};
#define AVI_METADATA_LOADER_NUMERICAL_DATE_LENGTH 19
#define AVI_METADATA_LOADER_NIKON_NCTG_TIMESTAMP_MARKER ((guint16) 0x13)
#define AVI_METADATA_LOADER_MAX_STRD_LENGTH 100
static gulong avi_metadata_loader_get_creation_date_time_for_avi (AVIMetadataLoader* self);
gpointer avi_chunk_ref (gpointer instance);
void avi_chunk_unref (gpointer instance);
GParamSpec* param_spec_avi_chunk (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
void value_set_avi_chunk (GValue* value, gpointer v_object);
void value_take_avi_chunk (GValue* value, gpointer v_object);
gpointer value_get_avi_chunk (const GValue* value);
GType avi_chunk_get_type (void) G_GNUC_CONST;
AVIChunk* avi_chunk_new (GFile* file);
AVIChunk* avi_chunk_construct (GType object_type, GFile* file);
void avi_chunk_open_file (AVIChunk* self, GError** error);
void avi_chunk_read_chunk (AVIChunk* self, GError** error);
gchar* avi_chunk_get_current_chunk_name (AVIChunk* self);
gchar* avi_chunk_read_name (AVIChunk* self, GError** error);
void avi_chunk_close_file (AVIChunk* self, GError** error);
static gchar* avi_metadata_loader_read_nikon_nctg_tag (AVIMetadataLoader* self, AVIChunk* chunk, GError** error);
guint64 avi_chunk_section_size_remaining (AVIChunk* self);
guint16 avi_chunk_read_uint16 (AVIChunk* self, GError** error);
void avi_chunk_skip (AVIChunk* self, guint64 skip_amount, GError** error);
guchar avi_chunk_read_byte (AVIChunk* self, GError** error);
static gchar* avi_metadata_loader_read_fuji_strd_tag (AVIMetadataLoader* self, AVIChunk* chunk, GError** error);
static gchar* avi_metadata_loader_read_section (AVIMetadataLoader* self, AVIChunk* chunk, GError** error);
gchar* avi_chunk_section_to_string (AVIChunk* self, GError** error);
AVIChunk* avi_chunk_get_first_child_chunk (AVIChunk* self);
gboolean avi_chunk_is_last_chunk (AVIChunk* self);
void avi_chunk_next_chunk (AVIChunk* self, GError** error);
static gulong avi_metadata_loader_parse_date (AVIMetadataLoader* self, const gchar* sdate);
static GDateMonth avi_metadata_loader_month_from_string (AVIMetadataLoader* self, const gchar* s);
void avi_chunk_nonsection_skip (AVIChunk* self, guint64 skip_amount, GError** error);
static void avi_metadata_loader_finalize (AVIMetadataLoader* obj);
#define AVI_CHUNK_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), TYPE_AVI_CHUNK, AVIChunkPrivate))
enum  {
	AVI_CHUNK_DUMMY_PROPERTY
};
#define AVI_CHUNK_MAX_STRING_TO_SECTION_LENGTH 1024
static AVIChunk* avi_chunk_new_with_input_stream (GDataInputStream* input, AVIChunk* parent);
static AVIChunk* avi_chunk_construct_with_input_stream (GType object_type, GDataInputStream* input, AVIChunk* parent);
static void avi_chunk_advance_section_offset (AVIChunk* self, guint64 amount);
static void avi_chunk_finalize (AVIChunk* obj);


VideoMetadata* video_metadata_construct (GType object_type) {
	VideoMetadata* self = NULL;
#line 13 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self = (VideoMetadata*) media_metadata_construct (object_type);
#line 13 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return self;
#line 381 "VideoMetadata.c"
}


VideoMetadata* video_metadata_new (void) {
#line 13 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return video_metadata_construct (TYPE_VIDEO_METADATA);
#line 388 "VideoMetadata.c"
}


static void video_metadata_real_read_from_file (MediaMetadata* base, GFile* file, GError** error) {
	VideoMetadata * self;
	QuickTimeMetadataLoader* quicktime = NULL;
	GFile* _tmp0_ = NULL;
	QuickTimeMetadataLoader* _tmp1_ = NULL;
	QuickTimeMetadataLoader* _tmp2_ = NULL;
	gboolean _tmp3_ = FALSE;
	AVIMetadataLoader* avi = NULL;
	GFile* _tmp8_ = NULL;
	AVIMetadataLoader* _tmp9_ = NULL;
	AVIMetadataLoader* _tmp10_ = NULL;
	gboolean _tmp11_ = FALSE;
	GFile* _tmp16_ = NULL;
	gchar* _tmp17_ = NULL;
	gchar* _tmp18_ = NULL;
	GError* _tmp19_ = NULL;
	GError* _tmp20_ = NULL;
	GError * _inner_error_ = NULL;
#line 19 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_VIDEO_METADATA, VideoMetadata);
#line 19 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (G_IS_FILE (file));
#line 20 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = file;
#line 20 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = quick_time_metadata_loader_new (_tmp0_);
#line 20 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	quicktime = _tmp1_;
#line 21 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp2_ = quicktime;
#line 21 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp3_ = quick_time_metadata_loader_is_supported (_tmp2_);
#line 21 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (_tmp3_) {
#line 426 "VideoMetadata.c"
		QuickTimeMetadataLoader* _tmp4_ = NULL;
		MetadataDateTime* _tmp5_ = NULL;
		QuickTimeMetadataLoader* _tmp6_ = NULL;
		gchar* _tmp7_ = NULL;
#line 22 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp4_ = quicktime;
#line 22 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp5_ = quick_time_metadata_loader_get_creation_date_time (_tmp4_);
#line 22 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_metadata_date_time_unref0 (self->priv->timestamp);
#line 22 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		self->priv->timestamp = _tmp5_;
#line 23 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp6_ = quicktime;
#line 23 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp7_ = quick_time_metadata_loader_get_title (_tmp6_);
#line 23 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_free0 (self->priv->title);
#line 23 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		self->priv->title = _tmp7_;
#line 25 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_free0 (self->priv->comment);
#line 25 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		self->priv->comment = NULL;
#line 26 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_quick_time_metadata_loader_unref0 (quicktime);
#line 26 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 455 "VideoMetadata.c"
	}
#line 28 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp8_ = file;
#line 28 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp9_ = avi_metadata_loader_new (_tmp8_);
#line 28 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	avi = _tmp9_;
#line 29 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp10_ = avi;
#line 29 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp11_ = avi_metadata_loader_is_supported (_tmp10_);
#line 29 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (_tmp11_) {
#line 469 "VideoMetadata.c"
		AVIMetadataLoader* _tmp12_ = NULL;
		MetadataDateTime* _tmp13_ = NULL;
		AVIMetadataLoader* _tmp14_ = NULL;
		gchar* _tmp15_ = NULL;
#line 30 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp12_ = avi;
#line 30 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp13_ = avi_metadata_loader_get_creation_date_time (_tmp12_);
#line 30 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_metadata_date_time_unref0 (self->priv->timestamp);
#line 30 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		self->priv->timestamp = _tmp13_;
#line 31 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp14_ = avi;
#line 31 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp15_ = avi_metadata_loader_get_title (_tmp14_);
#line 31 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_free0 (self->priv->title);
#line 31 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		self->priv->title = _tmp15_;
#line 32 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_free0 (self->priv->comment);
#line 32 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		self->priv->comment = NULL;
#line 33 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_avi_metadata_loader_unref0 (avi);
#line 33 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_quick_time_metadata_loader_unref0 (quicktime);
#line 33 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 500 "VideoMetadata.c"
	}
#line 36 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp16_ = file;
#line 36 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp17_ = g_file_get_path (_tmp16_);
#line 36 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp18_ = _tmp17_;
#line 36 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp19_ = g_error_new (G_IO_ERROR, G_IO_ERROR_NOT_SUPPORTED, "File %s is not a supported video format", _tmp18_);
#line 36 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp20_ = _tmp19_;
#line 36 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_free0 (_tmp18_);
#line 36 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_inner_error_ = _tmp20_;
#line 36 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_propagate_error (error, _inner_error_);
#line 36 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_avi_metadata_loader_unref0 (avi);
#line 36 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_quick_time_metadata_loader_unref0 (quicktime);
#line 36 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return;
#line 524 "VideoMetadata.c"
}


static gpointer _metadata_date_time_ref0 (gpointer self) {
#line 40 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return self ? metadata_date_time_ref (self) : NULL;
#line 531 "VideoMetadata.c"
}


static MetadataDateTime* video_metadata_real_get_creation_date_time (MediaMetadata* base) {
	VideoMetadata * self;
	MetadataDateTime* result = NULL;
	MetadataDateTime* _tmp0_ = NULL;
	MetadataDateTime* _tmp1_ = NULL;
#line 39 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_VIDEO_METADATA, VideoMetadata);
#line 40 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = self->priv->timestamp;
#line 40 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = _metadata_date_time_ref0 (_tmp0_);
#line 40 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = _tmp1_;
#line 40 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 550 "VideoMetadata.c"
}


static gchar* video_metadata_real_get_title (MediaMetadata* base) {
	VideoMetadata * self;
	gchar* result = NULL;
	const gchar* _tmp0_ = NULL;
	gchar* _tmp1_ = NULL;
#line 43 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_VIDEO_METADATA, VideoMetadata);
#line 44 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = self->priv->title;
#line 44 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = g_strdup (_tmp0_);
#line 44 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = _tmp1_;
#line 44 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 569 "VideoMetadata.c"
}


static gchar* video_metadata_real_get_comment (MediaMetadata* base) {
	VideoMetadata * self;
	gchar* result = NULL;
	const gchar* _tmp0_ = NULL;
	gchar* _tmp1_ = NULL;
#line 47 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self = G_TYPE_CHECK_INSTANCE_CAST (base, TYPE_VIDEO_METADATA, VideoMetadata);
#line 48 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = self->priv->comment;
#line 48 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = g_strdup (_tmp0_);
#line 48 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = _tmp1_;
#line 48 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 588 "VideoMetadata.c"
}


static void video_metadata_class_init (VideoMetadataClass * klass) {
#line 7 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	video_metadata_parent_class = g_type_class_peek_parent (klass);
#line 7 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	((MediaMetadataClass *) klass)->finalize = video_metadata_finalize;
#line 7 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_type_class_add_private (klass, sizeof (VideoMetadataPrivate));
#line 7 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	((MediaMetadataClass *) klass)->read_from_file = video_metadata_real_read_from_file;
#line 7 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	((MediaMetadataClass *) klass)->get_creation_date_time = video_metadata_real_get_creation_date_time;
#line 7 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	((MediaMetadataClass *) klass)->get_title = video_metadata_real_get_title;
#line 7 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	((MediaMetadataClass *) klass)->get_comment = video_metadata_real_get_comment;
#line 607 "VideoMetadata.c"
}


static void video_metadata_instance_init (VideoMetadata * self) {
#line 7 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv = VIDEO_METADATA_GET_PRIVATE (self);
#line 9 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->timestamp = NULL;
#line 10 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->title = NULL;
#line 11 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->comment = NULL;
#line 620 "VideoMetadata.c"
}


static void video_metadata_finalize (MediaMetadata* obj) {
	VideoMetadata * self;
#line 7 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_VIDEO_METADATA, VideoMetadata);
#line 9 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_metadata_date_time_unref0 (self->priv->timestamp);
#line 10 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_free0 (self->priv->title);
#line 11 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_free0 (self->priv->comment);
#line 7 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	MEDIA_METADATA_CLASS (video_metadata_parent_class)->finalize (obj);
#line 636 "VideoMetadata.c"
}


GType video_metadata_get_type (void) {
	static volatile gsize video_metadata_type_id__volatile = 0;
	if (g_once_init_enter (&video_metadata_type_id__volatile)) {
		static const GTypeInfo g_define_type_info = { sizeof (VideoMetadataClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) video_metadata_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (VideoMetadata), 0, (GInstanceInitFunc) video_metadata_instance_init, NULL };
		GType video_metadata_type_id;
		video_metadata_type_id = g_type_register_static (TYPE_MEDIA_METADATA, "VideoMetadata", &g_define_type_info, 0);
		g_once_init_leave (&video_metadata_type_id__volatile, video_metadata_type_id);
	}
	return video_metadata_type_id__volatile;
}


static gpointer _g_object_ref0 (gpointer self) {
#line 62 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return self ? g_object_ref (self) : NULL;
#line 655 "VideoMetadata.c"
}


QuickTimeMetadataLoader* quick_time_metadata_loader_construct (GType object_type, GFile* file) {
	QuickTimeMetadataLoader* self = NULL;
	GFile* _tmp0_ = NULL;
	GFile* _tmp1_ = NULL;
#line 61 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (G_IS_FILE (file), NULL);
#line 61 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self = (QuickTimeMetadataLoader*) g_type_create_instance (object_type);
#line 62 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = file;
#line 62 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = _g_object_ref0 (_tmp0_);
#line 62 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_object_unref0 (self->priv->file);
#line 62 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->file = _tmp1_;
#line 61 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return self;
#line 677 "VideoMetadata.c"
}


QuickTimeMetadataLoader* quick_time_metadata_loader_new (GFile* file) {
#line 61 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return quick_time_metadata_loader_construct (TYPE_QUICK_TIME_METADATA_LOADER, file);
#line 684 "VideoMetadata.c"
}


MetadataDateTime* quick_time_metadata_loader_get_creation_date_time (QuickTimeMetadataLoader* self) {
	MetadataDateTime* result = NULL;
	gulong _tmp0_ = 0UL;
	MetadataDateTime* _tmp1_ = NULL;
#line 65 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_QUICK_TIME_METADATA_LOADER (self), NULL);
#line 66 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = quick_time_metadata_loader_get_creation_date_time_for_quicktime (self);
#line 66 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = metadata_date_time_new ((time_t) _tmp0_);
#line 66 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = _tmp1_;
#line 66 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 702 "VideoMetadata.c"
}


gchar* quick_time_metadata_loader_get_title (QuickTimeMetadataLoader* self) {
	gchar* result = NULL;
#line 69 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_QUICK_TIME_METADATA_LOADER (self), NULL);
#line 71 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = NULL;
#line 71 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 714 "VideoMetadata.c"
}


gboolean quick_time_metadata_loader_is_supported (QuickTimeMetadataLoader* self) {
	gboolean result = FALSE;
	QuickTimeAtom* test = NULL;
	GFile* _tmp0_ = NULL;
	QuickTimeAtom* _tmp1_ = NULL;
	gboolean ret = FALSE;
	GError * _inner_error_ = NULL;
#line 75 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_QUICK_TIME_METADATA_LOADER (self), FALSE);
#line 76 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = self->priv->file;
#line 76 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = quick_time_atom_new (_tmp0_);
#line 76 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	test = _tmp1_;
#line 78 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	ret = FALSE;
#line 735 "VideoMetadata.c"
	{
		QuickTimeAtom* _tmp2_ = NULL;
		QuickTimeAtom* _tmp3_ = NULL;
		QuickTimeAtom* _tmp4_ = NULL;
		gchar* _tmp5_ = NULL;
		gchar* _tmp6_ = NULL;
		gboolean _tmp7_ = FALSE;
#line 80 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp2_ = test;
#line 80 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		quick_time_atom_open_file (_tmp2_, &_inner_error_);
#line 80 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 749 "VideoMetadata.c"
			goto __catch573_g_error;
		}
#line 81 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp3_ = test;
#line 81 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		quick_time_atom_read_atom (_tmp3_, &_inner_error_);
#line 81 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 758 "VideoMetadata.c"
			goto __catch573_g_error;
		}
#line 84 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp4_ = test;
#line 84 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp5_ = quick_time_atom_get_current_atom_name (_tmp4_);
#line 84 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp6_ = _tmp5_;
#line 84 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp7_ = g_strcmp0 ("ftyp", _tmp6_) == 0;
#line 84 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_free0 (_tmp6_);
#line 84 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (_tmp7_) {
#line 85 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			ret = TRUE;
#line 775 "VideoMetadata.c"
		} else {
#line 90 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			while (TRUE) {
#line 779 "VideoMetadata.c"
				QuickTimeAtom* _tmp8_ = NULL;
				gchar* _tmp9_ = NULL;
				gchar* _tmp10_ = NULL;
				gboolean _tmp11_ = FALSE;
				QuickTimeAtom* _tmp12_ = NULL;
				QuickTimeAtom* _tmp13_ = NULL;
				QuickTimeAtom* _tmp14_ = NULL;
				gboolean _tmp15_ = FALSE;
#line 91 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp8_ = test;
#line 91 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp9_ = quick_time_atom_get_current_atom_name (_tmp8_);
#line 91 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp10_ = _tmp9_;
#line 91 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp11_ = g_strcmp0 ("moov", _tmp10_) == 0;
#line 91 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_g_free0 (_tmp10_);
#line 91 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				if (_tmp11_) {
#line 92 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					ret = TRUE;
#line 93 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					break;
#line 804 "VideoMetadata.c"
				}
#line 95 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp12_ = test;
#line 95 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				quick_time_atom_next_atom (_tmp12_, &_inner_error_);
#line 95 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 812 "VideoMetadata.c"
					goto __catch573_g_error;
				}
#line 96 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp13_ = test;
#line 96 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				quick_time_atom_read_atom (_tmp13_, &_inner_error_);
#line 96 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 821 "VideoMetadata.c"
					goto __catch573_g_error;
				}
#line 97 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp14_ = test;
#line 97 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp15_ = quick_time_atom_is_last_atom (_tmp14_);
#line 97 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				if (_tmp15_) {
#line 98 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					break;
#line 832 "VideoMetadata.c"
				}
			}
		}
	}
	goto __finally573;
	__catch573_g_error:
	{
		GError* e = NULL;
		GFile* _tmp16_ = NULL;
		gchar* _tmp17_ = NULL;
		gchar* _tmp18_ = NULL;
		GError* _tmp19_ = NULL;
		const gchar* _tmp20_ = NULL;
#line 79 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		e = _inner_error_;
#line 79 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_inner_error_ = NULL;
#line 103 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp16_ = self->priv->file;
#line 103 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp17_ = g_file_get_path (_tmp16_);
#line 103 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp18_ = _tmp17_;
#line 103 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp19_ = e;
#line 103 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp20_ = _tmp19_->message;
#line 103 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_debug ("VideoMetadata.vala:103: Error while testing for QuickTime file for %s:" \
" %s", _tmp18_, _tmp20_);
#line 103 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_free0 (_tmp18_);
#line 79 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_error_free0 (e);
#line 866 "VideoMetadata.c"
	}
	__finally573:
#line 79 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 79 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_quick_time_atom_unref0 (test);
#line 79 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 79 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_clear_error (&_inner_error_);
#line 79 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return FALSE;
#line 879 "VideoMetadata.c"
	}
	{
		QuickTimeAtom* _tmp21_ = NULL;
#line 107 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp21_ = test;
#line 107 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		quick_time_atom_close_file (_tmp21_, &_inner_error_);
#line 107 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 889 "VideoMetadata.c"
			goto __catch574_g_error;
		}
	}
	goto __finally574;
	__catch574_g_error:
	{
		GError* e = NULL;
		GError* _tmp22_ = NULL;
		const gchar* _tmp23_ = NULL;
#line 106 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		e = _inner_error_;
#line 106 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_inner_error_ = NULL;
#line 109 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp22_ = e;
#line 109 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp23_ = _tmp22_->message;
#line 109 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_debug ("VideoMetadata.vala:109: Error while closing Quicktime file: %s", _tmp23_);
#line 106 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_error_free0 (e);
#line 911 "VideoMetadata.c"
	}
	__finally574:
#line 106 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 106 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_quick_time_atom_unref0 (test);
#line 106 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 106 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_clear_error (&_inner_error_);
#line 106 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return FALSE;
#line 924 "VideoMetadata.c"
	}
#line 111 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = ret;
#line 111 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_quick_time_atom_unref0 (test);
#line 111 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 932 "VideoMetadata.c"
}


static gulong quick_time_metadata_loader_get_creation_date_time_for_quicktime (QuickTimeMetadataLoader* self) {
	gulong result = 0UL;
	QuickTimeAtom* test = NULL;
	GFile* _tmp0_ = NULL;
	QuickTimeAtom* _tmp1_ = NULL;
	time_t timestamp = 0;
	time_t _tmp35_ = 0;
	time_t _tmp37_ = 0;
	GError * _inner_error_ = NULL;
#line 114 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_QUICK_TIME_METADATA_LOADER (self), 0UL);
#line 115 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = self->priv->file;
#line 115 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = quick_time_atom_new (_tmp0_);
#line 115 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	test = _tmp1_;
#line 116 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	timestamp = (time_t) 0;
#line 955 "VideoMetadata.c"
	{
		QuickTimeAtom* _tmp2_ = NULL;
		gboolean done = FALSE;
#line 119 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp2_ = test;
#line 119 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		quick_time_atom_open_file (_tmp2_, &_inner_error_);
#line 119 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 965 "VideoMetadata.c"
			goto __catch575_g_error;
		}
#line 120 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		done = FALSE;
#line 121 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		while (TRUE) {
#line 972 "VideoMetadata.c"
			gboolean _tmp3_ = FALSE;
			QuickTimeAtom* _tmp4_ = NULL;
			QuickTimeAtom* _tmp5_ = NULL;
			gboolean _tmp6_ = FALSE;
			QuickTimeAtom* _tmp7_ = NULL;
			gchar* _tmp8_ = NULL;
			gchar* _tmp9_ = NULL;
			gboolean _tmp10_ = FALSE;
			QuickTimeAtom* _tmp29_ = NULL;
#line 121 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp3_ = done;
#line 121 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			if (!(!_tmp3_)) {
#line 121 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				break;
#line 988 "VideoMetadata.c"
			}
#line 123 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp4_ = test;
#line 123 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			quick_time_atom_read_atom (_tmp4_, &_inner_error_);
#line 123 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 996 "VideoMetadata.c"
				goto __catch575_g_error;
			}
#line 124 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp5_ = test;
#line 124 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp6_ = quick_time_atom_is_last_atom (_tmp5_);
#line 124 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			if (_tmp6_) {
#line 124 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				break;
#line 1007 "VideoMetadata.c"
			}
#line 125 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp7_ = test;
#line 125 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp8_ = quick_time_atom_get_current_atom_name (_tmp7_);
#line 125 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp9_ = _tmp8_;
#line 125 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp10_ = g_strcmp0 ("moov", _tmp9_) == 0;
#line 125 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_g_free0 (_tmp9_);
#line 125 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			if (_tmp10_) {
#line 1021 "VideoMetadata.c"
				QuickTimeAtom* child = NULL;
				QuickTimeAtom* _tmp11_ = NULL;
				QuickTimeAtom* _tmp12_ = NULL;
#line 126 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp11_ = test;
#line 126 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp12_ = quick_time_atom_get_first_child_atom (_tmp11_);
#line 126 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				child = _tmp12_;
#line 127 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				while (TRUE) {
#line 1033 "VideoMetadata.c"
					gboolean _tmp13_ = FALSE;
					QuickTimeAtom* _tmp14_ = NULL;
					gboolean _tmp15_ = FALSE;
					QuickTimeAtom* _tmp16_ = NULL;
					gboolean _tmp17_ = FALSE;
					QuickTimeAtom* _tmp20_ = NULL;
					gchar* _tmp21_ = NULL;
					gchar* _tmp22_ = NULL;
					gboolean _tmp23_ = FALSE;
					QuickTimeAtom* _tmp28_ = NULL;
#line 127 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp13_ = done;
#line 127 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					if (!(!_tmp13_)) {
#line 127 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						break;
#line 1050 "VideoMetadata.c"
					}
#line 129 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp14_ = child;
#line 129 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					quick_time_atom_read_atom (_tmp14_, &_inner_error_);
#line 129 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 129 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						_quick_time_atom_unref0 (child);
#line 1060 "VideoMetadata.c"
						goto __catch575_g_error;
					}
#line 130 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp16_ = child;
#line 130 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp17_ = quick_time_atom_is_last_atom (_tmp16_);
#line 130 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					if (_tmp17_) {
#line 130 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						_tmp15_ = TRUE;
#line 1071 "VideoMetadata.c"
					} else {
						QuickTimeAtom* _tmp18_ = NULL;
						guint64 _tmp19_ = 0ULL;
#line 130 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						_tmp18_ = child;
#line 130 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						_tmp19_ = quick_time_atom_section_size_remaining (_tmp18_);
#line 130 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						_tmp15_ = ((guint64) 0) == _tmp19_;
#line 1081 "VideoMetadata.c"
					}
#line 130 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					if (_tmp15_) {
#line 131 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						done = TRUE;
#line 132 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						break;
#line 1089 "VideoMetadata.c"
					}
#line 135 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp20_ = child;
#line 135 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp21_ = quick_time_atom_get_current_atom_name (_tmp20_);
#line 135 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp22_ = _tmp21_;
#line 135 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp23_ = g_strcmp0 ("mvhd", _tmp22_) == 0;
#line 135 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_g_free0 (_tmp22_);
#line 135 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					if (_tmp23_) {
#line 1103 "VideoMetadata.c"
						QuickTimeAtom* _tmp24_ = NULL;
						guint32 _tmp25_ = 0U;
						QuickTimeAtom* _tmp26_ = NULL;
						guint32 _tmp27_ = 0U;
#line 137 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						_tmp24_ = child;
#line 137 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						quick_time_atom_read_uint32 (_tmp24_, &_inner_error_);
#line 137 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 137 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
							_quick_time_atom_unref0 (child);
#line 1116 "VideoMetadata.c"
							goto __catch575_g_error;
						}
#line 139 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						_tmp26_ = child;
#line 139 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						_tmp27_ = quick_time_atom_read_uint32 (_tmp26_, &_inner_error_);
#line 139 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						_tmp25_ = _tmp27_;
#line 139 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 139 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
							_quick_time_atom_unref0 (child);
#line 1129 "VideoMetadata.c"
							goto __catch575_g_error;
						}
#line 139 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						timestamp = _tmp25_ - QUICK_TIME_METADATA_LOADER_QUICKTIME_EPOCH_ADJUSTMENT;
#line 140 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						done = TRUE;
#line 141 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						break;
#line 1138 "VideoMetadata.c"
					}
#line 143 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp28_ = child;
#line 143 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					quick_time_atom_next_atom (_tmp28_, &_inner_error_);
#line 143 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 143 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						_quick_time_atom_unref0 (child);
#line 1148 "VideoMetadata.c"
						goto __catch575_g_error;
					}
				}
#line 125 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_quick_time_atom_unref0 (child);
#line 1154 "VideoMetadata.c"
			}
#line 146 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp29_ = test;
#line 146 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			quick_time_atom_next_atom (_tmp29_, &_inner_error_);
#line 146 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 1162 "VideoMetadata.c"
				goto __catch575_g_error;
			}
		}
	}
	goto __finally575;
	__catch575_g_error:
	{
		GError* e = NULL;
		GError* _tmp30_ = NULL;
		const gchar* _tmp31_ = NULL;
#line 118 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		e = _inner_error_;
#line 118 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_inner_error_ = NULL;
#line 149 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp30_ = e;
#line 149 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp31_ = _tmp30_->message;
#line 149 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_debug ("VideoMetadata.vala:149: Error while testing for QuickTime file: %s", _tmp31_);
#line 118 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_error_free0 (e);
#line 1185 "VideoMetadata.c"
	}
	__finally575:
#line 118 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 118 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_quick_time_atom_unref0 (test);
#line 118 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 118 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_clear_error (&_inner_error_);
#line 118 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return 0UL;
#line 1198 "VideoMetadata.c"
	}
	{
		QuickTimeAtom* _tmp32_ = NULL;
#line 153 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp32_ = test;
#line 153 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		quick_time_atom_close_file (_tmp32_, &_inner_error_);
#line 153 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 1208 "VideoMetadata.c"
			goto __catch576_g_error;
		}
	}
	goto __finally576;
	__catch576_g_error:
	{
		GError* e = NULL;
		GError* _tmp33_ = NULL;
		const gchar* _tmp34_ = NULL;
#line 152 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		e = _inner_error_;
#line 152 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_inner_error_ = NULL;
#line 155 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp33_ = e;
#line 155 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp34_ = _tmp33_->message;
#line 155 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_debug ("VideoMetadata.vala:155: Error while closing Quicktime file: %s", _tmp34_);
#line 152 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_error_free0 (e);
#line 1230 "VideoMetadata.c"
	}
	__finally576:
#line 152 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 152 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_quick_time_atom_unref0 (test);
#line 152 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 152 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_clear_error (&_inner_error_);
#line 152 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return 0UL;
#line 1243 "VideoMetadata.c"
	}
#line 166 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp35_ = timestamp;
#line 166 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (_tmp35_ < ((time_t) 0)) {
#line 1249 "VideoMetadata.c"
		time_t _tmp36_ = 0;
#line 167 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp36_ = timestamp;
#line 167 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		timestamp = _tmp36_ + QUICK_TIME_METADATA_LOADER_QUICKTIME_EPOCH_ADJUSTMENT;
#line 1255 "VideoMetadata.c"
	}
#line 169 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp37_ = timestamp;
#line 169 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = (gulong) _tmp37_;
#line 169 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_quick_time_atom_unref0 (test);
#line 169 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 1265 "VideoMetadata.c"
}


static void value_quick_time_metadata_loader_init (GValue* value) {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	value->data[0].v_pointer = NULL;
#line 1272 "VideoMetadata.c"
}


static void value_quick_time_metadata_loader_free_value (GValue* value) {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (value->data[0].v_pointer) {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		quick_time_metadata_loader_unref (value->data[0].v_pointer);
#line 1281 "VideoMetadata.c"
	}
}


static void value_quick_time_metadata_loader_copy_value (const GValue* src_value, GValue* dest_value) {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (src_value->data[0].v_pointer) {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		dest_value->data[0].v_pointer = quick_time_metadata_loader_ref (src_value->data[0].v_pointer);
#line 1291 "VideoMetadata.c"
	} else {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		dest_value->data[0].v_pointer = NULL;
#line 1295 "VideoMetadata.c"
	}
}


static gpointer value_quick_time_metadata_loader_peek_pointer (const GValue* value) {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return value->data[0].v_pointer;
#line 1303 "VideoMetadata.c"
}


static gchar* value_quick_time_metadata_loader_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (collect_values[0].v_pointer) {
#line 1310 "VideoMetadata.c"
		QuickTimeMetadataLoader* object;
		object = collect_values[0].v_pointer;
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (object->parent_instance.g_class == NULL) {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
#line 1317 "VideoMetadata.c"
		} else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
#line 1321 "VideoMetadata.c"
		}
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = quick_time_metadata_loader_ref (object);
#line 1325 "VideoMetadata.c"
	} else {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = NULL;
#line 1329 "VideoMetadata.c"
	}
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return NULL;
#line 1333 "VideoMetadata.c"
}


static gchar* value_quick_time_metadata_loader_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
	QuickTimeMetadataLoader** object_p;
	object_p = collect_values[0].v_pointer;
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (!object_p) {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value));
#line 1344 "VideoMetadata.c"
	}
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (!value->data[0].v_pointer) {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		*object_p = NULL;
#line 1350 "VideoMetadata.c"
	} else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		*object_p = value->data[0].v_pointer;
#line 1354 "VideoMetadata.c"
	} else {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		*object_p = quick_time_metadata_loader_ref (value->data[0].v_pointer);
#line 1358 "VideoMetadata.c"
	}
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return NULL;
#line 1362 "VideoMetadata.c"
}


GParamSpec* param_spec_quick_time_metadata_loader (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) {
	ParamSpecQuickTimeMetadataLoader* spec;
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (g_type_is_a (object_type, TYPE_QUICK_TIME_METADATA_LOADER), NULL);
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags);
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	G_PARAM_SPEC (spec)->value_type = object_type;
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return G_PARAM_SPEC (spec);
#line 1376 "VideoMetadata.c"
}


gpointer value_get_quick_time_metadata_loader (const GValue* value) {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_QUICK_TIME_METADATA_LOADER), NULL);
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return value->data[0].v_pointer;
#line 1385 "VideoMetadata.c"
}


void value_set_quick_time_metadata_loader (GValue* value, gpointer v_object) {
	QuickTimeMetadataLoader* old;
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_QUICK_TIME_METADATA_LOADER));
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	old = value->data[0].v_pointer;
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (v_object) {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_QUICK_TIME_METADATA_LOADER));
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value)));
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = v_object;
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		quick_time_metadata_loader_ref (value->data[0].v_pointer);
#line 1405 "VideoMetadata.c"
	} else {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = NULL;
#line 1409 "VideoMetadata.c"
	}
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (old) {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		quick_time_metadata_loader_unref (old);
#line 1415 "VideoMetadata.c"
	}
}


void value_take_quick_time_metadata_loader (GValue* value, gpointer v_object) {
	QuickTimeMetadataLoader* old;
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_QUICK_TIME_METADATA_LOADER));
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	old = value->data[0].v_pointer;
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (v_object) {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_QUICK_TIME_METADATA_LOADER));
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value)));
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = v_object;
#line 1434 "VideoMetadata.c"
	} else {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = NULL;
#line 1438 "VideoMetadata.c"
	}
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (old) {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		quick_time_metadata_loader_unref (old);
#line 1444 "VideoMetadata.c"
	}
}


static void quick_time_metadata_loader_class_init (QuickTimeMetadataLoaderClass * klass) {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	quick_time_metadata_loader_parent_class = g_type_class_peek_parent (klass);
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	((QuickTimeMetadataLoaderClass *) klass)->finalize = quick_time_metadata_loader_finalize;
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_type_class_add_private (klass, sizeof (QuickTimeMetadataLoaderPrivate));
#line 1456 "VideoMetadata.c"
}


static void quick_time_metadata_loader_instance_init (QuickTimeMetadataLoader * self) {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv = QUICK_TIME_METADATA_LOADER_GET_PRIVATE (self);
#line 59 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->file = NULL;
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->ref_count = 1;
#line 1467 "VideoMetadata.c"
}


static void quick_time_metadata_loader_finalize (QuickTimeMetadataLoader* obj) {
	QuickTimeMetadataLoader * self;
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_QUICK_TIME_METADATA_LOADER, QuickTimeMetadataLoader);
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_signal_handlers_destroy (self);
#line 59 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_object_unref0 (self->priv->file);
#line 1479 "VideoMetadata.c"
}


GType quick_time_metadata_loader_get_type (void) {
	static volatile gsize quick_time_metadata_loader_type_id__volatile = 0;
	if (g_once_init_enter (&quick_time_metadata_loader_type_id__volatile)) {
		static const GTypeValueTable g_define_type_value_table = { value_quick_time_metadata_loader_init, value_quick_time_metadata_loader_free_value, value_quick_time_metadata_loader_copy_value, value_quick_time_metadata_loader_peek_pointer, "p", value_quick_time_metadata_loader_collect_value, "p", value_quick_time_metadata_loader_lcopy_value };
		static const GTypeInfo g_define_type_info = { sizeof (QuickTimeMetadataLoaderClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) quick_time_metadata_loader_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (QuickTimeMetadataLoader), 0, (GInstanceInitFunc) quick_time_metadata_loader_instance_init, &g_define_type_value_table };
		static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) };
		GType quick_time_metadata_loader_type_id;
		quick_time_metadata_loader_type_id = g_type_register_fundamental (g_type_fundamental_next (), "QuickTimeMetadataLoader", &g_define_type_info, &g_define_type_fundamental_info, 0);
		g_once_init_leave (&quick_time_metadata_loader_type_id__volatile, quick_time_metadata_loader_type_id);
	}
	return quick_time_metadata_loader_type_id__volatile;
}


gpointer quick_time_metadata_loader_ref (gpointer instance) {
	QuickTimeMetadataLoader* self;
	self = instance;
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_atomic_int_inc (&self->ref_count);
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return instance;
#line 1504 "VideoMetadata.c"
}


void quick_time_metadata_loader_unref (gpointer instance) {
	QuickTimeMetadataLoader* self;
	self = instance;
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (g_atomic_int_dec_and_test (&self->ref_count)) {
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		QUICK_TIME_METADATA_LOADER_GET_CLASS (self)->finalize (self);
#line 53 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_type_free_instance ((GTypeInstance *) self);
#line 1517 "VideoMetadata.c"
	}
}


QuickTimeAtom* quick_time_atom_construct (GType object_type, GFile* file) {
	QuickTimeAtom* self = NULL;
	GFile* _tmp0_ = NULL;
	GFile* _tmp1_ = NULL;
#line 181 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (G_IS_FILE (file), NULL);
#line 181 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self = (QuickTimeAtom*) g_type_create_instance (object_type);
#line 182 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = file;
#line 182 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = _g_object_ref0 (_tmp0_);
#line 182 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_object_unref0 (self->priv->file);
#line 182 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->file = _tmp1_;
#line 181 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return self;
#line 1540 "VideoMetadata.c"
}


QuickTimeAtom* quick_time_atom_new (GFile* file) {
#line 181 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return quick_time_atom_construct (TYPE_QUICK_TIME_ATOM, file);
#line 1547 "VideoMetadata.c"
}


static gpointer _quick_time_atom_ref0 (gpointer self) {
#line 187 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return self ? quick_time_atom_ref (self) : NULL;
#line 1554 "VideoMetadata.c"
}


static QuickTimeAtom* quick_time_atom_construct_with_input_stream (GType object_type, GDataInputStream* input, QuickTimeAtom* parent) {
	QuickTimeAtom* self = NULL;
	GDataInputStream* _tmp0_ = NULL;
	GDataInputStream* _tmp1_ = NULL;
	QuickTimeAtom* _tmp2_ = NULL;
	QuickTimeAtom* _tmp3_ = NULL;
#line 185 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (G_IS_DATA_INPUT_STREAM (input), NULL);
#line 185 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_QUICK_TIME_ATOM (parent), NULL);
#line 185 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self = (QuickTimeAtom*) g_type_create_instance (object_type);
#line 186 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = input;
#line 186 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = _g_object_ref0 (_tmp0_);
#line 186 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_object_unref0 (self->priv->input);
#line 186 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->input = _tmp1_;
#line 187 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp2_ = parent;
#line 187 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp3_ = _quick_time_atom_ref0 (_tmp2_);
#line 187 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_quick_time_atom_unref0 (self->priv->parent);
#line 187 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->parent = _tmp3_;
#line 185 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return self;
#line 1588 "VideoMetadata.c"
}


static QuickTimeAtom* quick_time_atom_new_with_input_stream (GDataInputStream* input, QuickTimeAtom* parent) {
#line 185 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return quick_time_atom_construct_with_input_stream (TYPE_QUICK_TIME_ATOM, input, parent);
#line 1595 "VideoMetadata.c"
}


void quick_time_atom_open_file (QuickTimeAtom* self, GError** error) {
	GFileInputStream* _tmp0_ = NULL;
	GFile* _tmp1_ = NULL;
	GFileInputStream* _tmp2_ = NULL;
	GDataInputStream* _tmp3_ = NULL;
	GDataInputStream* _tmp4_ = NULL;
	gchar* _tmp5_ = NULL;
	GError * _inner_error_ = NULL;
#line 190 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (IS_QUICK_TIME_ATOM (self));
#line 191 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	quick_time_atom_close_file (self, &_inner_error_);
#line 191 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 191 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 191 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 1617 "VideoMetadata.c"
	}
#line 192 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = self->priv->file;
#line 192 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp2_ = g_file_read (_tmp1_, NULL, &_inner_error_);
#line 192 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = _tmp2_;
#line 192 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 192 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 192 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 1631 "VideoMetadata.c"
	}
#line 192 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp3_ = g_data_input_stream_new (G_TYPE_CHECK_INSTANCE_CAST (_tmp0_, g_input_stream_get_type (), GInputStream));
#line 192 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_object_unref0 (self->priv->input);
#line 192 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->input = _tmp3_;
#line 193 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp4_ = self->priv->input;
#line 193 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_data_input_stream_set_byte_order (_tmp4_, G_DATA_STREAM_BYTE_ORDER_BIG_ENDIAN);
#line 194 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_size = (guint64) 0;
#line 195 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_offset = (guint64) 0;
#line 196 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp5_ = g_strdup ("");
#line 196 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_free0 (self->priv->section_name);
#line 196 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_name = _tmp5_;
#line 190 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_object_unref0 (_tmp0_);
#line 1655 "VideoMetadata.c"
}


void quick_time_atom_close_file (QuickTimeAtom* self, GError** error) {
	GDataInputStream* _tmp0_ = NULL;
	GError * _inner_error_ = NULL;
#line 199 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (IS_QUICK_TIME_ATOM (self));
#line 200 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = self->priv->input;
#line 200 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (NULL != _tmp0_) {
#line 1668 "VideoMetadata.c"
		GDataInputStream* _tmp1_ = NULL;
#line 201 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp1_ = self->priv->input;
#line 201 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_input_stream_close (G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, g_input_stream_get_type (), GInputStream), NULL, &_inner_error_);
#line 201 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 201 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			g_propagate_error (error, _inner_error_);
#line 201 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return;
#line 1680 "VideoMetadata.c"
		}
#line 202 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_object_unref0 (self->priv->input);
#line 202 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		self->priv->input = NULL;
#line 1686 "VideoMetadata.c"
	}
}


static void quick_time_atom_advance_section_offset (QuickTimeAtom* self, guint64 amount) {
	guint64 _tmp0_ = 0ULL;
	guint64 _tmp1_ = 0ULL;
	QuickTimeAtom* _tmp2_ = NULL;
#line 206 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (IS_QUICK_TIME_ATOM (self));
#line 207 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = self->priv->section_offset;
#line 207 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = amount;
#line 207 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_offset = _tmp0_ + _tmp1_;
#line 208 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp2_ = self->priv->parent;
#line 208 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (NULL != _tmp2_) {
#line 1707 "VideoMetadata.c"
		QuickTimeAtom* _tmp3_ = NULL;
		guint64 _tmp4_ = 0ULL;
#line 209 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp3_ = self->priv->parent;
#line 209 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp4_ = amount;
#line 209 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		quick_time_atom_advance_section_offset (_tmp3_, _tmp4_);
#line 1716 "VideoMetadata.c"
	}
}


QuickTimeAtom* quick_time_atom_get_first_child_atom (QuickTimeAtom* self) {
	QuickTimeAtom* result = NULL;
	GDataInputStream* _tmp0_ = NULL;
	QuickTimeAtom* _tmp1_ = NULL;
#line 213 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_QUICK_TIME_ATOM (self), NULL);
#line 219 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = self->priv->input;
#line 219 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = quick_time_atom_new_with_input_stream (_tmp0_, self);
#line 219 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = _tmp1_;
#line 219 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 1735 "VideoMetadata.c"
}


guchar quick_time_atom_read_byte (QuickTimeAtom* self, GError** error) {
	guchar result = '\0';
	guint8 _tmp0_ = 0U;
	GDataInputStream* _tmp1_ = NULL;
	guint8 _tmp2_ = 0U;
	GError * _inner_error_ = NULL;
#line 222 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_QUICK_TIME_ATOM (self), '\0');
#line 223 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	quick_time_atom_advance_section_offset (self, (guint64) 1);
#line 224 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = self->priv->input;
#line 224 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp2_ = g_data_input_stream_read_byte (_tmp1_, NULL, &_inner_error_);
#line 224 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = _tmp2_;
#line 224 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 224 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 224 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return '\0';
#line 1761 "VideoMetadata.c"
	}
#line 224 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = (guchar) _tmp0_;
#line 224 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 1767 "VideoMetadata.c"
}


guint32 quick_time_atom_read_uint32 (QuickTimeAtom* self, GError** error) {
	guint32 result = 0U;
	guint32 _tmp0_ = 0U;
	GDataInputStream* _tmp1_ = NULL;
	guint32 _tmp2_ = 0U;
	GError * _inner_error_ = NULL;
#line 227 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_QUICK_TIME_ATOM (self), 0U);
#line 228 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	quick_time_atom_advance_section_offset (self, (guint64) 4);
#line 229 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = self->priv->input;
#line 229 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp2_ = g_data_input_stream_read_uint32 (_tmp1_, NULL, &_inner_error_);
#line 229 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = _tmp2_;
#line 229 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 229 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 229 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return 0U;
#line 1793 "VideoMetadata.c"
	}
#line 229 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = _tmp0_;
#line 229 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 1799 "VideoMetadata.c"
}


guint64 quick_time_atom_read_uint64 (QuickTimeAtom* self, GError** error) {
	guint64 result = 0ULL;
	guint64 _tmp0_ = 0ULL;
	GDataInputStream* _tmp1_ = NULL;
	guint64 _tmp2_ = 0ULL;
	GError * _inner_error_ = NULL;
#line 232 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_QUICK_TIME_ATOM (self), 0ULL);
#line 233 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	quick_time_atom_advance_section_offset (self, (guint64) 8);
#line 234 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = self->priv->input;
#line 234 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp2_ = g_data_input_stream_read_uint64 (_tmp1_, NULL, &_inner_error_);
#line 234 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = _tmp2_;
#line 234 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 234 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 234 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return 0ULL;
#line 1825 "VideoMetadata.c"
	}
#line 234 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = _tmp0_;
#line 234 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 1831 "VideoMetadata.c"
}


static gchar string_get (const gchar* self, glong index) {
	gchar result = '\0';
	glong _tmp0_ = 0L;
	gchar _tmp1_ = '\0';
#line 1086 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	g_return_val_if_fail (self != NULL, '\0');
#line 1087 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	_tmp0_ = index;
#line 1087 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	_tmp1_ = ((gchar*) self)[_tmp0_];
#line 1087 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	result = _tmp1_;
#line 1087 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	return result;
#line 1849 "VideoMetadata.c"
}


void quick_time_atom_read_atom (QuickTimeAtom* self, GError** error) {
	guint32 _tmp0_ = 0U;
	guint32 _tmp1_ = 0U;
	GString* sb = NULL;
	GString* _tmp2_ = NULL;
	guchar _tmp3_ = '\0';
	guchar _tmp4_ = '\0';
	GString* _tmp5_ = NULL;
	guchar _tmp6_ = '\0';
	guchar _tmp7_ = '\0';
	GString* _tmp8_ = NULL;
	guchar _tmp9_ = '\0';
	guchar _tmp10_ = '\0';
	GString* _tmp11_ = NULL;
	guchar _tmp12_ = '\0';
	guchar _tmp13_ = '\0';
	GString* _tmp14_ = NULL;
	GString* _tmp15_ = NULL;
	const gchar* _tmp16_ = NULL;
	gchar* _tmp17_ = NULL;
	const gchar* _tmp18_ = NULL;
	gint _tmp19_ = 0;
	gint _tmp20_ = 0;
	guint64 _tmp41_ = 0ULL;
	GError * _inner_error_ = NULL;
#line 237 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (IS_QUICK_TIME_ATOM (self));
#line 239 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = quick_time_atom_read_uint32 (self, &_inner_error_);
#line 239 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = _tmp1_;
#line 239 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 239 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 239 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 1890 "VideoMetadata.c"
	}
#line 239 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_size = (guint64) _tmp0_;
#line 242 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp2_ = g_string_new ("");
#line 242 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	sb = _tmp2_;
#line 243 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp4_ = quick_time_atom_read_byte (self, &_inner_error_);
#line 243 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp3_ = _tmp4_;
#line 243 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 243 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 243 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_string_free0 (sb);
#line 243 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 1910 "VideoMetadata.c"
	}
#line 243 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp5_ = sb;
#line 243 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_string_append_c (_tmp5_, (gchar) _tmp3_);
#line 244 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp7_ = quick_time_atom_read_byte (self, &_inner_error_);
#line 244 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp6_ = _tmp7_;
#line 244 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 244 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 244 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_string_free0 (sb);
#line 244 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 1928 "VideoMetadata.c"
	}
#line 244 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp8_ = sb;
#line 244 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_string_append_c (_tmp8_, (gchar) _tmp6_);
#line 245 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp10_ = quick_time_atom_read_byte (self, &_inner_error_);
#line 245 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp9_ = _tmp10_;
#line 245 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 245 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 245 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_string_free0 (sb);
#line 245 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 1946 "VideoMetadata.c"
	}
#line 245 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp11_ = sb;
#line 245 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_string_append_c (_tmp11_, (gchar) _tmp9_);
#line 246 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp13_ = quick_time_atom_read_byte (self, &_inner_error_);
#line 246 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp12_ = _tmp13_;
#line 246 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 246 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 246 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_string_free0 (sb);
#line 246 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 1964 "VideoMetadata.c"
	}
#line 246 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp14_ = sb;
#line 246 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_string_append_c (_tmp14_, (gchar) _tmp12_);
#line 247 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp15_ = sb;
#line 247 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp16_ = _tmp15_->str;
#line 247 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp17_ = g_strdup (_tmp16_);
#line 247 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_free0 (self->priv->section_name);
#line 247 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_name = _tmp17_;
#line 250 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp18_ = self->priv->section_name;
#line 250 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp19_ = strlen (_tmp18_);
#line 250 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp20_ = _tmp19_;
#line 250 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (_tmp20_ != 4) {
#line 1988 "VideoMetadata.c"
		GFile* _tmp21_ = NULL;
		gchar* _tmp22_ = NULL;
		gchar* _tmp23_ = NULL;
		GError* _tmp24_ = NULL;
		GError* _tmp25_ = NULL;
#line 251 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp21_ = self->priv->file;
#line 251 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp22_ = g_file_get_path (_tmp21_);
#line 251 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp23_ = _tmp22_;
#line 251 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp24_ = g_error_new (G_IO_ERROR, G_IO_ERROR_NOT_SUPPORTED, "QuickTime atom name length is invalid for %s", _tmp23_);
#line 251 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp25_ = _tmp24_;
#line 251 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_free0 (_tmp23_);
#line 251 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_inner_error_ = _tmp25_;
#line 251 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 251 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_string_free0 (sb);
#line 251 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 2014 "VideoMetadata.c"
	}
	{
		gint i = 0;
#line 254 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		i = 0;
#line 2020 "VideoMetadata.c"
		{
			gboolean _tmp26_ = FALSE;
#line 254 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp26_ = TRUE;
#line 254 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			while (TRUE) {
#line 2027 "VideoMetadata.c"
				gint _tmp28_ = 0;
				const gchar* _tmp29_ = NULL;
				gint _tmp30_ = 0;
				gint _tmp31_ = 0;
				const gchar* _tmp32_ = NULL;
				gint _tmp33_ = 0;
				gchar _tmp34_ = '\0';
				gboolean _tmp35_ = FALSE;
#line 254 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				if (!_tmp26_) {
#line 2038 "VideoMetadata.c"
					gint _tmp27_ = 0;
#line 254 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp27_ = i;
#line 254 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					i = _tmp27_ + 1;
#line 2044 "VideoMetadata.c"
				}
#line 254 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp26_ = FALSE;
#line 254 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp28_ = i;
#line 254 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp29_ = self->priv->section_name;
#line 254 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp30_ = strlen (_tmp29_);
#line 254 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp31_ = _tmp30_;
#line 254 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				if (!(_tmp28_ < _tmp31_)) {
#line 254 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					break;
#line 2060 "VideoMetadata.c"
				}
#line 255 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp32_ = self->priv->section_name;
#line 255 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp33_ = i;
#line 255 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp34_ = string_get (_tmp32_, (glong) _tmp33_);
#line 255 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp35_ = g_ascii_isprint (_tmp34_);
#line 255 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				if (!_tmp35_) {
#line 2072 "VideoMetadata.c"
					GFile* _tmp36_ = NULL;
					gchar* _tmp37_ = NULL;
					gchar* _tmp38_ = NULL;
					GError* _tmp39_ = NULL;
					GError* _tmp40_ = NULL;
#line 256 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp36_ = self->priv->file;
#line 256 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp37_ = g_file_get_path (_tmp36_);
#line 256 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp38_ = _tmp37_;
#line 256 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp39_ = g_error_new (G_IO_ERROR, G_IO_ERROR_NOT_SUPPORTED, "Bad QuickTime atom in file %s", _tmp38_);
#line 256 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp40_ = _tmp39_;
#line 256 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_g_free0 (_tmp38_);
#line 256 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_inner_error_ = _tmp40_;
#line 256 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					g_propagate_error (error, _inner_error_);
#line 256 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_g_string_free0 (sb);
#line 256 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					return;
#line 2098 "VideoMetadata.c"
				}
			}
		}
	}
#line 260 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp41_ = self->priv->section_size;
#line 260 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (((guint64) 1) == _tmp41_) {
#line 2107 "VideoMetadata.c"
		guint64 _tmp42_ = 0ULL;
		guint64 _tmp43_ = 0ULL;
#line 263 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp43_ = quick_time_atom_read_uint64 (self, &_inner_error_);
#line 263 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp42_ = _tmp43_;
#line 263 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 263 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			g_propagate_error (error, _inner_error_);
#line 263 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_g_string_free0 (sb);
#line 263 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return;
#line 2122 "VideoMetadata.c"
		}
#line 263 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		self->priv->section_size = _tmp42_;
#line 2126 "VideoMetadata.c"
	}
#line 237 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_string_free0 (sb);
#line 2130 "VideoMetadata.c"
}


static void quick_time_atom_skip (QuickTimeAtom* self, guint64 skip_amount, GError** error) {
	GDataInputStream* _tmp0_ = NULL;
	guint64 _tmp1_ = 0ULL;
	GError * _inner_error_ = NULL;
#line 267 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (IS_QUICK_TIME_ATOM (self));
#line 268 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = self->priv->input;
#line 268 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = skip_amount;
#line 268 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	skip_uint64 (G_TYPE_CHECK_INSTANCE_CAST (_tmp0_, g_input_stream_get_type (), GInputStream), _tmp1_, &_inner_error_);
#line 268 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 268 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 268 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 2152 "VideoMetadata.c"
	}
}


guint64 quick_time_atom_section_size_remaining (QuickTimeAtom* self) {
	guint64 result = 0ULL;
	guint64 _tmp0_ = 0ULL;
	guint64 _tmp1_ = 0ULL;
	guint64 _tmp2_ = 0ULL;
	guint64 _tmp3_ = 0ULL;
#line 271 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_QUICK_TIME_ATOM (self), 0ULL);
#line 272 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = self->priv->section_size;
#line 272 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = self->priv->section_offset;
#line 272 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_vala_assert (_tmp0_ >= _tmp1_, "section_size >= section_offset");
#line 273 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp2_ = self->priv->section_size;
#line 273 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp3_ = self->priv->section_offset;
#line 273 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = _tmp2_ - _tmp3_;
#line 273 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 2179 "VideoMetadata.c"
}


void quick_time_atom_next_atom (QuickTimeAtom* self, GError** error) {
	guint64 _tmp0_ = 0ULL;
	GError * _inner_error_ = NULL;
#line 276 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (IS_QUICK_TIME_ATOM (self));
#line 277 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = quick_time_atom_section_size_remaining (self);
#line 277 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	quick_time_atom_skip (self, _tmp0_, &_inner_error_);
#line 277 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 277 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 277 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 2198 "VideoMetadata.c"
	}
#line 278 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_size = (guint64) 0;
#line 279 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_offset = (guint64) 0;
#line 2204 "VideoMetadata.c"
}


gchar* quick_time_atom_get_current_atom_name (QuickTimeAtom* self) {
	gchar* result = NULL;
	const gchar* _tmp0_ = NULL;
	gchar* _tmp1_ = NULL;
#line 282 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_QUICK_TIME_ATOM (self), NULL);
#line 283 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = self->priv->section_name;
#line 283 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = g_strdup (_tmp0_);
#line 283 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = _tmp1_;
#line 283 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 2222 "VideoMetadata.c"
}


gboolean quick_time_atom_is_last_atom (QuickTimeAtom* self) {
	gboolean result = FALSE;
	guint64 _tmp0_ = 0ULL;
#line 286 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_QUICK_TIME_ATOM (self), FALSE);
#line 287 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = self->priv->section_size;
#line 287 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = ((guint64) 0) == _tmp0_;
#line 287 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 2237 "VideoMetadata.c"
}


static void value_quick_time_atom_init (GValue* value) {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	value->data[0].v_pointer = NULL;
#line 2244 "VideoMetadata.c"
}


static void value_quick_time_atom_free_value (GValue* value) {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (value->data[0].v_pointer) {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		quick_time_atom_unref (value->data[0].v_pointer);
#line 2253 "VideoMetadata.c"
	}
}


static void value_quick_time_atom_copy_value (const GValue* src_value, GValue* dest_value) {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (src_value->data[0].v_pointer) {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		dest_value->data[0].v_pointer = quick_time_atom_ref (src_value->data[0].v_pointer);
#line 2263 "VideoMetadata.c"
	} else {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		dest_value->data[0].v_pointer = NULL;
#line 2267 "VideoMetadata.c"
	}
}


static gpointer value_quick_time_atom_peek_pointer (const GValue* value) {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return value->data[0].v_pointer;
#line 2275 "VideoMetadata.c"
}


static gchar* value_quick_time_atom_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (collect_values[0].v_pointer) {
#line 2282 "VideoMetadata.c"
		QuickTimeAtom* object;
		object = collect_values[0].v_pointer;
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (object->parent_instance.g_class == NULL) {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
#line 2289 "VideoMetadata.c"
		} else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
#line 2293 "VideoMetadata.c"
		}
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = quick_time_atom_ref (object);
#line 2297 "VideoMetadata.c"
	} else {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = NULL;
#line 2301 "VideoMetadata.c"
	}
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return NULL;
#line 2305 "VideoMetadata.c"
}


static gchar* value_quick_time_atom_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
	QuickTimeAtom** object_p;
	object_p = collect_values[0].v_pointer;
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (!object_p) {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value));
#line 2316 "VideoMetadata.c"
	}
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (!value->data[0].v_pointer) {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		*object_p = NULL;
#line 2322 "VideoMetadata.c"
	} else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		*object_p = value->data[0].v_pointer;
#line 2326 "VideoMetadata.c"
	} else {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		*object_p = quick_time_atom_ref (value->data[0].v_pointer);
#line 2330 "VideoMetadata.c"
	}
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return NULL;
#line 2334 "VideoMetadata.c"
}


GParamSpec* param_spec_quick_time_atom (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) {
	ParamSpecQuickTimeAtom* spec;
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (g_type_is_a (object_type, TYPE_QUICK_TIME_ATOM), NULL);
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags);
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	G_PARAM_SPEC (spec)->value_type = object_type;
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return G_PARAM_SPEC (spec);
#line 2348 "VideoMetadata.c"
}


gpointer value_get_quick_time_atom (const GValue* value) {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_QUICK_TIME_ATOM), NULL);
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return value->data[0].v_pointer;
#line 2357 "VideoMetadata.c"
}


void value_set_quick_time_atom (GValue* value, gpointer v_object) {
	QuickTimeAtom* old;
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_QUICK_TIME_ATOM));
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	old = value->data[0].v_pointer;
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (v_object) {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_QUICK_TIME_ATOM));
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value)));
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = v_object;
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		quick_time_atom_ref (value->data[0].v_pointer);
#line 2377 "VideoMetadata.c"
	} else {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = NULL;
#line 2381 "VideoMetadata.c"
	}
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (old) {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		quick_time_atom_unref (old);
#line 2387 "VideoMetadata.c"
	}
}


void value_take_quick_time_atom (GValue* value, gpointer v_object) {
	QuickTimeAtom* old;
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_QUICK_TIME_ATOM));
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	old = value->data[0].v_pointer;
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (v_object) {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_QUICK_TIME_ATOM));
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value)));
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = v_object;
#line 2406 "VideoMetadata.c"
	} else {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = NULL;
#line 2410 "VideoMetadata.c"
	}
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (old) {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		quick_time_atom_unref (old);
#line 2416 "VideoMetadata.c"
	}
}


static void quick_time_atom_class_init (QuickTimeAtomClass * klass) {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	quick_time_atom_parent_class = g_type_class_peek_parent (klass);
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	((QuickTimeAtomClass *) klass)->finalize = quick_time_atom_finalize;
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_type_class_add_private (klass, sizeof (QuickTimeAtomPrivate));
#line 2428 "VideoMetadata.c"
}


static void quick_time_atom_instance_init (QuickTimeAtom * self) {
	gchar* _tmp0_ = NULL;
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv = QUICK_TIME_ATOM_GET_PRIVATE (self);
#line 174 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->file = NULL;
#line 175 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = g_strdup ("");
#line 175 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_name = _tmp0_;
#line 176 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_size = (guint64) 0;
#line 177 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_offset = (guint64) 0;
#line 178 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->input = NULL;
#line 179 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->parent = NULL;
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->ref_count = 1;
#line 2452 "VideoMetadata.c"
}


static void quick_time_atom_finalize (QuickTimeAtom* obj) {
	QuickTimeAtom * self;
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_QUICK_TIME_ATOM, QuickTimeAtom);
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_signal_handlers_destroy (self);
#line 174 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_object_unref0 (self->priv->file);
#line 175 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_free0 (self->priv->section_name);
#line 178 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_object_unref0 (self->priv->input);
#line 179 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_quick_time_atom_unref0 (self->priv->parent);
#line 2470 "VideoMetadata.c"
}


GType quick_time_atom_get_type (void) {
	static volatile gsize quick_time_atom_type_id__volatile = 0;
	if (g_once_init_enter (&quick_time_atom_type_id__volatile)) {
		static const GTypeValueTable g_define_type_value_table = { value_quick_time_atom_init, value_quick_time_atom_free_value, value_quick_time_atom_copy_value, value_quick_time_atom_peek_pointer, "p", value_quick_time_atom_collect_value, "p", value_quick_time_atom_lcopy_value };
		static const GTypeInfo g_define_type_info = { sizeof (QuickTimeAtomClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) quick_time_atom_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (QuickTimeAtom), 0, (GInstanceInitFunc) quick_time_atom_instance_init, &g_define_type_value_table };
		static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) };
		GType quick_time_atom_type_id;
		quick_time_atom_type_id = g_type_register_fundamental (g_type_fundamental_next (), "QuickTimeAtom", &g_define_type_info, &g_define_type_fundamental_info, 0);
		g_once_init_leave (&quick_time_atom_type_id__volatile, quick_time_atom_type_id);
	}
	return quick_time_atom_type_id__volatile;
}


gpointer quick_time_atom_ref (gpointer instance) {
	QuickTimeAtom* self;
	self = instance;
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_atomic_int_inc (&self->ref_count);
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return instance;
#line 2495 "VideoMetadata.c"
}


void quick_time_atom_unref (gpointer instance) {
	QuickTimeAtom* self;
	self = instance;
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (g_atomic_int_dec_and_test (&self->ref_count)) {
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		QUICK_TIME_ATOM_GET_CLASS (self)->finalize (self);
#line 173 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_type_free_instance ((GTypeInstance *) self);
#line 2508 "VideoMetadata.c"
	}
}


AVIMetadataLoader* avi_metadata_loader_construct (GType object_type, GFile* file) {
	AVIMetadataLoader* self = NULL;
	GFile* _tmp0_ = NULL;
	GFile* _tmp1_ = NULL;
#line 305 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (G_IS_FILE (file), NULL);
#line 305 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self = (AVIMetadataLoader*) g_type_create_instance (object_type);
#line 306 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = file;
#line 306 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = _g_object_ref0 (_tmp0_);
#line 306 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_object_unref0 (self->priv->file);
#line 306 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->file = _tmp1_;
#line 305 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return self;
#line 2531 "VideoMetadata.c"
}


AVIMetadataLoader* avi_metadata_loader_new (GFile* file) {
#line 305 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return avi_metadata_loader_construct (TYPE_AVI_METADATA_LOADER, file);
#line 2538 "VideoMetadata.c"
}


MetadataDateTime* avi_metadata_loader_get_creation_date_time (AVIMetadataLoader* self) {
	MetadataDateTime* result = NULL;
	gulong _tmp0_ = 0UL;
	MetadataDateTime* _tmp1_ = NULL;
#line 309 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_AVI_METADATA_LOADER (self), NULL);
#line 310 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = avi_metadata_loader_get_creation_date_time_for_avi (self);
#line 310 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = metadata_date_time_new ((time_t) _tmp0_);
#line 310 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = _tmp1_;
#line 310 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 2556 "VideoMetadata.c"
}


gchar* avi_metadata_loader_get_title (AVIMetadataLoader* self) {
	gchar* result = NULL;
#line 313 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_AVI_METADATA_LOADER (self), NULL);
#line 315 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = NULL;
#line 315 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 2568 "VideoMetadata.c"
}


gboolean avi_metadata_loader_is_supported (AVIMetadataLoader* self) {
	gboolean result = FALSE;
	AVIChunk* chunk = NULL;
	GFile* _tmp0_ = NULL;
	AVIChunk* _tmp1_ = NULL;
	gboolean ret = FALSE;
	GError * _inner_error_ = NULL;
#line 319 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_AVI_METADATA_LOADER (self), FALSE);
#line 320 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = self->priv->file;
#line 320 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = avi_chunk_new (_tmp0_);
#line 320 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	chunk = _tmp1_;
#line 321 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	ret = FALSE;
#line 2589 "VideoMetadata.c"
	{
		AVIChunk* _tmp2_ = NULL;
		AVIChunk* _tmp3_ = NULL;
		gboolean _tmp4_ = FALSE;
		AVIChunk* _tmp5_ = NULL;
		gchar* _tmp6_ = NULL;
		gchar* _tmp7_ = NULL;
		gboolean _tmp8_ = FALSE;
#line 323 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp2_ = chunk;
#line 323 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		avi_chunk_open_file (_tmp2_, &_inner_error_);
#line 323 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 2604 "VideoMetadata.c"
			goto __catch577_g_error;
		}
#line 324 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp3_ = chunk;
#line 324 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		avi_chunk_read_chunk (_tmp3_, &_inner_error_);
#line 324 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 2613 "VideoMetadata.c"
			goto __catch577_g_error;
		}
#line 326 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp5_ = chunk;
#line 326 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp6_ = avi_chunk_get_current_chunk_name (_tmp5_);
#line 326 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp7_ = _tmp6_;
#line 326 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp8_ = g_strcmp0 ("RIFF", _tmp7_) == 0;
#line 326 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_free0 (_tmp7_);
#line 326 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (_tmp8_) {
#line 2628 "VideoMetadata.c"
			gchar* _tmp9_ = NULL;
			AVIChunk* _tmp10_ = NULL;
			gchar* _tmp11_ = NULL;
			gchar* _tmp12_ = NULL;
			gchar* _tmp13_ = NULL;
#line 327 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp10_ = chunk;
#line 327 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp11_ = avi_chunk_read_name (_tmp10_, &_inner_error_);
#line 327 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp9_ = _tmp11_;
#line 327 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 2642 "VideoMetadata.c"
				goto __catch577_g_error;
			}
#line 327 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp12_ = _tmp9_;
#line 327 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp9_ = NULL;
#line 327 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp13_ = _tmp12_;
#line 327 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp4_ = g_strcmp0 ("AVI ", _tmp13_) == 0;
#line 327 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_g_free0 (_tmp13_);
#line 326 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_g_free0 (_tmp9_);
#line 2657 "VideoMetadata.c"
		} else {
#line 326 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp4_ = FALSE;
#line 2661 "VideoMetadata.c"
		}
#line 326 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (_tmp4_) {
#line 328 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			ret = TRUE;
#line 2667 "VideoMetadata.c"
		}
	}
	goto __finally577;
	__catch577_g_error:
	{
		GError* e = NULL;
		GError* _tmp14_ = NULL;
		const gchar* _tmp15_ = NULL;
#line 322 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		e = _inner_error_;
#line 322 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_inner_error_ = NULL;
#line 331 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp14_ = e;
#line 331 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp15_ = _tmp14_->message;
#line 331 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_debug ("VideoMetadata.vala:331: Error while testing for AVI file: %s", _tmp15_);
#line 322 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_error_free0 (e);
#line 2688 "VideoMetadata.c"
	}
	__finally577:
#line 322 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 322 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_avi_chunk_unref0 (chunk);
#line 322 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 322 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_clear_error (&_inner_error_);
#line 322 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return FALSE;
#line 2701 "VideoMetadata.c"
	}
	{
		AVIChunk* _tmp16_ = NULL;
#line 335 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp16_ = chunk;
#line 335 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		avi_chunk_close_file (_tmp16_, &_inner_error_);
#line 335 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 2711 "VideoMetadata.c"
			goto __catch578_g_error;
		}
	}
	goto __finally578;
	__catch578_g_error:
	{
		GError* e = NULL;
		GError* _tmp17_ = NULL;
		const gchar* _tmp18_ = NULL;
#line 334 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		e = _inner_error_;
#line 334 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_inner_error_ = NULL;
#line 337 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp17_ = e;
#line 337 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp18_ = _tmp17_->message;
#line 337 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_debug ("VideoMetadata.vala:337: Error while closing AVI file: %s", _tmp18_);
#line 334 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_error_free0 (e);
#line 2733 "VideoMetadata.c"
	}
	__finally578:
#line 334 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 334 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_avi_chunk_unref0 (chunk);
#line 334 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 334 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_clear_error (&_inner_error_);
#line 334 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return FALSE;
#line 2746 "VideoMetadata.c"
	}
#line 339 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = ret;
#line 339 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_avi_chunk_unref0 (chunk);
#line 339 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 2754 "VideoMetadata.c"
}


static gchar* avi_metadata_loader_read_nikon_nctg_tag (AVIMetadataLoader* self, AVIChunk* chunk, GError** error) {
	gchar* result = NULL;
	gboolean found_date = FALSE;
	gboolean _tmp9_ = FALSE;
	gchar* _tmp21_ = NULL;
	GError * _inner_error_ = NULL;
#line 343 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_AVI_METADATA_LOADER (self), NULL);
#line 343 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_AVI_CHUNK (chunk), NULL);
#line 344 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	found_date = FALSE;
#line 345 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	while (TRUE) {
#line 2772 "VideoMetadata.c"
		AVIChunk* _tmp0_ = NULL;
		guint64 _tmp1_ = 0ULL;
		guint16 tag = 0U;
		AVIChunk* _tmp2_ = NULL;
		guint16 _tmp3_ = 0U;
		guint16 size = 0U;
		AVIChunk* _tmp4_ = NULL;
		guint16 _tmp5_ = 0U;
		guint16 _tmp6_ = 0U;
		AVIChunk* _tmp7_ = NULL;
		guint16 _tmp8_ = 0U;
#line 345 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp0_ = chunk;
#line 345 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp1_ = avi_chunk_section_size_remaining (_tmp0_);
#line 345 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (!(_tmp1_ > ((guint64) (sizeof (guint16) * 2)))) {
#line 345 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			break;
#line 2792 "VideoMetadata.c"
		}
#line 346 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp2_ = chunk;
#line 346 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp3_ = avi_chunk_read_uint16 (_tmp2_, &_inner_error_);
#line 346 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		tag = _tmp3_;
#line 346 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 346 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			g_propagate_error (error, _inner_error_);
#line 346 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return NULL;
#line 2806 "VideoMetadata.c"
		}
#line 347 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp4_ = chunk;
#line 347 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp5_ = avi_chunk_read_uint16 (_tmp4_, &_inner_error_);
#line 347 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		size = _tmp5_;
#line 347 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 347 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			g_propagate_error (error, _inner_error_);
#line 347 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return NULL;
#line 2820 "VideoMetadata.c"
		}
#line 348 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp6_ = tag;
#line 348 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (AVI_METADATA_LOADER_NIKON_NCTG_TIMESTAMP_MARKER == _tmp6_) {
#line 349 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			found_date = TRUE;
#line 350 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			break;
#line 2830 "VideoMetadata.c"
		}
#line 352 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp7_ = chunk;
#line 352 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp8_ = size;
#line 352 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		avi_chunk_skip (_tmp7_, (guint64) _tmp8_, &_inner_error_);
#line 352 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 352 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			g_propagate_error (error, _inner_error_);
#line 352 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return NULL;
#line 2844 "VideoMetadata.c"
		}
	}
#line 355 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp9_ = found_date;
#line 355 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (_tmp9_) {
#line 2851 "VideoMetadata.c"
		GString* sb = NULL;
		GString* _tmp10_ = NULL;
		GString* _tmp18_ = NULL;
		const gchar* _tmp19_ = NULL;
		gchar* _tmp20_ = NULL;
#line 357 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp10_ = g_string_new ("");
#line 357 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		sb = _tmp10_;
#line 2861 "VideoMetadata.c"
		{
			gint i = 0;
#line 358 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			i = 0;
#line 2866 "VideoMetadata.c"
			{
				gboolean _tmp11_ = FALSE;
#line 358 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp11_ = TRUE;
#line 358 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				while (TRUE) {
#line 2873 "VideoMetadata.c"
					gint _tmp13_ = 0;
					guchar _tmp14_ = '\0';
					AVIChunk* _tmp15_ = NULL;
					guchar _tmp16_ = '\0';
					GString* _tmp17_ = NULL;
#line 358 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					if (!_tmp11_) {
#line 2881 "VideoMetadata.c"
						gint _tmp12_ = 0;
#line 358 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						_tmp12_ = i;
#line 358 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						i = _tmp12_ + 1;
#line 2887 "VideoMetadata.c"
					}
#line 358 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp11_ = FALSE;
#line 358 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp13_ = i;
#line 358 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					if (!(_tmp13_ < AVI_METADATA_LOADER_NUMERICAL_DATE_LENGTH)) {
#line 358 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						break;
#line 2897 "VideoMetadata.c"
					}
#line 359 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp15_ = chunk;
#line 359 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp16_ = avi_chunk_read_byte (_tmp15_, &_inner_error_);
#line 359 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp14_ = _tmp16_;
#line 359 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 359 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						g_propagate_error (error, _inner_error_);
#line 359 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						_g_string_free0 (sb);
#line 359 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						return NULL;
#line 2913 "VideoMetadata.c"
					}
#line 359 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp17_ = sb;
#line 359 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					g_string_append_c (_tmp17_, (gchar) _tmp14_);
#line 2919 "VideoMetadata.c"
				}
			}
		}
#line 361 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp18_ = sb;
#line 361 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp19_ = _tmp18_->str;
#line 361 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp20_ = g_strdup (_tmp19_);
#line 361 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		result = _tmp20_;
#line 361 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_string_free0 (sb);
#line 361 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return result;
#line 2935 "VideoMetadata.c"
	}
#line 363 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp21_ = g_strdup ("");
#line 363 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = _tmp21_;
#line 363 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 2943 "VideoMetadata.c"
}


static glong string_strnlen (gchar* str, glong maxlen) {
	glong result = 0L;
	gchar* end = NULL;
	gchar* _tmp0_ = NULL;
	glong _tmp1_ = 0L;
	gchar* _tmp2_ = NULL;
	gchar* _tmp3_ = NULL;
#line 1295 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	_tmp0_ = str;
#line 1295 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	_tmp1_ = maxlen;
#line 1295 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	_tmp2_ = memchr (_tmp0_, 0, (gsize) _tmp1_);
#line 1295 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	end = _tmp2_;
#line 1296 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	_tmp3_ = end;
#line 1296 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	if (_tmp3_ == NULL) {
#line 2966 "VideoMetadata.c"
		glong _tmp4_ = 0L;
#line 1297 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		_tmp4_ = maxlen;
#line 1297 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		result = _tmp4_;
#line 1297 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		return result;
#line 2974 "VideoMetadata.c"
	} else {
		gchar* _tmp5_ = NULL;
		gchar* _tmp6_ = NULL;
#line 1299 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		_tmp5_ = end;
#line 1299 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		_tmp6_ = str;
#line 1299 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		result = (glong) (_tmp5_ - _tmp6_);
#line 1299 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		return result;
#line 2986 "VideoMetadata.c"
	}
}


static gchar* string_substring (const gchar* self, glong offset, glong len) {
	gchar* result = NULL;
	glong string_length = 0L;
	gboolean _tmp0_ = FALSE;
	glong _tmp1_ = 0L;
	glong _tmp8_ = 0L;
	glong _tmp14_ = 0L;
	glong _tmp17_ = 0L;
	glong _tmp18_ = 0L;
	glong _tmp19_ = 0L;
	glong _tmp20_ = 0L;
	glong _tmp21_ = 0L;
	gchar* _tmp22_ = NULL;
#line 1306 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	g_return_val_if_fail (self != NULL, NULL);
#line 1308 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	_tmp1_ = offset;
#line 1308 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	if (_tmp1_ >= ((glong) 0)) {
#line 3010 "VideoMetadata.c"
		glong _tmp2_ = 0L;
#line 1308 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		_tmp2_ = len;
#line 1308 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		_tmp0_ = _tmp2_ >= ((glong) 0);
#line 3016 "VideoMetadata.c"
	} else {
#line 1308 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		_tmp0_ = FALSE;
#line 3020 "VideoMetadata.c"
	}
#line 1308 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	if (_tmp0_) {
#line 3024 "VideoMetadata.c"
		glong _tmp3_ = 0L;
		glong _tmp4_ = 0L;
		glong _tmp5_ = 0L;
#line 1310 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		_tmp3_ = offset;
#line 1310 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		_tmp4_ = len;
#line 1310 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		_tmp5_ = string_strnlen ((gchar*) self, _tmp3_ + _tmp4_);
#line 1310 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		string_length = _tmp5_;
#line 3036 "VideoMetadata.c"
	} else {
		gint _tmp6_ = 0;
		gint _tmp7_ = 0;
#line 1312 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		_tmp6_ = strlen (self);
#line 1312 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		_tmp7_ = _tmp6_;
#line 1312 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		string_length = (glong) _tmp7_;
#line 3046 "VideoMetadata.c"
	}
#line 1315 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	_tmp8_ = offset;
#line 1315 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	if (_tmp8_ < ((glong) 0)) {
#line 3052 "VideoMetadata.c"
		glong _tmp9_ = 0L;
		glong _tmp10_ = 0L;
		glong _tmp11_ = 0L;
#line 1316 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		_tmp9_ = string_length;
#line 1316 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		_tmp10_ = offset;
#line 1316 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		offset = _tmp9_ + _tmp10_;
#line 1317 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		_tmp11_ = offset;
#line 1317 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		g_return_val_if_fail (_tmp11_ >= ((glong) 0), NULL);
#line 3066 "VideoMetadata.c"
	} else {
		glong _tmp12_ = 0L;
		glong _tmp13_ = 0L;
#line 1319 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		_tmp12_ = offset;
#line 1319 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		_tmp13_ = string_length;
#line 1319 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		g_return_val_if_fail (_tmp12_ <= _tmp13_, NULL);
#line 3076 "VideoMetadata.c"
	}
#line 1321 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	_tmp14_ = len;
#line 1321 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	if (_tmp14_ < ((glong) 0)) {
#line 3082 "VideoMetadata.c"
		glong _tmp15_ = 0L;
		glong _tmp16_ = 0L;
#line 1322 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		_tmp15_ = string_length;
#line 1322 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		_tmp16_ = offset;
#line 1322 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
		len = _tmp15_ - _tmp16_;
#line 3091 "VideoMetadata.c"
	}
#line 1324 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	_tmp17_ = offset;
#line 1324 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	_tmp18_ = len;
#line 1324 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	_tmp19_ = string_length;
#line 1324 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	g_return_val_if_fail ((_tmp17_ + _tmp18_) <= _tmp19_, NULL);
#line 1325 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	_tmp20_ = offset;
#line 1325 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	_tmp21_ = len;
#line 1325 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	_tmp22_ = g_strndup (((gchar*) self) + _tmp20_, (gsize) _tmp21_);
#line 1325 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	result = _tmp22_;
#line 1325 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	return result;
#line 3111 "VideoMetadata.c"
}


static gchar* avi_metadata_loader_read_fuji_strd_tag (AVIMetadataLoader* self, AVIChunk* chunk, GError** error) {
	gchar* result = NULL;
	AVIChunk* _tmp0_ = NULL;
	AVIChunk* _tmp1_ = NULL;
	gint colons = 0;
	gint post_colons = 0;
	GString* sb = NULL;
	GString* _tmp2_ = NULL;
	GString* _tmp20_ = NULL;
	const gchar* _tmp21_ = NULL;
	gint _tmp22_ = 0;
	gint _tmp23_ = 0;
	GString* _tmp25_ = NULL;
	const gchar* _tmp26_ = NULL;
	GString* _tmp27_ = NULL;
	const gchar* _tmp28_ = NULL;
	gint _tmp29_ = 0;
	gint _tmp30_ = 0;
	gchar* _tmp31_ = NULL;
	GError * _inner_error_ = NULL;
#line 368 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_AVI_METADATA_LOADER (self), NULL);
#line 368 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_AVI_CHUNK (chunk), NULL);
#line 369 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = chunk;
#line 369 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	avi_chunk_skip (_tmp0_, (guint64) 98, &_inner_error_);
#line 369 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 369 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 369 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return NULL;
#line 3149 "VideoMetadata.c"
	}
#line 370 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = chunk;
#line 370 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	avi_chunk_skip (_tmp1_, (guint64) 8, &_inner_error_);
#line 370 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 370 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 370 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return NULL;
#line 3161 "VideoMetadata.c"
	}
#line 372 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	colons = 0;
#line 373 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	post_colons = 0;
#line 374 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp2_ = g_string_new ("");
#line 374 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	sb = _tmp2_;
#line 376 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	while (TRUE) {
#line 3173 "VideoMetadata.c"
		gboolean _tmp3_ = FALSE;
		gint _tmp4_ = 0;
		guchar _tmp6_ = '\0';
		AVIChunk* _tmp7_ = NULL;
		guchar _tmp8_ = '\0';
		gchar c = '\0';
		gint _tmp9_ = 0;
		gchar _tmp11_ = '\0';
		gchar _tmp13_ = '\0';
		gboolean _tmp14_ = FALSE;
		GString* _tmp17_ = NULL;
		gssize _tmp18_ = 0L;
#line 376 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp4_ = colons;
#line 376 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (_tmp4_ <= 4) {
#line 3190 "VideoMetadata.c"
			gint _tmp5_ = 0;
#line 376 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp5_ = post_colons;
#line 376 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp3_ = _tmp5_ < 2;
#line 3196 "VideoMetadata.c"
		} else {
#line 376 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp3_ = FALSE;
#line 3200 "VideoMetadata.c"
		}
#line 376 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (!_tmp3_) {
#line 376 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			break;
#line 3206 "VideoMetadata.c"
		}
#line 377 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp7_ = chunk;
#line 377 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp8_ = avi_chunk_read_byte (_tmp7_, &_inner_error_);
#line 377 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp6_ = _tmp8_;
#line 377 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 377 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			g_propagate_error (error, _inner_error_);
#line 377 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_g_string_free0 (sb);
#line 377 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return NULL;
#line 3222 "VideoMetadata.c"
		}
#line 377 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		c = (gchar) _tmp6_;
#line 378 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp9_ = colons;
#line 378 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (4 == _tmp9_) {
#line 3230 "VideoMetadata.c"
			gint _tmp10_ = 0;
#line 379 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp10_ = post_colons;
#line 379 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			post_colons = _tmp10_ + 1;
#line 3236 "VideoMetadata.c"
		}
#line 381 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp11_ = c;
#line 381 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (':' == _tmp11_) {
#line 3242 "VideoMetadata.c"
			gint _tmp12_ = 0;
#line 382 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp12_ = colons;
#line 382 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			colons = _tmp12_ + 1;
#line 3248 "VideoMetadata.c"
		}
#line 384 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp13_ = c;
#line 384 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp14_ = g_ascii_isprint (_tmp13_);
#line 384 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (_tmp14_) {
#line 3256 "VideoMetadata.c"
			GString* _tmp15_ = NULL;
			gchar _tmp16_ = '\0';
#line 385 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp15_ = sb;
#line 385 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp16_ = c;
#line 385 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			g_string_append_c (_tmp15_, _tmp16_);
#line 3265 "VideoMetadata.c"
		}
#line 387 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp17_ = sb;
#line 387 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp18_ = _tmp17_->len;
#line 387 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (_tmp18_ > ((gssize) AVI_METADATA_LOADER_MAX_STRD_LENGTH)) {
#line 3273 "VideoMetadata.c"
			gchar* _tmp19_ = NULL;
#line 388 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp19_ = g_strdup ("");
#line 388 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			result = _tmp19_;
#line 388 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_g_string_free0 (sb);
#line 388 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return result;
#line 3283 "VideoMetadata.c"
		}
	}
#line 392 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp20_ = sb;
#line 392 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp21_ = _tmp20_->str;
#line 392 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp22_ = strlen (_tmp21_);
#line 392 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp23_ = _tmp22_;
#line 392 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (_tmp23_ < AVI_METADATA_LOADER_NUMERICAL_DATE_LENGTH) {
#line 3296 "VideoMetadata.c"
		gchar* _tmp24_ = NULL;
#line 393 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp24_ = g_strdup ("");
#line 393 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		result = _tmp24_;
#line 393 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_string_free0 (sb);
#line 393 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return result;
#line 3306 "VideoMetadata.c"
	}
#line 396 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp25_ = sb;
#line 396 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp26_ = _tmp25_->str;
#line 396 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp27_ = sb;
#line 396 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp28_ = _tmp27_->str;
#line 396 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp29_ = strlen (_tmp28_);
#line 396 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp30_ = _tmp29_;
#line 396 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp31_ = string_substring (_tmp26_, (glong) (_tmp30_ - AVI_METADATA_LOADER_NUMERICAL_DATE_LENGTH), (glong) -1);
#line 396 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = _tmp31_;
#line 396 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_string_free0 (sb);
#line 396 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 3328 "VideoMetadata.c"
}


static gchar* avi_metadata_loader_read_section (AVIMetadataLoader* self, AVIChunk* chunk, GError** error) {
	gchar* result = NULL;
	GError * _inner_error_ = NULL;
#line 400 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_AVI_METADATA_LOADER (self), NULL);
#line 400 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_AVI_CHUNK (chunk), NULL);
#line 401 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	while (TRUE) {
#line 3341 "VideoMetadata.c"
		AVIChunk* _tmp0_ = NULL;
		gchar* name = NULL;
		AVIChunk* _tmp1_ = NULL;
		gchar* _tmp2_ = NULL;
		const gchar* _tmp3_ = NULL;
		const gchar* _tmp18_ = NULL;
		AVIChunk* _tmp28_ = NULL;
		gboolean _tmp29_ = FALSE;
		AVIChunk* _tmp30_ = NULL;
#line 402 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp0_ = chunk;
#line 402 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		avi_chunk_read_chunk (_tmp0_, &_inner_error_);
#line 402 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 402 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			g_propagate_error (error, _inner_error_);
#line 402 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return NULL;
#line 3361 "VideoMetadata.c"
		}
#line 403 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp1_ = chunk;
#line 403 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp2_ = avi_chunk_get_current_chunk_name (_tmp1_);
#line 403 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		name = _tmp2_;
#line 404 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp3_ = name;
#line 404 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (g_strcmp0 ("IDIT", _tmp3_) == 0) {
#line 3373 "VideoMetadata.c"
			gchar* _tmp4_ = NULL;
			AVIChunk* _tmp5_ = NULL;
			gchar* _tmp6_ = NULL;
			gchar* _tmp7_ = NULL;
#line 405 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp5_ = chunk;
#line 405 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp6_ = avi_chunk_section_to_string (_tmp5_, &_inner_error_);
#line 405 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp4_ = _tmp6_;
#line 405 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 405 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				g_propagate_error (error, _inner_error_);
#line 405 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_g_free0 (name);
#line 405 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				return NULL;
#line 3392 "VideoMetadata.c"
			}
#line 405 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp7_ = _tmp4_;
#line 405 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp4_ = NULL;
#line 405 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			result = _tmp7_;
#line 405 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_g_free0 (_tmp4_);
#line 405 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_g_free0 (name);
#line 405 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return result;
#line 3406 "VideoMetadata.c"
		} else {
			const gchar* _tmp8_ = NULL;
#line 406 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp8_ = name;
#line 406 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			if (g_strcmp0 ("nctg", _tmp8_) == 0) {
#line 3413 "VideoMetadata.c"
				gchar* _tmp9_ = NULL;
				AVIChunk* _tmp10_ = NULL;
				gchar* _tmp11_ = NULL;
				gchar* _tmp12_ = NULL;
#line 407 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp10_ = chunk;
#line 407 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp11_ = avi_metadata_loader_read_nikon_nctg_tag (self, _tmp10_, &_inner_error_);
#line 407 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp9_ = _tmp11_;
#line 407 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 407 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					g_propagate_error (error, _inner_error_);
#line 407 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_g_free0 (name);
#line 407 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					return NULL;
#line 3432 "VideoMetadata.c"
				}
#line 407 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp12_ = _tmp9_;
#line 407 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp9_ = NULL;
#line 407 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				result = _tmp12_;
#line 407 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_g_free0 (_tmp9_);
#line 407 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_g_free0 (name);
#line 407 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				return result;
#line 3446 "VideoMetadata.c"
			} else {
				const gchar* _tmp13_ = NULL;
#line 408 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_tmp13_ = name;
#line 408 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				if (g_strcmp0 ("strd", _tmp13_) == 0) {
#line 3453 "VideoMetadata.c"
					gchar* _tmp14_ = NULL;
					AVIChunk* _tmp15_ = NULL;
					gchar* _tmp16_ = NULL;
					gchar* _tmp17_ = NULL;
#line 409 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp15_ = chunk;
#line 409 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp16_ = avi_metadata_loader_read_fuji_strd_tag (self, _tmp15_, &_inner_error_);
#line 409 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp14_ = _tmp16_;
#line 409 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 409 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						g_propagate_error (error, _inner_error_);
#line 409 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						_g_free0 (name);
#line 409 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
						return NULL;
#line 3472 "VideoMetadata.c"
					}
#line 409 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp17_ = _tmp14_;
#line 409 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_tmp14_ = NULL;
#line 409 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					result = _tmp17_;
#line 409 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_g_free0 (_tmp14_);
#line 409 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					_g_free0 (name);
#line 409 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
					return result;
#line 3486 "VideoMetadata.c"
				}
			}
		}
#line 412 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp18_ = name;
#line 412 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (g_strcmp0 ("LIST", _tmp18_) == 0) {
#line 3494 "VideoMetadata.c"
			AVIChunk* _tmp19_ = NULL;
			gchar* _tmp20_ = NULL;
			gchar* _tmp21_ = NULL;
			gchar* _result_ = NULL;
			AVIChunk* _tmp22_ = NULL;
			AVIChunk* _tmp23_ = NULL;
			AVIChunk* _tmp24_ = NULL;
			gchar* _tmp25_ = NULL;
			gchar* _tmp26_ = NULL;
			const gchar* _tmp27_ = NULL;
#line 413 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp19_ = chunk;
#line 413 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp20_ = avi_chunk_read_name (_tmp19_, &_inner_error_);
#line 413 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp21_ = _tmp20_;
#line 413 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_g_free0 (_tmp21_);
#line 413 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 413 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				g_propagate_error (error, _inner_error_);
#line 413 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_g_free0 (name);
#line 413 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				return NULL;
#line 3521 "VideoMetadata.c"
			}
#line 414 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp22_ = chunk;
#line 414 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp23_ = avi_chunk_get_first_child_chunk (_tmp22_);
#line 414 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp24_ = _tmp23_;
#line 414 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp25_ = avi_metadata_loader_read_section (self, _tmp24_, &_inner_error_);
#line 414 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp26_ = _tmp25_;
#line 414 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_avi_chunk_unref0 (_tmp24_);
#line 414 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_result_ = _tmp26_;
#line 414 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 414 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				g_propagate_error (error, _inner_error_);
#line 414 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_g_free0 (name);
#line 414 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				return NULL;
#line 3545 "VideoMetadata.c"
			}
#line 415 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp27_ = _result_;
#line 415 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			if (NULL != _tmp27_) {
#line 416 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				result = _result_;
#line 416 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				_g_free0 (name);
#line 416 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				return result;
#line 3557 "VideoMetadata.c"
			}
#line 412 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_g_free0 (_result_);
#line 3561 "VideoMetadata.c"
		}
#line 420 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp28_ = chunk;
#line 420 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp29_ = avi_chunk_is_last_chunk (_tmp28_);
#line 420 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (_tmp29_) {
#line 421 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_g_free0 (name);
#line 421 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			break;
#line 3573 "VideoMetadata.c"
		}
#line 423 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp30_ = chunk;
#line 423 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		avi_chunk_next_chunk (_tmp30_, &_inner_error_);
#line 423 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 423 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			g_propagate_error (error, _inner_error_);
#line 423 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_g_free0 (name);
#line 423 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return NULL;
#line 3587 "VideoMetadata.c"
		}
#line 401 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_free0 (name);
#line 3591 "VideoMetadata.c"
	}
#line 425 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = NULL;
#line 425 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 3597 "VideoMetadata.c"
}


static gulong avi_metadata_loader_parse_date (AVIMetadataLoader* self, const gchar* sdate) {
	gulong result = 0UL;
	const gchar* _tmp0_ = NULL;
	gint _tmp1_ = 0;
	gint _tmp2_ = 0;
	GDate date = {0};
	guint seconds = 0U;
	gint year = 0;
	gint month = 0;
	gint day = 0;
	gint hour = 0;
	gint min = 0;
	gint sec = 0;
	gchar weekday[4] = {0};
	gchar monthstr[4] = {0};
	const gchar* _tmp3_ = NULL;
	gchar _tmp4_ = '\0';
	gboolean _tmp5_ = FALSE;
	struct tm time = {0};
	struct tm _tmp26_ = {0};
	time_t tm = 0;
	time_t _tmp27_ = 0;
	gulong _result_ = 0UL;
	time_t _tmp28_ = 0;
	guint _tmp29_ = 0U;
	gulong _tmp30_ = 0UL;
	time_t _tmp31_ = 0;
#line 432 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_AVI_METADATA_LOADER (self), 0UL);
#line 432 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (sdate != NULL, 0UL);
#line 433 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = sdate;
#line 433 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = strlen (_tmp0_);
#line 433 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp2_ = _tmp1_;
#line 433 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (_tmp2_ == 0) {
#line 434 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		result = (gulong) 0;
#line 434 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return result;
#line 3644 "VideoMetadata.c"
	}
#line 437 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	memset (&date, 0, sizeof (GDate));
#line 438 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	seconds = (guint) 0;
#line 443 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp3_ = sdate;
#line 443 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp4_ = string_get (_tmp3_, (glong) 0);
#line 443 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp5_ = g_ascii_isdigit (_tmp4_);
#line 443 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (_tmp5_) {
#line 3658 "VideoMetadata.c"
		gchar* tmp = NULL;
		const gchar* _tmp6_ = NULL;
		gchar* _tmp7_ = NULL;
		const gchar* _tmp8_ = NULL;
		gint _result_ = 0;
		const gchar* _tmp9_ = NULL;
		gint _tmp10_ = 0;
		gint _tmp11_ = 0;
		gint _tmp12_ = 0;
		gint _tmp13_ = 0;
		gint _tmp14_ = 0;
		gint _tmp15_ = 0;
		gint _tmp16_ = 0;
		gint _tmp17_ = 0;
#line 447 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp6_ = sdate;
#line 447 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp7_ = g_strdup (_tmp6_);
#line 447 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		tmp = _tmp7_;
#line 448 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp8_ = tmp;
#line 448 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_strcanon (_tmp8_, "0123456789 ", ' ');
#line 449 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		sec = 0;
#line 450 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp9_ = tmp;
#line 450 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp10_ = sscanf (_tmp9_, "%d %d %d %d %d %d", &year, &month, &day, &hour, &min, &sec);
#line 450 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_result_ = _tmp10_;
#line 451 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp11_ = _result_;
#line 451 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (_tmp11_ < 5) {
#line 452 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			result = (gulong) 0;
#line 452 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_g_free0 (tmp);
#line 452 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return result;
#line 3701 "VideoMetadata.c"
		}
#line 454 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp12_ = day;
#line 454 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp13_ = month;
#line 454 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp14_ = year;
#line 454 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_date_set_dmy (&date, (GDateDay) _tmp12_, (gint) ((GDateMonth) _tmp13_), (GDateYear) _tmp14_);
#line 455 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp15_ = sec;
#line 455 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp16_ = min;
#line 455 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp17_ = hour;
#line 455 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		seconds = (guint) ((_tmp15_ + (_tmp16_ * 60)) + (_tmp17_ * 3600));
#line 443 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_free0 (tmp);
#line 3721 "VideoMetadata.c"
	} else {
		const gchar* _tmp18_ = NULL;
		gint _tmp19_ = 0;
		gint _tmp20_ = 0;
		GDateMonth _tmp21_ = 0;
		gint _tmp22_ = 0;
		gint _tmp23_ = 0;
		gint _tmp24_ = 0;
		gint _tmp25_ = 0;
#line 458 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp18_ = sdate;
#line 458 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp19_ = sscanf (_tmp18_, "%3s %3s %d %d:%d:%d %d", weekday, monthstr, &day, &hour, &min, &sec, &year);
#line 458 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (7 != _tmp19_) {
#line 460 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			result = (gulong) 0;
#line 460 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return result;
#line 3741 "VideoMetadata.c"
		}
#line 462 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp20_ = day;
#line 462 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp21_ = avi_metadata_loader_month_from_string (self, (const gchar*) monthstr);
#line 462 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp22_ = year;
#line 462 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_date_set_dmy (&date, (GDateDay) _tmp20_, (gint) _tmp21_, (GDateYear) _tmp22_);
#line 463 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp23_ = sec;
#line 463 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp24_ = min;
#line 463 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp25_ = hour;
#line 463 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		seconds = (guint) ((_tmp23_ + (_tmp24_ * 60)) + (_tmp25_ * 3600));
#line 3759 "VideoMetadata.c"
	}
#line 466 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	memset (&time, 0, sizeof (struct tm));
#line 467 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_date_to_struct_tm (&date, &_tmp26_);
#line 467 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	time = _tmp26_;
#line 470 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp27_ = mktime (&time);
#line 470 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	tm = _tmp27_;
#line 471 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp28_ = tm;
#line 471 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp29_ = seconds;
#line 471 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_result_ = (gulong) (_tmp28_ + _tmp29_);
#line 472 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp30_ = _result_;
#line 472 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp31_ = tm;
#line 472 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (_tmp30_ < ((gulong) _tmp31_)) {
#line 3783 "VideoMetadata.c"
		GFile* _tmp32_ = NULL;
		gchar* _tmp33_ = NULL;
		gchar* _tmp34_ = NULL;
#line 473 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp32_ = self->priv->file;
#line 473 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp33_ = g_file_get_path (_tmp32_);
#line 473 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp34_ = _tmp33_;
#line 473 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_debug ("VideoMetadata.vala:473: Overflow for timestamp in video file %s", _tmp34_);
#line 473 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_free0 (_tmp34_);
#line 475 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		result = (gulong) 0;
#line 475 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return result;
#line 3801 "VideoMetadata.c"
	}
#line 478 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = _result_;
#line 478 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 3807 "VideoMetadata.c"
}


static GDateMonth avi_metadata_loader_month_from_string (AVIMetadataLoader* self, const gchar* s) {
	GDateMonth result = 0;
	const gchar* _tmp0_ = NULL;
	gchar* _tmp1_ = NULL;
	gchar* _tmp2_ = NULL;
	GQuark _tmp4_ = 0U;
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	static GQuark _tmp3_label0 = 0;
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	static GQuark _tmp3_label1 = 0;
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	static GQuark _tmp3_label2 = 0;
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	static GQuark _tmp3_label3 = 0;
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	static GQuark _tmp3_label4 = 0;
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	static GQuark _tmp3_label5 = 0;
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	static GQuark _tmp3_label6 = 0;
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	static GQuark _tmp3_label7 = 0;
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	static GQuark _tmp3_label8 = 0;
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	static GQuark _tmp3_label9 = 0;
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	static GQuark _tmp3_label10 = 0;
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	static GQuark _tmp3_label11 = 0;
#line 481 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_AVI_METADATA_LOADER (self), 0);
#line 481 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (s != NULL, 0);
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = s;
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = g_utf8_strdown (_tmp0_, (gssize) -1);
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp2_ = _tmp1_;
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp4_ = (NULL == _tmp2_) ? 0 : g_quark_from_string (_tmp2_);
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_free (_tmp2_);
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (_tmp4_ == ((0 != _tmp3_label0) ? _tmp3_label0 : (_tmp3_label0 = g_quark_from_static_string ("jan")))) {
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		switch (0) {
#line 3859 "VideoMetadata.c"
			default:
			{
#line 484 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				result = G_DATE_JANUARY;
#line 484 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				return result;
#line 3866 "VideoMetadata.c"
			}
		}
	} else if (_tmp4_ == ((0 != _tmp3_label1) ? _tmp3_label1 : (_tmp3_label1 = g_quark_from_static_string ("feb")))) {
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		switch (0) {
#line 3872 "VideoMetadata.c"
			default:
			{
#line 486 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				result = G_DATE_FEBRUARY;
#line 486 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				return result;
#line 3879 "VideoMetadata.c"
			}
		}
	} else if (_tmp4_ == ((0 != _tmp3_label2) ? _tmp3_label2 : (_tmp3_label2 = g_quark_from_static_string ("mar")))) {
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		switch (0) {
#line 3885 "VideoMetadata.c"
			default:
			{
#line 488 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				result = G_DATE_MARCH;
#line 488 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				return result;
#line 3892 "VideoMetadata.c"
			}
		}
	} else if (_tmp4_ == ((0 != _tmp3_label3) ? _tmp3_label3 : (_tmp3_label3 = g_quark_from_static_string ("apr")))) {
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		switch (0) {
#line 3898 "VideoMetadata.c"
			default:
			{
#line 490 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				result = G_DATE_APRIL;
#line 490 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				return result;
#line 3905 "VideoMetadata.c"
			}
		}
	} else if (_tmp4_ == ((0 != _tmp3_label4) ? _tmp3_label4 : (_tmp3_label4 = g_quark_from_static_string ("may")))) {
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		switch (0) {
#line 3911 "VideoMetadata.c"
			default:
			{
#line 492 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				result = G_DATE_MAY;
#line 492 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				return result;
#line 3918 "VideoMetadata.c"
			}
		}
	} else if (_tmp4_ == ((0 != _tmp3_label5) ? _tmp3_label5 : (_tmp3_label5 = g_quark_from_static_string ("jun")))) {
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		switch (0) {
#line 3924 "VideoMetadata.c"
			default:
			{
#line 494 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				result = G_DATE_JUNE;
#line 494 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				return result;
#line 3931 "VideoMetadata.c"
			}
		}
	} else if (_tmp4_ == ((0 != _tmp3_label6) ? _tmp3_label6 : (_tmp3_label6 = g_quark_from_static_string ("jul")))) {
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		switch (0) {
#line 3937 "VideoMetadata.c"
			default:
			{
#line 496 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				result = G_DATE_JULY;
#line 496 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				return result;
#line 3944 "VideoMetadata.c"
			}
		}
	} else if (_tmp4_ == ((0 != _tmp3_label7) ? _tmp3_label7 : (_tmp3_label7 = g_quark_from_static_string ("aug")))) {
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		switch (0) {
#line 3950 "VideoMetadata.c"
			default:
			{
#line 498 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				result = G_DATE_AUGUST;
#line 498 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				return result;
#line 3957 "VideoMetadata.c"
			}
		}
	} else if (_tmp4_ == ((0 != _tmp3_label8) ? _tmp3_label8 : (_tmp3_label8 = g_quark_from_static_string ("sep")))) {
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		switch (0) {
#line 3963 "VideoMetadata.c"
			default:
			{
#line 500 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				result = G_DATE_SEPTEMBER;
#line 500 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				return result;
#line 3970 "VideoMetadata.c"
			}
		}
	} else if (_tmp4_ == ((0 != _tmp3_label9) ? _tmp3_label9 : (_tmp3_label9 = g_quark_from_static_string ("oct")))) {
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		switch (0) {
#line 3976 "VideoMetadata.c"
			default:
			{
#line 502 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				result = G_DATE_OCTOBER;
#line 502 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				return result;
#line 3983 "VideoMetadata.c"
			}
		}
	} else if (_tmp4_ == ((0 != _tmp3_label10) ? _tmp3_label10 : (_tmp3_label10 = g_quark_from_static_string ("nov")))) {
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		switch (0) {
#line 3989 "VideoMetadata.c"
			default:
			{
#line 504 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				result = G_DATE_NOVEMBER;
#line 504 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				return result;
#line 3996 "VideoMetadata.c"
			}
		}
	} else if (_tmp4_ == ((0 != _tmp3_label11) ? _tmp3_label11 : (_tmp3_label11 = g_quark_from_static_string ("dec")))) {
#line 482 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		switch (0) {
#line 4002 "VideoMetadata.c"
			default:
			{
#line 506 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				result = G_DATE_DECEMBER;
#line 506 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
				return result;
#line 4009 "VideoMetadata.c"
			}
		}
	}
#line 508 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = G_DATE_BAD_MONTH;
#line 508 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 4017 "VideoMetadata.c"
}


static gchar* string_strip (const gchar* self) {
	gchar* result = NULL;
	gchar* _result_ = NULL;
	gchar* _tmp0_ = NULL;
	const gchar* _tmp1_ = NULL;
#line 1207 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	g_return_val_if_fail (self != NULL, NULL);
#line 1208 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	_tmp0_ = g_strdup (self);
#line 1208 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	_result_ = _tmp0_;
#line 1209 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	_tmp1_ = _result_;
#line 1209 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	g_strstrip (_tmp1_);
#line 1210 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	result = _result_;
#line 1210 "/usr/share/vala-0.34/vapi/glib-2.0.vapi"
	return result;
#line 4040 "VideoMetadata.c"
}


static gulong avi_metadata_loader_get_creation_date_time_for_avi (AVIMetadataLoader* self) {
	gulong result = 0UL;
	AVIChunk* chunk = NULL;
	GFile* _tmp0_ = NULL;
	AVIChunk* _tmp1_ = NULL;
	gulong timestamp = 0UL;
	GError * _inner_error_ = NULL;
#line 511 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_AVI_METADATA_LOADER (self), 0UL);
#line 512 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = self->priv->file;
#line 512 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = avi_chunk_new (_tmp0_);
#line 512 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	chunk = _tmp1_;
#line 513 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	timestamp = (gulong) 0;
#line 4061 "VideoMetadata.c"
	{
		AVIChunk* _tmp2_ = NULL;
		AVIChunk* _tmp3_ = NULL;
		gchar* sdate = NULL;
		AVIChunk* _tmp4_ = NULL;
		gchar* _tmp5_ = NULL;
		const gchar* _tmp6_ = NULL;
#line 515 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp2_ = chunk;
#line 515 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		avi_chunk_open_file (_tmp2_, &_inner_error_);
#line 515 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 4075 "VideoMetadata.c"
			goto __catch579_g_error;
		}
#line 516 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp3_ = chunk;
#line 516 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		avi_chunk_nonsection_skip (_tmp3_, (guint64) 12, &_inner_error_);
#line 516 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 4084 "VideoMetadata.c"
			goto __catch579_g_error;
		}
#line 517 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp4_ = chunk;
#line 517 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp5_ = avi_metadata_loader_read_section (self, _tmp4_, &_inner_error_);
#line 517 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		sdate = _tmp5_;
#line 517 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 4095 "VideoMetadata.c"
			goto __catch579_g_error;
		}
#line 518 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp6_ = sdate;
#line 518 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (NULL != _tmp6_) {
#line 4102 "VideoMetadata.c"
			const gchar* _tmp7_ = NULL;
			gchar* _tmp8_ = NULL;
			gchar* _tmp9_ = NULL;
			gulong _tmp10_ = 0UL;
#line 519 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp7_ = sdate;
#line 519 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp8_ = string_strip (_tmp7_);
#line 519 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp9_ = _tmp8_;
#line 519 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp10_ = avi_metadata_loader_parse_date (self, _tmp9_);
#line 519 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			timestamp = _tmp10_;
#line 519 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_g_free0 (_tmp9_);
#line 4119 "VideoMetadata.c"
		}
#line 514 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_free0 (sdate);
#line 4123 "VideoMetadata.c"
	}
	goto __finally579;
	__catch579_g_error:
	{
		GError* e = NULL;
		GError* _tmp11_ = NULL;
		const gchar* _tmp12_ = NULL;
#line 514 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		e = _inner_error_;
#line 514 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_inner_error_ = NULL;
#line 522 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp11_ = e;
#line 522 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp12_ = _tmp11_->message;
#line 522 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_debug ("VideoMetadata.vala:522: Error while reading AVI file: %s", _tmp12_);
#line 514 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_error_free0 (e);
#line 4143 "VideoMetadata.c"
	}
	__finally579:
#line 514 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 514 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_avi_chunk_unref0 (chunk);
#line 514 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 514 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_clear_error (&_inner_error_);
#line 514 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return 0UL;
#line 4156 "VideoMetadata.c"
	}
	{
		AVIChunk* _tmp13_ = NULL;
#line 526 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp13_ = chunk;
#line 526 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		avi_chunk_close_file (_tmp13_, &_inner_error_);
#line 526 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 4166 "VideoMetadata.c"
			goto __catch580_g_error;
		}
	}
	goto __finally580;
	__catch580_g_error:
	{
		GError* e = NULL;
		GError* _tmp14_ = NULL;
		const gchar* _tmp15_ = NULL;
#line 525 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		e = _inner_error_;
#line 525 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_inner_error_ = NULL;
#line 528 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp14_ = e;
#line 528 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp15_ = _tmp14_->message;
#line 528 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_debug ("VideoMetadata.vala:528: Error while closing AVI file: %s", _tmp15_);
#line 525 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_error_free0 (e);
#line 4188 "VideoMetadata.c"
	}
	__finally580:
#line 525 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 525 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_avi_chunk_unref0 (chunk);
#line 525 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
#line 525 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_clear_error (&_inner_error_);
#line 525 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return 0UL;
#line 4201 "VideoMetadata.c"
	}
#line 530 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = timestamp;
#line 530 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_avi_chunk_unref0 (chunk);
#line 530 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 4209 "VideoMetadata.c"
}


static void value_avi_metadata_loader_init (GValue* value) {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	value->data[0].v_pointer = NULL;
#line 4216 "VideoMetadata.c"
}


static void value_avi_metadata_loader_free_value (GValue* value) {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (value->data[0].v_pointer) {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		avi_metadata_loader_unref (value->data[0].v_pointer);
#line 4225 "VideoMetadata.c"
	}
}


static void value_avi_metadata_loader_copy_value (const GValue* src_value, GValue* dest_value) {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (src_value->data[0].v_pointer) {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		dest_value->data[0].v_pointer = avi_metadata_loader_ref (src_value->data[0].v_pointer);
#line 4235 "VideoMetadata.c"
	} else {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		dest_value->data[0].v_pointer = NULL;
#line 4239 "VideoMetadata.c"
	}
}


static gpointer value_avi_metadata_loader_peek_pointer (const GValue* value) {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return value->data[0].v_pointer;
#line 4247 "VideoMetadata.c"
}


static gchar* value_avi_metadata_loader_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (collect_values[0].v_pointer) {
#line 4254 "VideoMetadata.c"
		AVIMetadataLoader* object;
		object = collect_values[0].v_pointer;
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (object->parent_instance.g_class == NULL) {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
#line 4261 "VideoMetadata.c"
		} else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
#line 4265 "VideoMetadata.c"
		}
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = avi_metadata_loader_ref (object);
#line 4269 "VideoMetadata.c"
	} else {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = NULL;
#line 4273 "VideoMetadata.c"
	}
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return NULL;
#line 4277 "VideoMetadata.c"
}


static gchar* value_avi_metadata_loader_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
	AVIMetadataLoader** object_p;
	object_p = collect_values[0].v_pointer;
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (!object_p) {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value));
#line 4288 "VideoMetadata.c"
	}
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (!value->data[0].v_pointer) {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		*object_p = NULL;
#line 4294 "VideoMetadata.c"
	} else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		*object_p = value->data[0].v_pointer;
#line 4298 "VideoMetadata.c"
	} else {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		*object_p = avi_metadata_loader_ref (value->data[0].v_pointer);
#line 4302 "VideoMetadata.c"
	}
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return NULL;
#line 4306 "VideoMetadata.c"
}


GParamSpec* param_spec_avi_metadata_loader (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) {
	ParamSpecAVIMetadataLoader* spec;
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (g_type_is_a (object_type, TYPE_AVI_METADATA_LOADER), NULL);
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags);
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	G_PARAM_SPEC (spec)->value_type = object_type;
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return G_PARAM_SPEC (spec);
#line 4320 "VideoMetadata.c"
}


gpointer value_get_avi_metadata_loader (const GValue* value) {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_AVI_METADATA_LOADER), NULL);
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return value->data[0].v_pointer;
#line 4329 "VideoMetadata.c"
}


void value_set_avi_metadata_loader (GValue* value, gpointer v_object) {
	AVIMetadataLoader* old;
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_AVI_METADATA_LOADER));
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	old = value->data[0].v_pointer;
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (v_object) {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_AVI_METADATA_LOADER));
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value)));
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = v_object;
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		avi_metadata_loader_ref (value->data[0].v_pointer);
#line 4349 "VideoMetadata.c"
	} else {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = NULL;
#line 4353 "VideoMetadata.c"
	}
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (old) {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		avi_metadata_loader_unref (old);
#line 4359 "VideoMetadata.c"
	}
}


void value_take_avi_metadata_loader (GValue* value, gpointer v_object) {
	AVIMetadataLoader* old;
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_AVI_METADATA_LOADER));
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	old = value->data[0].v_pointer;
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (v_object) {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_AVI_METADATA_LOADER));
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value)));
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = v_object;
#line 4378 "VideoMetadata.c"
	} else {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = NULL;
#line 4382 "VideoMetadata.c"
	}
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (old) {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		avi_metadata_loader_unref (old);
#line 4388 "VideoMetadata.c"
	}
}


static void avi_metadata_loader_class_init (AVIMetadataLoaderClass * klass) {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	avi_metadata_loader_parent_class = g_type_class_peek_parent (klass);
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	((AVIMetadataLoaderClass *) klass)->finalize = avi_metadata_loader_finalize;
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_type_class_add_private (klass, sizeof (AVIMetadataLoaderPrivate));
#line 4400 "VideoMetadata.c"
}


static void avi_metadata_loader_instance_init (AVIMetadataLoader * self) {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv = AVI_METADATA_LOADER_GET_PRIVATE (self);
#line 294 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->file = NULL;
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->ref_count = 1;
#line 4411 "VideoMetadata.c"
}


static void avi_metadata_loader_finalize (AVIMetadataLoader* obj) {
	AVIMetadataLoader * self;
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_AVI_METADATA_LOADER, AVIMetadataLoader);
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_signal_handlers_destroy (self);
#line 294 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_object_unref0 (self->priv->file);
#line 4423 "VideoMetadata.c"
}


GType avi_metadata_loader_get_type (void) {
	static volatile gsize avi_metadata_loader_type_id__volatile = 0;
	if (g_once_init_enter (&avi_metadata_loader_type_id__volatile)) {
		static const GTypeValueTable g_define_type_value_table = { value_avi_metadata_loader_init, value_avi_metadata_loader_free_value, value_avi_metadata_loader_copy_value, value_avi_metadata_loader_peek_pointer, "p", value_avi_metadata_loader_collect_value, "p", value_avi_metadata_loader_lcopy_value };
		static const GTypeInfo g_define_type_info = { sizeof (AVIMetadataLoaderClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) avi_metadata_loader_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (AVIMetadataLoader), 0, (GInstanceInitFunc) avi_metadata_loader_instance_init, &g_define_type_value_table };
		static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) };
		GType avi_metadata_loader_type_id;
		avi_metadata_loader_type_id = g_type_register_fundamental (g_type_fundamental_next (), "AVIMetadataLoader", &g_define_type_info, &g_define_type_fundamental_info, 0);
		g_once_init_leave (&avi_metadata_loader_type_id__volatile, avi_metadata_loader_type_id);
	}
	return avi_metadata_loader_type_id__volatile;
}


gpointer avi_metadata_loader_ref (gpointer instance) {
	AVIMetadataLoader* self;
	self = instance;
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_atomic_int_inc (&self->ref_count);
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return instance;
#line 4448 "VideoMetadata.c"
}


void avi_metadata_loader_unref (gpointer instance) {
	AVIMetadataLoader* self;
	self = instance;
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (g_atomic_int_dec_and_test (&self->ref_count)) {
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		AVI_METADATA_LOADER_GET_CLASS (self)->finalize (self);
#line 292 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_type_free_instance ((GTypeInstance *) self);
#line 4461 "VideoMetadata.c"
	}
}


AVIChunk* avi_chunk_construct (GType object_type, GFile* file) {
	AVIChunk* self = NULL;
	GFile* _tmp0_ = NULL;
	GFile* _tmp1_ = NULL;
#line 543 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (G_IS_FILE (file), NULL);
#line 543 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self = (AVIChunk*) g_type_create_instance (object_type);
#line 544 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = file;
#line 544 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = _g_object_ref0 (_tmp0_);
#line 544 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_object_unref0 (self->priv->file);
#line 544 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->file = _tmp1_;
#line 543 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return self;
#line 4484 "VideoMetadata.c"
}


AVIChunk* avi_chunk_new (GFile* file) {
#line 543 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return avi_chunk_construct (TYPE_AVI_CHUNK, file);
#line 4491 "VideoMetadata.c"
}


static gpointer _avi_chunk_ref0 (gpointer self) {
#line 549 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return self ? avi_chunk_ref (self) : NULL;
#line 4498 "VideoMetadata.c"
}


static AVIChunk* avi_chunk_construct_with_input_stream (GType object_type, GDataInputStream* input, AVIChunk* parent) {
	AVIChunk* self = NULL;
	GDataInputStream* _tmp0_ = NULL;
	GDataInputStream* _tmp1_ = NULL;
	AVIChunk* _tmp2_ = NULL;
	AVIChunk* _tmp3_ = NULL;
#line 547 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (G_IS_DATA_INPUT_STREAM (input), NULL);
#line 547 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_AVI_CHUNK (parent), NULL);
#line 547 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self = (AVIChunk*) g_type_create_instance (object_type);
#line 548 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = input;
#line 548 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = _g_object_ref0 (_tmp0_);
#line 548 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_object_unref0 (self->priv->input);
#line 548 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->input = _tmp1_;
#line 549 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp2_ = parent;
#line 549 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp3_ = _avi_chunk_ref0 (_tmp2_);
#line 549 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_avi_chunk_unref0 (self->priv->parent);
#line 549 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->parent = _tmp3_;
#line 547 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return self;
#line 4532 "VideoMetadata.c"
}


static AVIChunk* avi_chunk_new_with_input_stream (GDataInputStream* input, AVIChunk* parent) {
#line 547 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return avi_chunk_construct_with_input_stream (TYPE_AVI_CHUNK, input, parent);
#line 4539 "VideoMetadata.c"
}


void avi_chunk_open_file (AVIChunk* self, GError** error) {
	GFileInputStream* _tmp0_ = NULL;
	GFile* _tmp1_ = NULL;
	GFileInputStream* _tmp2_ = NULL;
	GDataInputStream* _tmp3_ = NULL;
	GDataInputStream* _tmp4_ = NULL;
	gchar* _tmp5_ = NULL;
	GError * _inner_error_ = NULL;
#line 552 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (IS_AVI_CHUNK (self));
#line 553 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	avi_chunk_close_file (self, &_inner_error_);
#line 553 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 553 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 553 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 4561 "VideoMetadata.c"
	}
#line 554 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = self->priv->file;
#line 554 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp2_ = g_file_read (_tmp1_, NULL, &_inner_error_);
#line 554 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = _tmp2_;
#line 554 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 554 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 554 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 4575 "VideoMetadata.c"
	}
#line 554 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp3_ = g_data_input_stream_new (G_TYPE_CHECK_INSTANCE_CAST (_tmp0_, g_input_stream_get_type (), GInputStream));
#line 554 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_object_unref0 (self->priv->input);
#line 554 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->input = _tmp3_;
#line 555 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp4_ = self->priv->input;
#line 555 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_data_input_stream_set_byte_order (_tmp4_, G_DATA_STREAM_BYTE_ORDER_LITTLE_ENDIAN);
#line 556 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_size = (guint64) 0;
#line 557 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_offset = (guint64) 0;
#line 558 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp5_ = g_strdup ("");
#line 558 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_free0 (self->priv->section_name);
#line 558 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_name = _tmp5_;
#line 552 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_object_unref0 (_tmp0_);
#line 4599 "VideoMetadata.c"
}


void avi_chunk_close_file (AVIChunk* self, GError** error) {
	GDataInputStream* _tmp0_ = NULL;
	GError * _inner_error_ = NULL;
#line 561 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (IS_AVI_CHUNK (self));
#line 562 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = self->priv->input;
#line 562 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (NULL != _tmp0_) {
#line 4612 "VideoMetadata.c"
		GDataInputStream* _tmp1_ = NULL;
#line 563 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp1_ = self->priv->input;
#line 563 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_input_stream_close (G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, g_input_stream_get_type (), GInputStream), NULL, &_inner_error_);
#line 563 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 563 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			g_propagate_error (error, _inner_error_);
#line 563 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return;
#line 4624 "VideoMetadata.c"
		}
#line 564 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_object_unref0 (self->priv->input);
#line 564 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		self->priv->input = NULL;
#line 4630 "VideoMetadata.c"
	}
}


void avi_chunk_nonsection_skip (AVIChunk* self, guint64 skip_amount, GError** error) {
	GDataInputStream* _tmp0_ = NULL;
	guint64 _tmp1_ = 0ULL;
	GError * _inner_error_ = NULL;
#line 568 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (IS_AVI_CHUNK (self));
#line 569 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = self->priv->input;
#line 569 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = skip_amount;
#line 569 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	skip_uint64 (G_TYPE_CHECK_INSTANCE_CAST (_tmp0_, g_input_stream_get_type (), GInputStream), _tmp1_, &_inner_error_);
#line 569 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 569 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 569 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 4653 "VideoMetadata.c"
	}
}


void avi_chunk_skip (AVIChunk* self, guint64 skip_amount, GError** error) {
	guint64 _tmp0_ = 0ULL;
	GDataInputStream* _tmp1_ = NULL;
	guint64 _tmp2_ = 0ULL;
	GError * _inner_error_ = NULL;
#line 572 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (IS_AVI_CHUNK (self));
#line 573 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = skip_amount;
#line 573 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	avi_chunk_advance_section_offset (self, _tmp0_);
#line 574 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = self->priv->input;
#line 574 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp2_ = skip_amount;
#line 574 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	skip_uint64 (G_TYPE_CHECK_INSTANCE_CAST (_tmp1_, g_input_stream_get_type (), GInputStream), _tmp2_, &_inner_error_);
#line 574 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 574 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 574 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 4681 "VideoMetadata.c"
	}
}


AVIChunk* avi_chunk_get_first_child_chunk (AVIChunk* self) {
	AVIChunk* result = NULL;
	GDataInputStream* _tmp0_ = NULL;
	AVIChunk* _tmp1_ = NULL;
#line 577 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_AVI_CHUNK (self), NULL);
#line 578 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = self->priv->input;
#line 578 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = avi_chunk_new_with_input_stream (_tmp0_, self);
#line 578 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = _tmp1_;
#line 578 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 4700 "VideoMetadata.c"
}


static void avi_chunk_advance_section_offset (AVIChunk* self, guint64 amount) {
	guint64 _tmp0_ = 0ULL;
	guint64 _tmp1_ = 0ULL;
	guint64 _tmp2_ = 0ULL;
	guint64 _tmp5_ = 0ULL;
	guint64 _tmp6_ = 0ULL;
	AVIChunk* _tmp7_ = NULL;
#line 581 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (IS_AVI_CHUNK (self));
#line 582 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = self->priv->section_offset;
#line 582 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = amount;
#line 582 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp2_ = self->priv->section_size;
#line 582 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if ((_tmp0_ + _tmp1_) > _tmp2_) {
#line 4721 "VideoMetadata.c"
		guint64 _tmp3_ = 0ULL;
		guint64 _tmp4_ = 0ULL;
#line 583 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp3_ = self->priv->section_size;
#line 583 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp4_ = self->priv->section_offset;
#line 583 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		amount = _tmp3_ - _tmp4_;
#line 4730 "VideoMetadata.c"
	}
#line 585 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp5_ = self->priv->section_offset;
#line 585 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp6_ = amount;
#line 585 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_offset = _tmp5_ + _tmp6_;
#line 586 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp7_ = self->priv->parent;
#line 586 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (NULL != _tmp7_) {
#line 4742 "VideoMetadata.c"
		AVIChunk* _tmp8_ = NULL;
		guint64 _tmp9_ = 0ULL;
#line 587 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp8_ = self->priv->parent;
#line 587 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp9_ = amount;
#line 587 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		avi_chunk_advance_section_offset (_tmp8_, _tmp9_);
#line 4751 "VideoMetadata.c"
	}
}


guchar avi_chunk_read_byte (AVIChunk* self, GError** error) {
	guchar result = '\0';
	guint8 _tmp0_ = 0U;
	GDataInputStream* _tmp1_ = NULL;
	guint8 _tmp2_ = 0U;
	GError * _inner_error_ = NULL;
#line 591 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_AVI_CHUNK (self), '\0');
#line 592 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	avi_chunk_advance_section_offset (self, (guint64) 1);
#line 593 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = self->priv->input;
#line 593 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp2_ = g_data_input_stream_read_byte (_tmp1_, NULL, &_inner_error_);
#line 593 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = _tmp2_;
#line 593 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 593 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 593 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return '\0';
#line 4778 "VideoMetadata.c"
	}
#line 593 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = (guchar) _tmp0_;
#line 593 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 4784 "VideoMetadata.c"
}


guint16 avi_chunk_read_uint16 (AVIChunk* self, GError** error) {
	guint16 result = 0U;
	guint16 _tmp0_ = 0U;
	GDataInputStream* _tmp1_ = NULL;
	guint16 _tmp2_ = 0U;
	GError * _inner_error_ = NULL;
#line 596 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_AVI_CHUNK (self), 0U);
#line 597 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	avi_chunk_advance_section_offset (self, (guint64) 2);
#line 598 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = self->priv->input;
#line 598 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp2_ = g_data_input_stream_read_uint16 (_tmp1_, NULL, &_inner_error_);
#line 598 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = _tmp2_;
#line 598 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 598 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 598 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return 0U;
#line 4810 "VideoMetadata.c"
	}
#line 598 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = _tmp0_;
#line 598 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 4816 "VideoMetadata.c"
}


void avi_chunk_read_chunk (AVIChunk* self, GError** error) {
	GString* sb = NULL;
	GString* _tmp0_ = NULL;
	guint8 _tmp1_ = 0U;
	GDataInputStream* _tmp2_ = NULL;
	guint8 _tmp3_ = 0U;
	GString* _tmp4_ = NULL;
	guint8 _tmp5_ = 0U;
	GDataInputStream* _tmp6_ = NULL;
	guint8 _tmp7_ = 0U;
	GString* _tmp8_ = NULL;
	guint8 _tmp9_ = 0U;
	GDataInputStream* _tmp10_ = NULL;
	guint8 _tmp11_ = 0U;
	GString* _tmp12_ = NULL;
	guint8 _tmp13_ = 0U;
	GDataInputStream* _tmp14_ = NULL;
	guint8 _tmp15_ = 0U;
	GString* _tmp16_ = NULL;
	GString* _tmp17_ = NULL;
	const gchar* _tmp18_ = NULL;
	gchar* _tmp19_ = NULL;
	guint32 _tmp20_ = 0U;
	GDataInputStream* _tmp21_ = NULL;
	guint32 _tmp22_ = 0U;
	GError * _inner_error_ = NULL;
#line 601 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (IS_AVI_CHUNK (self));
#line 604 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = g_string_new ("");
#line 604 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	sb = _tmp0_;
#line 605 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp2_ = self->priv->input;
#line 605 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp3_ = g_data_input_stream_read_byte (_tmp2_, NULL, &_inner_error_);
#line 605 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = _tmp3_;
#line 605 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 605 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 605 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_string_free0 (sb);
#line 605 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 4866 "VideoMetadata.c"
	}
#line 605 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp4_ = sb;
#line 605 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_string_append_c (_tmp4_, (gchar) _tmp1_);
#line 606 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp6_ = self->priv->input;
#line 606 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp7_ = g_data_input_stream_read_byte (_tmp6_, NULL, &_inner_error_);
#line 606 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp5_ = _tmp7_;
#line 606 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 606 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 606 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_string_free0 (sb);
#line 606 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 4886 "VideoMetadata.c"
	}
#line 606 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp8_ = sb;
#line 606 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_string_append_c (_tmp8_, (gchar) _tmp5_);
#line 607 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp10_ = self->priv->input;
#line 607 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp11_ = g_data_input_stream_read_byte (_tmp10_, NULL, &_inner_error_);
#line 607 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp9_ = _tmp11_;
#line 607 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 607 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 607 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_string_free0 (sb);
#line 607 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 4906 "VideoMetadata.c"
	}
#line 607 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp12_ = sb;
#line 607 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_string_append_c (_tmp12_, (gchar) _tmp9_);
#line 608 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp14_ = self->priv->input;
#line 608 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp15_ = g_data_input_stream_read_byte (_tmp14_, NULL, &_inner_error_);
#line 608 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp13_ = _tmp15_;
#line 608 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 608 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 608 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_string_free0 (sb);
#line 608 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 4926 "VideoMetadata.c"
	}
#line 608 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp16_ = sb;
#line 608 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_string_append_c (_tmp16_, (gchar) _tmp13_);
#line 609 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp17_ = sb;
#line 609 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp18_ = _tmp17_->str;
#line 609 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp19_ = g_strdup (_tmp18_);
#line 609 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_free0 (self->priv->section_name);
#line 609 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_name = _tmp19_;
#line 610 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp21_ = self->priv->input;
#line 610 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp22_ = g_data_input_stream_read_uint32 (_tmp21_, NULL, &_inner_error_);
#line 610 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp20_ = _tmp22_;
#line 610 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 610 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 610 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_string_free0 (sb);
#line 610 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 4956 "VideoMetadata.c"
	}
#line 610 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_size = (guint64) _tmp20_;
#line 611 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_offset = (guint64) 0;
#line 601 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_string_free0 (sb);
#line 4964 "VideoMetadata.c"
}


gchar* avi_chunk_read_name (AVIChunk* self, GError** error) {
	gchar* result = NULL;
	GString* sb = NULL;
	GString* _tmp0_ = NULL;
	guchar _tmp1_ = '\0';
	guchar _tmp2_ = '\0';
	GString* _tmp3_ = NULL;
	guchar _tmp4_ = '\0';
	guchar _tmp5_ = '\0';
	GString* _tmp6_ = NULL;
	guchar _tmp7_ = '\0';
	guchar _tmp8_ = '\0';
	GString* _tmp9_ = NULL;
	guchar _tmp10_ = '\0';
	guchar _tmp11_ = '\0';
	GString* _tmp12_ = NULL;
	GString* _tmp13_ = NULL;
	const gchar* _tmp14_ = NULL;
	gchar* _tmp15_ = NULL;
	GError * _inner_error_ = NULL;
#line 614 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_AVI_CHUNK (self), NULL);
#line 615 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = g_string_new ("");
#line 615 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	sb = _tmp0_;
#line 616 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp2_ = avi_chunk_read_byte (self, &_inner_error_);
#line 616 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = _tmp2_;
#line 616 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 616 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 616 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_string_free0 (sb);
#line 616 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return NULL;
#line 5006 "VideoMetadata.c"
	}
#line 616 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp3_ = sb;
#line 616 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_string_append_c (_tmp3_, (gchar) _tmp1_);
#line 617 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp5_ = avi_chunk_read_byte (self, &_inner_error_);
#line 617 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp4_ = _tmp5_;
#line 617 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 617 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 617 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_string_free0 (sb);
#line 617 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return NULL;
#line 5024 "VideoMetadata.c"
	}
#line 617 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp6_ = sb;
#line 617 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_string_append_c (_tmp6_, (gchar) _tmp4_);
#line 618 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp8_ = avi_chunk_read_byte (self, &_inner_error_);
#line 618 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp7_ = _tmp8_;
#line 618 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 618 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 618 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_string_free0 (sb);
#line 618 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return NULL;
#line 5042 "VideoMetadata.c"
	}
#line 618 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp9_ = sb;
#line 618 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_string_append_c (_tmp9_, (gchar) _tmp7_);
#line 619 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp11_ = avi_chunk_read_byte (self, &_inner_error_);
#line 619 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp10_ = _tmp11_;
#line 619 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 619 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 619 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_g_string_free0 (sb);
#line 619 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return NULL;
#line 5060 "VideoMetadata.c"
	}
#line 619 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp12_ = sb;
#line 619 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_string_append_c (_tmp12_, (gchar) _tmp10_);
#line 620 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp13_ = sb;
#line 620 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp14_ = _tmp13_->str;
#line 620 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp15_ = g_strdup (_tmp14_);
#line 620 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = _tmp15_;
#line 620 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_string_free0 (sb);
#line 620 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 5078 "VideoMetadata.c"
}


void avi_chunk_next_chunk (AVIChunk* self, GError** error) {
	guint64 _tmp0_ = 0ULL;
	GError * _inner_error_ = NULL;
#line 623 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (IS_AVI_CHUNK (self));
#line 624 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = avi_chunk_section_size_remaining (self);
#line 624 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	avi_chunk_skip (self, _tmp0_, &_inner_error_);
#line 624 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 624 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_propagate_error (error, _inner_error_);
#line 624 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return;
#line 5097 "VideoMetadata.c"
	}
#line 625 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_size = (guint64) 0;
#line 626 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_offset = (guint64) 0;
#line 5103 "VideoMetadata.c"
}


gchar* avi_chunk_get_current_chunk_name (AVIChunk* self) {
	gchar* result = NULL;
	const gchar* _tmp0_ = NULL;
	gchar* _tmp1_ = NULL;
#line 629 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_AVI_CHUNK (self), NULL);
#line 630 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = self->priv->section_name;
#line 630 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = g_strdup (_tmp0_);
#line 630 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = _tmp1_;
#line 630 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 5121 "VideoMetadata.c"
}


gboolean avi_chunk_is_last_chunk (AVIChunk* self) {
	gboolean result = FALSE;
	guint64 _tmp0_ = 0ULL;
#line 633 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_AVI_CHUNK (self), FALSE);
#line 634 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = self->priv->section_size;
#line 634 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = _tmp0_ == ((guint64) 0);
#line 634 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 5136 "VideoMetadata.c"
}


guint64 avi_chunk_section_size_remaining (AVIChunk* self) {
	guint64 result = 0ULL;
	guint64 _tmp0_ = 0ULL;
	guint64 _tmp1_ = 0ULL;
	guint64 _tmp2_ = 0ULL;
	guint64 _tmp3_ = 0ULL;
#line 637 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_AVI_CHUNK (self), 0ULL);
#line 638 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = self->priv->section_size;
#line 638 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp1_ = self->priv->section_offset;
#line 638 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_vala_assert (_tmp0_ >= _tmp1_, "section_size >= section_offset");
#line 639 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp2_ = self->priv->section_size;
#line 639 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp3_ = self->priv->section_offset;
#line 639 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = _tmp2_ - _tmp3_;
#line 639 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 5162 "VideoMetadata.c"
}


gchar* avi_chunk_section_to_string (AVIChunk* self, GError** error) {
	gchar* result = NULL;
	GString* sb = NULL;
	GString* _tmp0_ = NULL;
	GString* _tmp11_ = NULL;
	const gchar* _tmp12_ = NULL;
	gchar* _tmp13_ = NULL;
	GError * _inner_error_ = NULL;
#line 643 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (IS_AVI_CHUNK (self), NULL);
#line 644 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = g_string_new ("");
#line 644 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	sb = _tmp0_;
#line 645 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	while (TRUE) {
#line 5182 "VideoMetadata.c"
		guint64 _tmp1_ = 0ULL;
		guint64 _tmp2_ = 0ULL;
		guchar _tmp3_ = '\0';
		guchar _tmp4_ = '\0';
		GString* _tmp5_ = NULL;
		GString* _tmp6_ = NULL;
		gssize _tmp7_ = 0L;
#line 645 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp1_ = self->priv->section_offset;
#line 645 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp2_ = self->priv->section_size;
#line 645 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (!(_tmp1_ < _tmp2_)) {
#line 645 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			break;
#line 5198 "VideoMetadata.c"
		}
#line 646 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp4_ = avi_chunk_read_byte (self, &_inner_error_);
#line 646 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp3_ = _tmp4_;
#line 646 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (G_UNLIKELY (_inner_error_ != NULL)) {
#line 646 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			g_propagate_error (error, _inner_error_);
#line 646 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_g_string_free0 (sb);
#line 646 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return NULL;
#line 5212 "VideoMetadata.c"
		}
#line 646 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp5_ = sb;
#line 646 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_string_append_c (_tmp5_, (gchar) _tmp3_);
#line 647 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp6_ = sb;
#line 647 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		_tmp7_ = _tmp6_->len;
#line 647 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (_tmp7_ > ((gssize) AVI_CHUNK_MAX_STRING_TO_SECTION_LENGTH)) {
#line 5224 "VideoMetadata.c"
			GString* _tmp8_ = NULL;
			const gchar* _tmp9_ = NULL;
			gchar* _tmp10_ = NULL;
#line 648 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp8_ = sb;
#line 648 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp9_ = _tmp8_->str;
#line 648 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_tmp10_ = g_strdup (_tmp9_);
#line 648 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			result = _tmp10_;
#line 648 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			_g_string_free0 (sb);
#line 648 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return result;
#line 5240 "VideoMetadata.c"
		}
	}
#line 651 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp11_ = sb;
#line 651 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp12_ = _tmp11_->str;
#line 651 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp13_ = g_strdup (_tmp12_);
#line 651 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	result = _tmp13_;
#line 651 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_string_free0 (sb);
#line 651 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return result;
#line 5255 "VideoMetadata.c"
}


static void value_avi_chunk_init (GValue* value) {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	value->data[0].v_pointer = NULL;
#line 5262 "VideoMetadata.c"
}


static void value_avi_chunk_free_value (GValue* value) {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (value->data[0].v_pointer) {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		avi_chunk_unref (value->data[0].v_pointer);
#line 5271 "VideoMetadata.c"
	}
}


static void value_avi_chunk_copy_value (const GValue* src_value, GValue* dest_value) {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (src_value->data[0].v_pointer) {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		dest_value->data[0].v_pointer = avi_chunk_ref (src_value->data[0].v_pointer);
#line 5281 "VideoMetadata.c"
	} else {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		dest_value->data[0].v_pointer = NULL;
#line 5285 "VideoMetadata.c"
	}
}


static gpointer value_avi_chunk_peek_pointer (const GValue* value) {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return value->data[0].v_pointer;
#line 5293 "VideoMetadata.c"
}


static gchar* value_avi_chunk_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (collect_values[0].v_pointer) {
#line 5300 "VideoMetadata.c"
		AVIChunk* object;
		object = collect_values[0].v_pointer;
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		if (object->parent_instance.g_class == NULL) {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
#line 5307 "VideoMetadata.c"
		} else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
			return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
#line 5311 "VideoMetadata.c"
		}
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = avi_chunk_ref (object);
#line 5315 "VideoMetadata.c"
	} else {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = NULL;
#line 5319 "VideoMetadata.c"
	}
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return NULL;
#line 5323 "VideoMetadata.c"
}


static gchar* value_avi_chunk_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
	AVIChunk** object_p;
	object_p = collect_values[0].v_pointer;
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (!object_p) {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value));
#line 5334 "VideoMetadata.c"
	}
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (!value->data[0].v_pointer) {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		*object_p = NULL;
#line 5340 "VideoMetadata.c"
	} else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		*object_p = value->data[0].v_pointer;
#line 5344 "VideoMetadata.c"
	} else {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		*object_p = avi_chunk_ref (value->data[0].v_pointer);
#line 5348 "VideoMetadata.c"
	}
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return NULL;
#line 5352 "VideoMetadata.c"
}


GParamSpec* param_spec_avi_chunk (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) {
	ParamSpecAVIChunk* spec;
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (g_type_is_a (object_type, TYPE_AVI_CHUNK), NULL);
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags);
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	G_PARAM_SPEC (spec)->value_type = object_type;
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return G_PARAM_SPEC (spec);
#line 5366 "VideoMetadata.c"
}


gpointer value_get_avi_chunk (const GValue* value) {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_AVI_CHUNK), NULL);
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return value->data[0].v_pointer;
#line 5375 "VideoMetadata.c"
}


void value_set_avi_chunk (GValue* value, gpointer v_object) {
	AVIChunk* old;
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_AVI_CHUNK));
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	old = value->data[0].v_pointer;
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (v_object) {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_AVI_CHUNK));
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value)));
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = v_object;
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		avi_chunk_ref (value->data[0].v_pointer);
#line 5395 "VideoMetadata.c"
	} else {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = NULL;
#line 5399 "VideoMetadata.c"
	}
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (old) {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		avi_chunk_unref (old);
#line 5405 "VideoMetadata.c"
	}
}


void value_take_avi_chunk (GValue* value, gpointer v_object) {
	AVIChunk* old;
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_AVI_CHUNK));
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	old = value->data[0].v_pointer;
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (v_object) {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_AVI_CHUNK));
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value)));
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = v_object;
#line 5424 "VideoMetadata.c"
	} else {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		value->data[0].v_pointer = NULL;
#line 5428 "VideoMetadata.c"
	}
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (old) {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		avi_chunk_unref (old);
#line 5434 "VideoMetadata.c"
	}
}


static void avi_chunk_class_init (AVIChunkClass * klass) {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	avi_chunk_parent_class = g_type_class_peek_parent (klass);
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	((AVIChunkClass *) klass)->finalize = avi_chunk_finalize;
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_type_class_add_private (klass, sizeof (AVIChunkPrivate));
#line 5446 "VideoMetadata.c"
}


static void avi_chunk_instance_init (AVIChunk * self) {
	gchar* _tmp0_ = NULL;
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv = AVI_CHUNK_GET_PRIVATE (self);
#line 535 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->file = NULL;
#line 536 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_tmp0_ = g_strdup ("");
#line 536 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_name = _tmp0_;
#line 537 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_size = (guint64) 0;
#line 538 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->section_offset = (guint64) 0;
#line 539 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->input = NULL;
#line 540 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->priv->parent = NULL;
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self->ref_count = 1;
#line 5470 "VideoMetadata.c"
}


static void avi_chunk_finalize (AVIChunk* obj) {
	AVIChunk * self;
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_AVI_CHUNK, AVIChunk);
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_signal_handlers_destroy (self);
#line 535 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_object_unref0 (self->priv->file);
#line 536 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_free0 (self->priv->section_name);
#line 539 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_g_object_unref0 (self->priv->input);
#line 540 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	_avi_chunk_unref0 (self->priv->parent);
#line 5488 "VideoMetadata.c"
}


GType avi_chunk_get_type (void) {
	static volatile gsize avi_chunk_type_id__volatile = 0;
	if (g_once_init_enter (&avi_chunk_type_id__volatile)) {
		static const GTypeValueTable g_define_type_value_table = { value_avi_chunk_init, value_avi_chunk_free_value, value_avi_chunk_copy_value, value_avi_chunk_peek_pointer, "p", value_avi_chunk_collect_value, "p", value_avi_chunk_lcopy_value };
		static const GTypeInfo g_define_type_info = { sizeof (AVIChunkClass), (GBaseInitFunc) NULL, (GBaseFinalizeFunc) NULL, (GClassInitFunc) avi_chunk_class_init, (GClassFinalizeFunc) NULL, NULL, sizeof (AVIChunk), 0, (GInstanceInitFunc) avi_chunk_instance_init, &g_define_type_value_table };
		static const GTypeFundamentalInfo g_define_type_fundamental_info = { (G_TYPE_FLAG_CLASSED | G_TYPE_FLAG_INSTANTIATABLE | G_TYPE_FLAG_DERIVABLE | G_TYPE_FLAG_DEEP_DERIVABLE) };
		GType avi_chunk_type_id;
		avi_chunk_type_id = g_type_register_fundamental (g_type_fundamental_next (), "AVIChunk", &g_define_type_info, &g_define_type_fundamental_info, 0);
		g_once_init_leave (&avi_chunk_type_id__volatile, avi_chunk_type_id);
	}
	return avi_chunk_type_id__volatile;
}


gpointer avi_chunk_ref (gpointer instance) {
	AVIChunk* self;
	self = instance;
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	g_atomic_int_inc (&self->ref_count);
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	return instance;
#line 5513 "VideoMetadata.c"
}


void avi_chunk_unref (gpointer instance) {
	AVIChunk* self;
	self = instance;
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
	if (g_atomic_int_dec_and_test (&self->ref_count)) {
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		AVI_CHUNK_GET_CLASS (self)->finalize (self);
#line 534 "/home/jens/Source/shotwell/src/VideoMetadata.vala"
		g_type_free_instance ((GTypeInstance *) self);
#line 5526 "VideoMetadata.c"
	}
}