EU1KY AA
hit.h
Go to the documentation of this file.
1
/*
2
* (c) Yury Kuchura
3
* kuchura@gmail.com
4
*
5
* This code can be used on terms of WTFPL Version 2 (http://www.wtfpl.net/).
6
*/
7
8
#ifndef _HIT_H_
9
#define _HIT_H_
10
11
#include <stdint.h>
12
#include "
LCD.h
"
13
#include "
main.h
"
14
15
struct
HitRect
16
{
17
uint32_t
x1
;
18
uint32_t
y1
;
19
uint32_t
x2
;
20
uint32_t
y2
;
21
void
(*
HitCallback
)(
void
);
22
};
23
24
#define HITRECT(x0, y0, width, height, callback) \
25
{(x0), (y0), (x0) + (width) - 1, (y0) + (height) - 1, (callback)}
26
27
#define HITEND { 0xFFFFFFFFul, 0, 0xFFFFFFFFul, 0, 0 }
28
29
int
HitTest
(
const
struct
HitRect
* r, uint32_t x, uint32_t y);
30
void
ShowHitRect
(
const
struct
HitRect
*
hitArr
);
// WK
31
32
#endif
HitRect
Definition:
hit.h:15
hitArr
static const struct HitRect hitArr[]
Definition:
tdr.c:511
HitRect::y2
uint32_t y2
Definition:
hit.h:20
main.h
HitRect::y1
uint32_t y1
Definition:
hit.h:18
HitRect::HitCallback
void(* HitCallback)(void)
Definition:
hit.h:21
HitTest
int HitTest(const struct HitRect *r, uint32_t x, uint32_t y)
Definition:
hit.c:24
HitRect::x1
uint32_t x1
Definition:
hit.h:17
LCD.h
ShowHitRect
void ShowHitRect(const struct HitRect *hitArr)
Definition:
hit.c:13
void
void(Delete(void))
Definition:
mainwnd.c:360
HitRect::x2
uint32_t x2
Definition:
hit.h:19
analyzer
lcd
hit.h
Generated on Fri Mar 8 2019 12:41:37 for EU1KY AA by
1.8.11