[ Next Article | Previous Article | Book Contents | Library Home | Legal | Search ]
GL3.2 for AIX: Graphics Library (GL) Technical Reference

getXdpy or getXwid Subroutine

Purpose

Returns the Enhanced X-Windows connection for the given GL session, or the window ID of the current GL window.

Library

Graphics Library

C (libgl.a)

FORTRAN (libfgl.a)

C Syntax

Display *getXdpy()
Window getXwid()

FORTRAN Syntax

INTEGER *4 FUNCTION GETXDPY()
INTEGER *4 FUNCTION GETXWID()

Description

The getXdpy subroutine returns a pointer to a data structure that describes the Enhanced X-Windows connection being used by the GL library to communicate with the X server.

The getXwid subroutine returns the Enhanced X-Windows window ID of the current GL window.

The Enhanced X-Windows display connection, with the Enhanced X-Windows window ID, enables applications programs to use Enhanced X-Windows routines to modify a GL window. With this ability, application programs can do several things, including the following:

Not all possible combinations of GL and Enhanced X-Windows calls result in defined behavior, however. In particular, avoid the following usages:

The previous brief restrictions are explained more fully in "Using Enhanced X-Windows Calls with GL Subroutines" in GL3.2 Version 4 for AIX: Programming Concepts.

All GL windows opened by a client normally share one Enhanced X-Windows connection. GL rendering can be performed only locally; that is, a GL application must execute on the same physical machine as that which contains the display adapter. GL does not support a client-server model of network graphics programming.

Return Values

getXdpy Returns a pointer to the Enhanced X-Windows Display structure.
getXwid Returns the Enhanced X-Windows window ID.

Example

Example programs showing the usage of the getXdpy and getXwid subroutines can be found in the /usr/lpp/GL/examples directory.

Implementation Specifics

This subroutine is part of GL in the AIXwindows Environment/6000 Version 1, Release 2 with AIXwindows/3D Feature.

The POWERgraphics GXT1000 supports RGB and color index modes by creating separate separate X11 windows--one window is permanently in RGB mode, and the other is permanently in color index mode. Both of these windows are wrapped in a single parent window. The getXwid subroutine returns the X11 window handle of that parent window. Standard X11 interfaces can be used to determine the child windows of the parent.

Files

/usr/include/gl/gl.h Contains C language constant and variable type definitions for GL.
/usr/include/gl/fgl.h Contains FORTRAN constant and variable type definitions for GL.
/usr/include/X11/Xlib.h Contains C language constant and variable type definitions for version X11 of Enhanced X-Windows.

Related Information

The loadXfont subroutine, charstr subroutine, XReparentWindow subroutine.

Using Enhanced X-Windows Calls with GL Subroutines in GL3.2 Version 4 for AIX: Programming Concepts.


[ Next Article | Previous Article | Book Contents | Library Home | Legal | Search ]