mav_gfxWindowOpen(3)

NAME
mav_gfxWindowOpen - Open a window.

LEVEL
Maverik Level 3

SYNTAX
void mav_gfxWindowOpen(int id, int x, int y, int w, int h, char *name, char *disp, int wmp, int sb, int qb, int ms, int ab, int stenb, int desta, int *wret, int *hret);

ARGUMENTS
A unique handle to identify the window in subsequent calls. (x,y) position of window. Width and height of window. Name to place on titlebar. Name of X display on which to open window. Requests window manager positioning of window. Requests a single buffered graphics context. Requests a quad buffered graphics context. Requests a multisampled graphics context. Requests an accumulation buffered graphics context. Requests a stencil buffered graphics context. Requests a destination alpha buffered graphics context. Returns the actual width and height of the window opened.

DESCRIPTION
This function asks the window manager on the X display specified by disp to open a window and create an associated graphics context. This window is identified in subsequent mav_gfx* calls by the unique integer id. If disp is set to NULL, then the display defined by the DISPLAY environment variable is used.

Graphics contexts are, by default, double buffered and have the maximum colour and depth bits allowed by the hardware. The parameters sb, qb, ms, ab, stenb and desta (1 = TRUE, 0 = FALSE) control the creation of the graphics context. If a particular configuration is not supported by the hardware an error message is written to the shell window and execution halts. By default, multiple graphical contexts are "shared" with the first context opened (ie. contexts share a common set of display lists, textures etc).

Windows are of X resource class "MaverikApp". This allows the potential, depending on your window manager, for controlling window attributes via the .Xdefaults file. For example, adding the line "4Dwm*MaverikApp*clientDecoration: none" to your .Xdefault would cause Maverik windows to have no decoration on SGI's default window manager 4Dwm.

The window manager may not honour your requested size or position. The actual size of the window is returned in wret and hret. Setting wmp to TRUE lets the window manager place the window.