•  Back 
  •  VDI FONTGDOS 
  •  Index 
  •  Tree View 
  •  Cross references 
  •  %About 
  •  Show info about hypertext 
  •  View a new file 
Topic       : The ATARI Compendium
Author      : Scott Sanders / JAY Software
Version     : 1.25 (20/6/2003)
Subject     : Documentation
Nodes       : 1117
Index Size  : 32614
HCP-Version : 6
Compiled on : Atari
@charset    : UTF-8
@lang       : en
@default    : 
@help       : %About
@options    : +g -i -t4 +y +z
@width      : 100
View Ref-Filev_bez_fill()
v_bez_on()
v_bez_off()
v_bez_qual()
v_set_app_buff()
v_bez()                                                                 VDI

Syntax

VOID v_bez( handle, count, pxy, bezarr, extent, totpts, totmoves )
WORD handle, count;
WORD *pxy, *extent;
char *bezarr;
WORD *totpts, *totmoves;

Function      v_bez() outputs a bezier curve path.

Opcode        6

Sub-Opcode    13

Availability  Available only with FONTGDOS, FSMGDOS or SpeedoGDOS.

Parameters    handle is a valid workstation handle. count specifies the
              number of vertices in the path. pxy is a pointer to a WORD
              array (count * 2) WORDs long containing the vertices where
              pxy[0] is the X coordinate of the first point, pxy[1] is the
              Y coordinate of the first point and so on. bezarr is
              a pointer to a character array count BYTEs long where each
              byte is a bit mask with two flags that dictate the
              interpretation of each vertice as follows:

              Name          Bit   Meaning

              BEZ_BEZIER     0    If set, begin a 4-point bezier
              (0x01)              segment (anchor point, followed
              BEZ_POLYLINE        by two control points, followed
              (0x00)              anchor point), otherwise, begin
                                  a polyline segment.

              BEZ_NODRAW     1    If set, jump to this point without
              (0x02)              drawing.

              -             2-7   Currently unused (set to 0).

              Upon exit, a 4 WORD array pointed to by extent is filled in
              with a VDI format rectangle defining a bounding box of the
              path drawn. The WORD pointed to by totpts is filled in with
              the number of points in the resulting path whereas the total
              number of moves is stored in the WORD pointed to by
              totmoves.

Binding       WORD i;

              contrl[0] = 6;
              contrl[1] = count;
              contrl[3] = (count + 1)/2;
              contrl[5] = 13;
              contrl[6] = handle;

              for(i = 0;i < count; i++)
              {
               intin[i] = (WORD)bezarr[i];
               ptsin[ i*2 ] = pxy[ i*2 ];
               ptsin[ (i*2) + 1 ] = pxy[ (i*2) + 1];
              }

              vdi();

              *totpts = intin[0];
              *totmoves = intin[1];

              for(i = 0; i < 4; i++)
               extent[i] = ptsout[i];

See Also      v_bez_fill(), v_bez_on(), v_bez_off(), v_bez_qual(),
              v_set_app_buff()

Group         VDI FONTGDOS