1 /* $Id: svgamesa.h,v 1.1.1.1 2002/02/01 06:30:43 tacyas Exp $ */
4 * Mesa 3-D graphics library
6 * Copyright (C) 1995-1997 Brian Paul
8 * This library is free software; you can redistribute it and/or
9 * modify it under the terms of the GNU Library General Public
10 * License as published by the Free Software Foundation; either
11 * version 2 of the License, or (at your option) any later version.
13 * This library is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
16 * Library General Public License for more details.
18 * You should have received a copy of the GNU Library General Public
19 * License along with this library; if not, write to the Free
20 * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
25 * $Log: svgamesa.h,v $
26 * Revision 1.1.1.1 2002/02/01 06:30:43 tacyas
27 * Initail Import Into CVS
29 * Revision 1.6 1997/12/07 17:28:03 brianp
30 * updated version to 2.6
32 * Revision 1.5 1997/09/29 23:22:16 brianp
33 * updated version to 2.5
35 * Revision 1.4 1997/07/11 02:55:24 brianp
36 * added doubleBuffer flag to SVGAMesaCreateContext, bumped version to 2.4
38 * Revision 1.3 1996/10/30 03:12:47 brianp
39 * incremented version to 2.1
41 * Revision 1.2 1996/10/15 00:26:02 brianp
42 * added prototype for SVGAMesaSwapBuffers()
44 * Revision 1.1 1996/09/13 01:26:41 brianp
52 * SVGA/Mesa interface for Linux.
57 * Intro to using the VGA/Mesa interface
59 * 1. #include the <vga.h> file
60 * 2. Call vga_init() to initialize the SVGA library.
61 * 3. Call vga_setmode() to specify the screen size and color depth.
62 * 4. Call SVGAMesaCreateContext() to setup a Mesa context. If using 8-bit
63 * color Mesa assumes color index mode, if using 16-bit or deeper color
64 * Mesa assumes RGB mode.
65 * 5. Call SVGAMesaMakeCurrent() to activate the Mesa context.
66 * 6. You can now use the Mesa API functions.
67 * 7. Before exiting, call SVGAMesaDestroyContext() then vga_setmode(TEXT)
68 * to restore the original text screen.
71 * 1. You must run your executable as root (or use the set UID-bit) because
72 * the SVGA library requires it.
73 * 2. The SVGA driver is not fully implemented yet. See svgamesa.c for what
82 #define SVGAMESA_MAJOR_VERSION 2
83 #define SVGAMESA_MINOR_VERSION 6
96 * This is the SVGAMesa context 'handle':
98 typedef struct svgamesa_context *SVGAMesaContext;
103 * doubleBuffer flag new in version 2.4
105 extern SVGAMesaContext SVGAMesaCreateContext( GLboolean doubleBuffer );
107 extern void SVGAMesaDestroyContext( SVGAMesaContext ctx );
109 extern void SVGAMesaMakeCurrent( SVGAMesaContext ctx );
111 extern SVGAMesaContext SVGAMesaGetCurrentContext( void );
113 extern void SVGAMesaSwapBuffers( void );