[ Previous | Next | Contents | Glossary | Home | Search ]
The graPHIGS Programming Interface: ISO PHIGS Subroutine Reference

INITIALIZE STROKE 3 (PHOP,WSOP,*,*)

Purpose

Use Initialize Stroke 3 to initialize the specified stroke device.

The Initialize Stroke 3 subroutine stores the initial stroke, initial view index, prompt/echo type, echo volume and stroke data record in the workstation state list for the specified device.

For all prompt and echo types, the first entry of the stroke data record is the input buffer size, which is an integer in the range(1..n). The graPHIGS API compares this against the available input buffer size for the specified stroke device. If the requested buffer size is greater, then the graPHIGS API records the available size in the workstation state list instead of the specified input buffer size. If the initial stroke is longer than the buffer size, then the graPHIGS API issues an error.

When a stroke measure process begins, it acquires a buffer of the current input buffer size. The graPHIGS API copies the initial stroke pointlist into this buffer, and places the editing position at the initial buffer editing position. The replacement of points begins at this initial position. The x, y, z, and time intervals (where possible) of the data record control the frequency and density of stroke points.

This function supports the following prompt/echo types:

  • Type One displays the current stroke using a workstation-dependent technique.

  • Type Three displays a marker at each point of the current stroke. The marker representation is selected by a marker index, which is stored in the stroke data record.

  • Type Four displays a line joining successive points in the current stroke. A polyline index in the stroke data record selects the line representation used.

    Note:

    The stroke device must be in Request mode.

    Language Bindings

  • C

    pinit_stroke3 (ws_id, stroke_num, init_view_ind, init_stroke, pet, echo_vol, stroke_data)

    Input Parameters

    Pint ws_id
    Workstation identifier.

    Pint stroke_num
    Stroke device number (>=1).

    Pint init_view_ind
    Initial view index (>=0).

    const Ppoint_list3 *init_stroke
    Initial stroke in WC.

    Pint pet
    Prompt and echo type.

    const Plimit3 *echo_vol
    Echo volume in DC.

    const Pstroke_data3 *stroke_data
    Data record.

    FORTRAN

    PINSK3 (wkid, skdnr, iviewi, n, ipx, ipy, ipz, pet, evol, ldr, datrec)

    Input Parameters

    integer wkid
    Workstation identifier.

    integer stdnr
    Stroke device number (>=1).

    integer iviewi
    Initial view index (>=0).

    integer n
    Number of coordinates of initial stroke.

    real ipx (*)
    x coordinates of initial stroke in WC. The actual arguments are dimensioned by at least max(1,n).

    real ipy (*)
    y coordinates of initial stroke in WC. The actual arguments are dimensioned by at least max(1,n).

    real ipz (*)
    z coordinates of initial stroke in WC. The actual arguments are dimensioned by at least max(1,n).

    integer pet
    Prompt and echo type.

    real evol(6)
    Echo volume in DC (XMIN, XMAX, YMIN, YMAX, ZMIN, ZMAX).

    integer ldr
    Dimension of the data record array.

    character*80 datrec(ldr)
    Data record.

    The pprec parameters used to build the stroke input data record for pet= 1 are as follows: (IL=2, IA=input buffer size, editing position, RL=3, RA=x interval, y interval, time interval in seconds, SL=0, LSTR=(), STR=()).

    The pprec parameters used to build the stroke input data record for pet= 3 are as follows: (IL=9, IA=input buffer size, editing position, unused, marker type ASF, marker size scale factor ASF, polymarker color index ASF, polymarker index, marker type, polymarker color index, RL=4, RA=x interval, y interval, time interval in seconds, marker size scale factor, SL=0, LSTR=(), STR=()).

    The pprec parameters used to build the stroke input data record for pet= 4 are as follows: (IL=9, IA=input buffer size, editing position, unused, line type ASF, line width scale factor ASF, polyline color index ASF, polyline index, line type, polyline color index, RL=5, RA=x interval, y interval, time interval in seconds, line width scale factor, SL=0, LSTR=(), STR=()).

    Errors

    3
    Function Requires State (PHOP,WSOP,*,*)
    54
    Specified Workstation Is Not Open
    61
    Specified Workstation Is Not Of Category Input Or Outin
    250
    Specified Device Not Available On Workstation
    251
    Function Requires Input Device To Be In Request Mode
    254
    Invalid Echo Area/Volume: XMIN>=XMAX, YMIN>=YMAX OR ZMIN>ZMAX
    255
    Echo Area/Volume Boundary Point(s) Outside Device Range
    253
    Prompt/Echo Type Not Available On Specified Workstation
    260
    Input Device Data Record Field Is In Error
    261
    Initial Value Is Invalid
    262
    Number Of Points In Initial Stroke > Buffer Size
    114
    View Index Value < ZERO

    Related Subroutines

  • Inquire Stroke Device State 3

  • Inquire Default Stroke Device Data 3

  • Inquire Display Space Size

  • Inquire Number Of Available Logical Input Devices

  • Pack Data Record

  • Set Stroke Mode


  • [ Previous | Next | Contents | Glossary | Home | Search ]