-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathSDL_rect.fth
63 lines (58 loc) · 2.58 KB
/
SDL_rect.fth
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
\ This file has been generated using SWIG and fsi,
\ and is already platform dependent, search for the corresponding
\ fsi-file to compile it where no one has compiled it before ;)
\ Forth systems have their own own dynamic loader and don't need addional C-Code.
\ That's why this file will just print normal forth-code once compiled
\ and can be used directly with include or require.
\ As all comments are stripped during the compilation, please
\ insert the copyright notice of the original file here.
\ ----===< prefix >===-----
c-library sdl_rect
s" SDL2" add-lib
\c #include <SDL2/SDL_rect.h>
\ ----===< int constants >===-----
\ -------===< structs >===--------
\ struct SDL_Point
begin-structure SDL_Point
drop 0 4 +field SDL_Point-x
drop 4 4 +field SDL_Point-y
drop 8 end-structure
\ struct SDL_FPoint
begin-structure SDL_FPoint
drop 0 4 +field SDL_FPoint-x
drop 4 4 +field SDL_FPoint-y
drop 8 end-structure
\ struct SDL_Rect
begin-structure SDL_Rect
drop 8 4 +field SDL_Rect-w
drop 0 4 +field SDL_Rect-x
drop 4 4 +field SDL_Rect-y
drop 12 4 +field SDL_Rect-h
drop 16 end-structure
\ struct SDL_FRect
begin-structure SDL_FRect
drop 8 4 +field SDL_FRect-w
drop 0 4 +field SDL_FRect-x
drop 4 4 +field SDL_FRect-y
drop 12 4 +field SDL_FRect-h
drop 16 end-structure
\ ------===< functions >===-------
c-function SDL_PointInRect SDL_PointInRect a a -- n ( p r -- )
c-function SDL_RectEmpty SDL_RectEmpty a -- n ( r -- )
c-function SDL_RectEquals SDL_RectEquals a a -- n ( a b -- )
c-function SDL_HasIntersection SDL_HasIntersection a a -- n ( A B -- )
c-function SDL_IntersectRect SDL_IntersectRect a a a -- n ( A B result -- )
c-function SDL_UnionRect SDL_UnionRect a a a -- void ( A B result -- )
c-function SDL_EnclosePoints SDL_EnclosePoints a n a a -- n ( points count clip result -- )
c-function SDL_IntersectRectAndLine SDL_IntersectRectAndLine a a a a a -- n ( rect X1 Y1 X2 Y2 -- )
c-function SDL_PointInFRect SDL_PointInFRect a a -- n ( p r -- )
c-function SDL_FRectEmpty SDL_FRectEmpty a -- n ( r -- )
c-function SDL_FRectEqualsEpsilon SDL_FRectEqualsEpsilon a a r -- n ( a b epsilon -- )
c-function SDL_FRectEquals SDL_FRectEquals a a -- n ( a b -- )
c-function SDL_HasIntersectionF SDL_HasIntersectionF a a -- n ( A B -- )
c-function SDL_IntersectFRect SDL_IntersectFRect a a a -- n ( A B result -- )
c-function SDL_UnionFRect SDL_UnionFRect a a a -- void ( A B result -- )
c-function SDL_EncloseFPoints SDL_EncloseFPoints a n a a -- n ( points count clip result -- )
c-function SDL_IntersectFRectAndLine SDL_IntersectFRectAndLine a a a a a -- n ( rect X1 Y1 X2 Y2 -- )
\ ----===< postfix >===-----
end-c-library