PEXSetAltProtocolLevel - Set Alternate Protocol Level Generation


Synopsis

 
   void PEXSetAltProtocolLevel(
        Display *display,
        int level
   )
 

Arguments

display
A pointer to a display structure returned by a successful XOpenDisplay call.

level
The alternate protocol level (PEXProtocolLevel5_1, PEXProtocolLevel5_2)

Returns

None.

Description

Invoke PEXSetAltProtocolLevel to set the alternate protocol level that PEXlib uses to generate protocol when it is possible to encode a request or output command with an older variety of the protocol element.

The default alternate protocol level is PEXProtocolLevel5_2.

Use this function to set a lower alternate protocol level when you are designing a PEXlib application that is intended to work with that lower protocol level. You must, of course, restrict the application to use only the features at that protocol level. However, some PEXlib functions are capable of generating protocol for the intended protocol element at different protocol levels and do so at the highest level, unless instructed differently by this function.

For example, there are two different protocol encodings for the TriangleStrip output command. Normally, the PEXOCCTriangleStrip function encodes the primitive with the 5.2 version of the OC. If, for some reason, you need to force PEXlib to generate the 5.1 encoding, use this function to set the alternate protocol level to PEXProtocolLevel5_1. Take care to specify only the TriangleStrip data that is supported by PEX 5.1, otherwise an error may occur.

You must invoke PEXInitialize prior to using this function. If you specify an invalid value for level, the function ignores that value and the previous alternate protocol level remains in effect.

Errors

None.

See Also

For an overview, see PEXlib Access and Information Functions.