root/platform/ixus160_elph160/shooting.c

/* [<][>][^][v][top][bottom][index][help] */

DEFINITIONS

This source file includes following definitions.
  1. get_file_next_counter
  2. get_target_file_num
  3. get_target_dir_name

   1 #include "platform.h"
   2 
   3 // Tested by iterating over values
   4 const CapturemodeMap modemap[] = {
   5     { MODE_PORTRAIT,            32790 },
   6     { MODE_P,                   32773 },
   7     { MODE_LONG_SHUTTER,        32775 },
   8     { MODE_AUTO,                32768 },
   9     { MODE_LOWLIGHT,            32813 },
  10     { MODE_DIGITAL_IS,          33347 },
  11     { MODE_FACE_SELF_TIMER,     33332 },
  12     { MODE_FISHEYE,             33335 },
  13     { MODE_TOY_CAMERA,          33339 },
  14     { MODE_MONOCHROME,          33343 },
  15     { MODE_LIVE,                33345 },
  16     { MODE_SUPER_VIVID,         33330 },
  17     { MODE_POSTER_EFFECT,       33331 },
  18     { MODE_MINIATURE,           33336 },
  19     { MODE_SNOW,                32798 },
  20     { MODE_FIREWORK,            32800 },
  21 } ;
  22 
  23 //To do
  24 // http://chdk.setepontos.com/index.php?topic=2031.msg27692#msg27692
  25 // PROPCASE_AV (68)
  26 const ApertureSize aperture_sizes_table[] = {
  27     {  9, 293, "2.8" },
  28     { 10, 307, "3.2" },
  29     { 11, 344, "3.5" },
  30     { 12, 388, "4.0" },
  31     { 13, 413, "4.5" },
  32     { 14, 443, "5.0" },
  33     { 15, 476, "5.6" },
  34     { 16, 500, "5.9" },
  35     { 17, 1410, "14.1" },
  36     { 18, 1600, "16.0" },
  37     { 19, 1800, "18.0" },
  38     { 20, 2000, "20.1" },
  39 };
  40 
  41 //To do
  42 // SEE AROUND FFCCB7F0 for string constants
  43 const ShutterSpeed shutter_speeds_table[] = {
  44     { -12, -384, "15", 15000000 },
  45     { -11, -352, "13", 13000000 },
  46     { -10, -320, "10", 10000000 },
  47     {  -9, -288, "8",   8000000 },
  48     {  -8, -256, "6",   6000000 },
  49     {  -7, -224, "5",   5000000 },
  50     {  -6, -192, "4",   4000000 },
  51     {  -5, -160, "3.2", 3200000 },
  52     {  -4, -128, "2.5", 2500000 },
  53     {  -3,  -96, "2",   2000000 },
  54     {  -2,  -64, "1.6", 1600000 },
  55     {  -1,  -32, "1.3", 1300000 },
  56     {   0,    0, "1",   1000000 },
  57     {   1,   32, "0.8",  800000 },
  58     {   2,   64, "0.6",  600000 },
  59     {   3,   96, "0.5",  500000 },
  60     {   4,  128, "0.4",  400000 },
  61     {   5,  160, "0.3",  300000 },
  62     {   6,  192, "1/4",  250000 },
  63     {   7,  224, "1/5",  200000 },
  64     {   8,  256, "1/6",  166667 },
  65     {   9,  288, "1/8",  125000 },
  66     {  10,  320, "1/10", 100000 },
  67     {  11,  352, "1/13",  76923 },
  68     {  12,  384, "1/15",  66667 },
  69     {  13,  416, "1/20",  50000 },
  70     {  14,  448, "1/25",  40000 },
  71     {  15,  480, "1/30",  33333 },
  72     {  16,  512, "1/40",  25000 },
  73     {  17,  544, "1/50",  20000 },
  74     {  18,  576, "1/60",  16667 },
  75     {  19,  608, "1/80",  12500 },
  76     {  20,  640, "1/100", 10000 },
  77     {  21,  672, "1/125",  8000 },
  78     {  22,  704, "1/160",  6250 },
  79     {  23,  736, "1/200",  5000 },
  80     {  24,  768, "1/250",  4000 },
  81     {  25,  800, "1/320",  3125 },
  82     {  26,  832, "1/400",  2500 },
  83     {  27,  864, "1/500",  2000 },
  84     {  28,  896, "1/640",  1563 },
  85     {  29,  928, "1/800",  1250 },
  86     {  30,  960, "1/1000", 1000 },
  87     {  31,  992, "1/1250",  800 },
  88     {  32, 1024, "1/1600",  625 },
  89 };
  90 
  91 const ISOTable iso_table[] = {
  92     {  0,    0, "Auto", -1},
  93     {  1,  100,  "100", -1},
  94     {  2,  200,  "200", -1},
  95     {  3,  400,  "400", -1},
  96     {  4,  800,  "800", -1},
  97     {  5, 1600,  "1600", -1},
  98 };
  99 
 100 #include "../generic/shooting.c"
 101 
 102 // Hardcoded fix for filename counter offsetted by 1
 103 long get_file_next_counter() {
 104     return get_file_counter();
 105 }
 106 
 107 // Hardcoded fix for filename counter offsetted by 1
 108 long get_target_file_num() {
 109     return get_exposure_counter();
 110 }
 111 
 112 void get_target_dir_name(char *out) {
 113     extern void _GetImageFolder(char*,int,int);
 114     _GetImageFolder(out, get_file_next_counter(), CAM_DATE_FOLDER_NAMING);

/* [<][>][^][v][top][bottom][index][help] */