mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-02-01 04:40:22 +01:00
nouveau: move extension stuff into nouveau_screen.c
This commit is contained in:
parent
b5b9ac62e6
commit
210bf673c2
2 changed files with 41 additions and 51 deletions
|
|
@ -1,6 +1,7 @@
|
|||
#include "main/glheader.h"
|
||||
#include "glapi/glthread.h"
|
||||
#include <GL/internal/glcore.h>
|
||||
#include "utils.h"
|
||||
|
||||
#include "state_tracker/st_public.h"
|
||||
#include "pipe/p_defines.h"
|
||||
|
|
@ -12,55 +13,6 @@
|
|||
#include "nouveau_screen.h"
|
||||
#include "nouveau_winsys_pipe.h"
|
||||
|
||||
#define need_GL_ARB_fragment_program
|
||||
#define need_GL_ARB_multisample
|
||||
#define need_GL_ARB_occlusion_query
|
||||
#define need_GL_ARB_point_parameters
|
||||
#define need_GL_ARB_texture_compression
|
||||
#define need_GL_ARB_vertex_program
|
||||
#define need_GL_ARB_vertex_buffer_object
|
||||
#define need_GL_EXT_compiled_vertex_array
|
||||
#define need_GL_EXT_fog_coord
|
||||
#define need_GL_EXT_secondary_color
|
||||
#define need_GL_EXT_framebuffer_object
|
||||
#include "extension_helper.h"
|
||||
|
||||
const struct dri_extension common_extensions[] =
|
||||
{
|
||||
{ NULL, 0 }
|
||||
};
|
||||
|
||||
const struct dri_extension nv40_extensions[] =
|
||||
{
|
||||
{ "GL_ARB_fragment_program", NULL },
|
||||
{ "GL_ARB_multisample", GL_ARB_multisample_functions },
|
||||
{ "GL_ARB_occlusion_query", GL_ARB_occlusion_query_functions },
|
||||
{ "GL_ARB_point_parameters", GL_ARB_point_parameters_functions },
|
||||
{ "GL_ARB_texture_border_clamp", NULL },
|
||||
{ "GL_ARB_texture_compression", GL_ARB_texture_compression_functions },
|
||||
{ "GL_ARB_texture_cube_map", NULL },
|
||||
{ "GL_ARB_texture_env_add", NULL },
|
||||
{ "GL_ARB_texture_env_combine", NULL },
|
||||
{ "GL_ARB_texture_env_crossbar", NULL },
|
||||
{ "GL_ARB_texture_env_dot3", NULL },
|
||||
{ "GL_ARB_texture_mirrored_repeat", NULL },
|
||||
{ "GL_ARB_texture_non_power_of_two", NULL },
|
||||
{ "GL_ARB_vertex_program", GL_ARB_vertex_program_functions },
|
||||
{ "GL_ARB_vertex_buffer_object", GL_ARB_vertex_buffer_object_functions },
|
||||
{ "GL_ATI_texture_env_combine3", NULL },
|
||||
{ "GL_EXT_compiled_vertex_array", GL_EXT_compiled_vertex_array_functions },
|
||||
{ "GL_EXT_fog_coord", GL_EXT_fog_coord_functions },
|
||||
{ "GL_EXT_framebuffer_object", GL_EXT_framebuffer_object_functions },
|
||||
{ "GL_EXT_secondary_color", GL_EXT_secondary_color_functions },
|
||||
{ "GL_EXT_texture_edge_clamp", NULL },
|
||||
{ "GL_EXT_texture_env_add", NULL },
|
||||
{ "GL_EXT_texture_env_combine", NULL },
|
||||
{ "GL_EXT_texture_env_dot3", NULL },
|
||||
{ "GL_EXT_texture_mirror_clamp", NULL },
|
||||
{ "GL_NV_texture_rectangle", NULL },
|
||||
{ NULL, 0 }
|
||||
};
|
||||
|
||||
#ifdef DEBUG
|
||||
static const struct dri_debug_control debug_control[] = {
|
||||
{ "bo", DEBUG_BO },
|
||||
|
|
|
|||
|
|
@ -18,6 +18,45 @@
|
|||
#error nouveau_drm.h version does not match expected version
|
||||
#endif
|
||||
|
||||
/* Extension stuff, enabling of extensions handled by Gallium's GL state
|
||||
* tracker. But, we still need to define the entry points we want.
|
||||
*/
|
||||
#define need_GL_ARB_fragment_program
|
||||
#define need_GL_ARB_multisample
|
||||
#define need_GL_ARB_occlusion_query
|
||||
#define need_GL_ARB_point_parameters
|
||||
#define need_GL_ARB_shader_objects
|
||||
#define need_GL_ARB_texture_compression
|
||||
#define need_GL_ARB_vertex_program
|
||||
#define need_GL_ARB_vertex_shader
|
||||
#define need_GL_ARB_vertex_buffer_object
|
||||
#define need_GL_EXT_compiled_vertex_array
|
||||
#define need_GL_EXT_fog_coord
|
||||
#define need_GL_EXT_secondary_color
|
||||
#define need_GL_EXT_framebuffer_object
|
||||
#define need_GL_VERSION_2_0
|
||||
#define need_GL_VERSION_2_1
|
||||
#include "extension_helper.h"
|
||||
|
||||
const struct dri_extension card_extensions[] =
|
||||
{
|
||||
{ "GL_ARB_multisample", GL_ARB_multisample_functions },
|
||||
{ "GL_ARB_occlusion_query", GL_ARB_occlusion_query_functions },
|
||||
{ "GL_ARB_point_parameters", GL_ARB_point_parameters_functions },
|
||||
{ "GL_ARB_shader_objects", GL_ARB_shader_objects_functions },
|
||||
{ "GL_ARB_shading_language_100", GL_VERSION_2_0_functions },
|
||||
{ "GL_ARB_shading_language_120", GL_VERSION_2_1_functions },
|
||||
{ "GL_ARB_texture_compression", GL_ARB_texture_compression_functions },
|
||||
{ "GL_ARB_vertex_program", GL_ARB_vertex_program_functions },
|
||||
{ "GL_ARB_vertex_shader", GL_ARB_vertex_shader_functions },
|
||||
{ "GL_ARB_vertex_buffer_object", GL_ARB_vertex_buffer_object_functions },
|
||||
{ "GL_EXT_compiled_vertex_array", GL_EXT_compiled_vertex_array_functions },
|
||||
{ "GL_EXT_fog_coord", GL_EXT_fog_coord_functions },
|
||||
{ "GL_EXT_framebuffer_object", GL_EXT_framebuffer_object_functions },
|
||||
{ "GL_EXT_secondary_color", GL_EXT_secondary_color_functions },
|
||||
{ NULL, 0 }
|
||||
};
|
||||
|
||||
PUBLIC const char __driConfigOptions[] =
|
||||
DRI_CONF_BEGIN
|
||||
DRI_CONF_END;
|
||||
|
|
@ -260,8 +299,7 @@ __driCreateNewScreen_20050727(__DRInativeDisplay *dpy, int scrn,
|
|||
(nv_dri->bpp == 16) ? 0 : 8,
|
||||
1);
|
||||
|
||||
driInitExtensions(NULL, common_extensions, GL_FALSE);
|
||||
driInitExtensions(NULL, nv40_extensions, GL_FALSE);
|
||||
driInitExtensions(NULL, card_extensions, GL_FALSE);
|
||||
|
||||
return (void *)psp;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue