root/core/gui_usb.c

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

DEFINITIONS

This source file includes following definitions.
  1. gui_usb_draw_icon
  2. gui_usb_draw_text
  3. gui_usb_draw_osd

   1 #include "camera_info.h"
   2 #include "stdlib.h"
   3 #include "conf.h"
   4 #include "gui_draw.h"
   5 #include "gui_usb.h"
   6 
   7 //-------------------------------------------------------------------
   8 static icon_cmd usb_icon[] =
   9 {
  10         { IA_FILLED_ROUND_RECT, 3, 11, 29, 14, IDX_COLOR_GREY_DK, IDX_COLOR_GREY_DK },
  11         { IA_FILLED_ROUND_RECT, 0,  0, 31, 11, IDX_COLOR_GREY_DK, IDX_COLOR_GREY_DK },
  12         { IA_FILLED_RECT,       2,  1, 29,  2, IDX_COLOR_GREY,    IDX_COLOR_GREY    },
  13         { IA_FILLED_RECT,       1,  2,  2,  8, IDX_COLOR_GREY,    IDX_COLOR_GREY    },
  14         { IA_FILLED_RECT,      29,  2, 30,  8, IDX_COLOR_GREY,    IDX_COLOR_GREY    },
  15         { IA_FILLED_RECT,       5,  5, 26,  8, IDX_COLOR_GREY,    IDX_COLOR_GREY    },
  16         { IA_FILLED_RECT,       7,  7,  9,  8, IDX_COLOR_YELLOW,  IDX_COLOR_YELLOW  },
  17         { IA_FILLED_RECT,      12,  7, 14,  8, IDX_COLOR_YELLOW,  IDX_COLOR_YELLOW  },
  18         { IA_FILLED_RECT,      17,  7, 19,  8, IDX_COLOR_YELLOW,  IDX_COLOR_YELLOW  },
  19         { IA_FILLED_RECT,      22,  7, 24,  8, IDX_COLOR_YELLOW,  IDX_COLOR_YELLOW  },
  20         { IA_FILLED_RECT,       2,  9,  3, 10, IDX_COLOR_GREY,    IDX_COLOR_GREY    },
  21         { IA_FILLED_RECT,      28,  9, 29, 10, IDX_COLOR_GREY,    IDX_COLOR_GREY    },
  22         { IA_FILLED_RECT,       3, 11,  4, 12, IDX_COLOR_GREY,    IDX_COLOR_GREY    },
  23         { IA_FILLED_RECT,      27, 11, 28, 12, IDX_COLOR_GREY,    IDX_COLOR_GREY    },
  24         { IA_FILLED_RECT,       5, 12, 26, 13, IDX_COLOR_GREY,    IDX_COLOR_GREY    },
  25         { IA_END }
  26 };
  27 
  28 static void gui_usb_draw_icon()
  29 {
  30     draw_icon_cmds(conf.usb_info_pos.x, conf.usb_info_pos.y, usb_icon);
  31 }
  32 //-------------------------------------------------------------------
  33 static void gui_usb_draw_text()
  34 {
  35     twoColors cl = user_color(conf.osd_color);
  36     draw_string(conf.usb_info_pos.x, conf.usb_info_pos.y, "<USB>", cl);
  37 }
  38 //--------------------------------------------------------------------
  39 void gui_usb_draw_osd(int is_osd_edit)
  40 {
  41     if ((conf.usb_info_enable == 1 && conf.remote_enable) || is_osd_edit)
  42         gui_usb_draw_icon();
  43     else if ((conf.usb_info_enable == 2 && conf.remote_enable) || is_osd_edit)
  44         gui_usb_draw_text();
  45 }

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