PEXOCCSetGlobalTransform2D - Set Global Transformation 2D (5.0)


Synopsis

 
   void PEXOCCSetGlobalTransform2D(
        PEXOCC context,
        PEXMatrix3x3 transform,
        PEXMatrixHints hints
   )
 

 
   void PEXSetGlobalTransform2D(
        Display *display,
        XID resource_id,
        PEXOCRequestType req_type,
        PEXMatrix3x3 transform
   )
 

Arguments

context
An OC context returned by a successful PEXCreateOCC call.

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

resource_id (OCC)
The resource identifier of the renderer or structure.

req_type (OCC)
The request type for the output command (PEXOCRender, PEXOCStore, PEXOCRenderSingle or PEXOCStoreSingle).

transform
The new global transformation matrix.

hints
Hints for the new global transformation matrix. (PEXMHNone, PEXMHIdentity, PEXMHTranslation, PEXMHRotation, PEXMHReflection, PEXMHUniformScale, PEXMHNonUniformScale, PEXMHShear, PEXMHPerspProjective, PEXMHNonPerspProjective, PEXMH3DTo2DParProjection, PEXMH3DTo2DPerspProjection, PEXMHZero, PEXMHSingularUnknown, PEXMHNonSingularUnknown). Available only in the OCC form of the function.

Returns

None.

Description

Invoke PEXOCCSetGlobalTransform2D to create an attribute output command which replaces the current global transformation matrix with the specified matrix in the renderer's pipeline state.

The PEXOCCSetGlobalTransform2D function generates a PEXOCGlobalTransform2DWithHints output command. However, if the PEX server on the display connection is version 5.1 or the Alternate Protocol Level is 5.1, then this function generates a PEXOCGlobalTransform2D output command, ignoring any supplied hint.

The PEXSetGlobalTransform2D function generates a PEXOCGlobalTransform2D output command.

This attribute output command is similar to the PEXOCCSetGlobalTransform function except that you specify the global transformation matrix as a 3 x 3 matrix.

Before the implementation replaces the global transformation matrix, the 3 x 3 matrix is expanded to a 4 x 4 matrix as follows:

The matrix hints, if given, are representative of the matrix after it has been expanded.

This function is a member of the global attribute set.

Errors

BadPEXRenderer
The specified renderer resource identifier is invalid.

BadPEXStructure
The specified structure resource identifier is invalid.

See Also

For an overview and for a list of all output attribute functions, see Output Attribute Functions.