This source file includes following definitions.
- get_file_next_counter
- get_target_file_num
- get_target_dir_name
- get_target_dir_num
1 #include "platform.h"
2
3
4
5
6 #define PARAM_FILE_COUNTER 0x1
7
8
9
10
11
12 const ApertureSize aperture_sizes_table[] = {
13 { 9, 293, "2.8" },
14 { 10, 307, "3.2" },
15 { 11, 344, "3.5" },
16 { 12, 388, "4.0" },
17 { 13, 413, "4.5" },
18 { 14, 443, "5.0" },
19 { 15, 476, "5.6" },
20 { 16, 500, "5.9" },
21 { 17, 1410, "14.1" },
22 { 18, 1600, "16.0" },
23 { 19, 1800, "18.0" },
24 { 20, 2000, "20.1" },
25 };
26
27
28 const ShutterSpeed shutter_speeds_table[] = {
29 { -12, -384, "15", 15000000 },
30 { -11, -352, "13", 13000000 },
31 { -10, -320, "10", 10000000 },
32 { -9, -288, "8", 8000000 },
33 { -8, -256, "6", 6000000 },
34 { -7, -224, "5", 5000000 },
35 { -6, -192, "4", 4000000 },
36 { -5, -160, "3.2", 3200000 },
37 { -4, -128, "2.5", 2500000 },
38 { -3, -96, "2", 2000000 },
39 { -2, -64, "1.6", 1600000 },
40 { -1, -32, "1.3", 1300000 },
41 { 0, 0, "1", 1000000 },
42 { 1, 32, "0.8", 800000 },
43 { 2, 64, "0.6", 600000 },
44 { 3, 96, "0.5", 500000 },
45 { 4, 128, "0.4", 400000 },
46 { 5, 160, "0.3", 300000 },
47 { 6, 192, "1/4", 250000 },
48 { 7, 224, "1/5", 200000 },
49 { 8, 256, "1/6", 166667 },
50 { 9, 288, "1/8", 125000 },
51 { 10, 320, "1/10", 100000 },
52 { 11, 352, "1/13", 76923 },
53 { 12, 384, "1/15", 66667 },
54 { 13, 416, "1/20", 50000 },
55 { 14, 448, "1/25", 40000 },
56 { 15, 480, "1/30", 33333 },
57 { 16, 512, "1/40", 25000 },
58 { 17, 544, "1/50", 20000 },
59 { 18, 576, "1/60", 16667 },
60 { 19, 608, "1/80", 12500 },
61 { 20, 640, "1/100", 10000 },
62 { 21, 672, "1/125", 8000 },
63 { 22, 704, "1/160", 6250 },
64 { 23, 736, "1/200", 5000 },
65 { 24, 768, "1/250", 4000 },
66 { 25, 800, "1/320", 3125 },
67 { 26, 832, "1/400", 2500 },
68 { 27, 864, "1/500", 2000 },
69 { 28, 896, "1/640", 1563 },
70 { 29, 928, "1/800", 1250 },
71 { 30, 960, "1/1000", 1000 },
72 { 31, 992, "1/1250", 800 },
73 { 32, 1024, "1/1600", 625 },
74 };
75
76 const ISOTable iso_table[] = {
77 { 0, 0, "Auto", -1},
78 { 1, 100, "100", -1},
79 { 2, 200, "200", -1},
80 { 3, 400, "400", -1},
81 { 4, 800, "800", -1},
82 { 5, 1600, "1600", -1},
83 };
84
85
86 const CapturemodeMap modemap[] = {
87 { MODE_AUTO, 32768 },
88 { MODE_P, 32772 },
89 { MODE_LONG_SHUTTER, 32774 },
90 { MODE_PORTRAIT, 32787 },
91 { MODE_SNOW, 32795 },
92 { MODE_FIREWORK, 32797 },
93 { MODE_LOWLIGHT, 32807 },
94 { MODE_SUPER_VIVID, 33324 },
95 { MODE_POSTER_EFFECT, 33325 },
96 { MODE_FACE_SELF_TIMER, 33326 },
97 { MODE_FISHEYE, 33329 },
98 { MODE_MINIATURE, 33330 },
99 { MODE_TOY_CAMERA, 33333 },
100 { MODE_MONOCHROME, 33336 },
101 { MODE_LIVE, 33338 },
102 { MODE_DIGITAL_IS, 33340 },
103 } ;
104
105 #include "../generic/shooting.c"
106
107 long get_file_next_counter() {
108 return get_file_counter();
109 }
110
111 long get_target_file_num() {
112 long n;
113
114 n = get_file_next_counter();
115 n = (n>>4)&0x3FFF;
116 return n;
117 }
118
119 #if defined(CAM_DATE_FOLDER_NAMING)
120 void get_target_dir_name(char *out) {
121 extern void _GetImageFolder(char*,int,int,int);
122 _GetImageFolder(out,get_file_next_counter(),CAM_DATE_FOLDER_NAMING,time(NULL));
123 }
124 #else
125 long get_target_dir_num() {
126 long n;
127
128 n = get_file_next_counter();
129 n = (n>>18)&0x3FF;
130 return n;
131 }
132 #endif