Museum

Home

Lab Overview

Retrotechnology Articles

⇒ Online Manual

Media Vault

Software Library

Restoration Projects

Artifacts Sought



GSLOP(3g,L)                 AIX Technical Reference                 GSLOP(3g,L)



-------------------------------------------------------------------------------
gslop



PURPOSE

Specifies the logical operation used when drawing lines.

C SYNTAX

int gslop_ (operation)

int *operation;

FORTRAN SYNTAX

INTEGER function gslop (operation)

INTEGER operation

PASCAL SYNTAX

FUNCTION gslop_ (

VAR operation INTEGER;
): INTEGER [PUBLIC];

DESCRIPTION

The gslop subroutine specifies the logical operation used for drawing the GSL
line-oriented, fill, save/restore, and polymarker primitives.  It does not
apply to the text primitives.

Parameters

operation         Indicates the logical operation to perform between the
                  primitive being drawn and the current contents of the frame
                  buffer.

                  In the following table, please note:

                    o The source pixels represent bits of data to be merged in
                      some way with the corresponding bits of data in the
                      destination rectangle.

                    o The first three columns of the table specify the
                      operations you can perform, and the Code column contains
                      the corresponding value you should specify for the
                      operation parameter.

                    o A ~ (tilde) represents the logical INVERSE.



Processed November 7, 1990        GSLOP(3g,L)                                 1





GSLOP(3g,L)                 AIX Technical Reference                 GSLOP(3g,L)




            Type of     Logical           Type of                 Code
            Source      Operation         Destination

                                           Destination clear       0
                                           Set Destination        15
                        No operation       Destination             5
                                          ~Destination            10
             Source     REPLACE            Destination             3
             Source     AND                Destination             1
             Source     AND               ~Destination             2
             Source     Exclusive-or       Destination             6
             Source     OR                 Destination             7
             Source     OR                ~Destination            11
            ~Source     REPLACE            Destination            12
            ~Source     AND                Destination             4
            ~Source     AND               ~Destination             8
            ~Source     Exclusive-or       Destination             9
            ~Source     OR                 Destination            13
            ~Source     OR                ~Destination            14

                  Replace (3) is the default logical operation.

Only REPLACE, AND, OR, and Exclusive-or (codes 3, 1, 7, and 6, respectively),
are supported for VGA displays.

For printers, the operations performed are the same as those for displays,
except that a value of 0 turns the color off, and a value of 15 changes the
color to white.

For plotters, the default and only valid logical operation is logical OR.  The
plotters interpret this as an overstrike.  The GSL performs each of the boolean
operations for each bit of the source and destination color values enabled by
the plane mask. The destination receives the color value that results from the
operation.

The logical operations are performed on the color index rather than the color
itself.  This can cause some operations on color displays to produce results
that are not expected.

RETURN VALUE

GS_SUCC  Successful.
GS_LONS  Logical operation not supported.











Processed November 7, 1990        GSLOP(3g,L)                                 2



Typewritten Software • bear@typewritten.org • Edmonds, WA 98026