Blame GLwDrawA.h

Packit Service 7a208c
/*
Packit Service 7a208c
 * (c) Copyright 1993, Silicon Graphics, Inc.
Packit Service 7a208c
 * ALL RIGHTS RESERVED 
Packit Service 7a208c
 * Permission to use, copy, modify, and distribute this software for 
Packit Service 7a208c
 * any purpose and without fee is hereby granted, provided that the above
Packit Service 7a208c
 * copyright notice appear in all copies and that both the copyright notice
Packit Service 7a208c
 * and this permission notice appear in supporting documentation, and that 
Packit Service 7a208c
 * the name of Silicon Graphics, Inc. not be used in advertising
Packit Service 7a208c
 * or publicity pertaining to distribution of the software without specific,
Packit Service 7a208c
 * written prior permission. 
Packit Service 7a208c
 *
Packit Service 7a208c
 * THE MATERIAL EMBODIED ON THIS SOFTWARE IS PROVIDED TO YOU "AS-IS"
Packit Service 7a208c
 * AND WITHOUT WARRANTY OF ANY KIND, EXPRESS, IMPLIED OR OTHERWISE,
Packit Service 7a208c
 * INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF MERCHANTABILITY OR
Packit Service 7a208c
 * FITNESS FOR A PARTICULAR PURPOSE.  IN NO EVENT SHALL SILICON
Packit Service 7a208c
 * GRAPHICS, INC.  BE LIABLE TO YOU OR ANYONE ELSE FOR ANY DIRECT,
Packit Service 7a208c
 * SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY
Packit Service 7a208c
 * KIND, OR ANY DAMAGES WHATSOEVER, INCLUDING WITHOUT LIMITATION,
Packit Service 7a208c
 * LOSS OF PROFIT, LOSS OF USE, SAVINGS OR REVENUE, OR THE CLAIMS OF
Packit Service 7a208c
 * THIRD PARTIES, WHETHER OR NOT SILICON GRAPHICS, INC.  HAS BEEN
Packit Service 7a208c
 * ADVISED OF THE POSSIBILITY OF SUCH LOSS, HOWEVER CAUSED AND ON
Packit Service 7a208c
 * ANY THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE
Packit Service 7a208c
 * POSSESSION, USE OR PERFORMANCE OF THIS SOFTWARE.
Packit Service 7a208c
 * 
Packit Service 7a208c
 * 
Packit Service 7a208c
 * US Government Users Restricted Rights 
Packit Service 7a208c
 * Use, duplication, or disclosure by the Government is subject to
Packit Service 7a208c
 * restrictions set forth in FAR 52.227.19(c)(2) or subparagraph
Packit Service 7a208c
 * (c)(1)(ii) of the Rights in Technical Data and Computer Software
Packit Service 7a208c
 * clause at DFARS 252.227-7013 and/or in similar or successor
Packit Service 7a208c
 * clauses in the FAR or the DOD or NASA FAR Supplement.
Packit Service 7a208c
 * Unpublished-- rights reserved under the copyright laws of the
Packit Service 7a208c
 * United States.  Contractor/manufacturer is Silicon Graphics,
Packit Service 7a208c
 * Inc., 2011 N.  Shoreline Blvd., Mountain View, CA 94039-7311.
Packit Service 7a208c
 *
Packit Service 7a208c
 * OpenGL(TM) is a trademark of Silicon Graphics, Inc.
Packit Service 7a208c
 */
Packit Service 7a208c
#ifndef _GLwDrawA_h
Packit Service 7a208c
#define _GLwDrawA_h
Packit Service 7a208c
Packit Service 7a208c
#include <GL/glx.h>
Packit Service 7a208c
#include <GL/gl.h>
Packit Service 7a208c
Packit Service 7a208c
/****************************************************************
Packit Service 7a208c
 *
Packit Service 7a208c
 * GLwDrawingArea widgets
Packit Service 7a208c
 *
Packit Service 7a208c
 ****************************************************************/
Packit Service 7a208c
Packit Service 7a208c
/* Resources:
Packit Service 7a208c
Packit Service 7a208c
 Name		     Class		RepType		Default Value
Packit Service 7a208c
 ----		     -----		-------		-------------
Packit Service 7a208c
 attribList	     AttribList		int *		NULL
Packit Service 7a208c
 visualInfo	     VisualInfo		VisualInfo	NULL
Packit Service 7a208c
 installColormap     InstallColormap	Boolean		TRUE
Packit Service 7a208c
 allocateBackground  AllocateColors	Boolean		FALSE
Packit Service 7a208c
 allocateOtherColors AllocateColors	Boolean		FALSE
Packit Service 7a208c
 installBackground   InstallBackground	Boolean		TRUE
Packit Service 7a208c
 exposeCallback      Callback		Pointer		NULL
Packit Service 7a208c
 ginitCallback       Callback		Pointer		NULL
Packit Service 7a208c
 inputCallback       Callback		Pointer		NULL
Packit Service 7a208c
 resizeCallback      Callback		Pointer		NULL
Packit Service 7a208c
Packit Service 7a208c
*** The following resources all correspond to the GLX configuration
Packit Service 7a208c
*** attributes and are used to create the attribList if it is NULL
Packit Service 7a208c
 bufferSize	     BufferSize		int		0
Packit Service 7a208c
 level		     Level		int		0
Packit Service 7a208c
 rgba		     Rgba		Boolean		FALSE
Packit Service 7a208c
 doublebuffer	     Doublebuffer	Boolean		FALSE
Packit Service 7a208c
 stereo		     Stereo		Boolean		FALSE
Packit Service 7a208c
 auxBuffers	     AuxBuffers		int		0
Packit Service 7a208c
 redSize	     ColorSize		int		1
Packit Service 7a208c
 greenSize	     ColorSize		int		1
Packit Service 7a208c
 blueSize	     ColorSize		int		1
Packit Service 7a208c
 alphaSize	     AlphaSize		int		0
Packit Service 7a208c
 depthSize	     DepthSize		int		0
Packit Service 7a208c
 stencilSize	     StencilSize	int		0
Packit Service 7a208c
 accumRedSize	     AccumColorSize	int		0
Packit Service 7a208c
 accumGreenSize	     AccumColorSize	int		0
Packit Service 7a208c
 accumBlueSize	     AccumColorSize	int		0
Packit Service 7a208c
 accumAlphaSize	     AccumAlphaSize	int		0
Packit Service 7a208c
*/
Packit Service 7a208c
Packit Service 7a208c
#define GLwNattribList		"attribList"
Packit Service 7a208c
#define GLwCAttribList		"AttribList"
Packit Service 7a208c
#define GLwNvisualInfo		"visualInfo"
Packit Service 7a208c
#define GLwCVisualInfo		"VisualInfo"
Packit Service 7a208c
#define GLwRVisualInfo		"VisualInfo"
Packit Service 7a208c
Packit Service 7a208c
#define GLwNinstallColormap	"installColormap"
Packit Service 7a208c
#define GLwCInstallColormap	"InstallColormap"
Packit Service 7a208c
#define GLwNallocateBackground	"allocateBackground"
Packit Service 7a208c
#define GLwNallocateOtherColors	"allocateOtherColors"
Packit Service 7a208c
#define GLwCAllocateColors	"AllocateColors"
Packit Service 7a208c
#define GLwNinstallBackground	"installBackground"
Packit Service 7a208c
#define GLwCInstallBackground	"InstallBackground"
Packit Service 7a208c
Packit Service 7a208c
#define GLwCCallback		"Callback"
Packit Service 7a208c
#define GLwNexposeCallback	"exposeCallback"
Packit Service 7a208c
#define GLwNginitCallback	"ginitCallback"
Packit Service 7a208c
#define GLwNresizeCallback	"resizeCallback"
Packit Service 7a208c
#define GLwNinputCallback	"inputCallback"
Packit Service 7a208c
Packit Service 7a208c
#define GLwNbufferSize		"bufferSize"
Packit Service 7a208c
#define GLwCBufferSize		"BufferSize"
Packit Service 7a208c
#define GLwNlevel		"level"
Packit Service 7a208c
#define GLwCLevel		"Level"
Packit Service 7a208c
#define GLwNrgba		"rgba"
Packit Service 7a208c
#define GLwCRgba		"Rgba"
Packit Service 7a208c
#define GLwNdoublebuffer	"doublebuffer"
Packit Service 7a208c
#define GLwCDoublebuffer	"Doublebuffer"
Packit Service 7a208c
#define GLwNstereo		"stereo"
Packit Service 7a208c
#define GLwCStereo		"Stereo"
Packit Service 7a208c
#define GLwNauxBuffers		"auxBuffers"
Packit Service 7a208c
#define GLwCAuxBuffers		"AuxBuffers"
Packit Service 7a208c
#define GLwNredSize		"redSize"
Packit Service 7a208c
#define GLwNgreenSize		"greenSize"
Packit Service 7a208c
#define GLwNblueSize		"blueSize"
Packit Service 7a208c
#define GLwCColorSize		"ColorSize"
Packit Service 7a208c
#define GLwNalphaSize		"alphaSize"
Packit Service 7a208c
#define GLwCAlphaSize		"AlphaSize"
Packit Service 7a208c
#define GLwNdepthSize		"depthSize"
Packit Service 7a208c
#define GLwCDepthSize		"DepthSize"
Packit Service 7a208c
#define GLwNstencilSize		"stencilSize"
Packit Service 7a208c
#define GLwCStencilSize		"StencilSize"
Packit Service 7a208c
#define GLwNaccumRedSize	"accumRedSize"
Packit Service 7a208c
#define GLwNaccumGreenSize	"accumGreenSize"
Packit Service 7a208c
#define GLwNaccumBlueSize	"accumBlueSize"
Packit Service 7a208c
#define GLwCAccumColorSize	"AccumColorSize"
Packit Service 7a208c
#define GLwNaccumAlphaSize	"accumAlphaSize"
Packit Service 7a208c
#define GLwCAccumAlphaSize	"AccumAlphaSize"
Packit Service 7a208c
Packit Service 7a208c
#if (defined(__GNUC__) && __GNUC__ >= 4) || (defined(__SUNPRO_C) && (__SUNPRO_C >= 0x590))
Packit Service 7a208c
#  define GLAPIVAR extern __attribute__((visibility("default")))
Packit Service 7a208c
#else
Packit Service 7a208c
#  define GLAPIVAR extern
Packit Service 7a208c
#endif
Packit Service 7a208c
Packit Service 7a208c
#ifdef __GLX_MOTIF
Packit Service 7a208c
Packit Service 7a208c
typedef struct _GLwMDrawingAreaClassRec	*GLwMDrawingAreaWidgetClass;
Packit Service 7a208c
typedef struct _GLwMDrawingAreaRec	*GLwMDrawingAreaWidget;
Packit Service 7a208c
Packit Service 7a208c
GLAPIVAR WidgetClass glwMDrawingAreaWidgetClass;
Packit Service 7a208c
Packit Service 7a208c
Packit Service 7a208c
#else 
Packit Service 7a208c
Packit Service 7a208c
typedef struct _GLwDrawingAreaClassRec	*GLwDrawingAreaWidgetClass;
Packit Service 7a208c
typedef struct _GLwDrawingAreaRec	*GLwDrawingAreaWidget;
Packit Service 7a208c
Packit Service 7a208c
GLAPIVAR WidgetClass glwDrawingAreaWidgetClass;
Packit Service 7a208c
Packit Service 7a208c
Packit Service 7a208c
#endif
Packit Service 7a208c
Packit Service 7a208c
Packit Service 7a208c
/* Callback reasons */
Packit Service 7a208c
#ifdef __GLX_MOTIF
Packit Service 7a208c
#define GLwCR_EXPOSE	XmCR_EXPOSE
Packit Service 7a208c
#define GLwCR_RESIZE	XmCR_RESIZE
Packit Service 7a208c
#define GLwCR_INPUT	XmCR_INPUT
Packit Service 7a208c
#else 
Packit Service 7a208c
/* The same values as Motif, but don't use Motif constants */
Packit Service 7a208c
#define GLwCR_EXPOSE	38
Packit Service 7a208c
#define GLwCR_RESIZE	39
Packit Service 7a208c
#define GLwCR_INPUT	40
Packit Service 7a208c
#endif
Packit Service 7a208c
Packit Service 7a208c
#define GLwCR_GINIT	32135	/* Arbitrary number that should neverr clash */
Packit Service 7a208c
Packit Service 7a208c
typedef struct 
Packit Service 7a208c
  {
Packit Service 7a208c
  int       reason;
Packit Service 7a208c
  XEvent   *event;
Packit Service 7a208c
  Dimension width,height;
Packit Service 7a208c
  } 
Packit Service 7a208c
  GLwDrawingAreaCallbackStruct;
Packit Service 7a208c
Packit Service 7a208c
#if defined(__cplusplus) || defined(c_plusplus)
Packit Service 7a208c
extern "C" {
Packit Service 7a208c
#endif
Packit Service 7a208c
Packit Service 7a208c
/* front ends to glXMakeCurrent and glXSwapBuffers */
Packit Service 7a208c
GLAPI void GLwDrawingAreaMakeCurrent(Widget w,GLXContext ctx);
Packit Service 7a208c
GLAPI void GLwDrawingAreaSwapBuffers(Widget w);
Packit Service 7a208c
Packit Service 7a208c
#ifdef __GLX_MOTIF
Packit Service 7a208c
#ifdef _NO_PROTO
Packit Service 7a208c
GLAPI Widget GLwCreateMDrawingArea();
Packit Service 7a208c
#else
Packit Service 7a208c
GLAPI Widget GLwCreateMDrawingArea(Widget parent,char *name,ArgList arglist,Cardinal argcount);
Packit Service 7a208c
#endif
Packit Service 7a208c
#endif 
Packit Service 7a208c
Packit Service 7a208c
#if defined(__cplusplus) || defined(c_plusplus)
Packit Service 7a208c
}
Packit Service 7a208c
#endif
Packit Service 7a208c
Packit Service 7a208c
#endif