Jerome, Nicolas is actually right. There is absolutely nothing driver-specific about the extension. It's a pure API improvement and doesn't have *anything* to do with the hardware. There are no capabilities required, just ARB_vertex_program.
Nicolas, Please test the attached patch. I have also enabled ARB_half_float_pixel and ARB/APPLE_vertex_array_object. Marek On Sun, Apr 17, 2011 at 7:08 PM, Jerome Glisse <j.gli...@gmail.com> wrote: > On Sun, Apr 17, 2011 at 7:59 AM, Nicolas Kaiser <ni...@nikai.net> wrote: > > * Nicolas Kaiser <ni...@nikai.net>: > >> * Marek Olšák <mar...@gmail.com>: > >> > r200 does support ARB_vertex_program. The backend is in > r200_vertprog.c. I > >> > think it has vertex shader 1.1 in D3D. > >> > > >> > The patch is wrong though. The extension should be listed in the > >> > ARB_vp_extension array, not card_extensions. > >> > >> Thanks! I copied it from dri/r300/r300_context.c, where it's listed > >> in the card_extensions as well. > >> > >> I'll fix the patch. > > > > Well, when I move it to the ARB_vp_extension array, > > it doesn't work: > > > > .src/tests/prog_parameter > > GL_RENDERER = Mesa DRI R200 (R200 514D) TCL DRI2 > > GL_VERSION = 1.3 Mesa 7.11-devel (git-9dacbe2) > > > > GL_EXT_gpu_program_parameters not available. > > Testing glProgramEnvParameter4fvARB (count = 256)... > > Testing glProgramLocalParameter4fvARB (count = 1024)... > > PASS! > > > > I guess I'm doing something wrong. > > > > Best regards, > > Nicolas Kaiser > > > > You missing the point this extension is useless on r200, because r200 > hardware doesn't the capabilities to use this extension, the test you > are using is just querying info not doing anythings usefull. Sure we > can report wrong informations but what's the point ? > > Cheers, > Jerome >
From 6030b434ea665b1112d0edcee5cc5e65f7cebf8a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marek=20Ol=C5=A1=C3=A1k?= <mar...@gmail.com> Date: Sun, 17 Apr 2011 23:41:33 +0200 Subject: [PATCH] r200: enable some extensions Specifically: - GL_ARB_half_float_pixel - GL_ARB_vertex_array_object - GL_APPLE_vertex_array_object - GL_EXT_gpu_program_parameters --- src/mesa/drivers/dri/r200/r200_context.c | 12 ++++++++++-- 1 files changed, 10 insertions(+), 2 deletions(-) diff --git a/src/mesa/drivers/dri/r200/r200_context.c b/src/mesa/drivers/dri/r200/r200_context.c index 4773263..4e08d34 100644 --- a/src/mesa/drivers/dri/r200/r200_context.c +++ b/src/mesa/drivers/dri/r200/r200_context.c @@ -62,13 +62,16 @@ WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. #include "radeon_span.h" #define need_GL_ARB_occlusion_query +#define need_GL_ARB_vertex_array_object #define need_GL_ARB_vertex_program +#define need_GL_APPLE_vertex_array_object #define need_GL_ATI_fragment_shader #define need_GL_EXT_blend_minmax #define need_GL_EXT_fog_coord #define need_GL_EXT_secondary_color #define need_GL_EXT_blend_equation_separate #define need_GL_EXT_blend_func_separate +#define need_GL_EXT_gpu_program_parameters #define need_GL_NV_vertex_program #define need_GL_ARB_point_parameters #define need_GL_EXT_framebuffer_object @@ -112,6 +115,7 @@ static const GLubyte *r200GetString( struct gl_context *ctx, GLenum name ) */ static const struct dri_extension card_extensions[] = { + { "GL_ARB_half_float_pixel", NULL }, { "GL_ARB_multitexture", NULL }, { "GL_ARB_occlusion_query", GL_ARB_occlusion_query_functions}, { "GL_ARB_texture_border_clamp", NULL }, @@ -120,6 +124,7 @@ static const struct dri_extension card_extensions[] = { "GL_ARB_texture_env_dot3", NULL }, { "GL_ARB_texture_env_crossbar", NULL }, { "GL_ARB_texture_mirrored_repeat", NULL }, + { "GL_ARB_vertex_array_object", GL_ARB_vertex_array_object_functions}, { "GL_EXT_blend_minmax", GL_EXT_blend_minmax_functions }, { "GL_EXT_blend_subtract", NULL }, { "GL_EXT_fog_coord", GL_EXT_fog_coord_functions }, @@ -133,6 +138,7 @@ static const struct dri_extension card_extensions[] = { "GL_EXT_texture_lod_bias", NULL }, { "GL_EXT_texture_mirror_clamp", NULL }, { "GL_EXT_texture_rectangle", NULL }, + { "GL_APPLE_vertex_array_object", GL_APPLE_vertex_array_object_functions }, { "GL_ATI_texture_env_combine3", NULL }, { "GL_ATI_texture_mirror_once", NULL }, { "GL_MESA_pack_invert", NULL }, @@ -150,7 +156,9 @@ static const struct dri_extension blend_extensions[] = { }; static const struct dri_extension ARB_vp_extension[] = { - { "GL_ARB_vertex_program", GL_ARB_vertex_program_functions } + { "GL_ARB_vertex_program", GL_ARB_vertex_program_functions }, + { "GL_EXT_gpu_program_parameters", GL_EXT_gpu_program_parameters_functions}, + { NULL, NULL } }; static const struct dri_extension NV_vp_extension[] = { @@ -455,7 +463,7 @@ GLboolean r200CreateContext( gl_api api, driInitExtensions( ctx, blend_extensions, GL_FALSE ); } if(rmesa->radeon.radeonScreen->drmSupportsVertexProgram) - driInitSingleExtension( ctx, ARB_vp_extension ); + driInitExtensions( ctx, ARB_vp_extension, GL_FALSE ); if(driQueryOptionb(&rmesa->radeon.optionCache, "nv_vertex_program")) driInitSingleExtension( ctx, NV_vp_extension ); -- 1.7.1
_______________________________________________ mesa-dev mailing list mesa-dev@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/mesa-dev