Commit graph

40409 commits

Author SHA1 Message Date
Chad Versace
223568fbcd mesa: Fix C++ includes in sampler.cpp
Some C++ header files were included in an extern "C" block. When building with
Clang, this caused the build to fail due to namespace errors. (GCC did not
report any errors.)

Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
2010-11-02 10:36:20 -07:00
Keith Whitwell
8dfafbf086 st/mesa: unbind constant buffer when not in use
Important as more constant buffers per shader start to get used.

Fix up r600 (tested) and nv50 (untested) to cope with this.  Drivers
previously didn't see unbinds of constant buffers often or ever, so
this isn't always dealt with cleanly.

For r600 just return and keep the reference.  Will try to do better in
a followup change.
2010-11-02 16:57:24 +00:00
Keith Whitwell
debcb43489 llvmpipe: guard against NULL task->query pointer
This doesn't seem like it should be possible, but some test suites
manage to hit this case.  Avoid crashing release builds under those
circumstances.
2010-11-02 16:48:10 +00:00
Keith Whitwell
98445b4307 llvmpipe: avoid generating tri_16 for tris which extend past tile bounds
Don't trim triangle bounding box to scissor/draw-region until after
the logic for emitting tri_16.  Don't generate tri_16 commands for
triangles with untrimmed bounding boxes outside the current tile.

This is important as the tri-16 itself can extend past tile bounds and
we don't want to add code to it to check against tile bounds (slow) or
restrict it to locations within a tile (pessimistic).
2010-11-02 16:48:10 +00:00
Brian Paul
fc70c05dbd mesa: fix aux/accum comment and error message mixups 2010-11-02 09:56:04 -06:00
Brian Paul
4a9ce9b299 mesa: remove always-false conditional in check_compatible()
The two gl_config pointers can never be equal.
2010-11-02 09:40:57 -06:00
Brian Paul
670207e6d0 dri/util: add a bunch of comments 2010-11-02 09:33:23 -06:00
Brian Paul
0fefafb2e4 mesa: move the gl_config struct declaration
It was in the middle of the lighting-related structures before.
Also add some info about field sizes in this structure.
2010-11-02 09:33:17 -06:00
Brian Paul
ee1f047c81 mesa: use GLubyte for edge flag arrays
Fixes http://bugs.freedesktop.org/show_bug.cgi?id=31310
2010-11-02 08:23:24 -06:00
José Fonseca
265b53983e scons: Propagate installation targets.
Fixes libgl-xlib target.
2010-11-02 14:20:12 +00:00
José Fonseca
45f4b85d58 scons: i915 can't build on MSVC either.
I thought I had singled it out before, but apparently not.
2010-11-02 13:49:35 +00:00
José Fonseca
3ae04dd910 scons: Add aliases for several pipe drivers. 2010-11-02 12:35:52 +00:00
José Fonseca
4f8dbd2f5e r600g: List recently added files in SConscript. 2010-11-02 12:35:52 +00:00
Zhenyu Wang
aedc270966 i965: refresh wm push constant also for BRW_NEW_FRAMENT_PROGRAM on gen6
Fix compiz crash.

https://bugs.freedesktop.org/show_bug.cgi?id=31124
2010-11-02 16:06:13 +08:00
Chia-I Wu
16ee7a55ae mesa: Allow contexts of different APIs to coexist.
This effectively redoes 1741ddb747 in a
way that allows contexts of different APIs to coexist.

First, the changes to the remap table are reverted.  The remap table
(driDispatchRemapTable) is always initialized in the same way regardless
of the context API.

es_generator.py is updated to use a local remap table, whose sole
purpose is to help initialize its dispatch table.  The local remap table
and the global one are always different, as they use different
glapidispatch.h.  But the dispatch tables initialized by both remap
tables are always compatible with glapi (libGL.so).

Finally, the semantics of one_time_init are changed to per-api one-time
initialization.
2010-11-02 14:43:35 +08:00
Chia-I Wu
fdede1efaa mesa: Select FEATURE_remap_table when multiple APIs are enabled.
Core mesa should query glapi for the positions of the functions in
_glapi_table when multiple APIs are supported.  It does not know which
glapitable.h glapi used.
2010-11-02 14:17:56 +08:00
Tom Stellard
6b999c89ce r300/compiler: Don't track readers into an IF block.
This makes rc_get_readers_normal() more conservative than it needs to be,
but it fixes some incorrect behavior in the optimization passes.
2010-11-01 22:06:20 -07:00
Chia-I Wu
ad00a92ee7 egl: Rework _eglGetSearchPath.
So that the directory part of EGL_DRIVER, if exists, is prepended to the
search path.  This commit also adds a sanity check to _eglLog.
2010-11-02 01:37:16 +08:00
José Fonseca
583e41855b scons: Disable python state tracker when swig is not present. 2010-11-01 15:27:34 +00:00
José Fonseca
0fd41d236f scons: Restore x11 tool behavior for backwards compatability. 2010-11-01 14:37:18 +00:00
José Fonseca
ab9ca6caa8 scons: Some pipe drivers are not portable for MSVC 2010-11-01 14:24:08 +00:00
José Fonseca
f9156ebcc4 scons: Fix MinGW cross-compilation. 2010-11-01 13:56:16 +00:00
José Fonseca
601498ae73 scons: Revamp how to specify targets to build.
Use scons target and dependency system instead of ad-hoc options.

Now is simply a matter of naming what to build. For example:

  scons libgl-xlib

  scons libgl-gdi

  scons graw-progs

  scons llvmpipe

and so on. And there is also the possibility of scepcified subdirs, e.g.

  scons src/gallium/drivers

If nothing is specified then everything will be build.

There might be some rough corners over the next days. Please bare with me.
2010-11-01 13:30:22 +00:00
Francisco Jerez
a84bd587c6 dri/nouveau: Re-emit the BO state when coming back from a software fallback. 2010-10-31 22:07:38 +01:00
Francisco Jerez
4a282629c2 dri/nouveau: Validate the framebuffer state on read buffer changes. 2010-10-31 22:07:26 +01:00
Francisco Jerez
453b718552 dri/nouveau: Fix type promotion issue on 32bit platforms.
Fixes some VTX protection errors introduced by e89af20926.
2010-10-31 22:07:10 +01:00
Benjamin Franzke
6102683b19 st/egl image: multiply drm buf-stride with blocksize
[olv: formatted for 80-column wrapping]
2010-11-01 01:03:53 +08:00
Chia-I Wu
52ef148923 targets/egl: Fix a warning with --disable-opengl build.
API_DEFINES is the defines for libmesagallium.a.  Append it to
egl_CPPFLAGS only when st_GL.so, which uses libmesagallium.a, is built.
2010-10-31 21:22:26 +08:00
Chia-I Wu
1230050363 autoconf: Tidy configure output for EGL.
Prefix EGL driver names by "egl_".  Make it clear that EGL_CLIENT_APIS
is only used by egl_gallium.
2010-10-31 21:22:26 +08:00
Tom Stellard
a15cf3cd0b r300/compiler: Don't clobber presubtract sources during optimizations
https://bugs.freedesktop.org/show_bug.cgi?id=28294
2010-10-30 22:26:19 -07:00
Francisco Jerez
088145f950 dri/nouveau: Pipeline glTexSubImage texture transfers. 2010-10-31 02:02:33 +01:00
Francisco Jerez
f67fa52293 dri/nouveau: Keep small DYNAMIC_DRAW vertex buffers in system ram. 2010-10-31 02:01:24 +01:00
Francisco Jerez
e89af20926 dri/nouveau: Optimize VBO binding re-emission. 2010-10-31 02:50:44 +02:00
Francisco Jerez
57382e71ef dri/nouveau: Split out array handling to its own file. 2010-10-31 02:50:04 +02:00
Francisco Jerez
9d1f1fcf13 dri/nouveau: Use a macro to iterate over the bound vertex attributes. 2010-10-31 02:45:38 +02:00
Francisco Jerez
dbe1eae785 dri/nouveau: Avoid recursion in nouveau_bo_context_reset(). 2010-10-31 02:45:31 +02:00
Francisco Jerez
f2098e0fef dri/nouveau: Split out the scratch helpers to a separate file. 2010-10-31 02:44:45 +02:00
Francisco Jerez
6daaf45359 dri/nouveau: Tell the vbo module we want real hardware BOs. 2010-10-31 02:44:35 +02:00
Francisco Jerez
6ee9cd482a dri/nouveau: Honor the access flags in nouveau_bufferobj_map_range. 2010-10-31 02:43:14 +02:00
Francisco Jerez
f102c5220c dri/nouveau: Call _mesa_update_state() after framebuffer invalidation.
Previously nouveau_state_emit() was being called directly, sometimes
that doesn't work because it doesn't update the derived GL context.
2010-10-30 19:25:33 +02:00
Francisco Jerez
e3c0b7ba41 dri/nv25: Bind a hierarchical depth buffer. 2010-10-30 19:25:32 +02:00
Francisco Jerez
c5ca972c07 dri/nouveau: Don't assert(0) on compressed internal formats. 2010-10-30 19:25:32 +02:00
Francisco Jerez
920481d387 dri/nv20: Clear with the 3D engine. 2010-10-30 19:25:31 +02:00
Chia-I Wu
cfc81d93f7 st/mesa: Unreference the sampler view in st_bind_surface.
Without this, update_textures may not pick up the new pipe_resource.

It is actually update_textures that should check
stObj->sampler_view->texture != stObj->pt, but let's follow st_TexImage
and others for now.
2010-10-31 01:18:59 +08:00
Brian Paul
9c2b4814d0 osmesa: fix renderbuffer memleak in OSMesaMakeCurrent()
Fixes fd.o bug 31128.
2010-10-30 10:11:37 -06:00
Chia-I Wu
156e955c25 autoconf: st/vega requires --enable-openvg.
Make it a warning for now to smooth the transition.
2010-10-30 14:41:17 +08:00
Kenneth Graunke
cff1aeea10 glsl: Remove unused ARRAY_SIZE macro.
It's also equivalent to Elements(...) which is already used elsewhere.
2010-10-29 11:43:30 -07:00
Eric Anholt
a974949f3b mesa: Make metaops use program refcounts instead of names.
Fixes failure on restoring state when the program was active but
deleted, and the name no longer exists.

Bug #31194
2010-10-29 11:28:38 -07:00
Brian Paul
34e8801b9c mesa: remove dead code 2010-10-29 08:13:31 -06:00
José Fonseca
d070edd4f0 mesa: Fix windows build (uint -> GLuint). 2010-10-29 13:05:31 +01:00