Commit graph

40612 commits

Author SHA1 Message Date
Brian Paul
78587ea012 mesa: fix glDeleteBuffers() regression
This fixes a regression (failed assertion) from commit
c552f273f5 which was hit if glDeleteBuffers()
was called on a buffer that was never bound.

NOTE: this is a candidate for the 7.9 branch.
2010-11-11 15:31:36 -07:00
Brian Paul
c552f273f5 mesa: make glIsBuffer() return false for never bound buffers
Use a dummy buffer object as we do for frame/renderbuffer objects.
Fixes http://bugs.freedesktop.org/show_bug.cgi?id=31514

Note: this is a candidate for the 7.9 branch.
2010-11-11 14:49:53 -07:00
Aras Pranckevicius
d67df5dd9d glsl: fix crash in loop analysis when some controls can't be determined
Fixes loop-07.frag.
2010-11-11 10:49:37 -08:00
Keith Whitwell
7fb16423cc r600g: enforce minimum stride on render target texture images
Fixes piglit/fbo_readpixels since staging upload changes.
2010-11-11 16:20:24 +00:00
Keith Whitwell
8a3c181e9c r600g: do not try to use staging resource for depth textures
Currently r600_resource_copy_region() will turn these copies into
transfers + memcpys, so to avoid recursion we must not turn those
transfers back into blits.
2010-11-11 15:43:31 +00:00
Brian Paul
b3b6476695 mesa: handle more pixel types in mipmap generation code
NOTE: This is a candidate for the 7.9 branch.
2010-11-11 08:33:42 -07:00
Brian Paul
79c65410c1 mesa: add missing formats in _mesa_format_to_type_and_comps()
NOTE: this is a candidate for the 7.9 branch
2010-11-11 08:31:21 -07:00
Brian Paul
c9126d66fa mesa: improve error message 2010-11-11 07:43:46 -07:00
Brian Paul
624661cae4 mesa: #include mfeatures.h in enums.h 2010-11-11 07:43:46 -07:00
Keith Whitwell
6baad55f15 r600g: guard experimental s3tc code with R600_ENABLE_S3TC 2010-11-11 14:30:09 +00:00
Lucas Stach
089056a5f3 nvfx: fill PIPE_CAP_PRIMITIVE_RESTART and PIPE_CAP_SHADER_STENCIL_EXPORT
Signed-off-by: Lucas Stach <dev@lynxeye.de>
Signed-off-by: Francisco Jerez <currojerez@riseup.net>
2010-11-11 14:55:46 +01:00
Francisco Jerez
cdb38b5d3d dri/nouveau: Split hardware/software TNL instantiation more cleanly. 2010-11-11 14:50:50 +01:00
Vinson Lee
dc524adee2 mesa: Fix printf format warnings. 2010-11-10 17:30:59 -08:00
Ian Romanick
bcef51c3b8 mesa: Allow query of MAX_SAMPLES with EXT_framebuffer_multisample
Previously queries of MAX_SAMPLES were only allowed with
ARB_framebuffer_object, but EXT_framebuffer_multisample also enables
this query.  This seems to only effect the i915.  All other drivers
support both extensions or neither extension.

This patch is based on a patch that Kenneth sent along with the report.

NOTE: this is a candidate for the 7.9 branch.

Reported-by: Kenneth Waters <kwaters@chromium.org>
2010-11-10 16:00:03 -08:00
Jakob Bornecrantz
0faa7ada84 libgl-xlib: Use sw helper instead of roll your own 2010-11-10 23:40:18 +00:00
Jakob Bornecrantz
89deebb1af graw: Use inline sw helper instead of roll your own loader 2010-11-10 23:05:17 +00:00
Jakob Bornecrantz
d4c60575f8 galahad: Correct the name of the scons library 2010-11-10 23:05:17 +00:00
Jerome Glisse
8e0230a85c r600g: allow driver to work without submitting cmd to GPU
For driver performance analysis it usefull to be able to
disable as much as possible the GPU interaction so that
one can profile the userspace only.

Signed-off-by: Jerome Glisse <jglisse@redhat.com>
2010-11-10 16:49:50 -05:00
Robert Hooker
e8b2d36723 intel: Add a new B43 pci id.
Signed-off-by: Robert Hooker <robert.hooker@canonical.com>
2010-11-10 13:37:47 -08:00
Eric Anholt
9effc1adf1 i965: re-enable gen6 IF statements in the fragment shader.
IF statements were getting flattened while they were broken.  With
Zhenyu's last fix for ENDIF's type, everything appears to have lined
up to actually work.

This regresses two tests:
glsl1-! (not) operator (1, fail)
glsl1-! (not) operator (1, pass)

but fixes tests that couldn't work before because the IFs couldn't be
flattened:
glsl-fs-discard-01
occlusion-query-discard

(and, naturally, this should be a performance improvement for apps
that actually use IF statements to avoid executing a bunch of code).
2010-11-10 13:33:27 -08:00
Eric Anholt
490c23ee6b i965: Work around strangeness in swizzling/masking of gen6 math.
Sometimes we swizzled in a different channel it looked like, and
sometimes we swizzled in zero.  Or something.

Having looked at the output of another code generator for this chip,
this is approximately what they do, too: use align1 math on
temporaries, and then move the results into place.

Fixes:
glean/vp1-EX2 test
glean/vp1-EXP test
glean/vp1-LG2 test
glean/vp1-RCP test (reciprocal)
glean/vp1-RSQ test 1 (reciprocal square root)
shaders/glsl-cos
shaders/glsl-sin
shaders/glsl-vs-masked-cos
shaders/vpfp-generic/vp-exp-alias
2010-11-10 12:36:23 -08:00
Francisco Jerez
47c471f281 meta: Handle bitmaps with alpha test enabled.
Acked-by: Brian Paul <brianp@vmware.com>
2010-11-10 21:24:31 +01:00
Zack Rusin
f623d0c1c2 gallivm: implement indirect addressing over inputs
Instead of messing with the callers simply copy our inputs into a
alloca array at the beginning of the function and then use it.

Reviewed-by: José Fonseca <jfonseca@vmware.com>
2010-11-10 13:00:35 -05:00
Roland Scheidegger
aad65fa112 mesa: remove unneeded DD_POINT_SIZE and DD_LINE_WIDTH tricaps
DD_POINT_SIZE was broken for quite some time, and the only driver (r200) relying
on this no longer needs it.
Both DD_POINT_SIZE and DD_LINE_WIDTH have no users left outside of debugging
output, hence instead of fixing DD_POINT_SIZE setting just drop both of them -
there was a plan to remove tricaps flags entirely at some point.
2010-11-10 17:24:42 +01:00
Roland Scheidegger
c7192ab11f r200: fix r200 large points
DD_POINT_SIZE got never set for some time now (as it was set only in ifdefed
out code), which caused the r200 driver to use the point primitive mistakenly
in some cases which can only do size 1 instead of point sprite. Since the
logic to use point instead of point sprite prim is flaky at best anyway (can't
work correctly for per-vertex point size), just drop this and always emit point
sprites (except for AA points) - reasons why the driver tried to use points for
size 1.0 are unknown though it is possible they are faster or more conformant.
Note that we can't emit point sprites without point sprite cntl as that might
result in undefined point sizes, hence need drm version check (which was
unnecessary before as it should always have selected points). An
alternative would be to rely on the RE point size clamp controls which could
clamp the size to 1.0 min/max even if the SE point size is undefined, but currently
always use 0 for min clamp. (As a side note, this also means the driver does
not honor the gl spec which mandates points, but not point sprites, with zero size
to be rendered as size 1.)
This should fix recent reports of https://bugs.freedesktop.org/show_bug.cgi?id=702.
This is a candidate for the mesa 7.9 branch.
2010-11-10 17:24:41 +01:00
Chia-I Wu
aa139a14ba egl_dri2: Fix __DRI_DRI2 version 1 support.
Correctly set __DRI_API_OPENGL flag.
2010-11-10 23:57:50 +08:00
Marek Olšák
93c04749be r300g: turn magic numbers into names in the hyperz code 2010-11-10 15:14:25 +01:00
Marek Olšák
1d28936dea r300g: rename has_hyperz -> can_hyperz 2010-11-10 15:14:25 +01:00
Marek Olšák
88ddfc57e4 r300g: mention ATI in the renderer string 2010-11-10 15:14:25 +01:00
Keith Whitwell
9a04eca2f8 ws/r600: match bo_busy shared/fence logic in bo_wait
Fixes crash in piglit depthrange-clear.
2010-11-10 11:04:38 +00:00
Vinson Lee
5b8ed2f6d2 mesa: Clean up header file inclusion in pixelstore.h. 2010-11-10 00:49:53 -08:00
Vinson Lee
700add5707 mesa: Clean up header file inclusion in pixel.h. 2010-11-10 00:46:27 -08:00
Zhenyu Wang
65972f992f Revert "i965: VS use SPF mode on sandybridge for now"
This reverts commit 9c39a9fcb2.

Remove VS SPF mode, conditional instruction works for VS now.
2010-11-10 08:17:45 -05:00
Zhenyu Wang
9249af17b8 i965: fix dest type of 'endif' on sandybridge
That should also be immediate value for type W.
2010-11-10 08:17:29 -05:00
Eric Anholt
f289dcd849 i965: Add support for math on constants in gen6 brw_wm_glsl.c path.
Fixes 10 piglit cases that were assertion failing.
2010-11-09 20:20:00 -08:00
Ian Romanick
ad8cb131d8 ir_to_mesa: Refactor code for emitting DP instructions 2010-11-09 18:09:41 -08:00
Eric Anholt
f00929cbdd i965: Allow OPCODE_SWZ to put immediates in the first arg.
Fixes assertion failure with texture swizzling in the GLSL path when
it's triggered (such as gen6 FF or ARB_fp shadow comparisons).

Fixes:
texdepth
texSwizzle
fp1-DST test
fp1-LIT test 3
2010-11-09 17:18:52 -08:00
Kenneth Graunke
afb6fb9a92 glsl: Remove unnecessary "unused variable" warning suppression.
The "instructions" variable -is- used, so the cast to void can go away.
2010-11-09 15:55:40 -08:00
Peter Clifton
efb0417040 intel: Add assert check for blitting alignment.
Also fixup code comment to reflect that the GPU requires DWORD
alignment, but in this case does not actually pass the value "in
DWORDs" as I previously stated.
2010-11-09 14:35:28 -08:00
Eric Anholt
00391c7941 Revert "intel: Fix the client-side swapbuffers throttling."
This reverts commit 76360d6abc.  On
second thought, it turned out that sync objects also used the
wait_rendering API like this, and would need the same treatment, and
so wait_rendering itself is fixed in libdrm now.
2010-11-09 14:03:04 -08:00
Eric Anholt
76360d6abc intel: Fix the client-side swapbuffers throttling.
We were asking for a wait to GTT read (all GPU rendering to it
complete), instead of asking for all GPU reading from it to be
complete.  Prevents swapbuffers-based apps from running away with
rendering, and produces a better input experience.
2010-11-09 13:30:27 -08:00
Ian Romanick
956ae44dcf glsl: Fix incorrect gl_type of sampler2DArray and sampler1DArrayShadow
NOTE: this is a candidate for the 7.9 branch.
2010-11-09 13:05:07 -08:00
José Fonseca
10740acf46 gallivm: Allocate TEMP/OUT arrays only once. 2010-11-09 20:36:28 +00:00
Zack Rusin
528c3cd241 gallivm: implement indirect addressing of the output registers 2010-11-09 20:36:28 +00:00
Vinson Lee
520140a6c9 winsys/xlib: Add cygwin to SConscript.
Fixes SCons NameError exception on Cygwin.
2010-11-09 12:31:11 -08:00
Keith Whitwell
63c3e3a3dc r600: fix my pessimism about PIPE_TRANSFER_x flags
For some reason I though we needed the _DISCARD flag to avoid
readbacks, which isn't true at all.  Now write operations should
pipeline properly, gives a good speedup to demos/tunnel.
2010-11-09 20:12:46 +00:00
Keith Whitwell
9f7ec103e2 r600g: translate ARR instruction 2010-11-09 20:12:46 +00:00
Keith Whitwell
c2c55547dc r600g: attempt to turn on DXTn formats
Seems to sort-of work for non-mipmapped textures.  Better than just
black anyway.
2010-11-09 20:12:46 +00:00
Keith Whitwell
e3ea4aec03 r600g: avoid recursion with staged uploads
Don't use an intermediate for formats which don't support hardware
blits under u_blitter.c, as these will recursively attempt to create a
transfer.
2010-11-09 20:12:46 +00:00
Brian Paul
6e2e136428 mesa: no-op glBufferSubData() on size==0
Fixes http://bugs.freedesktop.org/show_bug.cgi?id=31439

NOTE: this is a candidate for the 7.9 branch
2010-11-09 12:24:51 -07:00