Changeset 928 for trunk/core/gui.c


Ignore:
Timestamp:
08/29/10 09:47:13 (3 years ago)
Author:
fe50
Message:

New edge overlay, rewritten zebra, SX20 stuff

Note:

  • some of this (edge overlay, zebra) affects ALL cameras !
  • since there are changes in the CHDK configuration, it's recommended to use a new config file (i.e. to rename/delete the cchdk.cfg file)

The SX20 1.02D now is enabled in the main makefile for the autobuild server

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/core/gui.c

    r919 r928  
    161161static void gui_menuproc_edge_save(int arg); 
    162162static void gui_menuproc_edge_load(int arg); 
    163 static void gui_menuproc_edge_free(int arg); 
    164163#ifdef OPT_DEBUGGING 
    165164void gui_compare_props(int arg); 
     
    256255        static void gui_debug_shortcut(void); 
    257256#endif 
     257 
     258static const char* gui_edge_pano_enum(int change, int arg); 
     259 
    258260void rinit(); 
    259261 
     
    635637static CMenuItem edge_overlay_submenu_items[] = { 
    636638    {0x5c,LANG_MENU_EDGE_OVERLAY_ENABLE,     MENUITEM_BOOL,          &conf.edge_overlay_enable }, 
    637     {0x33,LANG_MENU_EDGE_SAVE,                  MENUITEM_PROC,          (int*)gui_menuproc_edge_save }, 
    638     {0x5c,LANG_MENU_EDGE_ZOOM,     MENUITEM_BOOL,          &conf.edge_overlay_zoom }, 
    639     {0x5c,LANG_MENU_EDGE_LOCK,     MENUITEM_BOOL,          &conf.edge_overlay_lock }, 
     639    {0x5c,LANG_MENU_EDGE_FILTER,     MENUITEM_BOOL,          &conf.edge_overlay_filter }, 
     640    {0x5c,LANG_MENU_EDGE_PANO,     MENUITEM_ENUM,          (int*)gui_edge_pano_enum }, 
     641    {0x7f,LANG_MENU_EDGE_PANO_OVERLAP,   MENUITEM_INT|MENUITEM_F_UNSIGNED|MENUITEM_F_MINMAX, &conf.edge_overlay_pano_overlap, MENU_MINMAX(0, 100)}, 
     642    {0x5c,LANG_MENU_EDGE_SHOW,     MENUITEM_BOOL,          &conf.edge_overlay_show }, 
    640643    {0x7f,LANG_MENU_EDGE_OVERLAY_TRESH,      MENUITEM_INT|MENUITEM_F_UNSIGNED|MENUITEM_F_MINMAX, &conf.edge_overlay_thresh, MENU_MINMAX(0, 255)}, 
    641644    {0x65,LANG_MENU_EDGE_OVERLAY_COLOR,      MENUITEM_COLOR_FG,      (int*)&conf.edge_overlay_color }, 
    642645    {0x5c,LANG_MENU_EDGE_PLAY,                  MENUITEM_BOOL,          &conf.edge_overlay_play }, //does not work on cams like s-series, which dont have a real "hardware" play/rec switch, need a workaround, probably another button 
    643     {0x33,LANG_MENU_EDGE_FREE,                  MENUITEM_PROC,          (int*)gui_menuproc_edge_free }, 
     646    {0x33,LANG_MENU_EDGE_SAVE,                  MENUITEM_PROC,          (int*)gui_menuproc_edge_save }, 
     647    {0x5c,LANG_MENU_EDGE_ZOOM,     MENUITEM_BOOL,          &conf.edge_overlay_zoom }, 
    644648    {0x33,LANG_MENU_EDGE_LOAD,                  MENUITEM_PROC,          (int*)gui_menuproc_edge_load }, 
    645649    {0x51,LANG_MENU_BACK,                    MENUITEM_UP }, 
     
    32013205} 
    32023206 
    3203 void gui_menuproc_edge_free(int arg) { 
    3204     free_memory_edge_overlay(); 
    3205 } 
    3206  
    32073207void gui_menuproc_edge_save(int arg) { 
    32083208    save_edge_overlay(); 
     
    34153415} 
    34163416 
    3417 #endif 
     3417static const char* gui_edge_pano_enum(int change, int arg) 
     3418{ 
     3419    static const char* modes[]={ "Off", "Right", "Down", "Left", "Up", "Free"}; 
     3420 
     3421    conf.edge_overlay_pano+=change; 
     3422    if (conf.edge_overlay_pano<0) 
     3423        conf.edge_overlay_pano=0; 
     3424    else if (conf.edge_overlay_pano>=(sizeof(modes)/sizeof(modes[0]))) 
     3425        conf.edge_overlay_pano=sizeof(modes)/sizeof(modes[0])-1; 
     3426 
     3427    return modes[conf.edge_overlay_pano];  
     3428} 
     3429 
     3430#endif 
Note: See TracChangeset for help on using the changeset viewer.