Ben Skeggs [Tue, 6 Oct 2009 03:18:09 +0000 (13:18 +1000)]
nouveau: fix buffer object leak
Very apparent with resizing windows on DRI2.
Jakob Bornecrantz [Tue, 6 Oct 2009 01:30:43 +0000 (18:30 -0700)]
i915g: Add more defines to tweek batchbuffer
Jakob Bornecrantz [Tue, 6 Oct 2009 01:11:25 +0000 (18:11 -0700)]
i915g: Tweek vertexbuffer size
Brian Paul [Mon, 5 Oct 2009 20:43:38 +0000 (14:43 -0600)]
i965g: remove 965/brw files from XLIB_WINSYS_SOURCES
Brian Paul [Mon, 5 Oct 2009 20:42:08 +0000 (14:42 -0600)]
Merge branch 'mesa_7_6_branch'
Conflicts:
src/gallium/auxiliary/util/u_cpu_detect.c
Brian Paul [Mon, 5 Oct 2009 20:26:16 +0000 (14:26 -0600)]
intel: use driReadDrawable in do_copy_texsubimage()
Brian Paul [Mon, 5 Oct 2009 20:25:36 +0000 (14:25 -0600)]
intel: use driReadDrawable, not driDrawable in do_blit_readpixels()
Brian Paul [Mon, 5 Oct 2009 20:07:29 +0000 (14:07 -0600)]
intel: remove a buffer equality test in _mesa_make_current()
Before, if we called glXMakeCurrent() to change a context's window binding
while an FBO was bound, we weren't updating the intel->driDrawable and
intel->driReadDrawable fields. This could cause us to dereference a null
pointer elsewhere.
Jakob Bornecrantz [Tue, 29 Sep 2009 23:07:11 +0000 (16:07 -0700)]
i915g: Drop the simple sufix
None of the other driver have a silly sufix,
so just drop it. Nothing new added in this commit
or any other commit but this is better marketing.
Jakob Bornecrantz [Tue, 29 Sep 2009 17:22:15 +0000 (10:22 -0700)]
i965g: Drop i965simple
The driver never work with real hardware and has
bitrotted for quite some time now, might as well
drop it. If somebody wants to look at it just use git.
Joakim Sindholt [Mon, 5 Oct 2009 17:25:04 +0000 (19:25 +0200)]
r300g: fix scons build
So I didn't touch r300compiler, but r300g now compiles after having
declarations and code untangled. As nha so gently points out, we shouldn't
have to do this just to comply with MSVC compilers.
Brian Paul [Mon, 5 Oct 2009 17:10:31 +0000 (11:10 -0600)]
mesa: fix return value when clipping {Read,Draw}Pixels height <= 0
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
(cherry picked from master, commit
7aeaca33c331f70d507fc83583b13b8d9fc3e847)
Jon TURNEY [Fri, 24 Jul 2009 19:33:25 +0000 (20:33 +0100)]
Fix building of GLSL demos which use M_PI
Some <math.h> files do not define M_PI, in which case, provide our own definition
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
José Fonseca [Mon, 5 Oct 2009 15:45:38 +0000 (16:45 +0100)]
util: Improve the cpuid assembly.
No need to save ebx on 64bit. Use just xchgl. Refer to gcc's cpuid.h header.
Thanks to Uros Bizjak for pointing this out.
José Fonseca [Mon, 5 Oct 2009 10:05:34 +0000 (11:05 +0100)]
mesa: Copy textures' base format into wrapper renderbuffer.
Otherwise st_copy_texsubimage will fallback to software blit due to
inconsistent base formats.
Keith Whitwell [Mon, 5 Oct 2009 14:50:11 +0000 (15:50 +0100)]
mesa/st: add ST_DEBUG environment variable
At last it's possible to turn on tgsi dumps and other debugging in the
state tracker without modifying sources...
Keith Whitwell [Mon, 5 Oct 2009 14:46:47 +0000 (15:46 +0100)]
util: add lost code to util_make_fragment_tex_shader_writemask()
This got ported to ureg at some point, but lost the code that
distinguishes it from regular util_make_fragment_tex_shader().
Andre Maasikas [Mon, 5 Oct 2009 09:53:40 +0000 (12:53 +0300)]
r600: update vertex program selection for draw path
Michel Dänzer [Mon, 5 Oct 2009 10:31:51 +0000 (12:31 +0200)]
Use _mesa_select_tex_image() rather than hardcoding face 0.
Fixes crash loading a map in sauerbraten with
hwmipmap 1
in ~/.sauerbraten/config.cfg.
Ben Skeggs [Mon, 5 Oct 2009 05:51:47 +0000 (15:51 +1000)]
st/dri: avoid segfault if we can't get a pixmap's buffers
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Ben Skeggs [Mon, 5 Oct 2009 03:41:33 +0000 (13:41 +1000)]
nv50: support PIPE_FORMAT_X8R8G8B8_UNORM
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Ben Skeggs [Mon, 5 Oct 2009 03:39:34 +0000 (13:39 +1000)]
nouveau: return pitch value from local_handle_from_texture()
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Ben Skeggs [Mon, 5 Oct 2009 04:42:45 +0000 (14:42 +1000)]
mesa: fix return value when clipping {Read,Draw}Pixels height <= 0
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Ben Skeggs [Mon, 5 Oct 2009 05:32:55 +0000 (15:32 +1000)]
st/dri: no need to request fake front buffer, only handle it being returned
The previous behaviour was incorrect, and resulted in EXT_tfp being broken
for DDX drivers that implement the correct behaviour (intel/radeon/nouveau).
In the cases where a fake front buffer is required, the X server will
return one when requesting __DRI_BUFFER_FRONT_LEFT.
The Xorg state tracker (aka modesetting_drv) is likely broken now until
it's modified to match the other drivers.
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
Frederic Crozat [Sun, 4 Oct 2009 21:46:40 +0000 (17:46 -0400)]
r200: remove subpixel offset from viewport
Fixes bug fdo 20340 for r200.
José Fonseca [Sun, 4 Oct 2009 20:59:24 +0000 (21:59 +0100)]
util: Make assert a no-op on non-debug builds.
This ensures that an assertion like
assert(expensive_test());
won't have any penalty on release builds. It also implies that no vital
code should be in assert expressions.
José Fonseca [Sun, 4 Oct 2009 12:25:24 +0000 (13:25 +0100)]
llvmpipe: Ensure tile cache transfers are mapped before flushing it.
José Fonseca [Sun, 4 Oct 2009 12:04:08 +0000 (13:04 +0100)]
llvmpipe: Autogenerate lp_tile_soa.c from u_format.csv.
This is just a temporary change until we code generate the tile read/write
functions in runtime. The new code avoids an extra memcpy that exists in
u_tile.c functions, from which lp_tile_soa.c was originally based.
This achieves up to 5% improvement, particularly in frames with
little geometry overlap.
José Fonseca [Sun, 4 Oct 2009 11:49:31 +0000 (12:49 +0100)]
util: Fix cpuid invocation for x86_64.
José Fonseca [Sun, 4 Oct 2009 10:36:42 +0000 (11:36 +0100)]
llvmpipe: Remove loop testing from format testing.
Loop building will be rewritten.
José Fonseca [Sun, 4 Oct 2009 10:35:50 +0000 (11:35 +0100)]
llvmpipe: Match header's protection macro with filename.
José Fonseca [Sat, 3 Oct 2009 21:15:17 +0000 (22:15 +0100)]
llvmpipe: Adjust format assertion.
We support array layout too -- if it has a single channel.
Corbin Simpson [Thu, 1 Oct 2009 02:44:38 +0000 (19:44 -0700)]
r300g: xRGB and RGBx formats.
We now have 48 GLX visuals. Pretty soon, we'll have 90+ visuals,
only five of which ever get tested. :3
Chris Wilson [Sat, 3 Oct 2009 22:08:39 +0000 (23:08 +0100)]
intel: Suppress a compiler warning for an pointer->int cast
intel_pixel_read.c: In function ‘do_blit_readpixels’:
intel_pixel_read.c:221: warning: cast from pointer to integer of
different size
Cast via an intermediate (GLintptr) instead and hope the result fits
within GLuint... [It should as we simply do not support textures *that*
large!]
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Chris Wilson [Fri, 2 Oct 2009 18:46:03 +0000 (19:46 +0100)]
intel: Assert that relocation offsets are within the target
This should catch the common programming error where we attempt to
emit a relocation to beyond the end of the target buffer.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
José Fonseca [Sat, 3 Oct 2009 18:42:22 +0000 (19:42 +0100)]
llvmpipe: Fetch tile only if a color buffer is bound.
Nicolai Hähnle [Sat, 3 Oct 2009 14:18:57 +0000 (16:18 +0200)]
prog_parameter: Document the fact that Size may be > 4
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
Nicolai Hähnle [Sat, 3 Oct 2009 17:20:31 +0000 (19:20 +0200)]
r300g: Do not abort on fragment program compiler error
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
Nicolai Hähnle [Sat, 3 Oct 2009 15:56:51 +0000 (17:56 +0200)]
r300g: Fix memory leak in radeon_texture_from_shared_handle
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
Sedat Dilek [Sat, 3 Oct 2009 16:01:58 +0000 (18:01 +0200)]
r300g: Build in the trace and softpipe driver for xorg state tracker
Same as in src/gallium/winsys/drm/intel/xorg/Makefile
Thanks MrCooper for explanations on IRC
[ Summary amended by Michel Dänzer to clarify that this is related to the xorg
state tracker ]
Michel Dänzer [Sat, 3 Oct 2009 16:01:58 +0000 (18:01 +0200)]
radeon: Cope better with texture images with no miptrees.
Fixes crash with compiz magnifier plugin.
Michel Dänzer [Sat, 3 Oct 2009 16:01:58 +0000 (18:01 +0200)]
swrast: Move up state validation in _swrast_ReadPixels.
This ensures the driver won't map the wrong set of textures.
Michel Dänzer [Sat, 3 Oct 2009 16:01:57 +0000 (18:01 +0200)]
meta: Make sure texImage->TexFormat is valid for CopyTex(Sub)Image.
Nicolai Hähnle [Sat, 3 Oct 2009 15:49:16 +0000 (17:49 +0200)]
r300g: Remove an unnecessarily created pipe buffer (and thus fix a leak)
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
Nicolai Hähnle [Sat, 3 Oct 2009 15:39:32 +0000 (17:39 +0200)]
st/dri: Install APPLE_vertex_array_object functions
Besides from being necessary to use that extension, it also fixes a crash
when deleting the currently bound vertex array object.
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
Nicolai Hähnle [Sat, 3 Oct 2009 15:24:04 +0000 (17:24 +0200)]
r300g: Reset vbo_offset after allocation of a new buffer
This fixes the glxgears bug, among other things.
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
Nicolai Hähnle [Sat, 3 Oct 2009 00:11:02 +0000 (02:11 +0200)]
st/dri: Install ARB_vertex_array_object functions
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
Nicolai Hähnle [Fri, 2 Oct 2009 23:26:38 +0000 (01:26 +0200)]
r300: Workaround problem on R500 with very large fragment programs
The non-KMS interface is to blame here. In theory, a proper fix
could be produced that works for the KMS interface only, but it
require cleaning a lot of mess. Easier to just do it right in r300g.
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
Brian Paul [Fri, 2 Oct 2009 19:59:41 +0000 (13:59 -0600)]
mesa: optimized _mesa_meta_BlitFramebuffer() for src=texture case
If the src renderbuffer is actually a texture, we can directly use that
texture as the src and avoid a copy.
Eric Anholt [Fri, 2 Oct 2009 17:53:56 +0000 (10:53 -0700)]
i965: Use a little stack space to avoid a malloc in wm_get_binding_table.
Eric Anholt [Fri, 2 Oct 2009 00:59:05 +0000 (17:59 -0700)]
mesa: Remove another unexplained Flush call, this time from BindFramebuffer.
Combined with the previous fix, it takes cairo-gl firefox-talos-gfx time
from 120 seconds to 90 seconds on my GM45.
Eric Anholt [Thu, 1 Oct 2009 23:53:12 +0000 (16:53 -0700)]
Revert "Flush driver, not just tnl module."
This reverts commit
df058298e1570eea8712f9bb051f674fab2eaf24. It didn't
explain why it was required, doesnt appear to be required, and is a
significant performance penalty for cairo-gl firefox.
Conflicts:
src/mesa/main/fbobject.c
Eric Anholt [Fri, 2 Oct 2009 01:07:57 +0000 (18:07 -0700)]
intel: Remove an unexplained flush from intelClearWithBlit.
Alex Deucher [Fri, 2 Oct 2009 18:25:52 +0000 (14:25 -0400)]
r600: remove support for host-based ibs
no longer used now that the hw supports this natively.
Also, clean up some formatting.
Keith Whitwell [Fri, 2 Oct 2009 14:36:47 +0000 (15:36 +0100)]
mesa/st: don't reuse vertex buffers for bitmap, clear quads
Currently using max_slots > 1 will cause synchronous rendering
if the driver flushes its command buffers between one bitmap and the
next.
Need to improve buffer_write to allow NO_WAIT (as well as no_flush)
updates to buffers where we know there is no conflict with previous
data.
Michel Dänzer [Fri, 2 Oct 2009 16:13:26 +0000 (18:13 +0200)]
st/xorg: Use PIPE_TRANSFER_MAP_DIRECTLY flag in EXA PrepareAccess hook.
Propagate NULL return value.
This also allows removing the DRM_MODE_FEATURE_DIRTYFB specific pixmap
management hacks.
Michel Dänzer [Fri, 2 Oct 2009 16:13:26 +0000 (18:13 +0200)]
gallium: Add PIPE_TRANSFER_MAP_DIRECTLY usage flag.
Asks the driver to map the texture storage directly or return NULL if that's
not possible.
Michel Dänzer [Fri, 2 Oct 2009 16:13:26 +0000 (18:13 +0200)]
gallium: Preparations for adding more PIPE_TRANSFER_* usage flags.
Always test for PIPE_TRANSFER_READ/WRITE using the bit-wise and operator, and
add a pipe_transfer_buffer_flags() helper for getting the buffer usage flags
corresponding to them.
Brian Paul [Fri, 2 Oct 2009 15:58:16 +0000 (09:58 -0600)]
docs: document default texture binding fix
Brian Paul [Fri, 2 Oct 2009 15:55:07 +0000 (09:55 -0600)]
mesa: fix incorrect default texture binding in unbind_texobj_from_texunits()
If we deleted a currently bound texture, we were always reverting the texture
binding to the default 1D texture rather than the proper default texture.
Brian Paul [Fri, 2 Oct 2009 14:55:25 +0000 (08:55 -0600)]
intel: wrap _mesa_meta_GenerateMipmap()
Need to check if we'll take the software path so which requires mapping the
src texture image.
Fixes crash in piglit gen-compressed-teximage, bug 24219. However, the
test still does not pass (it may never have).
Brian Paul [Fri, 2 Oct 2009 14:54:55 +0000 (08:54 -0600)]
mesa: added _mesa_meta_check_generate_mipmap_fallback()
Brian Paul [Fri, 2 Oct 2009 13:52:27 +0000 (07:52 -0600)]
gallium/xlib: use bitwise-and to test GLX_RGBA_BIT in choose_visual()
The parameter is a bitmask.
Brian Paul [Fri, 2 Oct 2009 13:51:15 +0000 (07:51 -0600)]
xlib: use bitwise-and to test GLX_RGBA_BIT in choose_visual()
The parameter is a bitmask.
Brian Paul [Fri, 2 Oct 2009 13:47:49 +0000 (07:47 -0600)]
gallium/xlib: return GLX_RGBA_BIT or GLX_COLOR_INDEX_BIT in get_config()
This reverts part of commit
a6b84aef4ad3a7bac40704146a98977c62bfb6e8
Brian Paul [Fri, 2 Oct 2009 13:31:42 +0000 (07:31 -0600)]
gallium: replace // comments with /* */
Brian Paul [Fri, 2 Oct 2009 13:26:28 +0000 (07:26 -0600)]
gallium: remove // comment and extra whitespace
Younes Manton [Fri, 2 Oct 2009 02:25:46 +0000 (22:25 -0400)]
g3dvl: Formatting.
Younes Manton [Fri, 2 Oct 2009 02:17:47 +0000 (22:17 -0400)]
g3dvl: Delete state_trackers/g3dvl, other unused files.
Younes Manton [Fri, 2 Oct 2009 02:16:10 +0000 (22:16 -0400)]
g3dvl: Copyright blocks.
Younes Manton [Fri, 2 Oct 2009 02:01:18 +0000 (22:01 -0400)]
st/xvmc: Set default CSC matrix to BT.601, no ProcAmp, full range RGB.
Younes Manton [Fri, 2 Oct 2009 01:53:17 +0000 (21:53 -0400)]
g3dvl: Color space conv interface & vl impl.
Interface is pipe_video_context::set_csc_matrix().
vl_csc.h defines some helpers to generate CSC matrices based on one of
the color standard and a user defined ProcAmp (brightness, contrast,
saturation, hue).
Eric Anholt [Wed, 29 Jul 2009 20:07:49 +0000 (13:07 -0700)]
i915: Add stub ARB_occlusion_query support under a driconf debug option.
This is useful for enabling our GLSL testcases using the 2.0 entrypoints
even though we don't have full GL 2.0.
Eric Anholt [Wed, 29 Jul 2009 20:00:09 +0000 (13:00 -0700)]
i915: Add optional support for ARB_fragment_shader under a driconf option.
Other vendors have enabled ARB_fragment_shader as part of OpenGL 2.0
enablement even on hardware like the 915 with no dynamic branching or
dFdx/dFdy support. But for now we'll leave it disabled because we don't
do any flattening of ifs or loops, which is rather restrictive.
This support is not complete, and may be unstable depending on your shaders.
It passes 10/15 of the piglit glsl tests, but hangs on glean glsl1.
Eric Anholt [Thu, 30 Jul 2009 03:44:39 +0000 (20:44 -0700)]
i915: Add support or fallbacks for GLSL fragment shader opcodes.
Eric Anholt [Thu, 1 Oct 2009 21:00:28 +0000 (14:00 -0700)]
i915: Add support for varying inputs.
Eric Anholt [Wed, 29 Jul 2009 19:15:14 +0000 (12:15 -0700)]
i915: Enable ARB_vertex_shader for both i915 and i830.
Since the TNL is all done in software anyway, it should be the same to
the user who's probably using ARB_vertex_program otherwise, but gives them
a nicer programming environment.
Eric Anholt [Thu, 30 Jul 2009 07:03:21 +0000 (00:03 -0700)]
i915: Increase maximum program size to the hardware limits.
This fixes potential heap trashing if the program of choice exceeds limits,
and fixes the native instructions limit being lower than what can be
used by valid programs.
Eric Anholt [Thu, 30 Jul 2009 06:37:04 +0000 (23:37 -0700)]
i915: Update and translate the fragment program along with state updates.
Previously, we were doing it in the midst of the pipeline run, which gave
an opportunity to enable/disable fallbacks, which is certainly the wrong
time to be doing so. This manifested itself in a NULL dereference for PutRow
after transitioning out of a fallback during a run_pipeline in glean glsl1.
Eric Anholt [Thu, 30 Jul 2009 05:46:14 +0000 (22:46 -0700)]
Revert "i915: don't validate PS program when falling back to software"
This reverts commit
e7044d552c6d16389447880b8744a51de1cf0199. It
prevented the driver from ever recovering from a software fallback due
to a program error. The original bug it claimed to fix doesn't appear to
exist post-revert.
Eric Anholt [Thu, 30 Jul 2009 05:39:15 +0000 (22:39 -0700)]
i915: Bail when the fragment program has too many total instructions.
Previously, we'd go trashing the heap.
Eric Anholt [Thu, 30 Jul 2009 19:32:40 +0000 (12:32 -0700)]
i915: Let i915_program_error take a format string, and don't use _mesa_problem.
It's misleading to report things like the program having too many native
instructions as a Mesa implementation error, when the program may just be
too big for the hardware.
Brian Paul [Thu, 1 Oct 2009 20:55:13 +0000 (14:55 -0600)]
mesa: fix memory leak when generating mipmaps for compressed textures
Brian Paul [Thu, 1 Oct 2009 20:52:28 +0000 (14:52 -0600)]
mesa: fix mem leaks
Brian Paul [Thu, 1 Oct 2009 20:52:10 +0000 (14:52 -0600)]
gallium/util: silence uninitialized var warning
Brian Paul [Thu, 1 Oct 2009 20:51:43 +0000 (14:51 -0600)]
mesa: add missing return when out of memory
Brian Paul [Thu, 1 Oct 2009 20:51:26 +0000 (14:51 -0600)]
mesa: fix potential uninitialized memory reads
Brian Paul [Thu, 1 Oct 2009 20:50:45 +0000 (14:50 -0600)]
glsl: fix mem leak
Brian Paul [Thu, 1 Oct 2009 20:49:34 +0000 (14:49 -0600)]
st/mesa: check for null before asserts, fix possible mem leak
Brian Paul [Thu, 1 Oct 2009 20:49:04 +0000 (14:49 -0600)]
st/mesa: silence hidden parameter warning
Brian Paul [Thu, 1 Oct 2009 19:35:42 +0000 (13:35 -0600)]
Merge branch 'mesa_7_6_branch'
Brian Paul [Thu, 1 Oct 2009 19:34:49 +0000 (13:34 -0600)]
st/mesa: fix non-mipmap lastLevel calculation.
reviewed by Brian Paul.
(cherry picked from master, commit
ae2daacbac7242938cffe0e2409071e030e00863)
Vinson Lee [Thu, 1 Oct 2009 19:33:20 +0000 (13:33 -0600)]
mesa: Return -FLT_MAX instead of 0 for LG2(0).
lim x->0 log(x) = -inf so -FLT_MAX is a better approximation than 0
for LG2(0).
Brian Paul [Thu, 1 Oct 2009 19:14:16 +0000 (13:14 -0600)]
objviewer: remove disabled code
Brian Paul [Thu, 1 Oct 2009 19:13:28 +0000 (13:13 -0600)]
objviewer: mouse/keyboard info in README file
Brian Paul [Thu, 1 Oct 2009 19:11:38 +0000 (13:11 -0600)]
docs: added objviewer to release notes
Brian Paul [Thu, 1 Oct 2009 19:11:25 +0000 (13:11 -0600)]
mesa: add objviewer to PROGRAM_DIRS
Brian Paul [Thu, 1 Oct 2009 19:11:13 +0000 (13:11 -0600)]
mesa: add progs/objviewer to tarball list
Brian Paul [Thu, 1 Oct 2009 19:07:01 +0000 (13:07 -0600)]
objview: clean up drawing VBO code
Brian Paul [Thu, 1 Oct 2009 19:05:25 +0000 (13:05 -0600)]
objview: set skybox texture filter