summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/api_arrayelt.c
Commit message (Collapse)AuthorAgeFilesLines
* mesa: Use appropriate call convention in VertexAttribI*v.José Fonseca2011-03-251-136/+136
| | | | | | | | | We were using typecasts because the functions pointers are polymorphic in the second argument type, which. Surprisingly the wrong calling convention didn't cause crashes on Windows, but it was causing certain registers to be trashed in MSVC optimized builds, when processing callists in the ClearView RC Flight Simulator.
* mesa: Directly include mfeatures.h in files that perform feature tests.Vinson Lee2011-01-071-0/+1
|
* mesa: Include mtypes.h in files that use gl_context struct.Vinson Lee2011-01-051-0/+1
| | | | | | Directly include mtypes.h if a file uses a gl_context struct. This allows future removal of headers that are not strictly necessary but indirectly include mtypes.h for a file.
* mesa: clean-up array element codeBrian Paul2010-10-281-190/+353
| | | | Remove unnecessary GLAPIENTRY keywords, update comments, re-indent.
* mesa: glArrayElement support for integer-valued arraysBrian Paul2010-10-281-2/+215
|
* Drop GLcontext typedef and use struct gl_context insteadKristian Høgsberg2010-10-131-6/+6
|
* mesa: Move src/mesa/glapi/dispatch.h to mesa.Chia-I Wu2010-02-251-1/+1
| | | | | | glapi/dispatch.h is a core Mesa header file. Move the header file to main/ to make this clear. It also becomes clear after this change that IN_DRI_DRIVER is only used in core Mesa to enable the remap table.
* glapi: Always build libglapi.a.Chia-I Wu2009-10-231-1/+0
| | | | | | | | This is made possible by making glapioffsets.h and glapidispatch.h internal headers of glapi. They should only be included indirectly through dispatch.h by mesa. Signed-off-by: Chia-I Wu <[email protected]>
* mesa/main: New feature FEATURE_arrayelt.Chia-I Wu2009-09-301-2/+16
| | | | This allows the removal of AEcontext.
* mesa: use _mesa_is_bufferobj()Brian Paul2009-08-121-1/+2
|
* mesa: use Elements() for loop limitBrian Paul2009-05-221-1/+1
|
* mesa: minor code clean-upBrian Paul2009-05-221-18/+19
|
* mesa: add explict float castsKeith Whitwell2008-09-211-48/+48
|
* Be more consistant with paths in #includes. Eventually, eliminate a bunch ↵Brian2007-07-041-2/+2
| | | | of -I flags.
* Prune incoming state to the atoms of interest. Hopefully this willKeith Whitwell2006-11-221-6/+14
| | | | | prevent driver-initiated statechanges in the middle of DrawElements/DrawArrays from disturbing this code.
* Another fixKeith Whitwell2006-11-221-0/+8
|
* More fixes, glean seems to run now.Keith Whitwell2006-11-211-2/+3
|
* Fix more typos.Keith Whitwell2006-11-211-2/+2
|
* Fix typos that meant vbos were never unmappedKeith Whitwell2006-11-201-4/+3
|
* Make sure vbo's are mapped before accessing their contents inKeith Whitwell2006-11-161-6/+89
| | | | api_arrayelt.c. Reported by Haihao Xiang.
* Add support for GL_APPLE_vertex_array_object. Several test programsIan Romanick2006-06-121-18/+18
| | | | | | | and demos are also added. Adding basic support to drivers should be as easy as just enabling the extension, though thorough test would also be required.
* No longer alias generic vertex attribs with conventional attribs for ↵Brian Paul2006-04-251-12/+463
| | | | GL_ARB_vertex_program.
* Revert my change from 1.37 as being bogus (see ensuing list discussion forAdam Jackson2006-03-301-3/+2
| | | | rationale).
* Init FogCoordFuncs[0..5] too, remove some unneeded #includesBrian Paul2006-03-171-3/+7
|
* remove another test for IN_DRI_DRIVERBrian Paul2006-03-171-36/+3
|
* Avoid a crash when the user has enabled glVertex{,Attrib}Pointer but hasn'tAdam Jackson2006-01-191-2/+3
| | | | filled in a valid pointer for that attribute or vertex array.
* use ADD_POINTERS macro instead of (uintptr_t) castBrian Paul2005-11-251-8/+8
|
* Fix recent problems with display lists and other parts of the code.Ian Romanick2005-08-051-0/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | CALL_by_offset, SET_by_offset, and GET_by_offset all had various problems. The core issue is that parts of the device-independent code in Mesa assumes that all functions have slots in the dispatch table. This is especially true in the display list code. It will merrilly try to set dispatch pointers for glVertexAttrib1fARB even if GL_ARB_vertex_program is not supported. When the GET/SET/CALL macros are invoked, they would read a 0 from the remap table. The problem is that 0 is the dispatch offset for glNewList! One change is that the remap table is now initialized to be full of -1 values. In addtion, all of the *_by_offset marcos misbehave in an obvious way if the specified offset is -1. SET_by_offset will do nothing, GET_by_offset will return NULL, and CALL_by_offset, since it uses GET_by_offset, will segfault. I also had to add GL_EXT_blend_func_separate to the list of default extensions in all_mesa_extensions (src/mesa/drivers/dri/common/utils.c). Even though many drivers do not export this extension, glBlendFunc is internally implemented by calling glBlendFuncSeparate. Without this addition, glBlendFunc stopped working on drivers (such as mga) that do not export GL_EXT_blend_func_separate. There are still a few assertions / crashes in GL_ARB_vertex_program tests, but I don't think that these are related to any of my changes.
* remove fprintf()Brian Paul2005-07-191-2/+0
|
* Wrap every place that accesses a dispatch table with a macro. A new script-Ian Romanick2005-07-181-424/+184
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | generated file, called src/mesa/glapi/dispatch.h, is added. This file contains three macros for each API function. It contains a GET, a SET, and a CALL. Each of the macros take a pointer to the context and a pointer to the dispatch table. In several threads on mesa3d-dev we discussed replacing _glapi_add_entrypoint with a new function called _glapi_add_dispatch. For this discussion, the important difference between the two is that the caller of _glapi_add_dispatch does *not* know what the dispatch offset will be at compile time. Because of this callers need to track the dispatch offset returned by _glapi_add_dispatch. http://marc.theaimsgroup.com/?t=111947074700001&r=1&w=2 The downside is that driver code then has to access the dispatch table two different ways. It accesses it using structure tags (e.g., exec->Begin) for functions with fixed offsets and via a remap table (e.g., exec[ remap->NewExtensionFunction ]) for functions without fixed offsets. Yuck! Using the macros allows both types of functions to be accessed identically. If a driver needs to set a pointer for Begin, it does 'SET_Begin(ctx, exec, my_begin_function)'. If it needs to set a pointer for NewExtensionFunction, it does 'SET_NewExtensionFunction(ctx, exec, my_NewExtensionFunction_function)'. Furthermore, if at some point in the future a static offset is assigned for NewExtensionFunction, only the macros need to change (instead of every single place that accesses a table for that function). This code differs slightly from the originally posted patches in that the CALL, GET, and SET marcos no longer take a context pointer as a parameter. Brian Paul had suggested that the remap table could be stored as a global since it would be set at CreateScreen time and would be constant for all contexts. This change reflects that feedback. http://marc.theaimsgroup.com/?t=112087194700001&r=1&w=2
* Port Mesa to build on a P64 platform (e.g., Win64). P64 platformsKarl Schultz2005-05-051-2/+2
| | | | | | | | use 64-bit pointers and 32-bit longs. So, operations like casting pointers to unsigned long and back to pointer won't work. glheader.h now includes files to define uintptr_t, which should instead be used for this sort of operation. It is an integer type that is the same size as a pointer.
* mesa-main-0-NULL.patch from Jeff MuizelaarKeith Whitwell2005-02-111-25/+25
|
* Change the dispatch offsets for the VertexAttrib*NV functions so they don'tBrian Paul2004-11-271-125/+124
| | | | | | | alias with the corresponding ARB functions. GL_ARB_vertex_shader (and OpenGL 2.0's) VertexAttrib functions don't alias with conventional vertex attributes, as GL_NV_vertex_program does. So, the ARB and NV version of VertexAttrib need to be distinct.
* Bug #1682: Mesa core code that gets linked into DRI drivers should never callAdam Jackson2004-10-241-63/+262
| | | | through the GL API directly, but should instead use the GL_CALL macro.
* Convert all calls using _glapi_Dispatch to use the new GL_CALL macro.Ian Romanick2004-05-271-99/+98
|
* GL_DOUBLE doesn't follow GL_FLOAT, fix indexing (Keith Harrison)Brian Paul2004-04-231-2/+2
|
* fix some warningsBrian Paul2004-03-261-2/+2
|
* fix incorrect texcoord attribute indexBrian Paul2004-02-241-1/+1
|
* added some GLAPIENTRY keywords, minor clean-upsBrian Paul2004-02-241-82/+82
|
* Yet another revision of _ae_update_state(). Issue both conventional ANDBrian Paul2004-02-241-82/+65
| | | | | generic vertex attribute commands, ignoring ctx->VertexProgram.Enabled since this function may be used during display list compilation.
* Fix the problem found with UT after I had added support for glVertexAttrib.Brian Paul2004-02-111-110/+568
| | | | | The problem came from using the _glapi_Dispatch->VertexAttrib*fvNV pointers since they can change from one glArrayElement call to the next.
* revert to version 1.18 for now to fix segfaults in some applicationsRoland Scheidegger2004-02-111-583/+110
|
* Restore some of the previous code for handling conventional vertex attributesBrian Paul2004-02-091-341/+654
| | | | | | more efficiently. Remove switches/conditionals from vertex attribute wrappers. glMultiTexCoord is implemented in terms of glVertexAttrib.
* Updated to handle generic vertex attributes accessed vi glArrayElement().Brian Paul2004-02-081-220/+380
| | | | | In fact, handle all conventional vertex attributes in terms of generic attributes (execept for edge flags and color indexes).
* Add GLAPIENTRY function decorations for correct operation on Windows.Karl Schultz2004-01-281-9/+9
|
* Add missing GLAPIENTRYKarl Schultz2003-12-041-1/+1
|
* Merge vtx-0-2-branchKeith Whitwell2003-11-241-0/+3
|
* GL_ARB_vertex_buffer_object working now, at least for non-indexedBrian Paul2003-09-171-3/+8
| | | | vertex arrays.
* Removed all RCS / CVS tags (Id, Header, Date, etc.) from everything.Ian Romanick2003-06-051-0/+1
|
* Use ctx->Const.MaxTextureImageUnits and MaxTextureCoordUnits in more places.Brian Paul2003-05-011-4/+2
| | | | Misc vertex array / vertex program changes.