bitblt.h

changeset 48
3d0be1c1c1b2
parent 47
bfc6aaa089b0
child 53
bb180150e603
     1.1 diff -r bfc6aaa089b0 -r 3d0be1c1c1b2 bitblt.h
     1.2 --- a/bitblt.h	Mon Aug 26 05:43:49 2002 +0000
     1.3 +++ b/bitblt.h	Mon Aug 26 06:03:55 2002 +0000
     1.4 @@ -1,7 +1,7 @@
     1.5  typedef struct Point
     1.6  {
     1.7 -  s32 x;
     1.8 -  s32 y;
     1.9 +  int32_t x;
    1.10 +  int32_t y;
    1.11  } Point;
    1.12  
    1.13  typedef struct Rect
    1.14 @@ -10,18 +10,18 @@
    1.15    Point max;
    1.16  } Rect;
    1.17  
    1.18 -static inline s32 rect_width (Rect *r)
    1.19 +static inline int32_t rect_width (Rect *r)
    1.20  {
    1.21    return (r->max.x - r->min.x);
    1.22  }
    1.23  
    1.24 -static inline s32 rect_height (Rect *r)
    1.25 +static inline int32_t rect_height (Rect *r)
    1.26  {
    1.27    return (r->max.y - r->min.y);
    1.28  }
    1.29  
    1.30  
    1.31 -typedef u32 word_type;
    1.32 +typedef uint32_t word_type;
    1.33  #define BITS_PER_WORD (8 * sizeof (word_type))
    1.34  #define ALL_ONES (~ 0U)
    1.35  
    1.36 @@ -30,7 +30,7 @@
    1.37  {
    1.38    word_type *bits;
    1.39    Rect rect;
    1.40 -  u32 row_words;
    1.41 +  uint32_t row_words;
    1.42  } Bitmap;
    1.43  
    1.44  
    1.45 @@ -43,8 +43,8 @@
    1.46  Bitmap *create_bitmap (Rect *rect);
    1.47  void free_bitmap (Bitmap *bitmap);
    1.48  
    1.49 -boolean get_pixel (Bitmap *bitmap, Point coord);
    1.50 -void set_pixel (Bitmap *bitmap, Point coord, boolean value);
    1.51 +bool get_pixel (Bitmap *bitmap, Point coord);
    1.52 +void set_pixel (Bitmap *bitmap, Point coord, bool value);
    1.53  
    1.54  
    1.55  Bitmap *bitblt (Bitmap *src_bitmap,
    1.56 @@ -68,4 +68,4 @@
    1.57  void rot_270 (Bitmap *src);  /* transpose + flip_v */
    1.58  
    1.59  
    1.60 -void reverse_bits (u8 *p, int byte_count);
    1.61 +void reverse_bits (uint8_t *p, int byte_count);