GRASS Programmer's Manual
6.4.2(2012)
Main Page
Related Pages
Namespaces
Data Structures
Files
File List
Globals
All
Data Structures
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Macros
Pages
driver/Box.c
Go to the documentation of this file.
1
#include "
driver.h
"
2
#include "
driverlib.h
"
3
4
void
COM_Box_abs
(
int
x1,
int
y1,
int
x2,
int
y2)
5
{
6
int
x[4], y[4];
7
8
if
(
driver
->
Box_abs
) {
9
(*
driver
->
Box_abs
) (x1, y1, x2, y2);
10
return
;
11
}
12
13
x[0] = x1;
14
y[0] = y1;
15
x[1] = x1;
16
y[1] = y2;
17
x[2] = x2;
18
y[2] = y2;
19
x[3] = x2;
20
y[3] = y1;
21
22
COM_Polygon_abs
(x, y, 4);
23
}
24
25
void
COM_Box_rel
(
int
x,
int
y)
26
{
27
if
(
driver
->
Box_rel
) {
28
(*
driver
->
Box_rel
) (x, y);
29
return
;
30
}
31
32
COM_Box_abs
(
cur_x
,
cur_y
,
cur_x
+ x,
cur_y
+ y);
33
}
lib
driver
Box.c
Generated on Sun Mar 16 2014 05:07:42 for GRASS Programmer's Manual by
1.8.1.2