Changeset 847 for trunk/include/platform.h
- Timestamp:
- 12/02/09 09:31:02 (3 years ago)
- File:
-
- 1 edited
-
trunk/include/platform.h (modified) (5 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/include/platform.h
r842 r847 13 13 #define MODE_SHOOTING_MASK 0x00FF 14 14 15 enum { 16 MODE_AUTO =1, 17 MODE_P , 18 MODE_TV , 19 MODE_AV , 20 MODE_M , 21 MODE_PORTRAIT , 22 MODE_NIGHT , 23 MODE_LANDSCAPE , 24 MODE_VIDEO_STD , 25 MODE_VIDEO_SPEED , 26 MODE_VIDEO_COMPACT , 27 MODE_VIDEO_MY_COLORS , 28 MODE_VIDEO_COLOR_ACCENT , 29 MODE_VIDEO_COLOR_SWAP , 30 MODE_STITCH , 31 MODE_MY_COLORS , 32 MODE_SCN_WATER , 33 MODE_SCN_NIGHT , 34 MODE_SCN_CHILD , 35 MODE_SCN_PARTY , 36 MODE_SCN_GRASS , 37 MODE_SCN_SNOW , 38 MODE_SCN_BEACH , 39 MODE_SCN_FIREWORK , 40 MODE_SCN_COLOR_ACCENT , 41 MODE_SCN_COLOR_SWAP , 42 MODE_VIDEO_HIRES , 43 MODE_SCN_AQUARIUM , 44 MODE_COLOR_ACCENT , 45 MODE_SCN_NIGHT1 , 46 MODE_SCN_ISO_3200 , 47 MODE_SCN_SPORT , 48 MODE_SCN_KIDS_PETS , 49 MODE_INDOOR , 50 MODE_KIDS_PETS , 51 MODE_NIGHT_SNAPSHOT , 52 MODE_DIGITAL_MACRO , 53 MODE_SCN_FOLIAGE , 54 MODE_VIDEO_TIME_LAPSE , 55 MODE_SCN_INDOOR , 56 MODE_SCN_PORTRAIT , 57 MODE_SUPER_MACRO , 58 MODE_VIDEO_PORTRAIT , 59 MODE_VIDEO_NIGHT , 60 MODE_VIDEO_INDOOR , 61 MODE_VIDEO_FOLIAGE , 62 MODE_VIDEO_SNOW , 63 MODE_VIDEO_BEACH , 64 MODE_VIDEO_AQUARIUM , 65 MODE_VIDEO_SUPER_MACRO , 66 MODE_VIDEO_STITCH , 67 MODE_VIDEO_MANUAL , 68 MODE_SPORTS , 69 MODE_QUICK , 70 MODE_SCN_SUNSET , 71 MODE_SCN_UNDERWATER , 72 MODE_EASY , 73 MODE_SCN_DIGITAL_MACRO , 74 MODE_SCN_STITCH , 75 }; 15 /* capture mode constants. These are in their own header for easier sed processing*/ 16 #include "modelist.h" 76 17 77 18 // this is nasty, but not as nasty as checking each of the flags all over the place … … 93 34 ((m)&MODE_SHOOTING_MASK)==MODE_VIDEO_STITCH || \ 94 35 ((m)&MODE_SHOOTING_MASK)==MODE_VIDEO_MANUAL) 36 /* propcase ID constants. These are in their own header files for easier sed processing */ 95 37 #if CAM_PROPSET == 2 // most digic3 cameras 96 38 #include "propset2.h" … … 137 79 #define ZOOM_DIGITAL_OUT 12 138 80 #define ZOOM_DIGITAL_REACHED_MAX 13 81 82 typedef struct { 83 int hackmode; // platform independent mode values from MODE_xxx enum 84 int canonmode; // PROPCASE_SHOOTING_MODE value 85 } CapturemodeMap; 139 86 140 87 typedef struct { … … 412 359 void shooting_iso_bracketing(); 413 360 /******************************************************************/ 361 // capture mode functions 362 // return a CHDK mode enum for a PROPCASE_SHOOTING_MODE value, or 0 if not found 363 int shooting_mode_canon2chdk(int canonmode); 364 // return a PROPCASE_SHOOTING_MODE value for a CHDK mode enum value, or -1 if not found. 0 is a valid mode on some cameras. 365 int shooting_mode_chdk2canon(int hackmode); 366 // set capture mode from CHDK mode, returns 0 if mode not found or not in rec, otherwise 1 367 int shooting_set_mode_chdk(int mode); 368 // set capture mode from PROPCASE_SHOOTING_MODE value. return 0 if not in rec or mode is -1, otherwise 1 369 int shooting_set_mode_canon(int mode); 370 371 // returns 0 if in play, nonzero if rec 372 int rec_mode_active(void); 373 374 // not used. Right now this is just to preserve code from earlier version of mode_get() 375 // in case we want to check play/rec switch state in the future. 376 // WARNING: it isn't known if all variants of this check the switch state or some other bit. 377 // should return 0 is switch is in play position, non-zero otherwise 378 //int rec_switch_state(void); 379 380 // swivel screen state. 381 #ifdef CAM_SWIVEL_SCREEN 382 // 0 not open, non-zero open 383 int screen_opened(void); 384 // 0 not rotated, non-zero rotated 385 int screen_rotated(void); 386 #endif 387 388 /******************************************************************/ 414 389 void clear_values(); 415 390 /******************************************************************/ 416 417 391 418 392 int mode_get(); … … 502 476 void SetLogicalEventActive(unsigned event, unsigned state); 503 477 void SetScriptMode(unsigned mode); 504 void SetCurrentCaptureModeType(unsigned mode);505 478 506 479 #define started() debug_led(1)
Note: See TracChangeset
for help on using the changeset viewer.