summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri/tdfx
Commit message (Collapse)AuthorAgeFilesLines
* Refactor and fix core vblank supportJesse Barnes2007-10-291-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Consolidate support for synchronizing to and retrieving vblank counters. Also fix the core vblank code to return monotonic MSC counters, which are required by some GLX extensions. Adding support for multiple pipes to a low level driver is fairly easy, the Intel 965 driver provides simple example code (see intel_buffers.c:intelWindowMoved()). The new code bumps the media stream counter extension version to 2 and adds a new getDrawableMSC callback. This callback takes a drawablePrivate pointer, which is used to calculate the MSC value seen by clients based on the actual vblank counter(s) returned from the kernel. The new drawable private fields are as follows: - vblSeq - used for tracking vblank counts for buffer swapping - vblFlags - flags (e.g. current pipe), updated by low level driver - msc_base - MSC counter from the last time the current pipe changed - vblank_base - kernel DRM vblank counter from the last time the pipe changed Using the above variables, the core vblank code (in vblank.c) can calculate a monotonic MSC value. The low level DRI drivers are responsible for updating the current pipe (by setting VBLANK_FLAG_SECONDARY for example in vblFlags) along with msc_base and vblank_base whenever the pipe associated with a given drawable changes (again, see intelWindowMoved for an example of this). Drivers should fill in the GetDrawableMSC DriverAPIRec field to point to driDrawableGetMSC32 and add code for pipe switching as outlined above to fully support the new scheme.
* Add a DRI_ReadDrawable marker extension to signal read drawable capability.Kristian Høgsberg2007-10-111-5/+5
|
* Pull createNewScreen entry point into dri_util.c.Kristian Høgsberg2007-10-101-53/+33
| | | | | | | | This pulls the top level createNewScreen entry point out of the drivers and rewrites __driUtilCreateNewScreen in dri_util.c to be the new entry point. The change moves more logic into the common/ layer and changes the createNewScreen entry point to only be defined in one place.
* Remove screenConfigs from __DRIscreen.Kristian Høgsberg2007-10-101-2/+1
| | | | | | | | | | | | The screenConfigs field of __DRIscreen points back to the containing __GLXscreenConfigs struct. This is a serious abstraction violation; it assumes that the loader is libGL and that there *is* a __GLXscreenConfigs type in the loader. Using the containerOf macro, we can get from the __DRIscreen pointer to the containing __GLXscreenConfigs struct, at a place in the stack where the above is a valid assumption. Besides, the __DRI* structs shouldn't hold state other than the private pointer.
* Drop __DRInativeDisplay and pass in __DRIscreen pointers instead.Kristian Høgsberg2007-10-101-11/+11
| | | | | | | | | | | | | Many DRI entry points took a __DRInativeDisplay pointer and a screen index as arguments. The only use for the native display pointer was to pass it back to the loader when looking up the __DRIscreen for the given screen index. Instead, let's just pass in the __DRIscreen pointer directly, which let's drop the __DRInativeDisplay type and the getScreen function. The assumption is now that the loader will be able to retrieve context from the __DRIscreen pointer when necessary.
* Replace Proxy1D/2D/etc with ProxyTex[] indexed by TEXTURE_x_INDEX.Brian2007-08-161-1/+1
| | | | Simplification in colortab.c too.
* Remove ctx->Point._Size and ctx->Line._Width.Brian2007-07-211-1/+1
| | | | | | The clamping for these values depends on whether we're drawing AA or non-AA points, lines. Defer clamping until drawing time. Drivers could compute and keep clamped AA and clamped non-AA values if desired.
* Overhaul/simplify SWvertex and SWspan attribute handling.Brian2007-05-201-8/+8
| | | | | Instead of separate fog/specular/texcoord/varying code, just treat all of them as generic attributes. Simplifies the point/line/triangle functions.
* remove _tnl_arb_vertex_program_stageBrian2007-04-161-6/+0
|
* Merge branch 'origin' into glsl-compiler-1Brian2007-03-091-1/+1
|\ | | | | | | | | | | Conflicts: src/mesa/main/context.c
| * Fix/improve framebuffer object reference counting.Brian2007-03-061-1/+1
| | | | | | | | | | | | | | Use _mesa_reference_framebuffer() and _mesa_unreference_framebuffer() functions to be sure reference counting is done correctly. Additional assertions are done too. Note _mesa_dereference_framebuffer() renamed to "unreference" as that's more accurate.
* | Update DRI drivers for new glsl compiler.Brian2007-02-231-8/+8
|/ | | | | | Mostly: - update #includes - update STATE_* token code
* Merge branch 'master' of git+ssh://[email protected]/git/mesa/mesa ↵Keith Whitwell2007-01-169-109/+150
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | into vbo-0.2 Conflicts: src/mesa/array_cache/sources src/mesa/drivers/dri/i965/brw_context.c src/mesa/drivers/dri/i965/brw_draw.c src/mesa/drivers/dri/i965/brw_fallback.c src/mesa/drivers/dri/i965/brw_vs_emit.c src/mesa/drivers/dri/i965/brw_vs_tnl.c src/mesa/drivers/dri/mach64/mach64_context.c src/mesa/main/extensions.c src/mesa/main/getstring.c src/mesa/tnl/sources src/mesa/tnl/t_save_api.c src/mesa/tnl/t_save_playback.c src/mesa/tnl/t_vtx_api.c src/mesa/tnl/t_vtx_exec.c src/mesa/vbo/vbo_attrib.h src/mesa/vbo/vbo_exec_api.c src/mesa/vbo/vbo_save_api.c src/mesa/vbo/vbo_save_draw.c
| * Enable GLX_SGI_make_current_read for tdfx.Ian Romanick2006-11-146-30/+64
| | | | | | | | | | | | | | | | | | Implement GLX_SGI_make_current_read for tdfx. Remove annoying debug printf in tdfxSwapBuffers. Updated a comment in drirenderbuffer.h to note that the tdfx driver uses a flag that was previously only used by s3v. This code was tested with glxgears, wincopy, and manywin.
| * Clean-up compiler warnings.Ian Romanick2006-11-132-2/+5
| |
| * Implement GL_ARB_occlusion_query.Ian Romanick2006-11-132-1/+55
| | | | | | | | | | Based on the old code that implemented GL_HP_occlusion_test, implement GL_ARB_occlusion_query. This code passes progs/demo/arbocclude.
| * tdfxDDWriteDepthPixels can be called with mask == NULL.Ian Romanick2006-11-131-2/+2
| | | | | | | | | | | | | | Via depth_test_pixels (swrast/s_depth.c), tdfxDDWriteDepthPixels can be called with mask == NULL. Test for this condition in the places where mask might be dereference. This matches the behavior of several other functions in this file with a 'const GLubyte mask[]' parameter.
| * Major clean-up of tdfxDDGetString.Ian Romanick2006-11-131-43/+16
| |
| * Eliminate use of deprecated GetBufferSize interface.Ian Romanick2006-11-132-38/+15
| |
| * Fix "3D driver claims to not support visual ..." warnings.Ian Romanick2006-11-131-1/+1
| | | | | | | | | | | | | | In 16-bit color modes the 3D driver was erroneously creating fbconfigs with 16-bits of accumulation alpha. Since the 2D driver always generates modes with zero bits of alpha, the lists of fbconfigs did not match and warnings were generated by libGL.
| * Remove x/y/width/height parameters from Clear functions.Brian Paul2006-11-011-4/+2
| |
| * fix _mesa_select_tex_image() callsBrian Paul2006-11-011-4/+2
| |
* | merge current trunk into vbo branchAlan Hourihane2006-11-022-8/+4
| |
* | switch remaining drivers over to vboKeith Whitwell2006-10-312-5/+5
|/
* Want to stop passing x/y/width/height to Clear() function.Brian Paul2006-10-181-5/+4
| | | | | | | The coordinates need to be computed after we've got the hw lock. Code updated to: 1. Ignore all/x/y/width/height/ params passed to Clear func. 2. Pass 0,0,0,0,0 to _swrast_Clear() until they're totally removed.
* Remove a bunch of "ctx->Driver.function = _swrast_Function" lines sinceBrian Paul2006-10-151-12/+1
| | | | | default/fallback functions are already plugged in by the call to _mesa_init_driver_functions().
* Remove Driver.ResizeBuffers = _mesa_resize_framebuffer lines.Brian Paul2006-10-151-1/+0
| | | | | This is already done by the preceeding call to _mesa_init_driver_functions() which plugs in default functions like that.
* build fix: s/Table/TableUB/Brian Paul2006-10-141-1/+1
|
* Revamp color table code.Brian Paul2006-10-131-3/+1
| | | | Always store all color tables as both float and ubyte.
* Move mipmap generation functions, texture scaling functions into newBrian Paul2006-09-291-0/+1
| | | | mipmap.c file.
* include texobj.h to silence warningBrian Paul2006-08-251-0/+1
|
* Added _mesa_lookup_program() and _mesa_lookup_bufferobj() functions to avoidBrian Paul2006-08-232-7/+8
| | | | | | a lot of casting elsewhere. Use _mesa_lookup_texture() in tdfx driver, use _mesa_lookup_bufferobj() in r300 driver.
* change tex memory allocation calls (debian bug 383209)Brian Paul2006-08-161-2/+1
|
* In gl_texture_image, replace ImageStride with an ImageOffsets array.Brian Paul2006-05-201-18/+20
| | | | | | | | | Some hardware lays out 3D mipmaps in a manner that can't be expressed with a simple image stride. The ImageOffsets array is allocated and initialized to typical defaults in the _mesa_init_teximage_fields() function. If needed, a driver will then have to replace these offsets. TexStore and TexelFetch routines updated to use offsets array.
* Fix a number of texture compression issues.Brian Paul2006-05-081-17/+21
| | | | | | | | Pass the MESA_FORMAT_* token to the _mesa_compressed_row_stride(), _mesa_compressed_texture_size() and _mesa_compressed_image_address() functions since we want to use the driver-chosen format, not the user's internalFormat hint. Consolidate code related to choosing the texture format in texstoree.c
* updates to dri drivers for recent stencil changesKeith Whitwell2006-05-082-17/+17
|
* Bug #5754: Allocate texture memory correctly. (Richard Drummond)Adam Jackson2006-04-031-3/+4
|
* Coverity #650: Fix a memory leak when near OOM.Adam Jackson2006-04-021-0/+1
|
* s/IntFormat/InternalFormat/ and s/Format/_BaseFormat/ for gl_color_table.Brian Paul2005-10-051-2/+2
|
* In gl_texture_image replace IntFormat with InternalFormat and Format withBrian Paul2005-10-052-28/+28
| | | | _BaseFormat to be consistant with gl_renderbuffer.
* Instead of calling _mesa_ResizeBuffersMESA() in the Viewport function,Brian Paul2005-09-142-3/+3
| | | | call driUpdateFramebufferSize() when window size/position changes.
* Replace ctx->Driver.StencilOp/Func/Mask() functions withBrian Paul2005-09-131-8/+11
| | | | ctx->Driver.Stencil*Separate() functions.
* add _tnl_arb_vertex_program_stage to all drivers which already have ↵Roland Scheidegger2005-09-091-0/+1
| | | | _tnl_vertex_program_stage. Fixes crashes when using vertex programs. Tested on r200 only (fix by Keith Whitwell)
* Add new void *addr and __DRIdrawablePrivate parameters toBrian Paul2005-09-041-19/+15
| | | | driNewRenderbuffer().
* Use InitPointers helperBrian Paul2005-09-041-21/+3
|
* SetBuffer, renderbuffer changesBrian Paul2005-09-032-28/+4
|
* remove stray references to ctx->Depth.OcclusionTestBrian Paul2005-08-251-1/+0
|
* removed GL_HP_occlusion_test extensionBrian Paul2005-08-252-96/+0
|
* Add Egberts fixes for 64bit architecturesAlan Hourihane2005-08-152-2/+6
| | | | | | Add additional checks for the *DRIRec info structure passed in from the device driver. This ensures that things fallback to indirect rendering if the DDX driver has had modifications (i.e. removal of the drmAddress field).
* Major rip-up of internal function insertion interface. The oldmesa_6_3_1Ian Romanick2005-07-282-3/+17
| | | | | | | | | | | | | | | | | | | | | | _glapi_add_entrypoint has been replaced by a new routine called _glapi_add_dispatch. This new routine dynamically assignes dispatch offsets to functions added. This allows IHVs to add support for extension functions that do not have assigned dispatch offsets. It also means that a driver has no idea what offset will be assigned to a function. The vast majority of the changes in this commit account for that. An additional table, driDispatchRemapTable, is added. Functions not in the Linux OpenGL ABI (i.e., anything not in GL 1.2 + ARB_multitexture) has a fixed offset in this new table. The entry in this table specifies the offset in of the function in the real dispatch table. The internal interface was also bumped from version 20050725 to 20050727. This has been tested with various programs in progs/demos on: radeon (Radeon Mobility M6) r128 (Rage 128 Pro) mga (G400)