root/platform/ixus310_elph500hs/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
  4. get_target_dir_num

   1 #define PARAM_FILE_COUNTER      0x3b            // OK
   2 #define PARAM_EXPOSURE_COUNTER  0x02            // OK
   3 
   4 #include "platform.h"
   5 
   6 const ApertureSize aperture_sizes_table[] = {
   7         {  9, 200, "2.0" },
   8         { 10, 224, "2.2" },
   9         { 11, 256, "2.5" },
  10         { 12, 288, "2.8" },
  11         { 13, 320, "3.2" },
  12         { 14, 352, "3.5" },
  13         { 15, 384, "4.0" },
  14         { 16, 416, "4.5" },
  15         { 17, 448, "5.0" },
  16         { 18, 480, "5.6" },
  17         { 19, 512, "6.3" },
  18         { 20, 544, "7.1" },
  19         { 21, 576, "8.0" },
  20 };
  21 
  22 const ShutterSpeed shutter_speeds_table[] = {
  23         { -12, -384, "15", 15000000 },
  24         { -11, -352, "13", 13000000 },
  25         { -10, -320, "10", 10000000 },
  26         {  -9, -288, "8",   8000000 },
  27         {  -8, -256, "6",   6000000 },
  28         {  -7, -224, "5",   5000000 },
  29         {  -6, -192, "4",   4000000 },
  30         {  -5, -160, "3.2", 3200000 },
  31         {  -4, -128, "2.5", 2500000 },
  32         {  -3,  -96, "2",   2000000 },
  33         {  -2,  -64, "1.6", 1600000 },
  34         {  -1,  -32, "1.3", 1300000 },
  35         {   0,    0, "1",   1000000 },
  36         {   1,   32, "0.8",  800000 },
  37         {   2,   64, "0.6",  600000 },
  38         {   3,   96, "0.5",  500000 },
  39         {   4,  128, "0.4",  400000 },
  40         {   5,  160, "0.3",  300000 },
  41         {   6,  192, "1/4",  250000 },
  42         {   7,  224, "1/5",  200000 },
  43         {   8,  256, "1/6",  166667 },
  44         {   9,  288, "1/8",  125000 },
  45         {  10,  320, "1/10", 100000 },
  46         {  11,  352, "1/13",  76923 },
  47         {  12,  384, "1/15",  66667 },
  48         {  13,  416, "1/20",  50000 },
  49         {  14,  448, "1/25",  40000 },
  50         {  15,  480, "1/30",  33333 },
  51         {  16,  512, "1/40",  25000 },
  52         {  17,  544, "1/50",  20000 },
  53         {  18,  576, "1/60",  16667 },
  54         {  19,  608, "1/80",  12500 },
  55         {  20,  640, "1/100", 10000 },
  56         {  21,  672, "1/125",  8000 },
  57         {  22,  704, "1/160",  6250 },
  58         {  23,  736, "1/200",  5000 },
  59         {  24,  768, "1/250",  4000 },
  60         {  25,  800, "1/320",  3125 },
  61         {  26,  832, "1/400",  2500 },
  62         {  27,  864, "1/500",  2000 },
  63         {  28,  896, "1/640",  1563 },
  64         {  29,  928, "1/800",  1250 },
  65         {  30,  960, "1/1000", 1000 },
  66         {  31,  992, "1/1250",  800 },
  67         {  32, 1024, "1/1600",  625 },
  68         {  33, 1056, "1/2000",  500 },
  69         {  34, 1088, "1/2500",  400 },
  70         {  35, 1120, "1/3200",  313 },
  71         {  36, 1152, "1/4000",  250 },
  72 };
  73 
  74 const ISOTable iso_table[] = {
  75 //      { -1,    1,   "HI", -1},
  76         {  0,    0, "Auto", -1},
  77         {  1,  100,  "100", -1},
  78         {  2,  200,  "200", -1},
  79         {  3,  400,  "400", -1},
  80         {  4,  800,  "800", -1},
  81         {  5, 1600, "1600", -1},
  82         {  6, 3200, "3200", -1},
  83 };          
  84 
  85 /*
  86 http://www.usa.canon.com/cusa/consumer/products/cameras/digital_cameras/powershot_elph_500_hs#Specifications
  87 Shooting Modes
  88     P, Auto, Av, Tv, Movie Digest, Portrait, Kids & Pets, Smart Shutter, 
  89     High-speed Burst, Best Image Selection, Handheld Night Scene, Low Light, 
  90     Fish-eye Effect, Miniature Effect, Toy Camera Effect, Creative Light Effect, 
  91     Monochrome, Super Vivid, Poster Effect, Color Accent, Color Swap, 
  92     Beach, Foliage, Snow, Fireworks, Movie
  93 
  94 Smart Shutter Modes:
  95     Smile, Wink Self-timer, Face Self-Timer
  96 
  97 Movie Modes:
  98     Standard, iFrame Movie, Super Slow Motion Movie, Miniature Effect for Movies (Videos are recorded by pressing the movie button)
  99 
 100 Photo Effects
 101     My colors Off, Vivid, Neutral, Sepia, Black & White, Positive Film, 
 102     Lighter Skin, Darker Skin, Vivid Blue, Vivid Green, Vivid Red, 
 103     Custom Color adjustment of contrast, sharpness, saturation, red, green, blue and skin tone are available
 104 */
 105 // IXUS 310 HS modelist table found @0xff4ce6f0 (firmware 1.00a)
 106 const CapturemodeMap modemap[] = {
 107         { MODE_TV,                  32771 },
 108         { MODE_AV,                  32770 },
 109         { MODE_P,                   32772 },
 110         { MODE_AUTO,                32768 },
 111 
 112     { MODE_PORTRAIT,            32783 },
 113     { MODE_KIDS_PETS,           32786 },
 114     { MODE_SMART_SHUTTER,       33321 },
 115     { MODE_WINK_SELF_TIMER,     33322 },
 116     { MODE_FACE_SELF_TIMER,     33320 },
 117     { MODE_HIGHSPEED_BURST,     33288 },
 118     { MODE_BEST_IMAGE,          33289 },
 119     { MODE_NIGHT_SCENE,         33325 },
 120     { MODE_LOWLIGHT,            32801 },
 121     { MODE_FISHEYE,             33323 },
 122     { MODE_MINIATURE,           33324 },
 123     { MODE_TOY_CAMERA,          33327 },
 124     { MODE_CREATIVE_EFFECT,     33297 },
 125     { MODE_MONOCHROME,          33330 },
 126     { MODE_SUPER_VIVID,         33318 },
 127     { MODE_POSTER_EFFECT,       33319 },
 128     { MODE_COLOR_ACCENT,        33309 },
 129     { MODE_COLOR_SWAP,          33310 },
 130     { MODE_BEACH,               32791 },
 131     { MODE_FOLIAGE,             32789 },
 132     { MODE_SNOW,                32790 },
 133     { MODE_FIREWORK,            32792 },
 134 
 135     { MODE_VIDEO_MOVIE_DIGEST,  33333 },
 136     { MODE_VIDEO_IFRAME_MOVIE,   2628 },
 137     { MODE_VIDEO_SUPER_SLOW,     2626 },
 138 };
 139 
 140 #include "../generic/shooting.c"
 141 
 142 long get_file_next_counter() {
 143         return get_file_counter();
 144 }
 145 
 146 long get_target_file_num() {
 147         long n;
 148         
 149         n = get_file_next_counter();
 150         n = (n>>4)&0x3FFF;
 151         return n;
 152 }
 153 
 154 #if defined(CAM_DATE_FOLDER_NAMING)
 155 // IXUS 310 HS uses date to name directory
 156 void get_target_dir_name(char *out)
 157 {
 158         extern void _GetImageFolder(char*,int,int,int);
 159         _GetImageFolder(out,get_file_next_counter(),CAM_DATE_FOLDER_NAMING,time(NULL));
 160 }
 161 #else
 162 long get_target_dir_num() {
 163         long n;
 164         
 165         n = get_file_next_counter();
 166         n = (n>>18)&0x3FF;
 167         return n;
 168 }
 169 #endif

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