1f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org/*
2f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org * (C) Copyright IBM Corporation 2002, 2004
3f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org * All Rights Reserved.
4f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org *
5f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org * Permission is hereby granted, free of charge, to any person obtaining a
6f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org * copy of this software and associated documentation files (the "Software"),
7f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org * to deal in the Software without restriction, including without limitation
8f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org * on the rights to use, copy, modify, merge, publish, distribute, sub
9f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org * license, and/or sell copies of the Software, and to permit persons to whom
10f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org * the Software is furnished to do so, subject to the following conditions:
11f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org *
12f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org * The above copyright notice and this permission notice (including the next
13f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org * paragraph) shall be included in all copies or substantial portions of the
14f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org * Software.
15f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org *
16f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org * FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.  IN NO EVENT SHALL
19f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org * VA LINUX SYSTEM, IBM AND/OR THEIR SUPPLIERS BE LIABLE FOR ANY CLAIM,
20f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org * DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
21f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org * OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
22f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org * USE OR OTHER DEALINGS IN THE SOFTWARE.
23f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org *
24f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org * Authors:
25f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org *    Ian Romanick <idr@us.ibm.com>
26f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org */
27f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org
28f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org#ifndef DRI_DEBUG_H
29f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org#define DRI_DEBUG_H
30f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org
31f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org#include <GL/gl.h>
32f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org#include <GL/internal/dri_interface.h>
33f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org#include "main/context.h"
34f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org
35f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.orgstruct dri_debug_control {
36f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org    const char * string;
37f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org    unsigned     flag;
38f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org};
39f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org
40f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.orgextern unsigned driParseDebugString( const char * debug,
41f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org    const struct dri_debug_control * control );
42f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org
43f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.orgextern unsigned driGetRendererString( char * buffer,
44f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org    const char * hardware_name, GLuint agp_mode );
45f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org
46f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.orgstruct __DRIconfigRec {
47f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org    struct gl_config modes;
48f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org};
49f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org
50f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.orgextern __DRIconfig **
51f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.orgdriCreateConfigs(GLenum fb_format, GLenum fb_type,
52f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org		 const uint8_t * depth_bits, const uint8_t * stencil_bits,
53f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org		 unsigned num_depth_stencil_bits,
54f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org		 const GLenum * db_modes, unsigned num_db_modes,
55f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org		 const uint8_t * msaa_samples, unsigned num_msaa_modes,
56f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org		 GLboolean enable_accum);
57f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org
58f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org__DRIconfig **driConcatConfigs(__DRIconfig **a,
59f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org			       __DRIconfig **b);
60f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org
61f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.orgint
62f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.orgdriGetConfigAttrib(const __DRIconfig *config,
63f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org		   unsigned int attrib, unsigned int *value);
64f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.orgint
65f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.orgdriIndexConfigAttrib(const __DRIconfig *config, int index,
66f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org		     unsigned int *attrib, unsigned int *value);
67f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org
68f2ba7591b1407a7ee9209f842c50696914dc2dedkbr@chromium.org#endif /* DRI_DEBUG_H */
69