IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 39418


Ignore:
Timestamp:
Mar 1, 2016, 11:31:53 AM (10 years ago)
Author:
eugene
Message:

list unused parameters; bitmaps are unsigned char; fix overshoot on Y - dY > Ymax

Location:
branches/eam_branches/ohana.20160226/src/kapa2
Files:
11 edited

Legend:

Unmodified
Added
Removed
  • branches/eam_branches/ohana.20160226/src/kapa2/include/buttons.h

    r29539 r39418  
    11#define PS_width 25
    22#define PS_height 25
    3 static char PS_bits[] = {
     3static unsigned char PS_bits[] = {
    44   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x81, 0x3f, 0x00,
    55   0x82, 0x67, 0x60, 0x00, 0x02, 0x26, 0x40, 0x00, 0x02, 0x24, 0x40, 0x00,
     
    1313#define grey_width 25
    1414#define grey_height 25
    15 static char grey_bits[] = {
     15static unsigned char grey_bits[] = {
    1616   0x90, 0x40, 0xf7, 0x01, 0x04, 0xaa, 0xad, 0x01, 0x68, 0xd5, 0xfe, 0x01,
    1717   0x82, 0x28, 0xdb, 0x01, 0x10, 0xd2, 0x75, 0x01, 0x40, 0xad, 0xee, 0x01,
     
    2525#define rainbow_width 25
    2626#define rainbow_height 25
    27 static char rainbow_bits[] = {
     27static unsigned char rainbow_bits[] = {
    2828   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
    2929   0x00, 0x80, 0xff, 0x00, 0x00, 0x70, 0x00, 0x01, 0x00, 0x0c, 0x7f, 0x00,
     
    3737#define recenter_width 25
    3838#define recenter_height 25
    39 static char recenter_bits[] = {
     39static unsigned char recenter_bits[] = {
    4040   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xfe, 0x00, 0x00,
    4141   0x80, 0xef, 0x03, 0x00, 0xe0, 0x00, 0x0e, 0x00, 0x30, 0x00, 0x18, 0x00,
     
    4949#define heat_width 25
    5050#define heat_height 25
    51 static char heat_bits[] = {
     51static unsigned char heat_bits[] = {
    5252   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x07, 0xd8, 0x01,
    5353   0x00, 0x0c, 0x37, 0x00, 0xf8, 0xc9, 0x6f, 0x00, 0x0c, 0xde, 0xf0, 0x00,
     
    6161#define red_width 25
    6262#define red_height 25
    63 static char red_bits[] = {
     63static unsigned char red_bits[] = {
    6464   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0xfc, 0x03, 0x00,
    6565   0x20, 0x07, 0x06, 0x00, 0xe0, 0x00, 0x0c, 0x00, 0x20, 0x00, 0x08, 0x00,
     
    7373#define green_width 25
    7474#define green_height 25
    75 static char green_bits[] = {
     75static unsigned char green_bits[] = {
    7676   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xf8, 0x07, 0x00,
    7777   0x00, 0x06, 0x04, 0x00, 0x80, 0x03, 0x00, 0x00, 0xc0, 0x00, 0x00, 0x00,
     
    8585#define blue_width 25
    8686#define blue_height 25
    87 static char blue_bits[] = {
     87static unsigned char blue_bits[] = {
    8888   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x40, 0xfe, 0x00, 0x00,
    8989   0xc0, 0x83, 0x07, 0x00, 0xc0, 0x00, 0x0c, 0x00, 0x40, 0x00, 0x08, 0x00,
     
    9797#define yellow_width 25
    9898#define yellow_height 25
    99 static char yellow_bits[] = {
     99static unsigned char yellow_bits[] = {
    100100   0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xc0, 0x00, 0x18, 0x00,
    101101   0x80, 0x01, 0x0c, 0x00, 0x00, 0x03, 0x06, 0x00, 0x00, 0x02, 0x02, 0x00,
     
    109109#define flipx_width 25
    110110#define flipx_height 25
    111 static char flipx_bits[] = {
     111static unsigned char flipx_bits[] = {
    112112   0x00, 0x10, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00,
    113113   0x00, 0x00, 0x00, 0x00, 0x00, 0x11, 0x01, 0x00, 0x80, 0x10, 0x02, 0x00,
     
    121121#define flipy_width 25
    122122#define flipy_height 25
    123 static char flipy_bits[] = {
     123static unsigned char flipy_bits[] = {
    124124   0x00, 0x10, 0x00, 0x00, 0x00, 0x28, 0x00, 0x00, 0x00, 0x44, 0x00, 0x00,
    125125   0x00, 0x82, 0x00, 0x00, 0x00, 0x01, 0x01, 0x00, 0x80, 0x00, 0x02, 0x00,
     
    133133#define hex_width 25
    134134#define hex_height 12
    135 static char hex_bits[] = {
     135static unsigned char hex_bits[] = {
    136136   0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00,
    137137   0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0xf0, 0x00, 0x1e, 0x00, 0x88, 0x00,
  • branches/eam_branches/ohana.20160226/src/kapa2/include/hms_buttons.h

    r29539 r39418  
    11#define hms_width 25
    22#define hms_height 12
    3 static char hms_bits[] = {
     3static unsigned char hms_bits[] = {
    44   0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00,
    55   0x02, 0x00, 0x00, 0x00, 0x02, 0x01, 0xf0, 0x00, 0x1e, 0xef, 0x89, 0x00,
     
    88#define ddd_width 25
    99#define ddd_height 12
    10 static char ddd_bits[] = {
     10static unsigned char ddd_bits[] = {
    1111   0x40, 0x80, 0x80, 0x00, 0x40, 0x80, 0x80, 0x00, 0x40, 0x80, 0x80, 0x00,
    1212   0x40, 0x80, 0x80, 0x00, 0x40, 0x80, 0x80, 0x00, 0x5c, 0xb8, 0xb8, 0x00,
  • branches/eam_branches/ohana.20160226/src/kapa2/include/prototypes.h

    r38986 r39418  
    172172void          SetImageSize        PROTO((Section *section));
    173173
    174 void          InitButtonSize      PROTO((Button *button, int width, int height, char *bitmap));
     174void          InitButtonSize      PROTO((Button *button, int width, int height, unsigned char *bitmap));
    175175void          InitButtonFunc      PROTO((Button *button, int (*function)(Graphic *graphic, KapaImageWidget *image)));
    176176void          DrawImage           PROTO((KapaImageWidget *image));
    177177void          DrawButton          PROTO((Graphic *graphic, Button *button));
    178 void          DrawBitmap          PROTO((Graphic *graphic, int x, int y, int dx, int dy, char *bitmap, int mode));
     178void          DrawBitmap          PROTO((Graphic *graphic, int x, int y, int dx, int dy, unsigned char *bitmap, int mode));
    179179void          CrossHairs          PROTO((Graphic *graphic, Picture *image));
    180180void          hh_hms              PROTO((char *line, double ra, double dec, char sep, int Nchar));
  • branches/eam_branches/ohana.20160226/src/kapa2/include/structures.h

    r38986 r39418  
    5555  int      x, y, dx, dy;      /* position and size */
    5656  int      width, height;     /* size of the bitmap */
    57   char    *bitmap;            /* picture on button */
     57  unsigned char *bitmap;            /* picture on button */
    5858  int    (*function_1) ();    /* mouse_button 1 function */
    5959  int    (*function_2) ();    /* mouse_button 2 function */
  • branches/eam_branches/ohana.20160226/src/kapa2/src/ButtonFunctions.c

    r29938 r39418  
    33
    44int PSfunction (Graphic *graphic, KapaImageWidget *image) {
     5  OHANA_UNUSED_PARAM(graphic);
     6  OHANA_UNUSED_PARAM(image);
    57
    68  int status;
     
    1113
    1214int PNGfunction (Graphic *graphic, KapaImageWidget *image) {
     15  OHANA_UNUSED_PARAM(graphic);
     16  OHANA_UNUSED_PARAM(image);
    1317
    1418  int status;
     
    1923
    2024int JPEGfunction (Graphic *graphic, KapaImageWidget *image) {
     25  OHANA_UNUSED_PARAM(graphic);
     26  OHANA_UNUSED_PARAM(image);
    2127
    2228  int status;
     
    137143/*********** overlay_button functions ************/
    138144int Overlay0 (Graphic *graphic, KapaImageWidget *image) {
     145  OHANA_UNUSED_PARAM(graphic);
    139146
    140147  image[0].overlay[0].active = image[0].overlay[0].active ^ TRUE;
     
    145152
    146153int Overlay1 (Graphic *graphic, KapaImageWidget *image) {
     154  OHANA_UNUSED_PARAM(graphic);
    147155
    148156  image[0].overlay[1].active = image[0].overlay[1].active ^ TRUE;
     
    153161
    154162int Overlay2 (Graphic *graphic, KapaImageWidget *image) {
     163  OHANA_UNUSED_PARAM(graphic);
    155164
    156165  image[0].overlay[2].active = image[0].overlay[2].active ^ TRUE;
     
    161170
    162171int Overlay3 (Graphic *graphic, KapaImageWidget *image) {
     172  OHANA_UNUSED_PARAM(graphic);
    163173
    164174  image[0].overlay[3].active = image[0].overlay[3].active ^ TRUE;
  • branches/eam_branches/ohana.20160226/src/kapa2/src/DrawBitmap.c

    r13320 r39418  
    11# include "Ximage.h"
    22
    3 void DrawBitmap (Graphic *graphic, int x, int y, int dx, int dy, char *bitmap, int mode) {
     3void DrawBitmap (Graphic *graphic, int x, int y, int dx, int dy, unsigned char *bitmap, int mode) {
    44
    55  int i, j, byte_line, byte, bit, flag;
  • branches/eam_branches/ohana.20160226/src/kapa2/src/Image.c

    r37807 r39418  
    132132}
    133133
    134 void InitButtonSize (Button *button, int width, int height, char *bitmap) {
     134void InitButtonSize (Button *button, int width, int height, unsigned char *bitmap) {
    135135  button->dx = width + 2;
    136136  button->dy = height + 2;
  • branches/eam_branches/ohana.20160226/src/kapa2/src/PNGit.c

    r33650 r39418  
    3232  }
    3333
    34   png_ptr = png_create_write_struct (PNG_LIBPNG_VER_STRING, (png_voidp) NULL, (png_voidp) NULL, (png_voidp) NULL);
     34  png_ptr = png_create_write_struct (PNG_LIBPNG_VER_STRING, NULL, NULL, NULL);
    3535  if (!png_ptr) {
    3636    fprintf (stderr, "can't get png structure\n");
     
    4242  if (!info_ptr) {
    4343    fprintf (stderr, "can't get png info structure\n");
    44     png_destroy_write_struct (&png_ptr, (png_infopp) NULL);
     44    png_destroy_write_struct (&png_ptr, NULL);
    4545    fclose (f);
    4646    return (TRUE);
  • branches/eam_branches/ohana.20160226/src/kapa2/src/PaintOverlay.c

    r34088 r39418  
    3434    if (X - dX > Xmax) continue;
    3535    if (Y + dY < Ymin) continue;
    36     if (Y - dY > Ymax);
     36    if (Y - dY > Ymax) continue;
    3737
    3838    pX = (image[0].picture.flipx) ? -1.0 : +1.0;
  • branches/eam_branches/ohana.20160226/src/kapa2/src/Resize.c

    r29938 r39418  
    1212
    1313  // must scan the message before possible return
    14   KiiScanMessage (sock, "%d %d", &NX, &NY);
     14  KiiScanMessage (sock, "%u %u", &NX, &NY);
    1515
    1616  // XXX keep this min limit (or modify for !USE_XWINDOW)?
     
    4242// resise the window so the image in the currently active window fills its section
    4343int ResizeByImage (int sock) {
     44  OHANA_UNUSED_PARAM(sock);
    4445 
    4546  int i, Nsection;
  • branches/eam_branches/ohana.20160226/src/kapa2/src/bDrawOverlay.c

    r34088 r39418  
    4444    if (X - dX > Xmax) continue;
    4545    if (Y + dY < Ymin) continue;
    46     if (Y - dY > Ymax);
     46    if (Y - dY > Ymax) continue;
    4747
    4848    pX = (image[0].picture.flipx) ? -1.0 : +1.0;
Note: See TracChangeset for help on using the changeset viewer.