www.4dsystems.com.au
µ
V
G
A
-PICASO-
MD1
31
6.1.19
Draw
r
ectangle
(
r
)
Serial Syntax :
cmd, x1
(msb:lsb),
y1
(msb:lsb),
x2
(msb:lsb),
y2
(msb:lsb),
colour
4DGL Syntax :
(refer to 4DGL programmers manual)
cmd :
72
hex
, r
ascii
x1 :
top left horizontal start position. 2 bytes
y1 :
top left vertical start position. 2 bytes
x2 :
bottom right horizontal end position. 2 bytes
y2 :
bottom right vertical end position. 2 bytes
colour :
rectangle colour value. 1 byte
Description :
This command will draw a rectangle of specified area on the screen.
x1, y1
refers to the top left corner of the area and
x2, y2
refers to the bottom right
hand corner of the rectangle on the screen. If colour is chosen to be that of the
background then the effect will be erasure. If Pen Size value was previously set to 0
rectangle will be solid, otherwise wire frame if value was 1.
Example :
70
hex
, 00
hex
, 20
hex
,
00
hex
, 20
hex
, 00
hex
, 40
hex
, 00
hex
, 50
hex
,
C0
hex
Draws a BLUE (
C0
hex) rectangle that has its top left corner at x1=32, y1=32 and its
bottom right corner at x2=64, y2=80.