source: trunk/platform/ixus870_sd880/shooting.c @ 754

Revision 754, 3.3 KB checked in by reyalp, 4 years ago (diff)

mantis 255: add beta ixus870/sd880 port from mweerden
also proper fix for mantis 251

  • Property svn:eol-style set to native
Line 
1#include "platform.h"
2
3//  prop 23, "Photo", "CanonSi"
4//  290 95/32  96   without ND filter
5//  307 107/32 102
6//  325 107/32 108
7//  347 116/32 115
8//  367 116/32 122
9//  369 128/32 129
10//  413 139/32 137
11//  443 149/32 147
12//  470 159/32 156
13//  494 162/32 164
14// 
15//  488 159/32 162  with ND filter
16//  505 170/32 168
17//  523 170/32 174
18//  545 181/32 181
19//  565 181/32 188
20//  587 192/32 195
21//  611 203/32 203
22//  641 213/32 213
23//  668 221/32 222
24//  692 221/32 230
25const ApertureSize aperture_sizes_table[] = {
26//       idx, p23, CanonSi/32
27        {  9, 290, "3.0" },
28        { 10, 307, "3.2" },
29        { 11, 325, "3.4" },
30        { 12, 347, "3.6" },
31        { 13, 367, "3.8" },
32        { 14, 369, "4.0" },
33        { 15, 413, "4.3" },
34        { 16, 443, "4.6" },
35        { 17, 470, "4.9" },
36        { 18, 494, "5.1" },
37        { 19, 488, "5.1" },
38        { 20, 505, "5.3" },
39        { 21, 523, "5.4" },
40        { 22, 545, "5.7" },
41        { 23, 565, "5.9" },
42        { 24, 587, "6.1" },
43        { 25, 611, "6.3" },
44        { 26, 641, "6.7" },
45        { 27, 668, "6.9" },
46        { 28, 692, "7.2" },
47};
48
49// taken from ixus860, not checked!
50const ShutterSpeed shutter_speeds_table[] = {
51    { -12, -384, "15", 15000000 },
52    { -11, -352, "13", 13000000 },
53    { -10, -320, "10", 10000000 },
54    {  -9, -288, "8",   8000000 },
55    {  -8, -256, "6",   6000000 },
56    {  -7, -224, "5",   5000000 },
57    {  -6, -192, "4",   4000000 },
58    {  -5, -160, "3.2", 3200000 },
59    {  -4, -128, "2.5", 2500000 },
60    {  -3,  -96, "2",   2000000 },
61    {  -2,  -64, "1.6", 1600000 },
62    {  -1,  -32, "1.3", 1300000 },
63    {   0,    0, "1",   1000000 },
64    {   1,   32, "0.8",  800000 },
65    {   2,   64, "0.6",  600000 },
66    {   3,   96, "0.5",  500000 },
67    {   4,  128, "0.4",  400000 },
68    {   5,  160, "0.3",  300000 },
69    {   6,  192, "1/4",  250000 },
70    {   7,  224, "1/5",  200000 },
71    {   8,  256, "1/6",  166667 },
72    {   9,  288, "1/8",  125000 },
73    {  10,  320, "1/10", 100000 },
74    {  11,  352, "1/13",  76923 },
75    {  12,  384, "1/15",  66667 },
76    {  13,  416, "1/20",  50000 },
77    {  14,  448, "1/25",  40000 },
78    {  15,  480, "1/30",  33333 },
79    {  16,  512, "1/40",  25000 },
80    {  17,  544, "1/50",  20000 },
81    {  18,  576, "1/60",  16667 },
82    {  19,  608, "1/80",  12500 },
83    {  20,  640, "1/100", 10000 },
84    {  21,  672, "1/125",  8000 },
85    {  22,  704, "1/160",  6250 },
86    {  23,  736, "1/200",  5000 },
87    {  24,  768, "1/250",  4000 },
88    {  25,  800, "1/320",  3125 },
89    {  26,  832, "1/400",  2500 },
90    {  27,  864, "1/500",  2000 },
91    {  28,  896, "1/640",  1563 },
92    {  29,  928, "1/800",  1250 },
93    {  30,  960, "1/1000", 1000 },
94    {  31,  992, "1/1250",  800 },
95    {  32, 1021, "1/1600",  625 },
96    {  33, 1053, "1/2000",  500 },
97};
98
99// idx, propcase 149, name, -1
100const ISOTable iso_table[] = {
101        { -1,    1,   "HI", -1},
102        {  0,    0, "Auto", -1},
103        {  1,   80,   "80", -1},
104        {  2,  100,  "100", -1},
105        {  3,  200,  "200", -1},
106        {  4,  400,  "400", -1},
107        {  5,  800,  "800", -1},
108        {  6, 1600, "1600", -1},
109        {  7, 3200, "3200", -1},
110};         
111
112#define PARAM_FILE_COUNTER      0x38
113#define PARAM_EXPOSURE_COUNTER  0x02
114#include "../generic/shooting.c"
115
116long get_file_next_counter() {
117        return get_file_counter();
118}
119
120long get_target_file_num() {
121        long n;
122       
123        n = get_file_next_counter();
124        n = (n>>4)&0x3FFF;
125        return n;
126}
127
128long get_target_dir_num() {
129        long n;
130       
131        n = get_file_next_counter();
132        n = (n>>18)&0x3FF;
133        return n;
134}
135
136int circle_of_confusion = 5;
Note: See TracBrowser for help on using the repository browser.