Commit Graph

74545 Commits

Author SHA1 Message Date
Brian Paul 4cb9fffa7e Added simple lookup_bufferobj() function to wrap the _mesa_HashLookup() call
and cast.  Simplifies the code a little bit elsewhere.
2006-06-03 15:32:27 +00:00
Brian Paul 3696f0ee1d updates for using libdrm (Hanno Bock) 2006-06-03 15:17:07 +00:00
Brian Paul 6f172f7aba minor clean-ups 2006-06-02 22:51:45 +00:00
Roland Scheidegger 98c791b543 implement arb_vertex_program in hw for r200. Code contains still some hacks, generic attribs cause a fallback, but otherwise it seems to work quite well. Passes all glean vertProg1 tests with the exception of the degnerated LIT case (which is a hw limitation), as well as runs the r200 render path of doom3/quake4 (1.1 patch needed for quake4). The code is heavily borrowed from the r300 driver as vertex programs encoding is almost identical. arb_vertex_program is not yet announced by default and still needs to be enabled via driconf. 2006-06-02 22:47:31 +00:00
Brian Paul 21fbdb14e9 set per-context GL_DRAW_BUFFER state regardless of currently bound FBO 2006-06-02 12:51:56 +00:00
Brian Paul 2b04dd9d2c fix depth-component test to allow rectangular textures 2006-06-02 12:46:53 +00:00
Roland Scheidegger b302419abe remove code dealing with drmMinor version < 6 since all radeon drivers request at least drmMinor 6 anyway. 2006-06-02 01:52:54 +00:00
Roland Scheidegger 5377ac80dc retry on EBUSY instead of EAGAIN in radeonWaitIrq (it appears this was the intention as drm seems to never return EAGAIN) in all radeon drivers. 2006-06-01 23:21:43 +00:00
Roland Scheidegger fe57ed4f25 Fix extended swizzling in vertex programs by introducing special swizzle instruction, extend the 2 bit rsw field to 3 bit like used in other places. While here, also fix up rsw (negation), dph and try to fix up rsq with negative values (doesn't work, bug seems elsewhere) in the sse codegen code. 2006-06-01 22:56:40 +00:00
Tilman Sauerbeck e689a7fc6a SWZ is nearly identical to MOV. the difference is that SWZ supports per-component negation, which MOV doesn't. as that's handled transparently, we can use the same code for them. 2006-05-31 17:57:14 +00:00
Tilman Sauerbeck 49db174df5 pass src->NegateBase as-is in t_src() now, as the flags are equivalent to r300's VSF_FLAGs now 2006-05-31 17:37:23 +00:00
Claudio Ciccani b18191cf30 Added DirectFB GLUT implementation. 2006-05-31 17:02:45 +00:00
Claudio Ciccani 9400550c16 Fixed bug with multiple contexts.
Added support for ARGB4444 and ARGB2554.
Added hardware accelerated Clear().
2006-05-31 17:00:10 +00:00
Brian Paul a8c4242395 Define new NEGATE_* tokens for setting the src register's NegateBase field.
Before, we were using GL_TRUE/GL_FALSE in a few places.
Note: only the SWZ instruction can negate individual components.
2006-05-30 22:17:35 +00:00
Brian Paul e4cb9cd167 remove redundant 'const' 2006-05-30 22:15:24 +00:00
Brian Paul 8333012b56 free convolved image / fix mem leak (bug 7077) 2006-05-30 21:58:55 +00:00
Tilman Sauerbeck 1d0fa45bc1 minor code cleanup, no actual changes 2006-05-30 18:49:20 +00:00
Tilman Sauerbeck 6be8127ea4 don't generate GL_INVALID_ENUM if GL_VERTEX_ATTRIB_ARRAY_BUFFER_BINDING_ARB, which is actually handled 2006-05-30 16:57:52 +00:00
Michal Krol 4decba90be Remove not needed forward declaration. 2006-05-30 09:45:33 +00:00
Tilman Sauerbeck b20cdf1d28 don't do the check for >= MAX_VERTEX_PROGRAM_ATTRIBS twice, it's already done in parse_generic_attrib_num() 2006-05-29 16:24:28 +00:00
Brian Paul 919f6a070c generic attribute 0 wasn't handled correctly (Jesse Allen) 2006-05-29 14:37:56 +00:00
Roland Scheidegger 76b6e88e56 fix some whitespace in previous commit 2006-05-27 09:09:56 +00:00
Roland Scheidegger 8a61821057 preparation for r200 hw vertex programs. Increase R200_CMD_BUF_SZ to 16k instead of 8k (the reasons why it was exactly 8k are unclear). Add register defines, sanity code, fix potential issue with wrong statechange order when disabling fragment programs. 2006-05-27 09:03:25 +00:00
Brian Paul 04fa003a50 The ctx->_TexEnvProgram that's allocated in update_state() doesn't seem to
be needed (it's set in texenvprogram.c) and is a memory leak according to
valgrind.
Disable with #if 0 / #endif
2006-05-24 03:34:17 +00:00
Brian Paul 65a51c0d62 Roll _mesa_free_parameters() into calling function (the only caller).
Replace assert(0) with _mesa_warning().
Use new _mesa_align_realloc() function.
New comments, clean-ups.
2006-05-24 03:30:31 +00:00
Brian Paul 5a67af97fa fix a small memory leak in _mesa_add_state_reference() 2006-05-24 03:25:22 +00:00
Brian Paul 1798d9a8a4 added _mesa_align_realloc() 2006-05-24 03:15:46 +00:00
Brian Paul 0c1cbd5805 use GLbitfield for StateFlags, improved comments 2006-05-24 03:01:58 +00:00
Brian Paul d9736db667 Add const qualifiers in a number of places. 2006-05-23 02:44:46 +00:00
Brian Paul f5a2ac95c3 init mask=0 to silence warning 2006-05-23 02:16:20 +00:00
Brian Paul fe9026d04a make mgaSetFence() and mgaWaitFence() static 2006-05-23 02:13:53 +00:00
Brian Paul a6f7f10efa prototype i915_udpate_fog() to silence warning 2006-05-23 02:12:08 +00:00
Brian Paul b8f2f6fee1 In cache_item(), there was sizeof(void) expression.
Replace void *key parameter with const struct state_key *
2006-05-23 01:55:31 +00:00
Brian Paul 17befff800 GL_INDEX_OFFSET didn't work with CI->RGB mappings.
Added some const qualifiers.
2006-05-22 17:40:07 +00:00
Keith Whitwell 8065c120c4 memory usage fixes for glean/conform, use a better hash function 2006-05-22 16:09:27 +00:00
Keith Whitwell 64da16146f Fix typo 2006-05-22 14:30:58 +00:00
Keith Whitwell 5ddc53f899 Better caching for texenv programs.
Initialize some values correctly.
2006-05-22 14:17:32 +00:00
Keith Whitwell 7e3fa7e837 Speedup the venerable mm.[ch] allocator with doubly linked lists and a
separate list of free segments.
2006-05-22 12:32:35 +00:00
Brian Paul b0b6d1abe5 In gl_texture_image, replace ImageStride with an ImageOffsets array.
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.
2006-05-20 16:19:48 +00:00
Brian Paul 04d5d16415 remove some redundant functions, fix-up reference counting 2006-05-20 15:16:45 +00:00
Brian Paul 89ffca52ac use new _mesa_remove_renderbuffer() 2006-05-20 15:12:42 +00:00
Brian Paul 7ac5b7b934 use new _mesa_dereference_frame/renderbuffer() functions 2006-05-20 15:08:25 +00:00
Brian Paul b52f02121b Added _mesa_remove_renderbuffer() as a counterpart to _mesa_add_renderbuffer().
Added _mesa_dereference_renderbuffer() to encapsulate renderbuffer
reference count decrement, delete, locking.
2006-05-20 15:07:32 +00:00
Brian Paul 2eb88c1752 Added _mesa_dereference_framebuffer() to encapsulate reference count
decrement, delete and locking.
2006-05-20 15:06:35 +00:00
Brian Paul cbb19930b3 some new comments 2006-05-19 17:31:09 +00:00
Brian Paul 20e11b2332 remove an assertion 2006-05-19 17:27:33 +00:00
Brian Paul 083f8111aa added some CHAN_BITS tests 2006-05-19 03:49:13 +00:00
Brian Paul 68bc7df638 replace FORMAT var with RB_TYPE 2006-05-19 03:47:16 +00:00
Brian Paul d44248ca00 Allow rendering 8, 16 and 32-bit/channel images without recompiling.
Uses new renderbuffer adaptors.
2006-05-19 03:41:37 +00:00
Brian Paul 6a74f65c58 install renderbuffer adaptors when color channel sizes need to be reduced 2006-05-19 03:40:29 +00:00