Brian Paul
f920d496e1
mesa: fix _mesa_texstore_argb8888() for MESA_FORMAT_XRGB8888
...
If we hit the general path and call _mesa_make_temp_chan_image() we
always want to get a GL_RGBA texture. We were getting a 3-channel
GL_RGB texture before and that messed up the memory layout.
2009-10-29 17:52:01 -06:00
Alex Deucher
c243e8dd23
r600: remove the no rrb messages
2009-10-29 19:44:35 -04:00
Alex Deucher
b924579bd4
r600: Add support for ARB_depth_clamp
2009-10-29 19:42:52 -04:00
Brian Paul
d0b6147291
intel: remove memcpy_get_tex_image() code
...
This has been lifted into core Mesa where it can be used for all drivers
that use the _mesa_get_teximage() fallback for ctx->Driver.GetTexImage().
2009-10-29 16:31:57 -06:00
Brian Paul
fcbf663640
mesa: lift memcpy_get_tex_image() code from intel driver into core Mesa
...
The code should work for any driver.
2009-10-29 16:31:57 -06:00
Brian Paul
bde7874317
mesa: refactor _mesa_get_teximage() code
...
Break different formats into different functions to make it easier to read.
2009-10-29 16:31:57 -06:00
Brian Paul
217a40d8d9
i965: indentation fix
2009-10-29 16:31:57 -06:00
Brian Paul
26d22b094b
i965: make brw_sf_prog_key::sprite_origin_lower_left one bit
...
Shrinks size of key to 8 bytes from 12.
Note that progs/demos/spriteblast.c is still broken.
2009-10-29 16:31:56 -06:00
Brian Paul
035b21f365
i965: make brw_wm_prog_key a little smaller
...
GLushort is big enough for the swizzle and origin fields.
The key could probably be made smaller still by re-ordering things.
I'll hold off on that until after the outputswritten64 branch is merged.
The key will get a little larger again with the GLbitfield64 fields.
2009-10-29 16:31:56 -06:00
Eric Anholt
8a9afe71b8
i915: Fix 1D texture mapping in the t coordinate.
...
Fixes piglit tex1d-2dborder test.
2009-10-29 14:56:52 -07:00
Eric Anholt
4b377ae292
i915: Correct and make use of the defines for 32-bit depth texture modes.
...
Previously, S8_Z24 depth textures would always be treated as intensity.
Fixes piglit depth-tex-modes.
2009-10-29 14:56:52 -07:00
Brian Paul
861fec163c
i965: avoid shader translation on window resize
...
If the fragment shader doesn't use FRAG_ATTRIB_WPOS (gl_FragCoord) we
don't need to worry about the window size and origin in
brw_wm_populate_key().
This avoids re-generating the i965 shader code when a window is resized.
Issue spotted by Keith Whitwell.
2009-10-29 15:33:43 -06:00
Brian Paul
198ec96d36
i965: define, use BRW_MAX_DRAW_BUFFERS
...
i965 might support more than 4 color draw buffers. But if not, this protects
from breakage if the Mesa limit is raised.
2009-10-29 15:33:43 -06:00
Brian Paul
7648c80ac8
i965: remove unused var
2009-10-29 15:33:43 -06:00
Brian Paul
9ef33b8685
i965: don't use context state in emit_fb_write()
...
Put the state that we care about in the hash key.
Issue spotted by Keith Whitwell.
2009-10-29 15:33:43 -06:00
Brian Paul
a8d233e509
i965: use macros to get/set prog_instruction::Aux field
...
This makes things a bit easier to remember/understand.
2009-10-29 15:33:43 -06:00
Brian Paul
a0959bcee5
i965: minor code reformatting
2009-10-29 15:33:43 -06:00
José Fonseca
c6164ff155
mesa: Add MESA_FORMAT_Z24_X8.
2009-10-29 20:03:51 +00:00
Zack Rusin
a7fa56a64b
st/xorg: fix scaling ov xv data, plus some cleanups
2009-10-29 15:13:17 -04:00
Eric Anholt
f8f40b53a6
i915: Implement min/max LOD clamping with the hardware.
...
This gets us expected behavior for clamping between mipmap levels, and
avoids relayout of textures for doing clamping.
Fixes piglit lodclamp-between.
2009-10-29 12:06:04 -07:00
Eric Anholt
3744472441
i965: Replace a MIN(MAX()) with CLAMP().
2009-10-29 12:06:03 -07:00
Brian Paul
ea414e3318
intel: check for single memcpy() in memcpy_get_tex_image()
2009-10-29 11:04:24 -06:00
Eric Anholt
92e7c6a258
i965: Fix fallout from ARB_depth_clamp enablement that broke glDepthRange.
...
If a backwards glDepthRange was supplied (as with the old Quake no-z-clearing
hack), the hardware would have always clamped because we weren't clamping to
the min of near/far and the max of near/far. Also, we shouldn't be clamping
to near/far at all when not in depth clamp mode (this usually didn't matter
since near/far are usually the same as the 0.0, 1.0 clamping you do for
fixed-point depth).
This should fix funny depth issues in PlaneShift, and fixes piglit
depth-clamp-range
2009-10-29 10:01:17 -07:00
Eric Anholt
32ec3f2673
mesa: Mostly fix swrast's ARB_depth_clamp support.
...
I'd written a testcase for the hard part of the extension enablement, so
naturally the easy stuff was completely broken. There are still issues,
as I'm seeing FLOAT_TO_UINT(max_f) == 0x0 when max_f == 1.0, but it gets
piglit depth-clamp-range closer to success.
2009-10-29 10:01:17 -07:00
Eric Anholt
6eb6a0e9cb
intel: Don't bother MI_FLUSHing on glFlush in the DRI2 case.
...
We only need it when drawing to the front buffer, which we never do for
DRI2. No significant performance difference, but the flush is definitely
gone from the end of every batchbuffer.
2009-10-29 10:01:17 -07:00
Eric Anholt
fb0084e69e
intel: Clean up merge leftover from the DRI2 swap throttling.
2009-10-29 10:01:16 -07:00
Brian Paul
1596f714d2
intel: remove debug code
2009-10-29 10:56:13 -06:00
Brian Paul
2b628d43c0
mesa: consolidate some code in _mesa_GetCompressedTexImageARB()
2009-10-29 10:53:26 -06:00
Brian Paul
dcb4716802
intel: added fast memcpy path for glGetTexImage()
2009-10-29 10:50:26 -06:00
Brian Paul
01ee5c63d3
mesa: move pixels==NULL check in glGetTexImage()
2009-10-29 10:50:26 -06:00
Brian Paul
99bbf4b4f5
mesa: consolidate some code in _mesa_GetTexImage()
2009-10-29 10:50:26 -06:00
Brian Paul
67df4fb56b
mesa: move, clean-up _mesa_print_texture()
2009-10-29 10:50:26 -06:00
Brian Paul
d580c0c8f7
mesa: fix some tests in subtexture_error_check2()
...
Don't use hard-coded compressed block sizes.
Update comments and error strings.
2009-10-29 10:50:26 -06:00
Brian Paul
cf7040594e
mesa: remove unneedded is_srgb_teximage() function
...
Use _mesa_get_format_color_encoding() function instead.
2009-10-29 10:50:26 -06:00
Brian Paul
c89f5b6ac8
glsl: make shader substitution a little better
2009-10-29 10:50:26 -06:00
David Heidelberger
41892e9b17
st/mesa: fix PIPE_FORMAT_X8Z24 <> MESA_FORMAT_X8_Z24 conversion
...
Signed-off-by: David Heidelberger <d.okias@gmail.com>
Signed-off-by: Brian Paul <brianp@vmware.com>
2009-10-29 10:14:41 -06:00
David Heidelberger
10a509564f
st/mesa: Add conversion from PIPE_FORMAT_X8Z24_UNORM to MESA_FORMAT_S8_Z24.
...
Fix glxgears and openarena for Nouveau (no more asserts and crash).
Signed-off-by: David Heidelberger <d.okias@gmail.com
Signed-off-by: Brian Paul <brianp@vmware.com>
2009-10-29 09:56:14 -06:00
David Heidelberger
c2f5eb7148
st/mesa: Fix nouveau glxinfo after merging texformat-rework.
...
Signed-off-by: David Heidelberger <d.okias@gmail.com>
Signed-off-by: Brian Paul <brianp@vmware.com>
2009-10-29 09:54:38 -06:00
Brian Paul
1f1bfe8cb5
mesa: move declaration to prevent unused var warning
2009-10-29 07:54:44 -06:00
Chia-I Wu
9927d7f31c
mesa: Fix compilation errors and warnings when features are disabled.
...
Some of the fixes are cherry-picked from opengl-es branch.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-29 07:52:58 -06:00
Chia-I Wu
59798cd886
mesa/main: Make FEATURE_texture_s3tc follow feature conventions.
...
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-29 07:52:58 -06:00
Chia-I Wu
20e20fc5af
mesa/main: Make FEATURE_texture_fxt1 follow feature conventions.
...
Also remove the unused initialization and GLchan fetch functions.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-29 07:52:58 -06:00
Chia-I Wu
920f023e8b
mesa/main: Never return NULL in _mesa_get_texstore_func.
...
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-29 07:52:58 -06:00
Brian Paul
e2131e0171
radeon: fix incorrect Z format in radeon_alloc_renderbuffer_storage()
...
And update error message.
2009-10-29 07:47:41 -06:00
Cooper Yuan
da1fb3be82
r300g: Fix bytes_per_line calculation error while displaying surface
2009-10-29 20:20:59 +08:00
Chia-I Wu
59b29516af
swrast: added braces
2009-10-28 22:14:01 -06:00
Brian Paul
c6bd5fae0c
mesa: remove old, unused #define
2009-10-28 21:52:37 -06:00
Brian Paul
bd36ca9b76
mesa: re-remove s3v and trident driver files
...
These were removed from master but a few files came back from the
texformat-rework branch.
2009-10-28 21:46:37 -06:00
Brian Paul
960d49b387
mesa: move some gl_texture_image and gl_renderbuffer fields around
2009-10-28 21:43:50 -06:00
Brian Paul
bc143b1a9f
mesa: minor code movement
2009-10-28 21:25:56 -06:00