Compare commits

...

7196 Commits

Author SHA1 Message Date
Brice Goglin
b7baa7ea1f Prepare changelog for upload 2010-04-18 09:26:29 +02:00
Brice Goglin
cac99a12f1 New upstream release and pull from upstream 7.8 branch 2010-04-18 09:25:33 +02:00
Brice Goglin
05d9719758 Merge branch 'upstream-experimental' into debian-experimental
Conflicts:
	progs/tests/zreaddraw.c
2010-04-18 09:18:20 +02:00
Brice Goglin
047880c42d Remove a binary file to avoid
dpkg-source: error: cannot represent change to ...
2010-04-18 09:16:32 +02:00
Brice Goglin
c3e287d04a Update some build dependencies 2010-04-18 09:16:31 +02:00
Brian Paul
db3b34219e docs: update links for new mesa-users and mesa-announce lists 2010-04-16 08:25:58 -06:00
Tormod Volden
885048232f savage: call _mesa_meta_init/free()
Fixes crash when using _mesa_CopyTexImage2D.
Bug #27652.

Signed-off-by: Tormod Volden <debian.tormod@gmail.com>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-04-16 08:24:53 -06:00
Arpad Borsos
b3a68cdc6f softpipe: Fix division by zero
This can be triggered by running the cairo tests using the gl backend
and softpipe.

Signed-off-by: Brian Paul <brianp@vmware.com>
2010-04-14 14:26:37 -06:00
Michael Schmidt
d9793fc3ac Initialize DRI2 swap interval to 0
https://bugs.freedesktop.org/show_bug.cgi?id=27628
2010-04-14 10:15:47 -04:00
Jesse Barnes
157bdd1446 DRI2: report swap events correctly in direct rendered case
In the direct rendered case, we need to convert DRI2 swap complete
events to GLX events for the client to consume.  This path had what
looks like a stray "& 0x75" from some earlier debugging that prevented
clients from seeing the right event code.
2010-04-13 09:39:28 -07:00
Brian Paul
497b66094d docs: update name, link for mesa-dev list 2010-04-12 18:45:10 -06:00
Vinson Lee
4a796264df i915g: Fix assert. 2010-04-11 17:56:21 -07:00
Maciej Cencora
2657325c4a r300: respect radeon common code fallbacks
Fixes progs/demos/shadowtex under KMS
2010-04-11 13:42:00 +02:00
Maciej Cencora
6a5518861e r300: set proper vertex index limits also in non indexed mode
Fixes #27521, broken menus in UT2004 and broken water refraction in Sauerbraten.
2010-04-11 13:41:38 +02:00
Alex Deucher
edff2e0585 r600: add new r7xx pci ids 2010-04-09 20:20:42 -04:00
Kristian Høgsberg
394c25133e glx: Fix config chooser logic for 'mask' matching
When matching attributes using the 'mask' matching criteria, the spec
says that

  "Only GLXFBConfigs for which the set bits of attribute include all
   the bits that are set in the requested value are
   considered. (Additional bits might be set in the attribute)."

The current test returns true if the two bit masks have bits in
common, specifically it matches even if the requested value has bits
set that are not set in the fbconfig attribute.  For example, an
application asking for

  GLX_DRAWABLE_TYPE, GLX_PIXMAP_BIT | GLX_PBUFFER_BIT,

as glxpbdemo does, will match fbconfigs that don't support pbuffer
rendering, as long as they support pixmap rendering.

Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2010-04-09 15:24:29 -04:00
Brian Paul
b22a00bff4 mesa: fix instruction indexing bugs
We were looping over instructions but only looking at the 0th instruction's
opcode.

Fixes fd.o bug 27566.
2010-04-09 10:03:36 -06:00
Brian Paul
21cf976ad9 docs: link to 7.8.2 release notes 2010-04-08 13:11:30 -06:00
Brian Paul
3ad9a98ec2 docs: initial 7.8.2 release notes 2010-04-08 13:11:30 -06:00
Brian Paul
ffedd28c9c progs/tests: added some debug code (disabled) 2010-04-08 13:11:29 -06:00
Brian Paul
bab6c0a035 st/mesa: fix glDrawPixels(GL_DEPTH_COMPONENT) regression
Commit 1454f20a99 caused the regression.
When the vertex shader emitted both a texcoord and color we were grabbing
the wrong vertex attributes.  Fix the draw_quad() code to put texcoords
in slot[1] and color in slot[2].  That's a bit cleaner than changing
the vertex shader code.

Tested with progs/tests/zreaddraw.c
2010-04-08 13:11:29 -06:00
Li Peng
8ac7d7fa05 intel: Call intel_prepare_render() in intelClear()
Make sure we have up to date buffers before we start looking at
the tiling bits to determine how to clear.
2010-04-08 14:20:14 -04:00
Dave Airlie
4b39a0da89 texenvprogram: fix for ARB_draw_buffers.
piglit has a test called fbo-drawbuffers, this fails for me on r300g,
and fixing the texenv program to use the DATA outputs fixes it.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-04-08 15:19:52 +10:00
Ian Romanick
582e292a88 docs: Update 7.8.1 release MD5 sums 2010-04-05 12:45:20 -07:00
Brian Paul
5683d77b22 mesa: bump MESA_TINY version 2010-04-05 11:22:32 -06:00
Brian Paul
0e0de77f0e docs: added news item for 7.8.1 release 2010-04-05 11:12:59 -06:00
Brian Paul
659669d74c docs: add link to 7.8.1 release notes 2010-04-05 11:10:51 -06:00
Brian Paul
0eea33b069 softpipe: index the correct blend/mask state index
Need to check pipe_blend_state::independent_blend_enable to determine
which render target/index to use when checking blend enable and colormask
state.

This is part of the fix for piglit/fbo-drawbuffers
2010-04-05 11:00:54 -06:00
Ian Romanick
1ad1a51f14 docs: Add 7.8.1 release MD5 sums 2010-04-05 09:51:18 -07:00
Ian Romanick
88b7329cdd mesa: set version string to 7.8.1 2010-04-05 09:49:08 -07:00
Ian Romanick
dcaa2c6e76 Initial 7.8.1 release notes 2010-04-05 09:12:33 -07:00
Henri Verbeet
f820b263db mesa: update_arrays() depends on program state.
It uses ctx->VertexProgram._Current.

Signed-off-by: Brian Paul <brianp@vmware.com>
2010-04-05 09:34:31 -06:00
Ian Romanick
42ea25cb4e Update to final names from GLX_INTEL_swap_event spec
Fixes bug #27454.
2010-04-04 23:06:01 -07:00
Ian Romanick
f66733e077 gl: updated glxext.h to version 27 2010-04-04 16:53:41 -07:00
Vinson Lee
930838efcd util: Use GCC atomic bultins on GCC 4.1 and higher only. 2010-04-03 12:14:21 -07:00
Jeremy Huddleston
71b2f1d8e6 xdemos: Build object files first
This helps debugging on darwin.

Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2010-04-03 11:23:09 -07:00
Vinson Lee
67776f66c9 glx: Fix compilation errors on non-GLX_DIRECT_RENDERING builds.
Add ifdef guards around variables of types defined only for
GLX_DIRECT_RENDERING.
2010-04-02 00:12:59 -07:00
Chia-I Wu
154d9242de st/vega: Do not depend on libm.
This fixes the "no rule to make target -lm" error on darwin, reported by
Jeremy Huddleston.
2010-04-02 10:32:36 +08:00
Jesse Barnes
2b4d8616f5 GLX/DRI2: pass GLX drawable ID to dri2InvalidateBuffers
The IDs will be the same in the case where an X window is used directly
as a GLX drawable, but will fail if a new GLX drawable is created
explicitly, as with glxgears_fbconfig.

Fixes fdo bug #27190.
2010-04-01 17:29:19 -07:00
Jeremy Huddleston
115203281c Revert accidental commits from the xquartz tree
This reverts commit 9aadc793f3.
This reverts commit 69ea4e7718.
This reverts commit dbe8b01393.
This reverts commit 23215ef4d6.
This reverts commit 9495e37030.
This reverts commit 0594cf7088.
This reverts commit 86a7978d37.
This reverts commit 437902ce97.
2010-04-01 17:01:51 -07:00
Jeremy Huddleston
9aadc793f3 apple: Don't build gallium
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2010-04-01 12:33:48 -07:00
Jeremy Huddleston
69ea4e7718 apple: Use mesa gl.h rather than generating one.
Signed-off-by: Jeremy Huddleston <jeremyhu@freedesktop.org>
2010-04-01 12:33:47 -07:00
Jeremy Huddleston
dbe8b01393 apple: Integrate our libGL into the existing build system better
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2010-04-01 12:33:47 -07:00
Jeremy Huddleston
23215ef4d6 apple: Change ifdefs for DRI to be DRI && !APPLE
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2010-04-01 12:33:46 -07:00
Jeremy Huddleston
9495e37030 apple: Remove duplicate headers that already exist in mesa.
Signed-off-by: Jeremy Huddleston <jeremyhu@freedesktop.org>
2010-04-01 12:33:46 -07:00
Jeremy Huddleston
0594cf7088 apple: Initial import of libGL for OSX from AppleSGLX svn repository.
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2010-04-01 12:33:45 -07:00
Jeremy Huddleston
86a7978d37 xdemos: Build object files first
This helps debugging on darwin.

Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2010-04-01 12:33:39 -07:00
Jeremy Huddleston
437902ce97 xdemos: Fix a build failure for non-autoconf configs
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2010-04-01 12:14:45 -07:00
Vinson Lee
16f568a183 glx: Fix compilation errors on non-GLX_DIRECT_RENDERING builds.
driContext field for __GLXcontextRec struct is only defined if
GLX_DIRECT_RENDERING is set.
2010-04-01 00:10:28 -07:00
Ben Skeggs
e24f4378a1 st/mesa: use BITFIELD64_BIT to access shader OutputsWritten in more places 2010-03-31 23:34:42 +10:00
Brice Goglin
b138003e6f Refresh patches 2010-03-30 22:00:17 +02:00
Brice Goglin
b711772744 New upstream release 2010-03-30 21:42:55 +02:00
Brice Goglin
366a8f2748 Merge branch 'merge-uu-in-ue' into debian-experimental
Conflicts:
	doxygen/Makefile
	include/GL/glut.h
	include/VG/vgplatform.h
	progs/egl/Makefile
	progs/egl/demo1.c
	progs/egl/demo2.c
	progs/egl/demo3.c
	progs/egl/eglgears.c
	progs/egl/eglinfo.c
	progs/egl/egltri.c
	progs/egl/xegl_tri.c
	progs/egl/xeglgears.c
	progs/egl/xeglthreads.c
	progs/fp/Makefile
	progs/fp/SConscript
	progs/fp/fp-tri.c
	progs/fp/position.txt
	progs/glsl/SConscript
	progs/openvg/demos/eglcommon.c
	progs/openvg/demos/lion.c
	progs/openvg/trivial/eglcommon.c
	progs/perf/SConscript
	progs/rbug/bin_to_bmp.c
	progs/rbug/ctx_rule.c
	progs/rbug/shdr_disable.c
	progs/rbug/shdr_info.c
	progs/rbug/tex_dump.c
	progs/rbug/tex_info.c
	progs/redbook/.gitignore
	progs/tests/.gitignore
	progs/tests/Makefile
	progs/tests/SConscript
	progs/tests/arraytexture.c
	progs/tests/bufferobj.c
	progs/tests/bug_3195.c
	progs/tests/cva.c
	progs/tests/getprocaddress.py
	progs/tests/mipgen.c
	progs/tests/mipmap_comp.c
	progs/tests/mipmap_comp_tests.c
	progs/tests/mipmap_view.c
	progs/tests/no_s3tc.c
	progs/tests/streaming_rect.c
	progs/tests/texwrap.c
	progs/tests/vao-01.c
	progs/tests/vao-02.c
	progs/tests/vpeval.c
	progs/tests/vptest1.c
	progs/tests/vptest2.c
	progs/tests/vptest3.c
	progs/tests/zcomp.c
	progs/tools/trace/Makefile
	progs/trivial/.gitignore
	progs/trivial/Makefile
	progs/trivial/SConscript
	progs/trivial/tri-orig.c
	progs/trivial/tri-scissor-tri.c
	progs/trivial/tri-z-eq.c
	progs/vp/SConscript
	progs/vpglsl/SConscript
	progs/wgl/SConscript
	scons/crossmingw.py
	scons/gallium.py
	scons/llvm.py
	scons/mslib_sa.py
	scons/mslink_sa.py
	scons/msvc_sa.py
	src/glew/SConscript
	src/glew/glew.c
	src/glew/glewinfo.c
	src/glew/visualinfo.c
	src/glut/glx/SConscript
	src/glut/glx/capturexfont.c
	src/glut/glx/glut_8x13.c
	src/glut/glx/glut_9x15.c
	src/glut/glx/glut_cmap.c
	src/glut/glx/glut_event.c
	src/glut/glx/glut_fullscrn.c
	src/glut/glx/glut_gamemode.c
	src/glut/glx/glut_hel10.c
	src/glut/glx/glut_hel12.c
	src/glut/glx/glut_hel18.c
	src/glut/glx/glut_init.c
	src/glut/glx/glut_menu2.c
	src/glut/glx/glut_mroman.c
	src/glut/glx/glut_overlay.c
	src/glut/glx/glut_roman.c
	src/glut/glx/glut_tr10.c
	src/glut/glx/glut_tr24.c
	src/glut/glx/glutstroke.h
	src/glut/glx/layerutil.c
	src/mesa/drivers/windows/gldirect/dx7/gld_driver_dx7.c
	src/mesa/drivers/windows/gldirect/dx7/gld_primitive_dx7.c
	src/mesa/drivers/windows/gldirect/dx7/gld_vb_d3d_render_dx7.c
	src/mesa/drivers/windows/gldirect/dx8/gld_driver_dx8.c
	src/mesa/drivers/windows/gldirect/dx8/gld_primitive_dx8.c
	src/mesa/drivers/windows/gldirect/dx8/gld_vb_d3d_render_dx8.c
	src/mesa/drivers/windows/gldirect/dx9/gld_driver_dx9.c
	src/mesa/drivers/windows/gldirect/dx9/gld_primitive_dx9.c
	src/mesa/drivers/windows/gldirect/dx9/gld_vb_d3d_render_dx9.c
	src/mesa/drivers/windows/gldirect/mesasw/gld_wgl_mesasw.c
	src/mesa/vf/vf.c
	src/mesa/vf/vf_generic.c
	src/mesa/vf/vf_sse.c
	windows/VC7/mesa/mesa/mesa.vcproj
2010-03-30 21:41:42 +02:00
Brice Goglin
fec705f935 Merge branch 'upstream-unstable' into merge-uu-in-ue 2010-03-30 21:24:58 +02:00
Brice Goglin
8d98d78320 Prepare changelog for upload 2010-03-30 17:15:15 +02:00
Brice Goglin
ce01e79d7b Bump Standards-Version to 3.8.4 2010-03-30 17:14:41 +02:00
Michel Dänzer
07c6d94cd7 glx/dri2: Fix debug build with old dri2proto.
Apparently the higher compiler optimization level in non-debug builds was
eliminating the unused functions referencing the unresolved DRI2 symbols...
2010-03-30 11:50:13 +02:00
Brian Paul
2aafbd7c2a docs: fix 7.7.1 release date
(cherry picked from commit e6f5ca0fa3)
2010-03-29 12:01:28 -06:00
Timo Aaltonen
44083f0cd6 Update the changelogs. 2010-03-29 19:52:23 +03:00
Timo Aaltonen
9f4072889f Merge commit 'mesa_7_7_1' into debian-unstable 2010-03-29 19:51:04 +03:00
Ian Romanick
dec94903d9 mesa: Add 7.8 release MD5 sums 2010-03-28 16:35:56 -07:00
Ian Romanick
ef6736e646 intel: Bump intel driver date to reflect status as 2010Q1 release 2010-03-28 16:33:53 -07:00
Ian Romanick
a6a4613135 mesa: set version string to 7.8
Also set the correct release date.
2010-03-28 16:33:12 -07:00
Ian Romanick
11289924b8 mesa: Add 7.7.1 release MD5 sums
(cherry picked from commit 0c88e34049)
2010-03-28 16:33:12 -07:00
Ian Romanick
cbc99d34b9 mesa: set version string to 7.7.1
Also set the correct release date.
(cherry picked from commit 663642b435)
2010-03-28 16:33:12 -07:00
Ian Romanick
0c88e34049 mesa: Add 7.7.1 release MD5 sums 2010-03-28 16:25:47 -07:00
Ian Romanick
663642b435 mesa: set version string to 7.7.1
Also set the correct release date.
2010-03-28 16:22:44 -07:00
Vinson Lee
6abc3501c6 progs/tests: Remove duplicate texcompress2 in SConscript. 2010-03-27 14:40:41 -07:00
Vinson Lee
1bf67a3b3f i965g: Add brw_winsys_debug.c to SCons build. 2010-03-27 14:25:03 -07:00
Vinson Lee
1b5b04de75 identity: Add id_drm.c to SCons build.
This was missed in commit f7cbaae13d.
(cherry picked from commit 02ee7c2950)
2010-03-27 13:43:16 -07:00
Brian Paul
9903d09f82 mesa: move/update hash function comments
(cherry picked from commit 535742d75f)
2010-03-27 08:59:17 -06:00
Brian Paul
038d2607ab mesa: fix deadlock in _mesa_HashFindFreeKeyBlock()
Fixes fd.o bug 27340.
(cherry picked from commit 8fe3b3f66a)
2010-03-27 08:58:59 -06:00
Brian Paul
535742d75f mesa: move/update hash function comments 2010-03-27 08:58:02 -06:00
Török Edwin
8fe3b3f66a mesa: fix deadlock in _mesa_HashFindFreeKeyBlock()
Fixes fd.o bug 27340.
2010-03-27 08:55:47 -06:00
Michel Dänzer
7996f0fc2c dri/swrast: Fix frontbuffer rendering.
Was broken since the endianness fixes.
(cherry picked from commit 4cf14fa80b)
2010-03-26 18:30:56 +01:00
Michel Dänzer
b005e75177 dri/swrast: Fix missed conversion of one pixel pointer increment.
This probably broke the swrast DRI driver when running X in depth 16.
(cherry picked from commit 6ec259eb17)
2010-03-26 18:30:49 +01:00
Michel Dänzer
4cf14fa80b dri/swrast: Fix frontbuffer rendering.
Was broken since the endianness fixes.
2010-03-26 18:29:18 +01:00
Michel Dänzer
6ec259eb17 dri/swrast: Fix missed conversion of one pixel pointer increment.
This probably broke the swrast DRI driver when running X in depth 16.
2010-03-26 16:29:59 +01:00
Eric Anholt
77c30c5915 i965: Fix readpixels from ReadBuffer != DrawBuffer.
Fixes piglit fbo-readdrawpix.
(cherry picked from commit 5782b2a968)
2010-03-25 17:30:37 -07:00
Eric Anholt
63fbae81e0 i965: Fix inversion for glCopyPixels to/from FBOs.
fixes piglit fbo-copypix.
(cherry picked from commit a589da14de)
2010-03-25 17:30:37 -07:00
Eric Anholt
fdbe1ca0bd intel: Rely on allocated region pitch for the miptree pitch.
Bug #26966: 945 miptree pitch disagreement with libdrm.
(cherry picked from commit da011faf48)
2010-03-25 17:30:37 -07:00
Eric Anholt
57e793644f intel: Remove extra tiling setting after allocating a tiled region.
(cherry picked from commit 32f143b432)
2010-03-25 17:30:37 -07:00
Eric Anholt
4980891252 intel: Respect src pitch in _mesa_copy_rect().
If a non-zero src_y was used, this would break piglit
depth-level-clamp.
(cherry picked from commit e1e48ea15c)
2010-03-25 17:30:37 -07:00
Tom Fogal
38cb44516e Regenerate gl_mangle.h 2010-03-25 17:10:51 -06:00
Brian Paul
59258498dc glapi: return int = 0 from NoOpGeneric()
If a GL function is called w/out a current rendering context, this stub
gets called.  It should return 0 so that non-void-valued functions return
0/NULL instead of a random number.
2010-03-25 16:04:47 -06:00
Vinson Lee
80f5f7d17a glslcompiler: Fix build. 2010-03-25 12:58:36 -07:00
Maciej Cencora
fabc744999 r300: report correct state atom size
Spotted by Pauli Nieminen
2010-03-24 20:08:17 +01:00
Maciej Cencora
88f785935e r300: fix off by one
R300_PVS_MAX_CONST_ADDR field holds highest const addr, not
const count.

Fixes missing models and others rendering errors for vertex
program using 256 params.
2010-03-24 20:08:09 +01:00
Maciej Cencora
7a77effb0b r300: fix vertex programs with big number of params (>255) under KMS
UMS will probably require some kernel work
2010-03-24 20:08:00 +01:00
Maciej Cencora
bed7d88708 r300: fix wpos/fog handling
It may happen that the vertex attribute we were going to stuff
the wpos/fog attrs in was already written by vertex program.
In such cases we need to remove instruction accessing these
attributes, so they don't overwrite the wpos/fog related
instructions.

This fixes non-textured models in many wine games.
2010-03-24 20:07:44 +01:00
Maciej Cencora
70929f4505 r300: clean fog_attr/wpos_attr if code accessing these attributes has been removed FP during compilation 2010-03-24 20:07:37 +01:00
Eric Anholt
516334b7ff i965: Stop abusing ctx->NewState flags for storing driver internal changes.
We're still abusing the flags by putting them where our driver stores
ctx->NewState changes.  Making them into more restricted state change
flags would be a project for later.

Fixes a failure where calling intel_draw_buffer() too often would trip
up Mesa assertions about when Mesa state could get changed, when it hadn't.

Bug #27034.
2010-03-23 15:51:54 -04:00
Brian Paul
ed29329b08 docs: update docs with 7.7.1 and 7.8 release info 2010-03-23 09:24:13 -06:00
Brian Paul
ca1c8a183d docs: added news item for 7.7.1 release 2010-03-23 09:19:44 -06:00
Brian Paul
3f3b1094bf docs: insert expected 7.7.1 release date 2010-03-23 09:19:26 -06:00
Brian Paul
ff54af530b softpipe: comments, re-formatting, etc 2010-03-23 09:08:35 -06:00
Brian Paul
fc1ba0423a softpipe: add special cases for all Z compare modes for 16-bit Z buffer
We had fast paths for PIPE_FUNC_LESS and LEQUAL before.  To satisfy
OpenGL invariance rules, all depth compare modes should produce the
same fragment Z values.

Fixes progs/demos/singlebuffer.c
2010-03-23 09:00:19 -06:00
Brian Paul
4ceeb1307a st/glx: better format selection in xmesa_choose_z_stencil_format()
This is a back-port of commit ef2664da6c
from master.
2010-03-23 08:58:12 -06:00
Chia-I Wu
2ded27b2f0 Add missing EGL files to the tarballs.
Add the Makefile of Gallium EGL drivers and demos using EGL to the
tarballs.
2010-03-23 14:46:03 +08:00
Kristian Høgsberg
094c6fbc45 glx: Suppress BadDrawable from DRI2CopyRegion
This can happen when an X window is destroyed behind our back.  We use
DRI2CopyRegion behind the scenes in many places (like flushing the fake
front to the real front) so we have to ignore X errors triggered in that
case.

The glean test cases trigger this consistently as they don't destroy the
GLX drawable nicely, they just destroy the X window.
2010-03-22 22:04:23 -04:00
Ian Romanick
e33121b2d8 mesa: set version string to 7.7.1-rc2 2010-03-22 18:15:53 -07:00
Ian Romanick
4eead42550 mesa: set version string to 7.8-rc2 2010-03-22 18:09:15 -07:00
Kristian Høgsberg
62d54f0387 intel: Call intel_prepare_render() before looking up regions.
Fixes #27213.
2010-03-22 17:59:04 -04:00
Karl Schultz
092ca30366 Fix potential compilation issue in visual studio project file
Add quotes around filespec in post-build event to allow paths
with embedded spaces.
2010-03-22 12:18:02 -06:00
Brian Paul
ca97f8b9ba glslcompiler: fix build breakage 2010-03-22 09:00:13 -06:00
Pauli Nieminen
361e8e9118 mesa: Add end of line to the end of a debug output. 2010-03-22 15:16:02 +02:00
Vinson Lee
fce72d5803 progs/tests: Add cva_huge to SCons build. 2010-03-21 19:21:11 -07:00
Vinson Lee
1e7d65bb5b progs/tests: Include stddef.h for ptrdiff_t on all platforms.
stddef.h is the standard C header that defines ptrdiff_t.

Fixes build of cva_huge on Mac OS X.
2010-03-21 19:09:54 -07:00
Pauli Nieminen
4ea694a26b r200: Fix emit size prediction to account elt splitting.
Emit sizes prediction didn't account for render splitting in
hwtnl path.
2010-03-21 23:39:55 +02:00
Pauli Nieminen
0900544fb5 r200: Don't flush when closing elts in KMS.
Flush in middle of rendering in KMS is not allowed because
buffers are discarded in flush.

Fixes crash when emiting split indices with RADEON_DEBUG=all.
2010-03-21 23:39:53 +02:00
Pauli Nieminen
415d0326bb r200: Fix emit size prediction to account elt splitting.
Emit sizes prediction didn't account for render splitting in
hwtnl path.
2010-03-21 23:32:14 +02:00
Pauli Nieminen
7e24ce2d9b r200: Don't flush when closing elts in KMS.
Flush in middle of rendering in KMS is not allowed because
buffers are discarded in flush.

Fixes crash when emiting split indices with RADEON_DEBUG=all.
2010-03-21 23:30:23 +02:00
Pauli Nieminen
1968d8f31d r200: Fix swtnl fallback to flush pending rendering before transition.
Flush after transition would emit wrong state that could cause
wrong state emited for pending rendering operation.

Fixes wan once from extrement tuxracer that is using per vertex
materials.
2010-03-21 20:27:49 +02:00
Pauli Nieminen
44e3ec3c05 r200: Fix mixed indetion in r200TclFallback. 2010-03-21 20:27:44 +02:00
Pauli Nieminen
2ae754b7b9 r200: Fix swtnl fallback to flush pending rendering before transition.
Flush after transition would emit wrong state that could cause
wrong state emited for pending rendering operation.

Fixes wan once from extrement tuxracer that is using per vertex
materials.
2010-03-21 20:23:01 +02:00
Pauli Nieminen
501156b36b r200: Fix mixed indetion in r200TclFallback. 2010-03-21 20:22:56 +02:00
Pauli Nieminen
9a7acbccfb vbo: Fix vbo_split_copy to pass correct max_index to draw.
vbo_split_copy was passing one past the max_index to draw function
which caused _tnl_draw_prims function to read uninitialized values
from copied array.

Bug was spoted in valgrind report of progs/tests/cva_huge.
2010-03-21 13:18:36 +02:00
Pauli Nieminen
a81cd67a4f tests: Add test for huge client arrays that has to be split.
When running this test case in valgrind report includes read of unitialized
value in _tnl_draw_prims. The bug doesn't cause any vissible errors.

Bug is caused by vbo_split_copy that is calling draw function with max_index
one past the end instead of the end.
2010-03-21 13:17:52 +02:00
Pauli Nieminen
4ff3244457 vbo: Fix vbo_split_copy to pass correct max_index to draw.
vbo_split_copy was passing one past the max_index to draw function
which caused _tnl_draw_prims function to read uninitialized values
from copied array.

Bug was spoted in valgrind report of progs/tests/cva_huge.
2010-03-21 12:42:10 +02:00
Marek Olšák
3d72c4ae78 r300/compiler: fix assertion failure in the r500-fragprog emission path 2010-03-20 18:54:55 +01:00
Brian Paul
f0491c945c docs: remove the 'Last updated date' 2010-03-20 10:33:10 -06:00
Chia-I Wu
6fed3a9fa0 glapi: Fix aliases to non-static functions.
The bug is triggered by 41a87a43e1.
glBlitFramebuffer, for example, is an alias to the non-static
glBlitFramebufferEXT.  We should define glBlitFramebuffer as an alias to
_dispatch_stub_NNN.
2010-03-21 00:05:01 +08:00
Chia-I Wu
41a87a43e1 glapi: Correctly generate static disatches for X86.
The entry point names, instead of the function name, should be used to
test if the entry point should be statically dispatched.
2010-03-20 13:02:05 +08:00
Marek Olšák
7e6e049bb7 r300g: remove hacks from translate_vertex_data_swizzle
Fixing RGBA 4ub vertex colors.
2010-03-19 19:13:01 +01:00
Brian Paul
73060ec7eb drivers/x11: add PUBLIC qualifier to more API functions
Based on a patch from Tom Fogal.
2010-03-19 10:35:58 -06:00
Michel Dänzer
3889556d70 Revert "Revert "mesa/st: Make ST_SURFACE_DEPTH index consistent with mesa's BUFFER_DEPTH.""
This reverts commit 52d83efdbc.

The fix it reverted should be fine with the two previous fixes.
2010-03-19 17:32:54 +01:00
Brian Paul
6412046f65 st/mesa: s/BUFFER_FRONT_LEFT/surfIndex/
(cherry picked from commit 5d5c524cbe)
2010-03-19 17:20:26 +01:00
Brian Paul
6e96cea6e2 st/mesa: fix st_set_framebuffer_surface() state validation
Set the _NEW_BUFFERS flag and remove the code which updated the
parent framebuffer size.  Normal Mesa state validation will do that.

Fixes issues with Warsow on r300g and possibly other bugs.
(cherry picked from commit c472ce5302)
2010-03-19 17:20:19 +01:00
Ian Romanick
3a3ef3d6c9 intel: Use bit-wise not instead of logical not (i830 path)
The assertion is checking that the low-order bits of offset are not
set.  It does this by anding the inverted offset mask with the
offset.  This is clearly intended to be a bit-wise "invert".

Fixes bug #25984.
(cherry picked from commit 062a208814)
2010-03-18 18:23:21 -07:00
Ian Romanick
98aed6dc69 intel: Correct value of S0_VB_OFFSET_MASK to match hardware docs.
(cherry picked from commit 689e4b5541)
2010-03-18 17:31:22 -07:00
Ian Romanick
062a208814 intel: Use bit-wise not instead of logical not (i830 path)
The assertion is checking that the low-order bits of offset are not
set.  It does this by anding the inverted offset mask with the
offset.  This is clearly intended to be a bit-wise "invert".

Fixes bug #25984.
2010-03-18 17:30:15 -07:00
Ian Romanick
689e4b5541 intel: Correct value of S0_VB_OFFSET_MASK to match hardware docs. 2010-03-18 17:28:52 -07:00
Ian Romanick
d3a607f889 Use bit-wise not instead of logical not.
The assertion is checking that the low-order bits of offset are not
set.  It does this by anding the inverted offset mask with the
offset.  This is clearly intended to be a bit-wise "invert".

Fixes bug #25984.
(cherry picked from commit fda5078324)
2010-03-18 15:39:00 -07:00
Ian Romanick
fda5078324 Use bit-wise not instead of logical not.
The assertion is checking that the low-order bits of offset are not
set.  It does this by anding the inverted offset mask with the
offset.  This is clearly intended to be a bit-wise "invert".

Fixes bug #25984.
2010-03-18 15:35:05 -07:00
Brian Paul
b7e8039132 st/mesa: s/unpack/pack/ to be more consistent 2010-03-18 09:17:11 -06:00
Kristian Høgsberg
38bd7282f2 intel: Call _mesa_make_current() after getting initial buffers
The default viewport is the window rectangle, which is set up by
_mesa_make_current().  To be able to do that we need to get the
window dimension (and buffers) first, so we have to call
intel_prepare_render() before we can call into _mesa_make_current().

Fixes #26676 and #26678.
2010-03-18 09:53:41 -04:00
Timo Aaltonen
65a728348a Update the changelogs. 2010-03-18 13:51:45 +02:00
Timo Aaltonen
99d174f882 Merge remote branch 'upstream/mesa_7_7_branch' into debian-unstable 2010-03-18 13:30:34 +02:00
Brian Paul
05a980ac2a cell: return 1 for PIPE_CAP_BLEND_EQUATION_SEPARATE
With this feature, we get OpenGL version 2.0 and the progs/glsl/
demos run as-is.
2010-03-17 17:40:13 -06:00
Brian Paul
6dd4054ca5 cell: be more conservative in cell_is_format_supported()
This fixes a regression from commit a84575cdc0
which changed the depth/stencil format we were trying to use.
2010-03-17 16:35:29 -06:00
Brian Paul
1bfc314596 st/mesa: fix glCopyPixels bugs/crashes when src region need clipping
Use the _mesa_clip_readpixels() function to clip the src region against
the buffer's bounds.  Neatly, the resulting pixel unpack object's
SkipPixels/SkipRows fields can be used to determine the position of the
region in the destination texture.

Fixes crash in progs/samples/copy.c and probably other cases.
2010-03-17 10:06:27 -06:00
Brian Paul
c492227683 mesa: rename params in prototype to match implementation 2010-03-17 09:04:26 -06:00
Brian Paul
3828910d0e swrast: remove unused compute_coveragei() function 2010-03-17 08:42:59 -06:00
Eric Anholt
a29c7948d9 i965: Fix ENDLOOP to only patch up this loop's BREAK and CONT.
Corresponds to d225a25e21a24508aea3b877c78beb35502e942d and fixes
piglit glsl-fs-loop-nested.  Bug #25173.
(cherry picked from commit a81836ee2f)
2010-03-16 12:15:18 -07:00
Eric Anholt
42e0e86866 i965: Unalias all GLSL source regs from the destination regs used.
We were doing it ad-hoc before, as instructions with potential
aliasing problems were identified.  But thanks to swizzling basically
anything can have aliasing, so just do it generally at source reg
setup time.  This is somewhat inefficient, because sometimes an
operation doesn't need unaliasing protection if the swizzling is safe,
but the unaliasing before didn't cover those cases either.

Fixes piglit glsl-fs-loop.
(cherry picked from commit 6b194dab6b)
2010-03-16 12:15:12 -07:00
Eric Anholt
d24f59d008 i965: Fix nested loops in the VS.
We were patching up all the break and continues between the start of
our loop and the end of our loop, even if they were breaks/continues
for an inner loop.  Avoiding patching already patched breaks/continues
fixes piglit glsl-vs-loop-nested.
(cherry picked from commit f6f547d87e)
2010-03-16 12:15:02 -07:00
Eric Anholt
009392f50d i965: Fix up VP constbuf leak on program delete.
(cherry picked from commit 7f6d2754d5)
2010-03-16 12:14:57 -07:00
Eric Anholt
1254d3d315 i965: Fix up the handling of point sprite coordinate replacement.
The code was walking over the regs of pairs of attributes and checking
whether the attribute with a given reg index had point sprite enabled.
So the point sprite setup code was rarely even getting executed.
Instead, we need to determine which channels of a reg need point
sprite coordinate replacement.  In addition, it was multiplying the
attribute by 1/w, when it's supposed to cover (0, 1) in each direction
regardless of w, and it wasn't filling in the Z and W components of
the texcoord as specified.

Fixes piglit point-sprite and the spriteblast demo.  Bug #24431, #22245.
(cherry picked from commit bc632d0437)
2010-03-16 12:14:48 -07:00
Eric Anholt
837f003eeb i965: Add support for the CMP opcode in the GLSL path.
This would be triggered by use of sqrt() along with control flow.
Fixes piglit-fs-sqrt-branch and a bug in Yo Frankie!.
(cherry picked from commit 48dca99feb)
2010-03-16 12:14:18 -07:00
Eric Anholt
7ee4db50b1 i965: Fix the response len of masked sampler messages for 8-wide dispatch.
The bad response length would hang the GPU with a masked sample in a
shader using control flow.  For 8-wide, the response length is always
4, and masked slots are just not written to.  brw_wm_glsl.c already
allocates registers in the right locations.

Fixes piglit glsl-fs-bug25902 (fd.o bug #25902).
(cherry picked from commit f6d210c284)
(cherry picked from commit dc8c035944)
2010-03-16 11:56:21 -07:00
Ian Romanick
c1c9fad293 Remove nonexistant files from tarballs rule of Makefile
The Makefile should eventually be fixed to stop building tarballs if
one of the individual calls to tar fails.
2010-03-16 10:21:37 -07:00
Ian Romanick
f0c3262927 mesa: set version string to 7.8-rc1 2010-03-16 10:21:37 -07:00
Matthew W. S. Bell
d320152b47 Correct GL_EQUIV code in r67/7xx.
From 247e121106e8d3e389f2e5a6edf13ea70ac18df7 Mon Sep 17 00:00:00 2001

These seem to be documented in
<http://www.svgopen.org/2003/papers/RasterOperationsUsingFilterElements/index.html>.
2010-03-16 11:39:53 -04:00
Pauli Nieminen
e9c2c4a764 radeon: Fix buffer object unmap to be called only once for dma buffers.
If flush happens inside radeonRefillCurrentMaRegion the last dma buffer would
be unmapped twice. Unmapping buffer when moving buffer to wait list fixes the
mapping error.
2010-03-16 17:00:14 +02:00
Marcin Baczyński
346298c765 Replace _mesa_strtod with _mesa_strtof.
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-15 08:38:24 -07:00
Thomas Hellstrom
00e41e007e st/xorg: Fix Xv cliprect scaling.
Due to a quantization error, different cliprects of scaled video windows may
not have identical x / y scale.

Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
2010-03-13 20:32:00 +01:00
Ian Romanick
6624845a5d mesa: set version string to 7.7.1-rc1 2010-03-16 10:26:52 -07:00
Matthew W. S. Bell
c9c54180e4 Correct GL_EQUIV code in r67/7xx.
From 247e121106e8d3e389f2e5a6edf13ea70ac18df7 Mon Sep 17 00:00:00 2001

These seem to be documented in
<http://www.svgopen.org/2003/papers/RasterOperationsUsingFilterElements/index.html>.
2010-03-16 11:38:32 -04:00
José Fonseca
93e77b0028 mesa: List Quake3 extensions first.
Quake3 truncates the extension string, and GL_EXT_compiled_vertex_array
wasn't being detected, making it very slow.

This is a quick fix. The IMHO best way to address this in a more general
fashion is to sort by year.
2010-03-13 10:41:32 +00:00
Keith Whitwell
0c9e8e6c6e mesa: Fix memory leak in decompress-with-blit.
(cherry picked from commit f05a4ee6f2840590c90da4be2fe5c6295410a5af)
2010-03-13 10:40:56 +00:00
Keith Whitwell
63af29bfbe mesa: Fix memory leak in decompress-with-blit.
(cherry picked from commit f05a4ee6f2840590c90da4be2fe5c6295410a5af)
2010-03-13 10:40:04 +00:00
Michel Dänzer
8561bec0ac vmwgfx/dri: Fix SCons build. 2010-03-12 18:54:23 +01:00
Michel Dänzer
51a51899d0 st/dri: Always try to set up R5G6B5 configs.
Allows compiz to work in depth 16.

The DRI2 getBuffersWithFormat hook is only required for 16/32 bit depth
buffers, for colour buffers the only requirement is that the format matches
the drawable depth, which we can't check here.

(cherry picked from commit c50477c255)
2010-03-12 18:52:07 +01:00
Michel Dänzer
c50477c255 st/dri: Always try to set up R5G6B5 configs.
Allows compiz to work in depth 16.

The DRI2 getBuffersWithFormat hook is only required for 16/32 bit depth
buffers, for colour buffers the only requirement is that the format matches
the drawable depth, which we can't check here.
2010-03-12 18:24:34 +01:00
Luc Verhaegen
4b598ce226 dri/r700: include shader/programopt.h instead of programopt.c.
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-03-12 08:57:55 -07:00
Jeff Smith
9b81103b1a Add programs to .gitignore in redbook
Signed-off-by: Jeff Smith <whydoubt@yahoo.com>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-03-12 08:57:34 -07:00
Jeff Smith
3aa8692883 Add programs to .gitignore in xdemos
Signed-off-by: Jeff Smith <whydoubt@yahoo.com>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-03-12 08:57:06 -07:00
Jeff Smith
9787060423 Add -L$(libdir) for xdemos and egl so that the right libX11 is found
Signed-off-by: Jeff Smith <whydoubt@yahoo.com>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-03-12 08:56:06 -07:00
Jeff Smith
fab1f07d6a Grammar and spelling fixes
Signed-off-by: Jeff Smith <whydoubt@yahoo.com>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-03-12 08:55:05 -07:00
Vinson Lee
39c2d3ecd9 radeon: Fix memory leaks from early return. 2010-03-11 21:55:44 -08:00
Brian Paul
5d5c524cbe st/mesa: s/BUFFER_FRONT_LEFT/surfIndex/ 2010-03-11 14:51:02 -07:00
Brian Paul
c472ce5302 st/mesa: fix st_set_framebuffer_surface() state validation
Set the _NEW_BUFFERS flag and remove the code which updated the
parent framebuffer size.  Normal Mesa state validation will do that.

Fixes issues with Warsow on r300g and possibly other bugs.
2010-03-11 13:44:53 -07:00
Jakob Bornecrantz
683a099954 st/xorg: Fixup configure
Make sure we always test for XEXT version.
Make sure that the user has a recent version of libkms and libdrm installed.

Note that the st/xorg code requires so new versions to work but these are
needed to make a proper vmwgfx_drv.so driver which is the only real user.

Cherry picked from 46cf606cd3
Conflicts:

	configure.ac
2010-03-11 19:30:16 +00:00
Brian Paul
bff128ff9c ARB prog parser: added (float) casts and regenerate files 2010-03-11 09:08:58 -07:00
Jakob Bornecrantz
54af54277a st/xorg: Include cursorstr.h 2010-03-11 00:50:58 +00:00
Karl Schultz
60121c41ce windows: fix compilation errors and warnings 2010-03-10 15:58:10 -07:00
Karl Schultz
7439f39016 windows: Quiet warning by not defining YY_NO_UNISTD_H. 2010-03-10 14:27:34 -07:00
Brian Paul
b60aa251e4 st/mesa: fix incorrect glCopyPixels between window/FBO
There was a DrawBuffer/ReadBuffer typo and we were neglecting to invert
the texture coords when copying from a window to an FBO.

Plus, add some surface dump/debug code (disabled).

(cherry picked from commit 34f0207161)
2010-03-10 10:42:22 -07:00
Brian Paul
c78ac7fcfa st/mesa: fix incorrect glDrawPixels into FBO
We weren't inverting the textured quad when drawing into an fbo.

(cherry picked from commit 8d3f629a13)
2010-03-10 10:41:22 -07:00
Michel Dänzer
766d90f1a2 st/xorg: Work around cursor reference counting bugs in older X servers.
Could result in use of freed memory and consequently random crashes, e.g. on
screen resize.
(cherry picked from commit 21c91b410a)

Conflicts:

	src/gallium/state_trackers/xorg/xorg_tracker.h
2010-03-10 18:26:25 +01:00
Alex Deucher
ffd625d4aa radeon: don't attempt to use alternate blit formats for depth buffers
noticed by fredrikh on IRC.
2010-03-08 17:38:39 -05:00
Brian Paul
e1762fb870 softpipe: zero-out entire clear_flags array in sp_tile_cache_flush_clear()
Before, we only cleared the flags for the active tiles (the ones inside
the framebuffer bound).  The problem is if we later bound a different,
larger surface to the tile cache we'd have some stale clear-flags still
set (and mistakenly clear some tiles in the new surface).

Fixes fd.o bug 26932.
2010-03-08 11:39:51 -07:00
Brian Paul
80dc54e308 st/mesa: don't detach renderbuffer, surface in st_finish_render_texture()
There's no reason to release the renderbuffer from the framebuffer object
or release the gallium surface in this function (they're reference counted).
In fact, we don't want to do this because we may later use the texture as a
pixel source (ex: glBlitFramebuffer) and need the surface.

Fixes fd.o bug 26923 and is part of the fix for bug 26932.
2010-03-08 11:39:51 -07:00
Alex Deucher
df9bf78f88 r600: enable GL_ARB_pixel_buffer_object 2010-03-08 12:00:57 -05:00
Brian Paul
fe25bee14f mesa: add additional missing z formats for render to texture
Allow render to texture for X8_Z24 and Z24_X8 formats.
Replace big if/else with switch, etc.
2010-03-08 10:00:29 -07:00
Alex Deucher
9458c2061b radeon/r200/r600: allow src and dst BOs to be placed in GTT during blit 2010-03-08 11:50:01 -05:00
Alex Deucher
d7ad1b8b07 radeon/r200/r600: reset bos when validating buffers during blit 2010-03-08 11:49:53 -05:00
Alex Deucher
c65235f97e r600: recalculate point size, if point min/max size changes 2010-03-08 11:49:44 -05:00
Alex Deucher
d18b302365 r600: no need to flush on context init 2010-03-08 11:49:31 -05:00
Maciej Cencora
b3b6bd5da1 r300: don't enable EXT_packed_depth_stencil
R300 hw doesn't support sampling from Z24_S8 or S8_Z24 formats.
2010-03-08 11:49:23 -05:00
Maciej Cencora
29e02c7e72 radeon: no need to emit full state twice after flush 2010-03-08 11:49:16 -05:00
Maciej Cencora
4572ae1925 r300: allow src and dst BOs to be placed in GTT during blit
Fixes some relocation failures
2010-03-08 11:49:09 -05:00
Maciej Cencora
62b3321d7d r300: reset bos when validating buffers during blit 2010-03-08 11:49:01 -05:00
Maciej Cencora
8ccd83ab92 radeon: fallback to software in glCopyTexImage if blit isn't available 2010-03-08 11:48:52 -05:00
Maciej Cencora
2872c1cc32 r300: VAP flush is needed only when vertex program or constants are changed 2010-03-08 11:48:45 -05:00
Maciej Cencora
77ed4d1f5d r300: recalculate point size, if point min/max size changes
Fixes two wine d3d9 unit tests
2010-03-08 11:48:36 -05:00
Maciej Cencora
44d92d4bbe r300: no need to flush on context init 2010-03-08 11:48:28 -05:00
Maciej Cencora
b1ab15c633 r300: remove unnecessary code
_tnl_UpdateFixedFunctionProgram is already called in r300_draw.c
2010-03-08 11:48:20 -05:00
Brian Paul
26aa870a0d mesa: add render-to-texture case for MESA_FORMAT_S8_Z24 2010-03-08 09:38:07 -07:00
Brian Paul
614f490ca9 mesa: s/GL_DEPTH_STENCIL/GL_DEPTH_COMPONENT/ for MESA_FORMAT_Z16 renderbuffer
MESA_FORMAT_Z16 has no stencil bits.
2010-03-08 09:35:28 -07:00
Chia-I Wu
ee6fbf8d2f st/vega: Fix OpenVG demo segfaults.
When the paint is color, paint_bind_samplers binds a dummy sampler
without a texture.  It causes demos requiring a sampler (those use a
mask or an image) to crash.
2010-03-08 11:29:25 +08:00
Vinson Lee
661b416e07 gallivm: Initialize variables for default cases.
Fixes use of uninitialized variables in non-debug builds.
2010-03-06 20:30:28 -08:00
Vinson Lee
ba8f4c5d36 progs/demos: Add arbocclude2 to Makefile and .gitignore. 2010-03-05 23:18:01 -08:00
Brian Paul
ae7b3a632d glx: Move initialization of ext_list_first_time to where it's storage is allocated
Move the initialization of ext_list_first_time from all of the DRI loader's
CreateScreen routines, to where the storage for the screen config is
allocated.

It needs to get set in the screen-config even if DRI is forced off
using LIBGL_ALWAYS_INDIRECT, so that psc->direct_support is initialized
correctly, otherwise __glXExtensionBitIsEnabled() always returns FALSE

Specifically, this causes a problem with an X server which advertises
GLX<=1.2, and the GLX_SGIX_fbconfig extension.
glXGetFBConfigFromVisualSGIX() uses __glXExtensionBitIsEnabled() to
check if the GLX_SGIX_fbconfig extension is available, but that function
won't return correct information because that data has never been
initialized, because ext_list_first_time was never set...

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Signed-off-by: Brian Paul <brianp@vmware.com>

(cherry picked from commit 96ab4d2b84)
2010-03-05 17:32:36 -07:00
Brian Paul
c781e2841a docs: remove merge conflict garbage 2010-03-05 17:32:07 -07:00
Ian Romanick
77fc3ef911 meta: Use the DrawBuffer's stencil size
Previously the code was erroneously using the stencil size of the
context instead of the stencil size of the DrawBuffer.  With FBOs
these may be different.  As a result, clearing the stencil buffer of
an FBO bound to a context that doesn't have stencil would fail.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-05 16:04:59 -08:00
Ian Romanick
66c0abba6b swrast: Remove redundant test of the visual's accumulation buffer size
If the visual doesn't have an accumulation buffer, the renderbuffer
passed into _swrast_clear_accum_buffer will be NULL anyway.  There is
no reason the check the visual.  Moreover, the test erroneously checks
the context's visual instead of the visual of the current DrawBuffer.
With FBOs these may be different.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-05 16:04:59 -08:00
Ian Romanick
ebbec7e4e4 swrast: Adjust colors based on ReadBuffer visual, not context visual
In the presence of FBOs, the visual of the context may not match the,
possibly fake, visual of the current ReadBuffer.  Note that the caller
of adjust_colors correctly uses the visual of the ReadBuffer.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-05 16:04:59 -08:00
Ian Romanick
c67af0628b swrast: Remove stray comment that mentions ctx->Visual
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-05 16:04:59 -08:00
Brian Paul
1a0a2b64ca gallivm: checkpoint: code gen for mipmap selection 2010-03-05 16:52:11 -07:00
Brian Paul
b5038fdd65 llvmpipe: added code to set texture depth, max mipmap levels info 2010-03-05 16:51:35 -07:00
Brian Paul
7f4b5c5387 gallivm: added methods for getting texture depth, num mipmap levels 2010-03-05 16:50:48 -07:00
Brian Paul
6bc644fe62 gallivm: checkpoint: texture LOD computation code gen 2010-03-05 16:32:09 -07:00
Brian Paul
36a0c4219d gallivm: added field for sampler lod 2010-03-05 16:32:09 -07:00
Eric Anholt
8c8e664f10 i965: Only use the effective subset of the WM sampler key.
The whole structure is 836 bytes, but if only the first one or two
samplers are used (as is common), the part that matters is only 56 or
108 bytes.  By using just that subset as the key (since the key size
is also part of the key), we improve firefox-talos-gfx performance by
1%.
2010-03-05 15:23:30 -08:00
Eric Anholt
a232cc59e3 intel: Remove support for the DRI1 TFP extension. 2010-03-05 15:23:30 -08:00
Eric Anholt
20952f0378 i965: Remove the paths for making a const surface object for a NULL BO. 2010-03-05 15:23:30 -08:00
Eric Anholt
9a38f76044 i965: Remove the unused SDC BO pointer from the sampler state key.
Since it's a BO pointer, it already lives outside the key in
brw->wm.sdc_bo[] which is used for sampler state lookup and setup.
2010-03-05 15:23:30 -08:00
Eric Anholt
879ea6f279 i965: Rename SNB brw_*_key structs to gen6_*_key structs. 2010-03-05 15:23:30 -08:00
Eric Anholt
5d18e86971 i965: Pack gen6 blend_state_key structure. 2010-03-05 15:23:30 -08:00
Eric Anholt
855515859e intel: Only do batchbuffer debug if --enable-debug is used.
This saves 6.6KB on the 965 driver, and appears to speed
firefox-talos-gfx up by 1-2%.  Unlike many other asserts in the
driver, when we make a mistake that would trigger one of these it
generally shows up all the time for developers, so turning it off for
release seems fine.
2010-03-05 15:23:30 -08:00
Eric Anholt
7392002041 intel: Replace batch macro contents with function calls.
This manages to cut down another 3800 bytes.
2010-03-05 15:23:30 -08:00
Eric Anholt
342a7f23bf intel: Move the assertions about reloc delta from the macros to the function.
Cuts another 1800 bytes from the driver.
2010-03-05 15:23:30 -08:00
Eric Anholt
8a9d8bd52a intel: Check that the batch is mapped per BEGIN, not each OUT.
Shaves 800 bytes off the driver.
2010-03-05 15:23:30 -08:00
Eric Anholt
f6f5e87679 i965: Try to assign SNB SF inputs to outputs. 2010-03-05 15:23:30 -08:00
Eric Anholt
3b9612645e i965: Fix the SNB SF input size. 2010-03-05 15:23:30 -08:00
Chris Wilson
24f9011276 Always return VOLATILE for ObjectPurgeable(VOLATILE)
Fixes fdo bug 26128.

The spec mandates that VOLATILE is returned from
ObjectPurgeable(VOLATILE) irrespective of the actual status of the
object upon completion of marking it purgeable.

Conform to the spec, even though it seems wrong.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-03-05 23:20:45 +00:00
Brian Paul
b704a4e8f3 llvmpipe: add pipe_thread_wait() calls
Wait for threads to exit before cleaning up per-thread data.
Fixes hang on context destruction with glean makeCurrent test.
See fd.o bug 26536.
2010-03-05 14:24:04 -07:00
Brian Paul
76e87786ab gallium/docs: document additional wrap mode restrictions 2010-03-05 13:30:24 -07:00
Brian Paul
88e2eae271 gallivm: minor arithmetic improvements 2010-03-05 13:29:25 -07:00
Brian Paul
d660e28c9c gallivm: implement non-normalized texture wrap modes
Note that only the PIPE_TEX_WRAP_CLAMP,CLAMP_TO_EDGE,CLAMP_TO_BORDER
modes work with non-normalized texcoords.
2010-03-05 13:29:25 -07:00
Brian Paul
b5b128b268 softpipe: implement PIPE_TEX_WRAP_CLAMP_TO_EDGE for unorm texture sampling
CLAMP_TO_BORDER and CLAMP_TO_EDGE were doing the same thing.
2010-03-05 13:28:18 -07:00
Brian Paul
e9968ebfa4 mesa: minor reformatting, new comments 2010-03-05 13:28:18 -07:00
Jesse Barnes
f846a008e9 progs/xdemos: fix up GLX extension checking
A few of my programs were using the client string in addition to the
main extensions string to see if a feature was present.  Correct this to
only check for the currently available and working extensions.
2010-03-05 11:22:05 -08:00
Jesse Barnes
1ca968363d DRI2: expose OML_sync_control if possible
If the server supports the OML related protocol, enable support for the
extension.
2010-03-05 11:22:05 -08:00
Jesse Barnes
6b3145d6ee GLX: remove debug prints from glXWaitForMscOML dispatch
Leftover from earlier commit.
2010-03-05 11:22:04 -08:00
Jesse Barnes
77bc721a52 xdemos/omlsync: add waitformsc and swap interval code 2010-03-05 11:22:04 -08:00
Michal Krol
2b15f4fc68 progs: Add arbocclude2 demo. 2010-03-05 18:42:42 +01:00
Brian Paul
c3b6adccc9 gallium/docs: updated/improve sampler state documentation 2010-03-05 09:53:47 -07:00
Brian Paul
60fae3b024 docs: document GL_APPLE_object_purgeable 2010-03-05 09:24:15 -07:00
Brian Paul
e176ae5f2a mesa: whitespace fixes, 80-column wrapping, etc. 2010-03-05 09:23:43 -07:00
Chris Wilson
6ba31fb2db Merge branch 'object-purgeable'
Acked-by: Brian Paul <brianp@vmware.com>
2010-03-05 15:03:56 +00:00
Chris Wilson
755915fa5d APPLE_object_purgeable: intel
Implement support for purgeable objects by using the GEM madvise ioctl.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-03-05 11:23:59 +00:00
Chris Wilson
99864d595f APPLE_object_purgeable: core
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-03-05 11:23:55 +00:00
Chia-I Wu
3490923c81 mesa/es: Update GLAPI and APISpec for GL_OES_EGL_image.
This generates the entrypoints and dispatches for GL_OES_EGL_image.
There is no real support yet.
2010-03-05 11:33:10 +08:00
Chia-I Wu
9373447a61 st/egl: Add support for EGL_KHR_image_base and EGL_KHR_image_pixmap.
These extensions are not quite useful until the client APIs gain support
for the respective EGLImage extensions.
2010-03-05 11:33:10 +08:00
Chia-I Wu
fade8a6eb6 st/egl: Add get_param to native display interface.
get_param can be used to query the parameters of a native display.
There is only NATIVE_PARAM_USE_NATIVE_BUFFER right now.  It queries
whether the window/pixmap surfaces use the native buffers instead of
private buffers.
2010-03-05 11:32:29 +08:00
Chia-I Wu
89a75b7634 st/egl: Move modeset interface to native_modeset.h.
native.h is getting more and more complex.  Move the independent modeset
interface to native_modeset.h to simplify native.h a little.
2010-03-05 11:32:11 +08:00
Chia-I Wu
e38f28dded st/egl: Add event support to the native display interface.
There is only invalid_surface event right now.  When EGL receives the
event, it sets the force_validate flag of the context binding to the
surface.  This helps skip an unnecessary check.
2010-03-05 10:19:05 +08:00
Vinson Lee
45df4bad9f Revert "mesa: Remove pointless comparison of unsigned integer with a negative constant."
This reverts commit a05fdbcb71.

Removing the comparison is wrong. The comparison with -1 should be changed
to another value (probably PROGRAM_UNDEFINED) along with another
change in the shader assembler.

Conflicts:

	src/mesa/shader/prog_execute.c
2010-03-04 17:41:20 -08:00
Eric Anholt
bb35000b4b intel: Remove non-kernel-exec-fencing support.
Shaves 60k off the driver from removing the broken spans code.  This
means we now require 2.6.29, which seems fair given that it's a year
old and we've removed support for non-KMS already in the last release
of 2D.
2010-03-04 16:56:32 -08:00
Eric Anholt
7cbc4c07ee intel: Remove the unused s8 spans code. Not hit during no_rast piglit.
Shaves 5.5k off of the driver.
2010-03-04 16:50:51 -08:00
Michel Dänzer
391b396f3f Fix comparison of unsigned value against < 0. 2010-03-05 00:15:40 +01:00
Brian Paul
b37c541500 softpipe: minor tweaks to texture filtering code 2010-03-04 15:58:01 -07:00
Brian Paul
2b5c5c0dcf gallivm: implement texture border color, plus tweaks to some wrap modes
The progs/test/texwrap demo looks pretty good, but there are still some
tiny differences from softpipe.  There may be a sub-pixel texcoord
interpolation error somewhere.

There's some room for optimization.  Many of the wrap modes compute
intermediate values that are constant for the texture size (see the
min/max values).  These could be computed earlier and stored somewhere
for later use.
2010-03-04 15:56:55 -07:00
Brian Paul
946edea794 gallivm: added texture border_color field 2010-03-04 15:56:55 -07:00
Brian Paul
71c0568952 gallivm: added question/comment 2010-03-04 15:56:55 -07:00
Brian Paul
ad1456a444 llvmpipe: new comment 2010-03-04 15:56:55 -07:00
Brian Paul
877f2356b2 gallivm: comments 2010-03-04 15:56:55 -07:00
Francisco Jerez
a42fd95f43 dri/nouveau: Remove some CI remnants. 2010-03-04 23:43:02 +01:00
Andrew Randrianasulu
9c4937524e dri/nouveau: Trivially add GL_ARB_texture_mirrored_repeat.
Signed-off-by: Francisco Jerez <currojerez@riseup.net>
2010-03-04 23:42:53 +01:00
Andrew Randrianasulu
44df3577a7 dri/nouveau: Enable GL_EXT_stencil_wrap.
Signed-off-by: Francisco Jerez <currojerez@riseup.net>
2010-03-04 23:14:24 +01:00
Andrew Randrianasulu
210bcf6d15 dri/nouveau: Add GL_EXT_stencil_wrap for nv04.
Signed-off-by: Francisco Jerez <currojerez@riseup.net>
2010-03-04 23:07:11 +01:00
Francisco Jerez
9c21c1e865 dri/nouveau: Fix rb->DataType for z24s8 renderbuffers. 2010-03-04 23:07:11 +01:00
Francisco Jerez
80316cbefa dri/nouveau: Try to keep client buffers smaller than the scratch VBO length. 2010-03-04 23:07:11 +01:00
Francisco Jerez
43c347c63e dri/nouveau: Pack client arrays as they're copied to the real BO. 2010-03-04 23:07:10 +01:00
Jesse Barnes
b6456dc234 xdemos: add OML sync test
Add program to test glXSwapBuffersMscOML behavior.  Based on glsync.c.
2010-03-04 13:14:59 -08:00
Corbin Simpson
566390bedf r300g: Fix indexbuf upper limits.
Wine tends to pessimistically use ~0 for its max index, but r300s
only can go up to 2^24-1, causing the kernel checker to freak out.

Civ4 is marginally improved now. Still crashes, but not as bad.
2010-03-04 12:49:44 -08:00
Brice Goglin
bf8957e7b9 Remove Thierry Reding from Uploaders 2010-03-04 20:52:25 +01:00
Chris Wilson
894d0ab938 APPLE_object_purgeable: autogenerated files 2010-03-04 19:43:19 +00:00
Chris Wilson
e5c49e49cc APPLE_object_purgeable: xml
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-03-04 19:26:54 +00:00
Brian Paul
4c0c728b2a gallivm: rework and implement more texture wrap modes
All the texture wrap modes are now implemented for linear and nearest
sampling.

However, texture border color is not yet supported so some wrap modes
will produce int coords outside the texture bounds.  We'll get garbage
values insted of the texture border color for now.
2010-03-04 10:53:27 -07:00
Brian Paul
516bad2272 gallivm: added lp_build_fract() 2010-03-04 10:53:27 -07:00
Brian Paul
6464d81e77 gallivm: added lp_build_set_sign() 2010-03-04 10:53:26 -07:00
Brian Paul
7d230dae70 gallivm: added lp_build_negate() 2010-03-04 10:53:26 -07:00
Brian Paul
38110fd1c3 gallivm: clarify unsigned vs. signed integer type construction
The lp_int_type() function was creating an unsigned type.  So rename
that function to lp_uint_type() and create new lp_int_type() that
creates a signed type.
2010-03-04 10:53:26 -07:00
Eric Anholt
8e7a8d6593 i915: Enable texture tiling by default.
This now passes piglit testcases, and shows performance improvements
on openarena.  Blit-heavy apps may see degradation, but the
expectation is that the common case of 3D rendering will see
significant wins.

This regresses gen-teximage on my 855, and no piglit tests on my 945.
2010-03-04 08:18:53 -08:00
Eric Anholt
41d3fdc380 i915: Fix up i830 for tiled drawing offsets.
Corresponds to b87406e55f.
2010-03-04 08:18:50 -08:00
George Sapountzis
aae81a7681 fix getprocaddress test 2010-03-04 16:34:01 +02:00
Ian Romanick
c7f7a309af DRI: Put back missing break-statement
The break in the __DRI_ATTRIB_RENDER_TYPE case was accidentally
removed in commit 5cf2c5851b.  This puts
it back.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-04 01:58:28 -08:00
Vinson Lee
34b2cec95c Revert "mesa: Fix unsigned comparison."
This reverts commit f9504e75f0.

This patch is incorrect.
2010-03-04 01:53:14 -08:00
Vinson Lee
ac610ab830 glsl: Remove unsigned greater than or equal zero comparison. 2010-03-04 01:35:28 -08:00
Vinson Lee
f9504e75f0 mesa: Fix unsigned comparison. 2010-03-04 01:24:44 -08:00
Vinson Lee
0dd40cc20a glsl: Remove unsigned greater than or equal zero comparison. 2010-03-04 01:10:44 -08:00
Vinson Lee
3c90777fd7 glsl: Return NULL on _slan_gen_asm error path on non-debug builds.
Exit the function early on the error path, instead of continuing, to
prevent a null pointer dereference later on.
2010-03-04 00:58:36 -08:00
Vinson Lee
df20c3943a glsl: Add assert to check input to strcmp. 2010-03-04 00:53:52 -08:00
Vinson Lee
df62b0da92 mesa: Add asserts to check inputs to memcpy. 2010-03-04 00:41:21 -08:00
Dave Airlie
25e439e69f r300: make blit code work on swtcl machines.
Only tested this on my rv530 with R300_NO_TCL=1, but it works there
at least. It would be nice to fix the tex_offset by chaning the vertex
program on tcl to read from offset 6 but this isn't really necessary.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-03-04 15:49:57 +10:00
Dave Airlie
c27fed58e4 r300_blit: initialise whole fp structure to 0
at least on the r500 we get a lockup unless I do this, the compiler
seems to fail to compile and we just get a null fp.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-03-04 15:11:42 +10:00
Vinson Lee
e5d0956ca4 Remove ffb and gamma from configs. 2010-03-03 19:03:45 -08:00
Vinson Lee
f4113012e0 wgl: Fix mingw32 build.
This was missed in commit fcf438e9e0.
2010-03-03 18:20:01 -08:00
Ian Romanick
6d9a9e57dc Fix unmatched parenthesis introduce by previous commits
I wasn't careful enough when removing support for GCC versions earlier
than 3.3.0.  I could have sworn that I compile tested before pushing,
but apparently not.  FAIL.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 17:50:11 -08:00
Ian Romanick
7d7e2198dd Note removal of pre-GCC 3.3.0 support in release notes. 2010-03-03 16:43:13 -08:00
Ian Romanick
f7dde2c131 Remove support for GCC older than 3.3.0 from generated sources
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 16:26:32 -08:00
Ian Romanick
6e8e4b918d Remove support for GCC older than 3.3.0 from generator scripts
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 16:26:32 -08:00
Ian Romanick
016fc30839 Remove support for GCC older than 3.3.0
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 16:26:32 -08:00
Ian Romanick
9aa3aa7138 Add version check for GCC
Mesa now requires GCC 3.3.0 or later.  See the following thread from
the mesa3d-dev mailing list for more details:

http://marc.info/?t=126748568900005&r=1&w=2

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 16:26:32 -08:00
Alex Deucher
3594bf233d radeon/r200/r300/r600: add check_blit vtbl function
Check if the native blit formats are supported, if not,
attempt to use an alternate format.

Skip 3, >4 bpp as per comments from mcencora on irc.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
2010-03-03 16:14:17 -05:00
Ian Romanick
21cc53c2bc Note removal of color-index rendering in release notes. 2010-03-03 12:37:05 -08:00
Ian Romanick
0384214923 Remove stray defines of HAVE_RGBA
Now that color-index support is removed from t_dd_tritmp.h and
t_dd_unfilled.h, drivers no longer need define HAVE_RGBA.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:05 -08:00
Ian Romanick
889a0f3471 mesa/tnl_dd: Remove color-index support from t_dd_unfilled.h
The code removal and the re-indent were done together for this one
because the cause of the affected code blocks is much, much smaller
than in t_dd_tritmp.h.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:05 -08:00
Ian Romanick
e00b50c39a mesa/tnl_dd: White-space / indentation fixes after previous commit
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:05 -08:00
Ian Romanick
78742f8e86 mesa/tnl_dd: Remove color-index support from t_dd_tritmp.h
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:05 -08:00
Ian Romanick
06ceba0a7c mesa: Remove unused RasterIndex field
With the preceeding changes, gl_current_attrib::RasterIndex is not
used.  Remove it.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:05 -08:00
Ian Romanick
5c52b4292f mesa: Always return default value for CURRENT_RASTER_INDEX
Since there is no color-index rendering, it is impossible to update
this value.  Just return the initial setting and be happy.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:05 -08:00
Ian Romanick
24d311c133 mesa: Eliminate index parameter to _mesa_feedback_vertex
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:05 -08:00
Ian Romanick
bb8c3b1bcc mesa: Remove ClearIndex and IndexMask from device-driver interface
These are used to inform the driver of the clear value for color-index
buffers and to control write-masking of bits in color-index buffers.
No driver use or need (not even Nouveau) these interfaces.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:05 -08:00
Ian Romanick
5034e8ad42 swrast: Remove _swrast_logicop_ci_span
After all the recent color-index rendering removal,
_swrast_logicop_ci_span is no longer used anywhere.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:05 -08:00
Ian Romanick
3d0f608e13 mesa: Remove _mesa_add_color_index_renderbuffers
After all the recent color-index visual support removal,
_mesa_add_color_index_renderbuffers is no longer used anywhere.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:04 -08:00
Ian Romanick
b9f63c277a mesa: Remove checks of Visual.rgbMode in Get paths
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:04 -08:00
Ian Romanick
22a96f3058 mesa: Remove checks of Visual.rgbMode
This must always be true now, so there is no reason to check it.  Ever.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:04 -08:00
Ian Romanick
fcf438e9e0 mesa: Remove support for creating color-index visuals
Remove the rgbMode and indexBits parameters from _mesa_create_visual
and _mesa_initialize_visual.  These values are now hardcoded to
GL_TRUE and 0.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:04 -08:00
Ian Romanick
a9c1b3caf6 tnl: Remove color-index TNL support
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:04 -08:00
Ian Romanick
5cf2c5851b DRI: Remove support for color-index visuals
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:04 -08:00
Ian Romanick
e650c07f47 swrast_setup: Remove more color-index rendering support
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:04 -08:00
Ian Romanick
859c98c392 swrast: Remove color-index rendering support from s_spantemp.h
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:04 -08:00
Ian Romanick
81fe9949ef mesa/xlib: Remove support for color-index rendering
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:04 -08:00
Ian Romanick
641705f032 osmesa: Remove support for color-index rendering
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:04 -08:00
Ian Romanick
6f317253bf fbdev: Remove support for color-index rendering
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:04 -08:00
Ian Romanick
718ff7e87b DRI/swrast: Remove color-index support from DRI swrast driver
It appears that color-index rendering wasn't actually supported
anyway.  swrastFillInModes did not previously create an color-index
configs, so it doesn't seem like there would be any way to get a
color-index visual.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:04 -08:00
Ian Romanick
dc14ce9e36 swrast: Remove SPAN_INDEX
Also adjust the bits that appear after it to fill in the gap.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:04 -08:00
Ian Romanick
7ce12c9024 swrast: Remove _swrast_read_index_span
After all the recent color-index rendering removal,
_swrast_read_index_span is no longer used anywhere.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:04 -08:00
Ian Romanick
0ca5729578 swrast: Remove _swrast_mask_ci_span
After all the recent color-index rendering removal,
_swrast_mask_ci_span is no longer used anywhere.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:04 -08:00
Ian Romanick
b00362e51b swrast: Remove _swrast_fog_ci_span and associated code
After all the recent color-index rendering removal,
_swrast_fog_ci_span is no longer used anywhere.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:04 -08:00
Ian Romanick
c00282102a swrast: Remove _swrast_write_index_span and associated code
After all the recent color-index rendering removal,
_swrast_write_index_span is no longer used anywhere.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:04 -08:00
Ian Romanick
2b7911d37d swrast: Remove remaining color-index state tracking infrastructure
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:04 -08:00
Ian Romanick
3fd8487ac6 swrast: Remove support for ReadPixels from a color-index buffer
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:03 -08:00
Ian Romanick
9e2d30e0b8 swrast: Remove support for Clear into a color-index buffer
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:03 -08:00
Ian Romanick
e5ed4c45c6 swrast: Remove support for rendering antialiased lines into a color-index buffer
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:03 -08:00
Ian Romanick
87b9f5a725 swrast: Remove support for rendering antialiased triangles into a color-index buffer
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:03 -08:00
Ian Romanick
e6df80184b swrast: Remove support for rendering lines into a color-index buffer
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:03 -08:00
Ian Romanick
dbe901ceb0 swrast: Remove support for rendering points into a color-index buffer
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:03 -08:00
Ian Romanick
0ed9c4bc7a swrast: Remove support for rendering triangles into a color-index buffer
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:03 -08:00
Ian Romanick
d05badba29 swrast: Remove support for Bitmap into a color-index buffer
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:03 -08:00
Ian Romanick
ef0e02f93d swrast: Remove _swrast_write_zoomed_index_span and associated code
After removing support for CopyPixels and DrawPixels involving
color-index buffers, _swrast_write_zoomed_index_span is no longer
used.  Removed it and all the support for COLOR_INDEX formats in zoom_span.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:03 -08:00
Ian Romanick
e7e748cd04 swrast: Remove support for CopyPixels to / from a color-index buffer
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:03 -08:00
Ian Romanick
d82e1d7f95 swrast: Remove support for DrawPixels into a color-index buffer
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-03-03 12:37:03 -08:00
José Fonseca
4053d33703 llvmpipe: Store the original triangle coordinates in the debug build.
For debugging purposes only.
2010-03-03 19:55:49 +00:00
José Fonseca
4d5dd82558 llvmpipe: Ensure context is flushed when destroying shaders. 2010-03-03 19:55:49 +00:00
Eric Anholt
b87406e55f i915: Use x,y drawing offsets instead of changing buffer offsets.
This should fix rendering into mipmaps of tiled textures.
2010-03-03 11:33:37 -08:00
Eric Anholt
06d1472ffa i915: Tell the kernel when we actually need fence registers on our BOs.
This improves tiled texture performance of OA on my 945 from 25.3fps
to 29.0fps, whereas untiled is 28.2fps, by avoiding stalls for fence
register changes.
2010-03-03 11:33:37 -08:00
Eric Anholt
179d2c0e0b intel: Use drm_intel_bo_alloc_tiled for region allocs.
This moves the logic for how to align pitches, heights, and sizes of
objects to one central location.  Fixes rendering with texture tiling
on i915.  Note that current libdrm is required for the change for
I915_TILING_NONE pitch alignment.
2010-03-03 11:33:37 -08:00
Eric Anholt
07439cf617 i915: Don't do the pitch expansion for tiled buffers.
The weirdness that led to the bumping of pitch for those 512/1024
pixels is that in taking a 2x2 subspan or bilinear filtering we'd end
up hitting the same channel in 2 different pages, leading to lower
performance.  With tiling, that doesn't occur, so we don't need to
waste the memory.
2010-03-03 11:33:37 -08:00
Eric Anholt
55e90e46e0 intel: Use GTT mapping in the blit fallback path in case there's tiling. 2010-03-03 11:33:37 -08:00
Eric Anholt
a3593833dc i965: Fix up Sandybridge VS sizing. 2010-03-03 11:33:37 -08:00
George Sapountzis
3b8ff24554 glapi: minor cosmetic 2010-03-03 21:23:20 +02:00
George Sapountzis
8bd8aec81d glapi: drop condvar
Seems unused and replaced by functionality in os module.
2010-03-03 21:23:20 +02:00
Alex Deucher
bdbf199a8c r600: add new rs880 pci id 2010-03-03 14:09:53 -05:00
Kristian Høgsberg
4007342584 egl_dri2: Factor out DRI2 protocol bits from initialize. 2010-03-03 10:47:49 -05:00
Kristian Høgsberg
af3f1bb269 intel: Set InternalFormat for renderbuffers created from an EGLImage 2010-03-03 10:47:49 -05:00
José Fonseca
be1b7d1a04 progs/gallium/unit: Test (un)pack_4ub.
Most of them are failing.
2010-03-03 13:47:42 +00:00
José Fonseca
f7e403b129 gallium: Remove PIPE_FORMAT_R8G8B8X8_SNORM. 2010-03-03 13:08:23 +00:00
José Fonseca
a5b56c8153 util: Remove PIPE_FORMAT_R8G8B8X8_SNORM information. 2010-03-03 13:08:08 +00:00
José Fonseca
c51f7a48cd r300: Remove PIPE_FORMAT_R8G8B8X8_SNORM support. 2010-03-03 13:07:56 +00:00
José Fonseca
c2ba284386 progs/gallium/unit: Remove PIPE_FORMAT_R8G8B8X8_SNORM test cases. 2010-03-03 13:07:43 +00:00
José Fonseca
7b7b66781b llvmpipe: Linux is no longer a dependency. Llvmpipe builds and runs fine on windows too. 2010-03-03 12:07:39 +00:00
José Fonseca
9f9b44222f llvmpipe: Centralize LLVM initialization. 2010-03-03 12:02:26 +00:00
José Fonseca
a9e6da7b4c gallivm: Centralize initialization. Fix stack alignment issues on Windows. 2010-03-03 12:02:26 +00:00
José Fonseca
f58ca9b02b llvmpipe: Update for lp_bld_init.h rename. 2010-03-03 12:02:26 +00:00
José Fonseca
af36b050eb gallivm: Rename lp_bld_misc -> lp_bld_init. 2010-03-03 12:02:26 +00:00
Dave Airlie
daf85c4608 radeon/r200/r300/r600: fix blit BO buffer validation
there is no need for these to be persistent since we flush the CS
at the end of the blit, and we don't reuse these buffers at all.

on my r600 the Wine DX9 test suite doesn't crash at least anymore.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-03-03 16:28:53 +10:00
Corbin Simpson
4cb7642ff3 r300g: Use a macro to consolidate general state handling.
My God, I've reinvented R300_STATECHANGE. Forgive me. :C
2010-03-02 19:14:09 -08:00
Christoph Bumiller
20443f969d nv50: fix RT formats after format rename fixes
Getting rid of the evil pre-processor magic, but not changing our
internal format naming convention (at least for now).
2010-03-02 19:16:39 +01:00
José Fonseca
aaa2d548ed nouveau: Rename pipe formats.
These format uses were being hiden by pre-processor magic and were
missed in the previous search'n'replace.
2010-03-02 17:26:40 +00:00
José Fonseca
2998cad9ce Merge branch 'gallium-format-cleanup' 2010-03-02 16:00:34 +00:00
Zack Rusin
faf8215bae llvmpipe: improve based on review from Jose and fix else clauses
else was broken in the outter most else statemants, plus the code
didn't need an inverted mask to compute the inverse of the current
condition.
2010-03-02 10:19:56 -05:00
Keith Whitwell
0c616da241 llvmpipe: remove some ifdefs
No longer any need to protect expensive asserts with #ifdef DEBUG.
2010-03-02 15:03:09 +00:00
Keith Whitwell
5fe2ce28b6 llvmpipe: reorganize transfer usage
Move transfer creation and mapping to the "scene" object, and out of
the rasterizer.  The rasterizer operates on already-mapped
framebuffers only, and no longer needs a screen or context pointer.

The scene object has access to a pipe_context, and this reorg prepares
for moving transfer functionality from the screen to the context.
2010-03-02 15:03:09 +00:00
Brian Paul
8417528e3a intel: passs correct context type to intel_prepare_render() call 2010-03-02 07:50:15 -07:00
Brian Paul
cb099c2ecf i965: include macros.h to get CLAMP macro 2010-03-02 07:47:56 -07:00
Brian Paul
5f40a7aed1 glx: replace assertion with conditional
See fd.o bug 26832.
2010-03-02 07:38:15 -07:00
José Fonseca
8598cebf43 progs/gallium/unit: Add test cases for single precision floats. 2010-03-02 12:47:16 +00:00
José Fonseca
77d9e93901 progs/gallium/unit: Add test cases for Nx16 and Nx32 integer formats. 2010-03-02 12:40:09 +00:00
Michal Krol
4ca70c489b Merge branch 'gallium-no-rhw-position'
Conflicts:
	src/gallium/drivers/r300/r300_blit.c
	src/gallium/drivers/r300/r300_emit.c
	src/gallium/drivers/r300/r300_state_derived.c
2010-03-02 13:35:30 +01:00
José Fonseca
915bbc8b0b progs/gallium/unit: Add more test cases. 2010-03-02 11:30:46 +00:00
José Fonseca
7a31bed4b1 util: Tweak comment for D3D10-like formats. 2010-03-02 11:30:23 +00:00
José Fonseca
4e1aa4a812 progs/gallium/python: Rename pipe formats. 2010-03-02 10:22:35 +00:00
José Fonseca
3b67f87970 gallium/unit: Rename pipe formats. 2010-03-02 10:22:35 +00:00
José Fonseca
496aa4793a rbug: Rename pipe formats. 2010-03-02 10:21:55 +00:00
José Fonseca
4028fab892 gdi: Rename pipe formats. 2010-03-02 10:21:55 +00:00
José Fonseca
907d5611b2 drm/nouveau: Rename pipe formats. 2010-03-02 10:21:55 +00:00
José Fonseca
b34d138d84 svga: Rename pipe formats. 2010-03-02 10:21:55 +00:00
José Fonseca
b7b07b0029 softpipe: Rename pipe formats. 2010-03-02 10:21:54 +00:00
José Fonseca
b5cfa6f196 r300: Rename pipe formats. 2010-03-02 10:21:21 +00:00
Marek Olšák
ff9ddf4d39 util/blitter: Fix the viewport transformation for Z coordinates
When clearing buffers, the depth is specified in the range [0, 1]
and should be passed through blitter "as is".
2010-03-02 10:27:37 +01:00
Vinson Lee
c1c7fa5192 i915g: Add assert to check for null pointer dereference. 2010-03-02 01:15:02 -08:00
Vinson Lee
8462fe2bbf glsl: Add assert to check input to strcmp. 2010-03-02 01:10:29 -08:00
Vinson Lee
247008f6c2 mesa: Add asserts to check inputs to memcpy. 2010-03-02 01:01:46 -08:00
Dave Airlie
8bf5c229f3 r600: fix blender picking.
This fixes the sw fallback for GL_SELECT picking modes.

Fixes object picking blender + depthpick test

http://bugs.freedesktop.org/show_bug.cgi?id=26419

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-03-02 14:12:28 +10:00
Zack Rusin
80f3cc36c5 llvmpipe: implement some control-flow
implements if/else/endif constructs and lays down the code for looping
and others. we create a conditional execution mask which decides which
of the four inputs are enabled for any store. it's used only if an
execution mask is present, otherwise we go through a direct store.
2010-03-01 22:13:22 -05:00
George Sapountzis
d3f24ab33c glapi: fix compile with ES 2010-03-02 03:32:43 +02:00
José Fonseca
6e48f17a16 glapi: Fix syntax. 2010-03-01 23:18:49 +00:00
Pauli Nieminen
9a7776696b radeon: Reduce number of radeon_bo_map calls that require kernel entry.
DMA buffers are often remapped many times for singel cs. To reduce number of
mapping calls ending to kernel dma buffers are mapped when allocated and unmapped
when full or in cs flush. This makes indifual mapping calls in other parts of
code simple increment/decrement reference count which is faster than entering
kernel.

This improves Anholt's openarena benchmark from 36 fps to 44 fps.
2010-03-01 23:56:35 +02:00
Karl Schultz
a379fa8b30 Remove now obsolete mesa_bzero symbol. 2010-03-01 12:21:13 -07:00
George Sapountzis
d7e6e879fd glapi: drop SOLARIS_THREADS
It seems that SOLARIS_THREADS is not used and does not work.
2010-03-01 20:54:20 +02:00
George Sapountzis
d41ab94d35 glapi.c: misc coscmetic for FreeTSD
- move out of of the dispatch/context block to after corresponding init functions

- use more consistent naming with corresponding init functions

- XXX use _glthread_InitTSD() vs (void)_glthread_GetTSD() in _glapi_check_multithread() XXX
2010-03-01 20:54:20 +02:00
George Sapountzis
7b454b00a4 glapi.c: misc cosmetic
mainly, move the multithread check mutex out of the dispatch/context block,
closer to where it is used.
2010-03-01 20:54:19 +02:00
George Sapountzis
cccdc1783f glapi.c: mv init_glapi_relocs to glapi_getproc.c 2010-03-01 20:54:19 +02:00
George Sapountzis
fae5758fac glapi.c: mv check_table to glapi_getproc.c 2010-03-01 20:54:19 +02:00
George Sapountzis
42f3241e04 glapi.c: split check_table to not_null and get_proc 2010-03-01 20:54:18 +02:00
George Sapountzis
750a7f1f1d glapi.h: drop dispatch_override prototypes
cannot find them in mesa tree
2010-03-01 20:54:18 +02:00
George Sapountzis
57d31591d1 glapi.h: misc cosmetic
- revert context/dispatch order, similar to glapi.c
- stray GL_GLEXT_PROTOTYPES
2010-03-01 20:54:18 +02:00
George Sapountzis
a4ec52f245 glapi.h: consolidate GET_DISPATCH() and GET_CURRENT_CONTEXT() macros
Use likely() macro, as this is what most projects use.

Drops GL_CALL define, cannot find it in mesa tree.

Also, whitespace cleaunps in glthread.h
2010-03-01 20:54:17 +02:00
José Fonseca
c9f1db0a03 nouveau: Rename pipe formats. 2010-03-01 18:53:32 +00:00
José Fonseca
33080a8454 llvmpipe: Rename pipe formats. 2010-03-01 18:53:32 +00:00
José Fonseca
4710040617 i965: Rename pipe formats. 2010-03-01 18:53:32 +00:00
José Fonseca
b2b1e899f6 i915g: Rename pipe formats. 2010-03-01 18:53:32 +00:00
José Fonseca
c828f784e5 cell: Rename pipe formats. 2010-03-01 18:53:32 +00:00
José Fonseca
0b6e45e1ee python: Rename pipe formats. 2010-03-01 18:53:32 +00:00
José Fonseca
b306308757 vega: Rename pipe formats. 2010-03-01 18:53:32 +00:00
José Fonseca
5706d7fcaf wgl: Rename pipe formats. 2010-03-01 18:53:32 +00:00
José Fonseca
d34a1a7028 xorg: Rename pipe formats. 2010-03-01 18:53:32 +00:00
José Fonseca
41b80461b7 glx: Rename pipe formats. 2010-03-01 18:53:31 +00:00
José Fonseca
ae3926011e egl: Rename pipe formats. 2010-03-01 18:53:31 +00:00
José Fonseca
c456dd5b4b dri: Rename pipe formats. 2010-03-01 18:53:31 +00:00
José Fonseca
7d1a79a04e mesa: Rename pipe formats. 2010-03-01 18:53:31 +00:00
José Fonseca
a489753471 translate: Rename pipe formats. 2010-03-01 18:53:31 +00:00
José Fonseca
7a61722f69 draw: Rename pipe formats. 2010-03-01 18:53:31 +00:00
José Fonseca
712ba6e6b0 util: Rename pipe formats. 2010-03-01 18:53:31 +00:00
José Fonseca
3843548a67 gallium: Standardize on the LSB->MSB notation.
Less confusing, and seems to gather more consensus.

Below are the sed commands used. This and following commits are the
result of applying this too to the whole tree, plus manual whitespaces
fixes.

s/\<PIPE_FORMAT_A8R8G8B8_UNORM\>/ASDGFSJKDGSDFGSJDFGREKT/g
s/\<PIPE_FORMAT_B8G8R8A8_UNORM\>/PIPE_FORMAT_A8R8G8B8_UNORM/g
s/\<ASDGFSJKDGSDFGSJDFGREKT\>/PIPE_FORMAT_B8G8R8A8_UNORM/g

s/\<PIPE_FORMAT_X8R8G8B8_UNORM\>/ASDGFSJKDGSDFGSJDFGREKT/g
s/\<PIPE_FORMAT_B8G8R8X8_UNORM\>/PIPE_FORMAT_X8R8G8B8_UNORM/g
s/\<ASDGFSJKDGSDFGSJDFGREKT\>/PIPE_FORMAT_B8G8R8X8_UNORM/g

s/\<PIPE_FORMAT_R8G8B8A8_UNORM_REV\>/PIPE_FORMAT_A8B8G8R8_UNORM/g
s/\<PIPE_FORMAT_R8G8B8X8_UNORM\>/PIPE_FORMAT_X8B8G8R8_UNORM/g
s/\<PIPE_FORMAT_A1R5G5B5_UNORM\>/PIPE_FORMAT_B5G5R5A1_UNORM/g
s/\<PIPE_FORMAT_A4R4G4B4_UNORM\>/PIPE_FORMAT_B4G4R4A4_UNORM/g
s/\<PIPE_FORMAT_R5G6B5_UNORM\>/PIPE_FORMAT_B5G6R5_UNORM/g
s/\<PIPE_FORMAT_A2B10G10R10_UNORM\>/PIPE_FORMAT_R10G10B10A2_UNORM/g

s/\<PIPE_FORMAT_A8L8_UNORM\>/PIPE_FORMAT_L8A8_UNORM/g

s/\<PIPE_FORMAT_A8L8_SRGB\>/PIPE_FORMAT_L8A8_SRGB/g
s/\<PIPE_FORMAT_R8G8B8A8_SRGB\>/PIPE_FORMAT_A8B8G8R8_SRGB/g
s/\<PIPE_FORMAT_R8G8B8X8_SRGB\>/PIPE_FORMAT_X8B8G8R8_SRGB/g

s/\<PIPE_FORMAT_A8R8G8B8_SRGB\>/ASDGFSJKDGSDFGSJDFGREKT/g
s/\<PIPE_FORMAT_B8G8R8A8_SRGB\>/PIPE_FORMAT_A8R8G8B8_SRGB/g
s/\<ASDGFSJKDGSDFGSJDFGREKT\>/PIPE_FORMAT_B8G8R8A8_SRGB/g

s/\<PIPE_FORMAT_X8R8G8B8_SRGB\>/ASDGFSJKDGSDFGSJDFGREKT/g
s/\<PIPE_FORMAT_B8G8R8X8_SRGB\>/PIPE_FORMAT_X8R8G8B8_SRGB/g
s/\<ASDGFSJKDGSDFGSJDFGREKT\>/PIPE_FORMAT_B8G8R8X8_SRGB/g

s/\<PIPE_FORMAT_A8B8G8R8_SNORM\>/PIPE_FORMAT_R8G8B8A8_SNORM/g
s/\<PIPE_FORMAT_X8B8G8R8_SNORM\>/PIPE_FORMAT_R8G8B8X8_SNORM/g
s/\<PIPE_FORMAT_X8UB8UG8SR8S_NORM\>/PIPE_FORMAT_R8SG8SB8UX8U_NORM/g
s/\<PIPE_FORMAT_B6UG5SR5S_NORM\>/PIPE_FORMAT_R5SG5SB6U_NORM/g

s/\<PIPE_FORMAT_S8Z24_UNORM\>/ASDGFSJKDGSDFGSJDFGREKT/g
s/\<PIPE_FORMAT_Z24S8_UNORM\>/PIPE_FORMAT_S8Z24_UNORM/g
s/\<ASDGFSJKDGSDFGSJDFGREKT\>/PIPE_FORMAT_Z24S8_UNORM/g

s/\<PIPE_FORMAT_X8Z24_UNORM\>/ASDGFSJKDGSDFGSJDFGREKT/g
s/\<PIPE_FORMAT_Z24X8_UNORM\>/PIPE_FORMAT_X8Z24_UNORM/g
s/\<ASDGFSJKDGSDFGSJDFGREKT\>/PIPE_FORMAT_Z24X8_UNORM/g

s/\<PIPE_FORMAT_YCBCR\>/PIPE_FORMAT_UYVY/g
s/\<PIPE_FORMAT_YCBCR_REV\>/PIPE_FORMAT_YUYV/g
2010-03-01 18:51:55 +00:00
José Fonseca
b152abe914 progs/gallium/unit: Rename PIPE_FORMAT_A8B8G8R8_SNORM. 2010-03-01 18:47:36 +00:00
José Fonseca
568a3c7365 r300: Remove PIPE_FORMAT_A8B8G8R8_SNORM.
PIPE_FORMAT_R8G8B8A8_SNORM already listed.
2010-03-01 18:47:36 +00:00
José Fonseca
971ab386c0 softpipe: Advertise PIPE_FORMAT_R8G8B8A8_SNORM instead. 2010-03-01 18:47:36 +00:00
José Fonseca
a6c4c4486d util: Remove PIPE_FORMAT_A8B8G8R8_SNORM. 2010-03-01 18:47:36 +00:00
José Fonseca
835a725684 gallium: Remove PIPE_FORMAT_A8B8G8R8_SNORM.
Its actually an alias for PIPE_FORMAT_R8G8B8A8_SNORM.
2010-03-01 18:47:36 +00:00
Michal Krol
c863f30155 util: Generate linear<->sRGB conversion tables. 2010-03-01 19:00:40 +01:00
Michal Krol
9a2c4f907b tgsi: Cleanup exec code for CLAMP, CMP and CND. 2010-03-01 17:57:18 +01:00
José Fonseca
ac8e1c18f2 util: Fix PIPE_FORMAT_R8G8B8_SRGB swizzles.
The only user of PIPE_FORMAT_R8G8B8_SRGB is mesa, which
per src/mesa/main/texstore.c interprets it as

  R8 G8 B8

and not the other way around.
2010-03-01 16:42:54 +00:00
José Fonseca
88e640fc14 xlib: Use PIPE_FORMAT_R8G8B8A8_UNORM(_REV) as appropriate. 2010-03-01 16:28:38 +00:00
José Fonseca
a2bcdb7e50 r300: Use PIPE_FORMAT_R8G8B8A8_UNORM_REV where appropriate. 2010-03-01 16:26:36 +00:00
José Fonseca
2c1249e226 i915g: Use PIPE_FORMAT_R8G8B8A8_UNORM_REV where appropriate. 2010-03-01 16:25:25 +00:00
José Fonseca
382d1d370b mesa: Use PIPE_FORMAT_R8G8B8A8_UNORM_REV where appropriate. 2010-03-01 16:25:04 +00:00
José Fonseca
daf7caf4cf util: Use PIPE_FORMAT_R8G8B8A8_UNORM_REV where appropriate. 2010-03-01 16:24:48 +00:00
José Fonseca
cd8b652303 gallium: Introduce a new format to disambiguate PIPE_FORMAT_R8G8B8A8_UNORM.
PIPE_FORMAT_R8G8B8A8_UNORM now means just

  R8 G8 B8 A8

PIPE_FORMAT_R8G8B8A8_UNORM_REV means

  A8 B8 G8 R8

And the thumb rule is vertex buffers refer to PIPE_FORMAT_R8G8B8A8_UNORM,
while textures refer to PIPE_FORMAT_R8G8B8A8_UNORM_REV.

PIPE_FORMAT_R8G8B8A8_UNORM_REV is just a temporary name.
2010-03-01 16:24:09 +00:00
José Fonseca
d170d73b16 bin: Remove raw2png.py.
Outdated, broken, and unused.
2010-03-01 16:10:49 +00:00
José Fonseca
018f4aca79 util: Fix PIPE_FORMAT_R8G8B8_UNORM description and notes.
There is actually no ambiguity in use -- it is always used as

  R8 G8 B8
2010-03-01 16:07:53 +00:00
Michal Krol
b42455c4f4 r300: Save viewport and clip states before invoking blitter. 2010-03-01 17:07:03 +01:00
Michal Krol
932e6f8d52 util: Fix u_blitter setup code after bypass_vs_clip_and_viewport removal.
Not tested.
2010-03-01 17:06:20 +01:00
José Fonseca
4c3bfc9778 gallium: Remove inexisting formats.
Can't find these formats used in any state tracker or any API.

For some of these probably the reverse notation was meant, for which
formats already exist.
2010-03-01 15:17:41 +00:00
José Fonseca
cfdc146247 util: Remove inexisting formats.
Can't find these formats used in any state tracker or any API.

For some of these probably the reverse notation was meant, for which
formats already exist.
2010-03-01 15:16:54 +00:00
José Fonseca
28f2888565 util: A few more links for D3D formats. 2010-03-01 15:14:30 +00:00
José Fonseca
3a26193fd5 r300: Don't implement PIPE_FORMAT_R8G8B8X8_SNORM.
This format is not actually used by any state tracker. Probably the
reverse notation was mean, which would make it identical to
PIPE_FORMAT_X8B8G8R8_SNORM.
2010-03-01 15:14:00 +00:00
José Fonseca
b66b4cf646 util: A few more todo marks. 2010-03-01 14:56:20 +00:00
José Fonseca
4a991b5783 util: More documentation for u_format.csv 2010-03-01 14:56:20 +00:00
José Fonseca
ffe90af2e8 util: Tweak comments regarding R8G8B8A8/X8_UNORM. 2010-03-01 14:56:20 +00:00
José Fonseca
bd3c063da8 python: Don't mention deprecated drivers=trace option.
Now trace always built.
2010-03-01 14:56:19 +00:00
José Fonseca
f54aecc4f2 python: Don't mention deprecated drivers=trace option.
Now trace always built.
2010-03-01 13:08:07 +00:00
José Fonseca
e243e87b52 llvmpipe: Don't mention deprecated drivers=trace option.
Now trace always built.
2010-03-01 13:08:07 +00:00
José Fonseca
c05c675de6 progs/gallium: Make a phony target "unit" to run unit tests. 2010-03-01 13:08:06 +00:00
Francisco Jerez
e7ca0e126e dri/nouveau: Combine the dummy texture more deterministically on nv0x. 2010-03-01 02:07:01 +01:00
Francisco Jerez
c7955f1341 dri/nouveau: Fix up the ADD texture environment on nv0x. 2010-03-01 02:07:01 +01:00
Andrew Randrianasulu
394672659d dri/nouveau: Add two stencil operation cases in nv04_state_raster.c.
Signed-off-by: Francisco Jerez <currojerez@riseup.net>
2010-03-01 02:07:00 +01:00
Andrew Randrianasulu
949587d169 dri/nouveau: Allow to render to XRGB8888 textures.
Signed-off-by: Francisco Jerez <currojerez@riseup.net>
2010-03-01 02:06:13 +01:00
Marek Olšák
d2ac3d5e79 r300g: atomize texture and sampler states 2010-02-28 19:30:39 +01:00
Marek Olšák
942762cd97 r300g: decouple vertex stream setup (PSC) and VS output mapping (VAP_OUT)
Formerly known as vertex_format_state. These two are completely
unrelated when using HWTCL and decoupling them makes the design
less SWTCL-centric.

When bypass_vs_clip_and_viewport gets removed, the PSC setup will
no longer be a derived state.

This change shouldn't make unbreaking SWTCL harder.
2010-02-28 19:30:39 +01:00
Jakob Bornecrantz
79a86d312d i965g: Fix texture creation 2010-02-28 16:28:44 +00:00
Alex Weiss
54f9c509a1 Fixed mklib to properly merge static libraries on darwin.
Signed-off-by: Dan Nicholson <dbn.lists@gmail.com>
2010-02-28 00:55:03 -08:00
Vinson Lee
909c08d177 dri: Remove dead code. 2010-02-27 21:57:38 -08:00
Vinson Lee
edd6c338cf glut: Add asserts to check for null pointer dereferences. 2010-02-27 21:19:47 -08:00
Vinson Lee
706fffbff5 glx: Add assert to check input to memcpy. 2010-02-27 20:23:17 -08:00
Vinson Lee
75dba756b2 mesa: Add asserts to check inputs to memcpy. 2010-02-27 20:11:31 -08:00
Vinson Lee
bfdee9cc70 mesa: Add assert to check input to memcpy is not null. 2010-02-27 17:19:31 -08:00
Vinson Lee
65974f67e1 glsl: Move assert from outside to inside of _slang_gen_swizzle function. 2010-02-27 17:01:25 -08:00
Vinson Lee
cab77711b3 dri: Add assert to check for null pointer dereference. 2010-02-27 16:51:17 -08:00
Vinson Lee
975f105bb8 i810: Add assert to check for null pointer dereference. 2010-02-27 16:41:49 -08:00
Vinson Lee
b45af1ec61 mach64: Add asserts to check for null pointer dereferences. 2010-02-27 16:38:09 -08:00
Vinson Lee
689249bcbe mga: Add assert to check for null pointer dereference. 2010-02-27 16:30:49 -08:00
Vinson Lee
a5406444ae r128: Add assert to check for null pointer dereference. 2010-02-27 16:28:30 -08:00
Marek Olšák
aa4d47f68f st/mesa: do not advertise S3TC if the external lib is not available 2010-02-28 00:46:36 +01:00
Marek Olšák
d36e3952c2 r300g: put validating buffers after flushing
Also cleaning up the nasty validation process.
2010-02-28 00:46:35 +01:00
Marek Olšák
4ed97f0a73 r300g: use the atom size directly during emission 2010-02-28 00:46:35 +01:00
Marek Olšák
279715e76e r300g: atomize invalidation of texture caches 2010-02-28 00:46:35 +01:00
Marek Olšák
fe6d3b9222 r300g: atomize PVS flush
The first non-state atom. It's better and cleaner to have it.
2010-02-28 00:46:35 +01:00
Marek Olšák
841122d0e8 r300g: add size parameter to the atom emit functions
Maintaining a closer relationship between the atom size and what's passed
in BEGIN_CS.
2010-02-28 00:46:35 +01:00
Marcin Slusarz
14771ba7e4 mesa: remove libmesagallium.a on make clean
Signed-off-by: José Fonseca <jfonseca@vmware.com>
2010-02-27 23:44:08 +00:00
Vinson Lee
3d3e3a56f2 r300: Add asserts to check for null pointer dereferences. 2010-02-27 15:36:11 -08:00
Vinson Lee
5c007f42a1 savage: Add assert to check for null pointer dereference. 2010-02-27 15:29:44 -08:00
Vinson Lee
9db6a70af5 sis: Add assert to check function pointer is not null. 2010-02-27 15:13:38 -08:00
Vinson Lee
b22437937f tdfx: Add asserts to check for null pointer dereferences. 2010-02-27 15:07:30 -08:00
Vinson Lee
e31a379661 unichrome: Assert that pointer is not null before dereferencing. 2010-02-27 14:56:27 -08:00
José Fonseca
1eba490202 util: Fix X8/A8B8G8R8_SNORM's swizzle. 2010-02-27 20:29:14 +00:00
José Fonseca
5b3c0c151b progs/gallium: Add unit tests for pixel format packing/unpacking. 2010-02-27 20:29:14 +00:00
Marek Olšák
74f94e8fdf r300g: move the emission of GA_POINT_MINMAX into emit_fb_state
The only practical limits are the ones derived from the currently-set
framebuffer state.
2010-02-27 20:09:38 +01:00
Marek Olšák
a3d4d0dec2 r300g: put the emission of R300_US_OUT_FMT_UNUSED back
It wasn't such a good idea to remove it. :/
2010-02-27 20:09:38 +01:00
Marek Olšák
f129a7dd68 r300g: mark rasterizer_state as dirty only when it's not NULL 2010-02-27 20:08:46 +01:00
Marek Olšák
c05f998f02 radeong: clean up includes 2010-02-27 18:40:47 +01:00
Marek Olšák
93da152209 r300g: always emit the correct max vertex index to avoid DRM errors
Fixing bizarre reports that a vertex buffer is not large enough.
2010-02-27 18:39:35 +01:00
Marek Olšák
dba7ad8953 r300g: remove pointless "while" 2010-02-27 18:37:44 +01:00
Vinson Lee
d3004d9156 radeon: Assert pointer is not null before dereferencing.
Add back an assert that was removed in commit
cd5f167353.
2010-02-27 02:28:00 -08:00
Vinson Lee
e63f532d26 dri: Assert pointer is not null before dereferencing. 2010-02-27 02:18:06 -08:00
Vinson Lee
307071fe1e st/dri: Assert pointer is not null before dereferencing. 2010-02-27 02:01:56 -08:00
Vinson Lee
226d981738 r600: Assert pointer is not null before dereferencing. 2010-02-27 01:52:46 -08:00
Vinson Lee
24a8b470ba glsl: Assert input to strcmp is not null. 2010-02-27 00:31:14 -08:00
Vinson Lee
fd29be3831 glsl: Assert pointer is not null before dereferencing. 2010-02-27 00:08:14 -08:00
Vinson Lee
be97d2c0a6 mesa: Remove unnecessary header. 2010-02-26 23:58:59 -08:00
Jakob Bornecrantz
bbefd86125 st/xorg: Re-enable crtc on resize 2010-02-27 02:12:48 +00:00
Jakob Bornecrantz
122b472814 st/xorg: Fix copy-topy 2010-02-27 02:12:48 +00:00
Jakob Bornecrantz
cfbf75670d vmware/xorg: Bump to match vmware driver 2010-02-27 02:12:48 +00:00
Jakob Bornecrantz
956cd73c23 st/xorg: Make resize fail gracefully 2010-02-27 02:12:48 +00:00
Jakob Bornecrantz
bad4b29d77 st/xorg: Obey max {width|height} from kernel and Gallium 2010-02-27 02:12:48 +00:00
Thomas Hellstrom
55e5737bae st/xorg: Encapsulate all customizable stuff in a separate class.
This avoids exposing the ms driver structure to the winsys,
and nicely encapsulates driver customizable stuff.
In the future more things might be customizable by the winsys, like
throttling, 3D readback etc.

Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
2010-02-27 02:12:47 +00:00
Jakob Bornecrantz
ab8a232b2c vmware/xorg: Export modinfo just as the other vmware X drivers does 2010-02-27 02:12:47 +00:00
Jakob Bornecrantz
dfe0cc4b02 st/xorg: A bit more debugging info 2010-02-27 02:12:47 +00:00
Jakob Bornecrantz
1eb5b42097 st/xorg: Make default of debugging fallbacks smart
Set it to the same as 2d acceleration
2010-02-27 02:12:47 +00:00
Jakob Bornecrantz
d11f9a7bd8 drm/vmware: Latest interface changes are backwards incopatible
Since the execbuffer change actually changed size off the ioctl
struct and not just a reuse of padded bits, we can't support
old kernels as easily as the scanout change was.
2010-02-27 02:12:47 +00:00
Thomas Hellstrom
0a1b760cd2 st/xorg, vmware/xorg: Fix xnfcalloc arguments.
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
2010-02-27 02:12:47 +00:00
Thomas Hellstrom
4fd43b0922 vmware: Update vmwgfx_drm.h to kernel version.
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
2010-02-27 02:12:47 +00:00
Alex Deucher
52eb2ef6bf r600: enable OQ on rv740 on drms with working pipe config 2010-02-26 15:26:51 -05:00
Klaus Schnass
424a8385e4 r600: fail to validate unsupported texture formats 2010-02-26 15:26:51 -05:00
Christoph Bumiller
d1fe9bcc3f nv40: fix include of nv04_surface_2d.h 2010-02-26 21:16:52 +01:00
Kristian Høgsberg
69a0f375cc eglinfo: Wrap extension string 2010-02-26 15:11:29 -05:00
Kristian Høgsberg
a509b8cc24 xeglgears: Add an case that exercises EGL_KHR_gl_renderbuffer_image 2010-02-26 14:52:14 -05:00
Kristian Høgsberg
557c20b309 egl_dri2: Implement EGL_KHR_gl_renderbuffer_image 2010-02-26 14:52:14 -05:00
Kristian Høgsberg
d7322c9d42 intel: Lookup requested renderbuffer in intel_create_image_from_renderbuffer
Previously we'd use the current renderbuffer.
2010-02-26 14:52:14 -05:00
Brian Paul
b056e15662 progs/tests: add compile-time option for coloring texture corners
When debugging wrap modes it's helpful to set each corner of the texture
image to a distinct color.
2010-02-26 12:32:04 -07:00
Brian Paul
f519d3d6b6 gallium: define GENERATED auxiliary files
Don't need special default dependency on u_format_pack.h anymore.
2010-02-26 12:32:04 -07:00
Brian Paul
f89c237c2c gallium: added GENERATED_SOURCES var to Makefile.template
For use in dependency checking and make clean.
2010-02-26 12:32:04 -07:00
Dan Nicholson
3a650ba3a2 progs/glsl: Ensure CFLAGS are passed during linking
Commit ab6825b3e3 fixed an issue where the
architecture option -m32 wasn't being passed to the compiler when
linking .o files. This would only fix the issue with user's building
with the hacky --enable-32-bit. The right way to fix this is to pass
CFLAGS to the linker, which the GNU make builtin rules unfortunately
don't do.

Signed-off-by: Dan Nicholson <dbn.lists@gmail.com>
Tested-by: Török Edwin <edwintorok@gmail.com>
2010-02-26 11:05:54 -08:00
Kristian Høgsberg
88c174d182 xeglgears: Clean up the code a bit
Still a mess...
2010-02-26 13:18:47 -05:00
Kristian Høgsberg
ea203de2d0 Set API dispatch pointers for OES_EGL_image functions
This chunk fell through the cracks when I rebase the EGLImage patch series.
2010-02-26 13:18:47 -05:00
Brian Paul
ac56a44d5e Revert "gallium: remove unneeded -I path from Makefile.templast"
This reverts commit d9c65ddd52.

Looks like the nouveau drivers need this.  Perhaps the drivers
could be fixed to add the extra -I path where needed.  I'll leave
that up to others.
2010-02-26 10:54:20 -07:00
Brian Paul
5ed444a7a4 gallium/nouveau: clean-up #includes 2010-02-26 10:54:05 -07:00
Brian Paul
d9c65ddd52 gallium: remove unneeded -I path from Makefile.templast 2010-02-26 10:44:41 -07:00
Brian Paul
298a035286 softpipe: fix up #includes 2010-02-26 10:43:56 -07:00
Brian Paul
3f9ec9aa96 gallium/trace: remove unneeded path prefixes on #includes 2010-02-26 10:43:19 -07:00
Brian Paul
549ce30784 gallium/identity: remove unneeded path prefixes on #includes 2010-02-26 10:43:04 -07:00
Markus Fleschutz
83f1183e76 glx: fix incorrect array stack memory allocation
The array stack space wasn't allocated to the proper size.  Fixes out of
bounds memory writes when the client/array stack depth exceeds one.

See fd.o bug 26768.
2010-02-26 10:34:21 -07:00
José Fonseca
c78f84eebb util: Define SRGB's channels as normalized.
A better approximation than uscaled...
2010-02-26 16:46:34 +00:00
José Fonseca
9beb302212 util: Code generate functions to pack and unpack a single pixel.
Should work correctly for all pixel formats except SRGB formats.

Generated code made much simpler by defining the pixel format as
a C structure. For example this is the generated structure for
PIPE_FORMAT_B6UG5SR5S_NORM:

union util_format_b6ug5sr5s_norm {
   uint16_t value;
   struct {
      int r:5;
      int g:5;
      unsigned b:6;
   } chan;
};

Not used everywhere yet because it seems compiled code is slower than
bitshift arithmetic by some misterious reason. So we should generate
bitshift arithmetic at least for the simple UNORM pixel formats.
2010-02-26 16:46:34 +00:00
José Fonseca
4757325951 util: Factor some code into u_format_parse.py 2010-02-26 16:46:34 +00:00
José Fonseca
fda9a19b34 util: Add util_bswap16. 2010-02-26 16:46:34 +00:00
José Fonseca
092010db37 util: Use python names consistent with u_format.h 2010-02-26 16:46:34 +00:00
Brian Paul
fe25476c04 mesa: fix _BaseFormat assignment in _mesa_soft_renderbuffer_storage()
The rb->InternalFormat field will be set by the caller if the allocation
succeeds.  Until then, this field's value can't be used.  Fixes a failed
assertion with FlightGear.
2010-02-26 09:03:34 -07:00
Brian Paul
e215830c38 mesa: update tarball file list, bump version string 2010-02-26 08:21:44 -07:00
Brian Paul
68205bf5b4 progs/xdemos: fix typo in glxinfo help 2010-02-26 08:17:37 -07:00
José Fonseca
8416d34279 llvmpipe: Fix lp_tile_r5g6b5_unorm_write_4ub.
Was using 32bit integer pointers instead of 16bits.
2010-02-26 10:12:53 +00:00
José Fonseca
eee21b3812 llvmpipe: Fix scons dependencies. 2010-02-26 10:12:53 +00:00
José Fonseca
e2b02ea9db util: Add is_pot() method to formats. 2010-02-26 10:12:53 +00:00
Michel Dänzer
0c20b30333 Fix up more stale references to gl(X)_API.xml which have moved.
AFAICT the getproc* stanzas in progs/{fp,trivial}/Makefile are completely
unused at this point, so just remove them.
2010-02-26 10:48:07 +01:00
Wil Reichert
2da7f1af38 fix test progs from gl_API move
Looks like these got missed.
2010-02-26 10:48:06 +01:00
José Fonseca
49f35a379d Revert "glapi: Remove unnecessary headers."
This reverts commit ead22e6a32.

This headers are not unnecessary on windows.
2010-02-26 09:09:35 +00:00
Vinson Lee
e5c691f445 r300/compiler: Assert that array index is not negative. 2010-02-26 00:17:03 -08:00
Vinson Lee
ead22e6a32 glapi: Remove unnecessary headers. 2010-02-25 23:58:45 -08:00
Vinson Lee
c76d4db252 i965: Remove unnecessary headers. 2010-02-25 23:51:05 -08:00
Brian Paul
bdbb5f8170 swrast: add 0.5 bias in tex_array_slice() per the spec 2010-02-25 20:21:39 -07:00
Brian Paul
70d5c48341 docs: GL_EXT_texture_array updates 2010-02-25 20:11:55 -07:00
Brian Paul
4db9f83612 mesa: enable GL_EXT_texture_array for sw drivers 2010-02-25 20:11:55 -07:00
Brian Paul
1f2b495b55 glsl: implement support for GL_EXT_texture_array
GL_EXT_texture_array is different from the existing GL_MESA_texture_array
support in that the former is only supported for GLSL, not fixed-function.

The shadow compare versions of the sampler functions haven't been tested
yet.  The non-shadow versions have been tested with a new piglit test.
2010-02-25 20:11:55 -07:00
Brian Paul
1edd444c2e mesa: added new extension flag for GL_EXT_texture_array 2010-02-25 20:11:54 -07:00
Brian Paul
58ab56d323 swrast: the only wrap mode for selecting texture array slices is clamp 2010-02-25 20:11:54 -07:00
Brian Paul
ac498f2dce mesa: added texture array targets in sizeof_glsl_type() 2010-02-25 20:11:54 -07:00
Brian Paul
2c1619869a mesa: added cases for texture array targets 2010-02-25 20:11:54 -07:00
Brian Paul
a8dafe713f mesa: remove redundant call to _mesa_base_fbo_format() 2010-02-25 20:11:54 -07:00
Brian Paul
a858bc393e mesa: added renderbuffer->_BaseFormat assertion 2010-02-25 20:11:54 -07:00
Eric Anholt
839e6bd8b9 i965: Try to hook up the Sandybridge URB_WRITE SEND message.
My units still hang when doing this if the VS is enabled.
2010-02-25 18:36:44 -08:00
Eric Anholt
c8e5100a39 i965: Fix up the VUE handling for SNB, and hopefully clarify comments. 2010-02-25 18:36:44 -08:00
Eric Anholt
54ea39f768 i965: Don't set a nonexistent enable bit in several SNB state pointers.
The modify bit is now usually in the instruction header.  The
exception is CC state pointers.
2010-02-25 18:36:44 -08:00
Eric Anholt
1d7aec053b i965: Lump SNB in with Ironlake for bigger VUEs.
This gets the VS to the point of accepting vertices.  \o/
2010-02-25 18:36:44 -08:00
Eric Anholt
d790564f94 i965: Fix the SNB VE valid bit.
So, when the docs say that 0 means enabled now?  That's a lie.
2010-02-25 18:36:44 -08:00
Eric Anholt
fc26f894ba intel: Fix up INTEL_NO_HW support.
This was accidentally (it seems) deleted in
5203b7227c
2010-02-25 18:36:44 -08:00
Eric Anholt
89cce536cb i965: Don't include SNB in has_negative_rhw_bug. 2010-02-25 18:36:44 -08:00
Eric Anholt
dedfc0e6e6 i965: Fix the SNB clip near VP API bit. 2010-02-25 18:36:44 -08:00
Eric Anholt
17ddb7c7e8 i965: Fix the SNB URB entry count setup. 2010-02-25 18:36:44 -08:00
George Sapountzis
9a4a219d20 drop header files and demos for dropped window systems 2010-02-26 04:02:41 +02:00
George Sapountzis
25da8e66f8 remove hack for miniglx from dri/utils.c 2010-02-26 04:02:41 +02:00
George Sapountzis
ddecefbb82 drop linux-solo configs 2010-02-26 04:02:41 +02:00
George Sapountzis
900b163a86 minor cleanup of dri/Makefile.template's after miniglx drop
also makes the WINDOW_SYSTEM configure var useless ...
2010-02-26 04:02:41 +02:00
George Sapountzis
593eb8a642 drop stray src/mesa/main/sources 2010-02-26 04:02:40 +02:00
Brian Paul
c9e8ff1976 mesa: use simplified _BaseFormat value in render-to-texture code
Fixes fd.o bug 26762.
2010-02-25 19:00:54 -07:00
Brian Paul
31ff9b0a13 util: remove a trailing semicolon in format table code 2010-02-25 18:59:00 -07:00
Török Edvin
ab6825b3e3 progs/glsl: add ARCH_FLAGS to LDLIBS
Allows building 32-bit demos on 64-bit Debian host.

Signed-off-by: Brian Paul <brianp@vmware.com>
2010-02-25 18:58:55 -07:00
Vinson Lee
3e882e943c util: Remove import of unused sys module. 2010-02-25 17:55:36 -08:00
Kristian Høgsberg
44f78eb18e Remove unused mini and mesa glu subdirectories 2010-02-25 17:40:11 -05:00
Kristian Høgsberg
b15fe60ba5 Drop unused glut subdirectories 2010-02-25 17:40:11 -05:00
Kristian Høgsberg
74377c8d1b Remove windml progs 2010-02-25 17:40:11 -05:00
Kristian Høgsberg
a9e3669683 Remove remaining miniglx references 2010-02-25 17:40:11 -05:00
Kristian Høgsberg
79aeafd3ca Drop fb, ffb and gamma dri drivers 2010-02-25 17:40:11 -05:00
Kristian Høgsberg
40c6bb58be Drop classic mesa svga driver 2010-02-25 17:40:10 -05:00
Kristian Høgsberg
e14a5b14b2 Drop glide driver 2010-02-25 17:40:10 -05:00
Kristian Høgsberg
230d263aca Remove GGI support 2010-02-25 17:40:10 -05:00
Kristian Høgsberg
b5c3199afe Remove dos driver 2010-02-25 17:40:10 -05:00
Kristian Høgsberg
97972244d5 Remove d3d driver 2010-02-25 17:40:10 -05:00
Kristian Høgsberg
4387580e50 Remove directfb support 2010-02-25 17:40:09 -05:00
Kristian Høgsberg
dadd5094bf Remove allegro driver 2010-02-25 17:40:09 -05:00
Vinson Lee
0bca812dc4 Revert "glu/sgi: Set freed pointer to NULL."
This commit breaks flightgear fgfs. A null pointer is
dereferenced in the function MakeVertex.

This reverts commit 9be414f4b9.
2010-02-25 14:26:25 -08:00
Eric Anholt
6a9705f41d Merge branch 'sandybridge'
This brings in the initial code I've been working on for bringing up
OpenGL on Sandybridge in the i965 driver.  It doesn't work yet.
2010-02-25 10:56:18 -08:00
Eric Anholt
b43cfa9c5e docs: addition of ARB_fcc to i965. 2010-02-25 10:56:00 -08:00
Eric Anholt
38c4494092 i965: Add SNB math opcode support.
This is untested at this point.
2010-02-25 10:53:08 -08:00
Eric Anholt
078e7b62f6 i965: Emit SNB FF unit state after the unit's push constants.
There's a BUN for the WM unit that says WM_STATE must immediately
follow PS_CONSTANTS, which this addresses.  Presumably other units are
roughly the same, too.
2010-02-25 10:53:08 -08:00
Eric Anholt
c791f8a1e5 i965: Set up the SNB sampler state pointers. 2010-02-25 10:53:08 -08:00
Eric Anholt
5878c841e9 i965: Set GS rendering enabled even when the GS stage is disabled.
This is copying the behavior of other drivers.
2010-02-25 10:53:08 -08:00
Eric Anholt
f69d46150c i965: Add a couple SNB state packets I saw in other batchbuffer dumps. 2010-02-25 10:53:08 -08:00
Eric Anholt
2ab3bf2fa3 i965: Re-disable the VS.
There's stuff that needs to happen in the ISA before we can play with
actually executing anything in the VS.
2010-02-25 10:53:08 -08:00
Eric Anholt
1489f108f4 i965: Fix up some Sandybridge define checks for the structure rebase. 2010-02-25 10:53:08 -08:00
Eric Anholt
591a996ab6 i965: Move PIPELINE_SELECT to the top of gen6 3d pipeline setup. 2010-02-25 10:53:08 -08:00
Eric Anholt
ab8c37fe18 i965: Untested Sandybridge WM packets. 2010-02-25 10:53:08 -08:00
Eric Anholt
737fac7ba2 i965: Hook up remaining Sandybridge state packets besides WM. 2010-02-25 10:53:08 -08:00
Eric Anholt
70be48dff6 i965: Untested Sandybridge SF setup. 2010-02-25 10:53:08 -08:00
Eric Anholt
dd743fa36f i965: Fixup Sandybridge GS packet from doc updates. 2010-02-25 10:53:08 -08:00
Eric Anholt
da577ee880 i965: Fix up Sandybridge GS reg definitions 2010-02-25 10:53:08 -08:00
Eric Anholt
a935cb2aca i965: fix typo in SNB VS defines comment 2010-02-25 10:53:08 -08:00
Eric Anholt
305b72154f i965: fix typo in SNB GS register defines 2010-02-25 10:53:08 -08:00
Eric Anholt
0fbc0b0c17 i965: Enable clip stats. 2010-02-25 10:53:07 -08:00
Eric Anholt
1ae0cb5f28 i965: Add Sandybridge viewport setup. 2010-02-25 10:53:07 -08:00
Eric Anholt
c9065cd61f i965: Enable DRAWING_RECTANGLE emit on Sandybridge. 2010-02-25 10:53:07 -08:00
Eric Anholt
64e0c586a7 i965: Add Sandybridge scissor state. 2010-02-25 10:53:07 -08:00
Eric Anholt
93fcfc8369 i965: Fix up the VF stats packet header. 2010-02-25 10:53:07 -08:00
Eric Anholt
a38096aa94 i965: Set the state base address on Sandybridge. 2010-02-25 10:53:07 -08:00
Eric Anholt
2c3d6f8e3e i965: Free gen6 state BOs on context destroy. 2010-02-25 10:53:07 -08:00
Eric Anholt
d971375bc1 i965: Giant pile of flushing to track down SNB bringup issues.
This should go away before we push the code.
2010-02-25 10:53:07 -08:00
Eric Anholt
d512aa3d6d i965: Fix some defines of gen6 regs from docs comparison. 2010-02-25 10:53:07 -08:00
Eric Anholt
040cf3fcdc i965: Add basic decode of new gen6 packet boundaries. 2010-02-25 10:53:07 -08:00
Eric Anholt
ff3997904a i965: Reconnect the index/vertex setup. 2010-02-25 10:53:07 -08:00
Eric Anholt
c9dc6d425e i965: Set up the SNB URB.
even with vs disabled, still doesn't work.
2010-02-25 10:53:06 -08:00
Eric Anholt
0da50fa670 i965: Try sending prims down the pipeline.
Now things catch on fire.
2010-02-25 10:53:06 -08:00
Eric Anholt
8485e100b8 i965: Try uploading SNB VS constants. 2010-02-25 10:53:06 -08:00
Eric Anholt
eda1b50aa1 i965: Try turning on the VS. 2010-02-25 10:53:06 -08:00
Eric Anholt
98f9666f04 i965: Get vp-tri batchbuffers running (no rendering). 2010-02-25 10:53:06 -08:00
Eric Anholt
f58fbcf761 i965: Add untested REJECT_ALL clip state. 2010-02-25 10:53:06 -08:00
Eric Anholt
520b64ddfb i965: Add untested passthrough GS setup. 2010-02-25 10:53:06 -08:00
Eric Anholt
ba882d7827 i965: Add untested Sandybridge passthrough VS setup. 2010-02-25 10:53:06 -08:00
Eric Anholt
7ee590424c i965: Start adding support for the Sandybridge CC unit. 2010-02-25 10:53:06 -08:00
Eric Anholt
9dce60f35b i965: Set up sandybridge binding table pointers but don't enable it yet.
It hangs the GPU at the clipper stage, presumably because we're lacking
other setup.
2010-02-25 10:53:06 -08:00
Eric Anholt
0b9932ffde i965: Update WM surface state setup for sandybridge's new BLEND_STATE. 2010-02-25 10:53:06 -08:00
Eric Anholt
719f2b1d85 i965: Set up sandybridge depthbuffer. 2010-02-25 10:53:06 -08:00
Eric Anholt
554a8f4026 intel: Start adding defines and some bits for sandybridge bringup. 2010-02-25 10:53:06 -08:00
Francisco Jerez
51e8a66fa1 dri/nouveau: Use the XRGB8888 hardware texture format. 2010-02-25 18:37:39 +01:00
Francisco Jerez
59ddf8ca63 dri/nouveau: Use the hardware I8 format for intensity textures. 2010-02-25 18:37:39 +01:00
Francisco Jerez
4a7e9b5df4 dri/nouveau: Implement EXT_texture_from_pixmap. 2010-02-25 18:37:38 +01:00
Francisco Jerez
a7b8d105a6 dri/nouveau: Support rectangle textures. 2010-02-25 18:37:38 +01:00
Francisco Jerez
7432ffbdfa dri/nouveau: Don't try to map a non-existent teximage. 2010-02-25 18:37:38 +01:00
Francisco Jerez
35041ec151 dri/nouveau: Add some RGB888 span functions. 2010-02-25 18:37:37 +01:00
Francisco Jerez
3ccfce85e2 dri/nouveau: Fake A8 and L8 texture support on nv04. 2010-02-25 18:37:37 +01:00
Francisco Jerez
7269a30b86 dri/nouveau: Restructure the nv[12]0 regcombiner code, and fake A8/L8 support. 2010-02-25 18:37:36 +01:00
Francisco Jerez
323e6bbb05 dri/nouveau: Try to validate textures earlier. 2010-02-25 18:37:36 +01:00
Francisco Jerez
44602bb23c dri/nouveau: Swizzle using the CPU when we hit a limitation of SIFM. 2010-02-25 18:37:35 +01:00
Francisco Jerez
e59e5e3388 dri/nouveau: Clean up the nv04 surface code a bit. 2010-02-25 18:37:35 +01:00
Francisco Jerez
1e4c0618a8 dri/nouveau: Avoid mask overflow on nv04_surface_fill. 2010-02-25 18:37:35 +01:00
Francisco Jerez
9a8e374c46 dri/nouveau: Set _BaseFormat correctly for z24s8 renderbuffers. 2010-02-25 18:37:34 +01:00
Francisco Jerez
91af398b32 dri/nouveau: Fix stencil mask handling on glClear(). 2010-02-25 18:37:34 +01:00
José Fonseca
db2e1518ff scons: Always build trace driver
There are so many state trackers and winsys that rely on it for debug
building, and trace can really build anywhere and is thin so there's no
point is making it an option.

Based on  Xavier Chantry <chantry.xavier@gmail.com>'s patch:

"I also removed the trace check in xlib SConscript which is now useless, and
that script seems to deal with the cell driver, so I added cell in the check
for supported drivers."
2010-02-25 17:02:52 +00:00
Michal Krol
aec4d225b2 python: Fix typo. 2010-02-25 16:16:25 +00:00
George Sapountzis
fec2a67e40 glapi/gen: just copy in glx/glapi 2010-02-25 17:52:05 +02:00
George Sapountzis
f1f33f9293 glapi: EXTRA_DEBUG is never defined, make this explicit 2010-02-25 17:52:05 +02:00
George Sapountzis
ec91810147 glapi: minor ugliness to be able to copy to xorg 2010-02-25 17:52:04 +02:00
Brian Paul
8ae701cbc9 docs: remove demos.html page which contained one dead link 2010-02-25 08:36:31 -07:00
Michal Krol
aa799fa2d0 tgsi: Remove dead code. 2010-02-25 15:01:10 +01:00
Chia-I Wu
2cf44390d1 mesa: Move src/mesa/glapi/dispatch.h to mesa.
glapi/dispatch.h is a core Mesa header file.  Move the header file to
main/ to make this clear.  It also becomes clear after this change that
IN_DRI_DRIVER is only used in core Mesa to enable the remap table.
2010-02-25 21:32:58 +08:00
Chia-I Wu
27d260b410 glapi: Move src/mesa/main/dispatch.c to glapi and rename.
main/dispatch.c is a glapi source file.  It is part of GLAPI_SOURCES in
sources.mak and part of glapi_sources in SConscript.  This commit moves
it to glapi/ and renames it to glapi_dispatch.c.
2010-02-25 21:32:58 +08:00
Chia-I Wu
4cb13b433c glapi: Generated GLX sources should use glapidispatch.h.
Fix glX_proto_recv.py and glX_proto_send.py, and regenerate the sources.
2010-02-25 21:32:45 +08:00
Chia-I Wu
2be1fcaafe mesa: Remove unused Makefile.{ugl,win}. 2010-02-25 21:30:51 +08:00
Chia-I Wu
6e28a4e0bc st/egl: Reduce validation round-trips in DRI2 backend.
This is similar to the changes to reduce the round-trips in ximage
backend.

When the server supports DRI_InvalidateBuffers, the event is used to
update the server stamp (this path is not tested).  Otherwise, the
server stamp is updated when flush_frontbuffer or swap_buffers is
called.  This makes sure at least the client APIs get the new buffers
when a new frame is started while skipping all round-trips during the
drawing.
2010-02-25 21:29:37 +08:00
Chia-I Wu
33b92471a7 st/egl: Reduce validation round-trips in ximage backend.
ximage_surface_validate is called several times per frame.  This commit
adds the client and server stamps to reduce the round-trips to the
server.  The idea is to bump the server stamp when flush_frontbuffer or
swap_buffers is called, and to skip the round-trip when the client stamp
is equal to the server stamp.  This makes sure the client APIs get the
new buffers when a new frame is started while skipping all round-trips
during the drawing.  To make this work, egl_g3d_validate_context is no
longer called after swap_buffers.
2010-02-25 21:29:37 +08:00
Chia-I Wu
29ec53d843 st/egl: Refactor dri2_surface_get_buffers.
Add dri2_surface_process_drawable_buffers to process the buffers
returned by the server.
2010-02-25 21:29:37 +08:00
Chia-I Wu
545ac97f9b st/egl: Add dri2InvalidateBuffers.
src/glx/dri2.c will call dri2InvalidateBuffers when
DRI2_InvalidateBuffers event is received.  This fixes a missing symbol
error, and paves the way for event-based validation.
2010-02-25 21:29:36 +08:00
Vinson Lee
cc7904ffa5 util: Assert that pointer is not null before dereferencing. 2010-02-25 02:42:41 -08:00
Vinson Lee
d553479cc4 mesa: Remove dead error condition. 2010-02-25 02:26:18 -08:00
Vinson Lee
9be414f4b9 glu/sgi: Set freed pointer to NULL. 2010-02-25 02:19:00 -08:00
Michal Krol
235c6bdf6d util: Fix blitter vertex and viewport setup. 2010-02-25 10:22:30 +01:00
Corbin Simpson
686f69bd13 r300g: Atomize vertex shader. 2010-02-24 20:02:59 -08:00
Corbin Simpson
f05d4526e3 r300g: Move CALLOCs to correct place. 2010-02-24 19:53:47 -08:00
Marek Olšák
e6632b4bf7 r300g: prevent CS overflow when emitting the draw packets
Signed-off-by: Corbin Simpson <MostAwesomeDude@gmail.com>
2010-02-24 17:11:47 -08:00
Kristian Høgsberg
b7041db8f8 xeglgears: Update help text 2010-02-24 20:08:54 -05:00
Brian Paul
bc04ae21c1 llvmpipe: clean up rasterization threads upon context destruction
Fixes glean hang, bug 26536.
2010-02-24 17:30:43 -07:00
Brian Paul
072aeb57bd vbo: remove dead code 2010-02-24 16:13:46 -07:00
Brian Paul
778276a4dd r300g: remove invalid .PHONY line
The $(COMPILER_ARCHIVE) target is not a phony target.
This solves the unconditional re-making of libr300.a
2010-02-24 15:49:13 -07:00
Brian Paul
1332ee5487 gallium: remove extra -I paths from Makefile.template 2010-02-24 15:09:57 -07:00
Vinson Lee
17efc8c05c mesa: Fix SCons build. 2010-02-24 14:00:30 -08:00
Brice Goglin
b5f7f02399 Prepare Changelog for upload 2010-02-24 22:44:25 +01:00
Brice Goglin
cfbe87746f New upstream snapshot, to avoid fd.o bug #26734 2010-02-24 22:44:03 +01:00
Brice Goglin
09dfea4380 Merge branch 'upstream-experimental' into debian-unstable 2010-02-24 22:42:33 +01:00
Brian Paul
f393d95ff2 dri: remove old assertion (see bug 26734)
(cherry picked from commit 293f4d51b4)
2010-02-24 14:06:52 -07:00
Brian Paul
293f4d51b4 dri: remove old assertion (see bug 26734) 2010-02-24 14:04:26 -07:00
Brian Paul
5046f2c195 llvmpipe: more lp_rasterizer_task parameter passing 2010-02-24 13:54:25 -07:00
Brian Paul
1c9db3c57f llvmpipe: pass fewer parameters to rasterization functions 2010-02-24 13:54:25 -07:00
Brian Paul
ab71a5e4c9 llvmpipe: added some assertions 2010-02-24 13:54:25 -07:00
Brice Goglin
d6f8c95d32 New upstream snapshot 2010-02-24 20:53:58 +01:00
Brice Goglin
fec3df9cfb Merge branch 'upstream-experimental' into debian-experimental
Conflicts:
	scons/crossmingw.py
	scons/gallium.py
2010-02-24 20:51:54 +01:00
Kristian Høgsberg
f272a780af xeglgears: Remove borrowed GL_OES_EGL_image types
These are now in gl.h.
2010-02-24 14:36:56 -05:00
Kristian Høgsberg
61cc18a866 xeglgears: Add test case for texturing from an EGLImage 2010-02-24 14:28:42 -05:00
Kristian Høgsberg
f4e7d1b1e5 egl_dri2: Implement EGL_KHR_image and EGL_KHR_image_pixmap 2010-02-24 14:28:42 -05:00
Kristian Høgsberg
10e7962741 intel: Implement GL_OES_EGL_image entrypoints 2010-02-24 14:28:42 -05:00
Kristian Høgsberg
c26247100b intel: Implement DRI image extension 2010-02-24 14:28:42 -05:00
Kristian Høgsberg
79cbcb663d dri_interface.h: Add DRI image and eglImageLookup extensions
These are used for implementing the various EGLImage extensions.
2010-02-24 14:28:41 -05:00
Brian Paul
ccd78fed88 gallium: remove $(DEFINES) from cc/c++ command lines
The $(DEFINES) is already in $(CFLAG)S and (CXXFLAGS).
This prevents all the -D args appearing twice in the compilation commands.
2010-02-24 12:03:59 -07:00
Brian Paul
51b799288a mesa: put declaration before code 2010-02-24 11:57:26 -07:00
Brian Paul
9f6990120a gallium: comment/document usage flags 2010-02-24 11:56:38 -07:00
Kristian Høgsberg
d1dc5b124e core: Implement GL_OES_EGL_image entry points 2010-02-24 13:38:56 -05:00
Kristian Høgsberg
07b07b4d72 glapi: GL_OES_EGL_image autogenerated files 2010-02-24 13:38:55 -05:00
Kristian Høgsberg
caa46f7538 glapi: Add GL_OES_EGL_image 2010-02-24 13:38:55 -05:00
Brian Paul
517faa4f37 st/mesa: updated comments 2010-02-24 11:33:54 -07:00
Brian Paul
002f914211 st/mesa: consolidate redundant format conversion code 2010-02-24 11:31:33 -07:00
Brian Paul
7802ef6f69 st/mesa: more format code clean-up and removal 2010-02-24 11:23:58 -07:00
Brian Paul
d7de632de3 st/mesa: clean-ups in FBO code 2010-02-24 11:17:41 -07:00
Brian Paul
87c85347ed st/mesa: clean-up of format-related code 2010-02-24 11:10:47 -07:00
Brian Paul
5d8aae55f2 st/mesa: use util_format_get_blocksize() 2010-02-24 11:03:58 -07:00
Brian Paul
5bc62895e2 st/mesa: code clean-ups in st_renderbuffer_alloc_storage() 2010-02-24 10:56:10 -07:00
Brian Paul
f8978f186e llvmpipe: SRGB textures not supported yet 2010-02-24 10:47:58 -07:00
Brian Paul
ba92947198 llvmpipe: vertex shader textures not supported yet 2010-02-24 10:44:01 -07:00
Alex Deucher
f0e99179bc r600: update state count for CB_COLOR0_FRAG & CB_COLOR0_TILE relocs 2010-02-24 12:03:10 -05:00
Jerome Glisse
69a94e1452 r6xx/r7xx: emit relocation for FRAG & TILE buffer
FRAG & TILE buffer are unused but still they need
to be associated with a valid relocation so that
userspace can't try to abuse them to overwritte
GART and then try to write anywhere in system
memory.
2010-02-24 12:03:00 -05:00
Alex Deucher
5997501ca0 r600: proper fix for 1560183536
PRE_EMIT_STATE_BUFSZ accounts for the start 3d, idle, cd/db flush
not for state.  The relocs for CB_COLOR0_FRAG & CB_COLOR0_TILE
are part of the render target state.
2010-02-24 11:43:33 -05:00
José Fonseca
f9f4f3df42 r300: Update for UTIL_FORMAT_LAYOUT_xxx changes. 2010-02-24 16:16:21 +00:00
José Fonseca
85434f9e3c mesa: Update for UTIL_FORMAT_LAYOUT_xxx changes. 2010-02-24 16:16:21 +00:00
José Fonseca
83686b3f92 llvmpipe: Update for UTIL_FORMAT_LAYOUT_xxx changes. 2010-02-24 16:16:21 +00:00
José Fonseca
e5a43ac594 gallivm: Update for UTIL_FORMAT_LAYOUT_xxx changes. 2010-02-24 16:16:21 +00:00
José Fonseca
816d23505a util: Kill array vs arith layouts. Revamp UTIL_FORMAT_LAYOUT_xxx.
Too confusing. I now can get the same information through other means.
2010-02-24 16:16:21 +00:00
Brian Paul
b64b78e7c3 i915g: fix a comment 2010-02-24 08:52:33 -07:00
Brian Paul
fb1834cdfd gallium/docs: clean up texture usage text, added texture geom info 2010-02-24 08:52:33 -07:00
José Fonseca
085810542f llvmpipe: Fix breakeage.
Due to the u_format.csv changes the unrolled code generator was being used
for formats it didn't support.

Bring some bugfixes from u_format_access.py too.
2010-02-24 15:45:28 +00:00
José Fonseca
1dbb5f02ae util: Refactor some code. 2010-02-24 15:45:28 +00:00
José Fonseca
3c45c4bc44 util: Cope with the fact that formats in u_format.csv are not ordered. 2010-02-24 15:45:28 +00:00
José Fonseca
943314f38f util: Factor out the code to shorten a format name. 2010-02-24 15:45:28 +00:00
José Fonseca
a9395360f2 llvmpipe: Handle correctly 24bit formats. 2010-02-24 15:45:28 +00:00
José Fonseca
395b335fa4 util: Handle correctly 24bit formats. 2010-02-24 15:45:28 +00:00
José Fonseca
5caa004829 util: Minor tweaks to ambigous/unused format descriptions. 2010-02-24 15:45:28 +00:00
José Fonseca
55f02ba364 util: Fix swizzles for SRGB formats.
Based on Marek Olšák's fix 8-bits-per-channel formats swizzles, with the
exception that the notation for several formats (the vector formats)
is actually reversed so they should be left alone.
2010-02-24 15:45:28 +00:00
José Fonseca
ba7ce0ccd4 util: Organize formats in groups. Add comments. 2010-02-24 15:45:28 +00:00
José Fonseca
b57d80da77 util: Allow '#' comments in u_format.csv. 2010-02-24 15:45:28 +00:00
Michal Krol
a9aa811af0 st/mesa: Reset clip state when clearing with quads. 2010-02-24 16:41:18 +01:00
Brian Paul
78f72d73ee mesa: disable unreachable meta mipmap gen code
More work is needed to support 3D mipmap generation.  Disable unreachable
code until then.

See bug 26722.
2010-02-24 08:14:33 -07:00
Michal Krol
5b3f8369c6 util: Reset clip state when doing blitting. 2010-02-24 15:48:30 +01:00
Michal Krol
8039ee09b8 st/mesa: Use cso context to manage clip state. 2010-02-24 15:28:41 +01:00
Michal Krol
227ae7b968 cso: Track clip state with cso context. 2010-02-24 15:16:54 +01:00
José Fonseca
573a8002d5 util: Kill unused UTIL_FORMAT_LAYOUT_SCALAR. 2010-02-24 12:15:13 +00:00
José Fonseca
4e526b42b0 llvmpipe: Kill unused UTIL_FORMAT_LAYOUT_SCALAR. 2010-02-24 12:15:13 +00:00
José Fonseca
5dce9b252b util: Store more derived data in the the format description. 2010-02-24 12:15:13 +00:00
Dave Airlie
bc7e12e5e3 radeon/r200: fix bad state emission causes kernel to do bad depth clear
The kernel lets you clear depth without getting a depth offset
from userspace, mesa used to emit state before clear, but that got
lost in the refactoring, which made the kernel bug show up. Fix
mesa driver to emit the state properly now.

cherry-pick + squash master commits.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-24 19:16:13 +10:00
Dave Airlie
3f5bac8960 radeon/r200: fix the state emission before kernel clear
this moves the emission outside the lock and adds r200 support.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-24 19:13:07 +10:00
Vinson Lee
e16f0c14f3 r600: Assert that array index is not negative. 2010-02-24 00:24:51 -08:00
Dave Airlie
b75d407369 radeon: fix bad state emission causes kernel to do bad depth clear
The kernel lets you clear depth without getting a depth offset
from userspace, mesa used to emit state before clear, but that got
lost in the refactoring, which made the kernel bug show up. Fix
mesa driver to emit the state properly now.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-24 17:19:09 +10:00
Kristian Høgsberg
db9c151d77 intel: Call intel_prepare_render() in intelMakeCurrent()
This restores old behaviour, where we end up doing a DRI2GetBuffers()
call from intelMakeCurrent().  The idea was that we could do this
lazily, just before we start rendering.  However, if we don't do the
DRI2GetBuffers() round-trip we don't get the drawable size and higher
level mesa ends up short-cutting a number of GL calls, such as glClear().
2010-02-23 23:20:07 -05:00
Brian Paul
402f54b0d1 gallivm: added clamp and int_to_float functions 2010-02-23 21:16:18 -07:00
Brian Paul
1eec90d660 llvmpipe: add lp_tile_image.c to sources 2010-02-23 21:14:48 -07:00
Brian Paul
5e321280c1 llvmpipe: whole image tile/untile functions 2010-02-23 21:14:48 -07:00
Brian Paul
b628950662 st/mesa: whitespace fixes 2010-02-23 19:02:25 -07:00
Brian Paul
cd25e436ef llvmpipe: remove Z16 format override hack 2010-02-23 18:57:18 -07:00
Brian Paul
0e7c22ff3c llvmpipe: Z16 format is not supported 2010-02-23 18:57:18 -07:00
Brian Paul
a84575cdc0 st/glx: improved depth/stencil format selection code
Actually ask the gallium screen what Z/stencil format is supported.
This will let us remove some hacks in the llvmpipe driver.
2010-02-23 18:57:18 -07:00
Brian Paul
f7830dc391 st/glx: added PIPE_FORMAT_Z24S8_UNORM code 2010-02-23 18:57:18 -07:00
Brian Paul
049b4c3405 llvmpipe: added assertions to verify that scene is empty 2010-02-23 18:57:18 -07:00
Brian Paul
c8aaa24f2d llvmpipe: added some assertions 2010-02-23 18:57:17 -07:00
George Sapountzis
295a02549d glapi: fix es after mv 2010-02-24 02:11:31 +02:00
George Sapountzis
ad520aaa87 glapi: fix code generation Makefile after mv 2010-02-24 02:11:31 +02:00
George Sapountzis
f437a67377 glapi: mv code generation to subdir
This just moves files, code generation Makefile will be fixed in next commit for easier review.
2010-02-24 02:11:30 +02:00
Marek Olšák
232f6e1761 r300g: fix texture swizzling for the SRGB formats 2010-02-24 01:00:34 +01:00
kleinerm
251bf298bf glx: Fix some typos in pointer checking for OML_sync_control entry points.
Signed-off-by: Mario Kleiner <mario.kleiner@tuebingen.mpg.de>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-02-23 13:35:05 -07:00
Luca Barbieri
2f5beb4b53 pipebuffer: slab: if size < alignment, use alignment to find bucket
If the size is lower than the alignment, we must use the alignment to
select the bucket.

Otherwise, the selected bucket won't be able to satisfy our request
and will fail.

Signed-off-by: José Fonseca <jfonseca@vmware.com>
2010-02-23 19:50:24 +00:00
Luca Barbieri
c36b912e09 pipebuffer: fix inverted signalled checking
A return of 0 means the fence is signalled.

Signed-off-by: José Fonseca <jfonseca@vmware.com>
2010-02-23 19:50:24 +00:00
Luca Barbieri
9f4f87893b pipebuffer: avoid assert due to increasing a zeroed refcnt
The cache manager stores buffers with a reference count that dropped to 0.
pipe_reference asserts in this case on debug builds,
so use pipe_reference_init instead.

Signed-off-by: José Fonseca <jfonseca@vmware.com>
2010-02-23 19:50:24 +00:00
Eric Anholt
c41cf31da8 i965: Enable GL_ARB_fragment_coord_conventions now that the GLSL is fixed.
Tested with piglit glsl-arb-fragment-coord-conventions.
2010-02-23 11:16:31 -08:00
Chia-I Wu
7d1237bc71 egl: Remove unused _EGL_SKIP_HANDLE_CHECK.
It was added to skip checking EGLDisplay, EGLSurface, and etc.  It is
never defined and the spec does not allow the checks to be skipped.
Remove it for good.
2010-02-23 22:42:46 +08:00
Chia-I Wu
58a72cd65e st/egl: Unify surface creation.
Add a new function egl_g3d_create_surface and use it to create window,
pixmap, buffer, and screen surfaces.
2010-02-23 22:42:41 +08:00
Vinson Lee
abcb6b6d01 mesa: Assert that array index is not negative. 2010-02-23 00:19:30 -08:00
Vinson Lee
83a5b7e468 glsl/apps: Assert that ftell does not return an error. 2010-02-22 23:49:50 -08:00
Vinson Lee
a0fe36a39b i965g: Add fallthrough comments in switch statement.
Silences warnings about missing break statements in static analysis.
2010-02-22 23:32:43 -08:00
Vinson Lee
6da07e45b3 draw: Remove dead code. 2010-02-22 23:23:57 -08:00
Marek Olšák
902ccfcb40 r300g: fix draw_elements for "start" != 0
Reported-by: Andre Maasikas <amaasikas@gmail.com>
2010-02-23 03:33:24 +01:00
José Fonseca
b330928549 svga: Upload user buffers only once. 2010-02-22 21:47:22 +00:00
José Fonseca
8ea7d8412c svga: Fix the guest offset of piecewise buffer DMAs.
It was being erroneously set equal to the host offset, but it should be
zero.
2010-02-22 21:47:19 +00:00
José Fonseca
066fd70639 svga: Emit a scalar rcp in shadow maps.
Small improvement in Lightsmark 2008.
2010-02-22 21:47:18 +00:00
José Fonseca
7384cdf651 svga: Don't emit zero writemasks.
This fixes a regression with Lightsmark, where more compact TGSI from Mesa
was causing a zero mask MOV to be emitted for shadow map compare, causing
problems in some backends.

Add a few more assertions to catch cases like this.
2010-02-22 21:47:15 +00:00
José Fonseca
28e80aa0b8 tgsi: Report an error when a destination has an empty writemask. 2010-02-22 21:47:07 +00:00
José Fonseca
d1a0225371 svga: Upload the dirty ranges instead of the whole buffer. 2010-02-22 21:46:42 +00:00
José Fonseca
2452921e5a svga: Break uploads of big buffers into smaller pieces.
Fixes crash in Homeworld2 which tries to create a 14MB buffer, because we
now avoid creating GMR buffers larger than 8MB to ensure progress given
we have only a 16MB pool.
2010-02-22 21:46:40 +00:00
José Fonseca
3a6e581f2f svga: Note ranges even when there is no hardware buffer around.
Not having a hardware buffer around doesn't change the fact that the
range is dirty and needs to be uploaded eventually.
2010-02-22 21:46:37 +00:00
José Fonseca
cf861335a4 svga: Further cleanup/comment svga buffer code.
Just cosmetic changes -- no behavior change.
2010-02-22 21:46:34 +00:00
José Fonseca
6390dbb373 svga: Temporarily create a sw vertex buf when failed to create a hw buf.
Many apps don't check the return of map buffer so it is better not to
fail.
2010-02-22 21:46:30 +00:00
José Fonseca
21480fb9e4 svga: Remove unused buffer download code.
Unnecessary now that we never destroy buffer storage.
2010-02-22 21:46:22 +00:00
José Fonseca
935929595c pipebuffer: Don't synchronize when checking for buffer overflows.
To avoid masking synchronization issues in debug builds.
2010-02-22 21:46:19 +00:00
José Fonseca
e9ac0fbe9b python/retrace: Dump all vertices for verbosity level 3. 2010-02-22 21:46:12 +00:00
José Fonseca
422167a9b0 svga: Prevent buffer overflow in buffer ranges.
Do this by extending the nearest range to cover the new range.

This fixes an access fault in Call of Duty which was doing many disjoint
glBufferSubData calls.
2010-02-22 21:46:09 +00:00
José Fonseca
12d5203bb3 svga: Fix PIPE_LOGICOP_INVERT.
Actually the current XOR implementation is an INVERT.

This fixes rectangle selection in Maya.
2010-02-22 21:46:00 +00:00
Michal Krol
63cb6f59ea gallium: Remove bypass_vs_clip_and_viewport from rasteriser state.
Needs testing.
2010-02-22 21:36:22 +01:00
Jakob Bornecrantz
7accf8ced6 vmware/xorg: Bump to match vmware driver 2010-02-22 20:07:06 +01:00
Jakob Bornecrantz
52d83efdbc Revert "mesa/st: Make ST_SURFACE_DEPTH index consistent with mesa's BUFFER_DEPTH."
This reverts commit 9d17ad2891.

Fun stuff so fixing exposes another bug which I'm having trouble
tracking down. So for now I'm just going to revert this untill
I can fix the real bug. Sorry about this.
2010-02-22 19:37:09 +01:00
Jakob Bornecrantz
1702db3a35 st/xorg: Make resize fail gracefully 2010-02-22 19:34:56 +01:00
Jakob Bornecrantz
fa6eee135e st/xorg: Obey max {width|height} from kernel and Gallium 2010-02-22 19:34:56 +01:00
José Fonseca
b5fa760972 svga: Upload user buffers only once. 2010-02-22 19:38:10 +00:00
José Fonseca
69cf45cdae svga: Fix the guest offset of piecewise buffer DMAs.
It was being erroneously set equal to the host offset, but it should be
zero.
2010-02-22 19:38:08 +00:00
José Fonseca
f5ffbe0bc3 svga: Emit a scalar rcp in shadow maps.
Small improvement in Lightsmark 2008.
2010-02-22 19:38:05 +00:00
José Fonseca
46d8ca023d svga: Don't emit zero writemasks.
This fixes a regression with Lightsmark, where more compact TGSI from Mesa
was causing a zero mask MOV to be emitted for shadow map compare, causing
problems in some backends.

Add a few more assertions to catch cases like this.
2010-02-22 19:38:04 +00:00
José Fonseca
9bef69782d tgsi: Report an error when a destination has an empty writemask. 2010-02-22 19:38:01 +00:00
Keith Packard
edd85bcd6b bin/mklib: Clear CDPATH to avoid damaging expand_archive output
The bash 'cd' command tends to emit random stuff to stdout when the
CDPATH variable is set, so clear it to keep extra filenames from being
emitted from the expand_archive function, which would otherwise cause
mklib to fail.

Signed-off-by: Keith Packard <keithp@keithp.com>
Reviewed-by: Dan Nicholson <dbn.lists@gmail.com>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-02-22 09:56:58 -08:00
Brian Paul
52cc3b03c3 glxinfo: Fix User error in glGetProgramivARB
glxinfo needed fixing after commit 4bccd69.

Move fragment program only parameters into their own list
so that they are not queried for a vertex program.

Signed-off-by: Xavier Chantry <chantry.xavier@gmail.com>
Signed-off-by: Brian Paul <brianp@vmware.com>

(cherry picked from commit b0e5dcb859)
2010-02-22 08:56:18 -07:00
Xavier Chantry
b0e5dcb859 glxinfo: Fix User error in glGetProgramivARB
glxinfo needed fixing after commit 4bccd69.

Move fragment program only parameters into their own list
so that they are not queried for a vertex program.

Signed-off-by: Xavier Chantry <chantry.xavier@gmail.com>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-02-22 08:53:03 -07:00
Brian Paul
2467354842 i965g: added missing texture cap queries 2010-02-22 08:14:14 -07:00
Brian Paul
98e2f6c38b i915g: added missing texture cap queries 2010-02-22 08:14:05 -07:00
Brian Paul
cfdd1ca695 st/mesa: change viewport Z scale/bias for glBitmap/glDrawPixels
This fixes incorrect Z position of glBitmap, glDraw/CopyPixels for the
svga driver.  Now we use 0.5, 0.5 as is typical for ordinary 3D rendering.

(cherry picked from commit bcd561c667)
2010-02-22 08:04:53 -07:00
Brian Paul
504e297a2c st/mesa: Add checks for ST_SURFACE_x vs MESA_BUFFER_x
The ST_SURFACE_x values should match the Mesa BUFFER_x values.
Added some assertions to prevent future mix-ups.

(cherry picked from commit 13cbb5fff6)
2010-02-22 08:04:39 -07:00
Brian Paul
6ce5b5e115 mesa/st: Make ST_SURFACE_DEPTH index consistent with mesa's BUFFER_DEPTH.
Some st functions assume that they are identical.

(cherry picked from commit 9d17ad2891)
2010-02-22 08:04:16 -07:00
Brian Paul
bcd561c667 st/mesa: change viewport Z scale/bias for glBitmap/glDrawPixels
This fixes incorrect Z position of glBitmap, glDraw/CopyPixels for the
svga driver.  Now we use 0.5, 0.5 as is typical for ordinary 3D rendering.
2010-02-22 08:01:28 -07:00
José Fonseca
c98eced9ae scons: Control caching via new SCONS_CACHE_DIR environment variable.
This serves several purposes:
- disable caching in situations were is it useless or undesired
- share caches among all trees
- simplify purging the cache (when it's a single location)
- move the cache out of the tree, since that slows downs IDEs considerably

To retain previous behavior just define do

  export SCONS_CACHE_DIR=$PWD/build/cache

before invoking scons.
2010-02-22 11:28:55 +00:00
Chris Wilson
15904c057b intel: assert that we do not overflow the batch buffer.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-02-22 09:55:41 +00:00
Chris Wilson
415b7c7775 i915: Fix logic !gen >= 3
The effect of this was that all objects were aligned to 128 bytes
on all generations, rather than just gen2.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-02-22 09:55:41 +00:00
Chris Wilson
ac6ce53af7 i915: Remove superfluous MI_NOOP from vertex emission
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-02-22 09:55:33 +00:00
Chris Wilson
5abee283d3 intel: Check that we have a bufmgr or bail out when initializing the context.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-02-22 09:53:56 +00:00
Dave Airlie
b14548ea32 Revert "r300g: rebuild winsys/pipe buffer handling and add buffer map"
This reverts commit fff5be8e7b.

Probably went too soon with this, dileX reported OA not working for him
it works here fine, but the optimisations I wanted aren't working properly
yet so I'll fix that now.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-22 17:26:35 +10:00
Dave Airlie
fff5be8e7b r300g: rebuild winsys/pipe buffer handling and add buffer map
This creates a cleaner winsys and drop the simple screen stuff.

It makes r300g use pb_bufmgr structs and adds usage of the cached
bufmgr for vertex/index buffers.

It also avoids mapping too often.

I'm not 100% sure this is perfect but it won't find its own bugs.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-22 16:23:44 +10:00
Marek Olšák
233290f203 r3OOg: support rendering of more than 65535 vertices per draw call (almost)
The path for VAP_ALT_NUM_VERTICES is also in place (and tested)
but not enabled by default due to the missing support of this reg
in the upstream kernel.

Also, a non-zero BUFFER_BASE in the INDX_BUFFER packet3 hangs the machine.
Am I missing something? Because of this, only draw_arrays can render
more than 65535 vertices without the use of VAP_ALT_NUM_VERTICES.
2010-02-22 03:12:13 +01:00
Vinson Lee
c786df2caf i965g: Fix memory leak. 2010-02-21 15:15:52 -08:00
Vinson Lee
b7eed19efe st/mesa: Fix memory leak on out-of-memory error path. 2010-02-21 15:10:50 -08:00
Vinson Lee
8ff6790afb r300g: Remove unnecessary header. 2010-02-21 14:26:53 -08:00
Ray Kohler
701ac58a0c Link egl progs to libm as necessary.
Signed-off-by: Ray Kohler <ataraxia937@gmail.com>
2010-02-22 01:26:12 +08:00
Marek Olšák
3c244dac47 r300g: precompute framebuffer register values 2010-02-21 14:24:13 +01:00
Marek Olšák
7a087e1d6f r300g: add all missing colorbuffer formats 2010-02-21 14:24:13 +01:00
Marek Olšák
5c14fd1743 r300g: make r300_translate_texformat private
Unlikely to increase performance from inlining.

And partially expose it through r300_is_sampler_format_supported.
2010-02-21 14:24:12 +01:00
Marek Olšák
2a30c268bd r300g: re-enable SRGB formats
Ouch.
2010-02-21 14:24:12 +01:00
Brian Paul
13cbb5fff6 st/mesa: Add checks for ST_SURFACE_x vs MESA_BUFFER_x
The ST_SURFACE_x values should match the Mesa BUFFER_x values.
Added some assertions to prevent future mix-ups.
2010-02-21 12:38:46 +01:00
Thomas Hellstrom
dd8d78c908 st/xorg: Encapsulate all customizable stuff in a separate class.
This avoids exposing the ms driver structure to the winsys,
and nicely encapsulates driver customizable stuff.
In the future more things might be customizable by the winsys, like
throttling, 3D readback etc.

Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
2010-02-21 12:25:33 +01:00
Vinson Lee
7da9da190f mesa: Add assert to check for null pointer dereference. 2010-02-21 02:13:15 -08:00
Vinson Lee
d89de9c13f draw: Remove dead code. 2010-02-21 01:57:16 -08:00
Thomas Hellstrom
9d17ad2891 mesa/st: Make ST_SURFACE_DEPTH index consistent with mesa's BUFFER_DEPTH.
Some st functions assume that they are identical.
2010-02-21 10:39:38 +01:00
Vinson Lee
3194197efd i965g: Remove dead code. 2010-02-21 01:30:35 -08:00
Vinson Lee
0b83f48e82 i965g: Fix assertions that were always true.
The surface_format field is 9 bits wide which has a maximum value
of 511. BRW_SURFACEFORMAT_INVALID has a value of 4095 which exceeds
the width of the surface_format field.

This patch asserts that the format is not BRW_SURFACEFORMAT_INVALID
before assignment to the surface_format field.
2010-02-21 01:19:47 -08:00
Vinson Lee
d1aafb33b5 glsl/cl: Prevent possible buffer overflow. 2010-02-21 00:36:50 -08:00
Vinson Lee
f56c9c2b19 i965g: Fix use of out-of-scope variable. 2010-02-21 00:24:05 -08:00
Chia-I Wu
1207482a03 st/egl: Disable SHM in ximage backend.
With pipe_screen::update_buffer being called in st_validate_state, it is
likely that softpipe will flush tile caches to a detached SHM segment.
Disable SHM for now until a better solution is found.
2010-02-21 15:50:33 +08:00
Vinson Lee
f96e8a033b radeon: Silence compiler format warning. 2010-02-20 23:43:33 -08:00
Vinson Lee
ae41339d4c glsl/cl: Prevent possible string overflow. 2010-02-20 23:27:07 -08:00
Chia-I Wu
dbaa845153 st/egl: Properly convert vrefresh to refresh rate.
Some kernels have vrefresh = (refresh rate * 1000) while others don't.
Use some heuristics here.
2010-02-21 10:22:08 +08:00
Chia-I Wu
5d4d54574f st/egl: Enable extensions before adding configs.
Configs are validated before added.  The validation depends on the
extensions available.  If configs are added before enabling extensions,
configs with EGL_SCREEN_SURFACE_MESA bit set will never pass the
validation for example.
2010-02-21 10:22:08 +08:00
Chia-I Wu
719c4b0fc2 st/egl: Do not force validate when update_buffer is called.
st/mesa was changed to call pipe_screen::update_buffer in
st_validate_state.  In most cases there is no need to validate.
2010-02-21 10:22:07 +08:00
Chia-I Wu
9d88006ca6 st/egl: Clean up DRI2 surface.
Mainly to move the call to DRI2GetBuffers from dri2_surface_validate to
the new dri2_surface_update_buffers.
2010-02-21 10:22:07 +08:00
Chia-I Wu
d6b348ddd1 st/egl: Clean up ximage surface.
Mainly to move buffer allocation code from ximage_surface_validate to
the new ximage_surface_update_buffers.
2010-02-21 10:22:07 +08:00
Vinson Lee
71e3abc014 st/xlib: Add assert to check for null pointer dereference. 2010-02-20 16:23:44 -08:00
Jon TURNEY
e3114d3f0f Cygwin build fix: Fix linkage
Fix the way we make static convenience libraries, such as libmesa.a,
to be the same as linux etc.

Putting archives inside archives doesn't make the objects inside
the archive linkable, so use expand_archives() to get all the objects
inside an archive out again before linking.

Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-02-20 09:24:15 -07:00
Vinson Lee
1613735d08 gamma: Silence uninitialized variable warnings. 2010-02-20 02:29:43 -08:00
Vinson Lee
fdcad8a583 gamma: Add missing headers. 2010-02-20 02:25:29 -08:00
Vinson Lee
fbf04cef71 gamma: Remove unnecessary header. 2010-02-20 02:02:17 -08:00
Vinson Lee
b76164dced intel: Silence compiler format warnings. 2010-02-20 01:58:27 -08:00
Vinson Lee
6cfdb61f73 progs/redbook: Silence warn_unused_result warnings. 2010-02-20 01:34:16 -08:00
Vinson Lee
5fd84e0246 tgsi: ifdef out unused function micro_sqrt. 2010-02-20 00:56:32 -08:00
Vinson Lee
a45f2ec7b7 mesa: Silence compiler format warning. 2010-02-19 23:53:27 -08:00
Brian Paul
150cce6aef mesa: fix snprintf() typo 2010-02-19 13:44:12 -07:00
Brian Paul
78a0c353d0 mesa: restore _mesa_snprintf() - it's needed for Windows
This reverts part of commit 298be2b028
2010-02-19 12:56:49 -07:00
Brian Paul
8de5a292f7 mesa: casts to silence new warnings from printf() 2010-02-19 12:45:49 -07:00
Brian Paul
984b72ad5f mesa: remove abs/negate from fetch_vector1ui()
This function is only used for the NV unpack instructions.
Negate/abs make no sense and removing the code fixes Windows
compiler warnings.  Found by Karl Schultz.
2010-02-19 12:43:47 -07:00
Kristian Høgsberg
da43aa84c8 intel: Set buffer stamp before getting new buffers
This way, if we get an invalidate as we update the buffers, we
don't clobber the drawable stamp and ignore the invalidate.

Pointed-out-by: Francisco Jerez
2010-02-19 14:12:27 -05:00
Marek Olšák
f0c50345d1 r300g: fix rendering into the L8 and A8 texture formats
RB3D_COLORPITCH.COLORFORMAT.I8 stores the C2 component.
2010-02-19 20:02:41 +01:00
Kristian Høgsberg
99ae9e8d7d Drop macro wrappers for the aligned memory functions 2010-02-19 13:30:22 -05:00
Brian Paul
3ef51b4bd9 progs/tests: new zbitmap.c test to exercize Z testing of glBitmap 2010-02-19 11:12:20 -07:00
Brian Paul
e9df31fac9 progs/demos: sort filenames 2010-02-19 11:09:05 -07:00
Michal Krol
f814a497f7 tgsi: Make more exec opcodes look pretty. 2010-02-19 19:02:35 +01:00
Michal Krol
f1f7006d1f tgsi: Change prototypes of micro opcodes to explicitly indicates number of args. 2010-02-19 19:02:31 +01:00
Michal Krol
d68f024b7d tgsi: Rewrite exec implementations of NRM and NRM4. 2010-02-19 19:02:26 +01:00
Kristian Høgsberg
298be2b028 Replace the _mesa_*printf() wrappers with the plain libc versions 2010-02-19 12:32:24 -05:00
Kristian Høgsberg
32f2fd1c5d Replace _mesa_malloc, _mesa_calloc and _mesa_free with plain libc versions 2010-02-19 12:03:01 -05:00
Brian Paul
6bf1ea897f mesa: replace _mesa_bzero() with memset() 2010-02-19 08:32:36 -07:00
Brian Paul
2240ba10f3 mesa: replace old MEMSET macro with memset 2010-02-19 08:12:31 -07:00
Brian Paul
e197de56cd mesa: replace old MEMCPY macro with memcpy 2010-02-19 08:09:01 -07:00
Kenneth Graunke
2efa86ea30 Remove _mesa_memcmp in favor of plain memcmp.
This may break the SUNOS4 build, but it's no longer relevant.
2010-02-19 09:19:20 -05:00
Kenneth Graunke
26f8fad145 Remove _mesa_memset in favor of plain memset.
This may break the SUNOS4 build, but it's no longer relevant.
2010-02-19 09:18:57 -05:00
Kenneth Graunke
c7ac486261 Remove _mesa_memcpy in favor of plain memcpy.
This may break the SUNOS4 build, but it's no longer relevant.
2010-02-19 09:18:36 -05:00
Kenneth Graunke
60b0cae412 Remove _mesa_atoi in favor of plain atoi. 2010-02-19 09:18:13 -05:00
Kenneth Graunke
9d9afe9393 Remove _mesa_strncmp in favor of plain strncmp. 2010-02-19 09:17:53 -05:00
Kenneth Graunke
8d73aa6d1a Remove _mesa_strcmp in favor of plain strcmp. 2010-02-19 07:53:04 -05:00
Kenneth Graunke
21d0c70b4b Remove _mesa_strlen in favor of plain strlen. 2010-02-19 07:51:02 -05:00
Kenneth Graunke
f69d1d1438 Remove _mesa_strncpy in favor of plain strncpy. 2010-02-19 07:50:40 -05:00
Kenneth Graunke
5fcaa78912 Remove _mesa_strcpy in favor of plain strcpy. 2010-02-19 07:50:22 -05:00
Kenneth Graunke
8ff7624653 Remove _mesa_strncat in favor of plain strncat. 2010-02-19 07:49:45 -05:00
Kenneth Graunke
0aecdb6383 Remove _mesa_strstr in favor of plain strstr. 2010-02-19 07:47:48 -05:00
Corbin Simpson
71214c640c Revert "r300g: remove L8_UNORM from colorbuffer formats"
This reverts commit fc427d2343.

At least xorg uses this, and just because something is not used in
OpenGL is *never* a valid reason to remove functionality from Gallium.
If something lacks a test, go add a test, don't remove features.
2010-02-19 03:12:14 -08:00
Vinson Lee
e95948ea03 gamma: s#colormac.h#main/colormac.h# 2010-02-19 00:51:21 -08:00
Vinson Lee
24bdace350 gamma: s/gammacontext.h/gamma_context.h/ 2010-02-19 00:44:17 -08:00
Chia-I Wu
496724b869 egl: Silence warnings when compiled with -pedantic.
Just follow gcc's advices here.
2010-02-19 12:40:01 +08:00
Chia-I Wu
bef4b476d7 egl: Silence warnings in check/return macros.
The macros give warnings when compiled with -pedantic.  This commit is
based on a patch by Brian Paul, with minor changes to add do {} while(0)
and rename the check macros.
2010-02-19 12:34:18 +08:00
Marek Olšák
fc427d2343 r300g: remove L8_UNORM from colorbuffer formats
Not renderable in OpenGL anyway.
2010-02-19 04:24:01 +01:00
Brian Paul
ae7a7026c7 softpipe: fix depth testing problems
The optimized Z-test functions assumed that the array of incoming quads
are adjacent, but that's not always true.  The fragment shader can cull
intermediate quads, for example.

Now these Z-test functions can cope with non-adjacent quads.  A little bit
of performance is probably lost, but it's probably not worth worring about.

This fixes broken glBitmap() Z testing, among other things.

(cherry picked from commit d437d905e6)
2010-02-18 17:00:10 -07:00
Brian Paul
0c728030ed st/mesa: added some bitmap debug code (disabled) 2010-02-18 16:58:39 -07:00
Brian Paul
86bf224cac progs/demos: update arbocclude.c to do multiple queries at once
Issue a whole bunch of queries then get the results and render.
Draw the test object in red instead of orange if the result was not
ready when we first queried it.
2010-02-18 16:58:38 -07:00
Brian Paul
00d1d8aad3 softpipe: comments and whitespace fixes 2010-02-18 16:58:38 -07:00
Brian Paul
46b5ae7169 softpipe: const qualifiers, comments 2010-02-18 16:58:38 -07:00
Brian Paul
d437d905e6 softpipe: fix depth testing problems
The optimized Z-test functions assumed that the array of incoming quads
are adjacent, but that's not always true.  The fragment shader can cull
intermediate quads, for example.

Now these Z-test functions can cope with non-adjacent quads.  A little bit
of performance is probably lost, but it's probably not worth worring about.

This fixes broken glBitmap() Z testing, among other things.
2010-02-18 16:47:27 -07:00
Jakob Bornecrantz
2ecdc2ecec identity: Propagate api->name and api->driver_name up 2010-02-18 23:17:48 +00:00
Jakob Bornecrantz
288e4b15e0 trace: Propagate api->name up 2010-02-18 23:17:48 +00:00
Jakob Bornecrantz
1ee905bc47 pipebuffer: Include fenced buffer manager in build 2010-02-18 23:17:47 +00:00
Jesse Barnes
0032525242 i915: update render buffers at prepare_render time
We need to do this before we emit any state dependent on the current
render buffers.
2010-02-18 14:59:06 -08:00
Dan Nicholson
79cc455cb8 Revert "Make mklib propogate all errors"
This reverts commit d6f55492af.

It's both not portable and not safe to trap & exit on ERR. This will
need to use a more invasive approach that tests return code only for
selected, important commands.
2010-02-18 14:48:53 -08:00
Brian Paul
cc66847c10 mklib: remove unused -contents_of_archives(), add comments 2010-02-18 13:02:59 -07:00
Brian Paul
b69dad2921 mesa: silence mklib output for libglapi.c as for other targets 2010-02-18 12:54:28 -07:00
Jon TURNEY
d6f55492af Make mklib propogate all errors
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-02-18 12:47:01 -07:00
Brian Paul
205c9659cf mklib: Teach mklib to fail build if link fails on cygwin
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Signed-off-by: Brian Paul <brianp@vmware.com>

(cherry picked from commit 551c96979e)
2010-02-18 12:46:48 -07:00
Brian Paul
979889038e configure: PTHREADS should be defined on cygwin, as well
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Signed-off-by: Brian Paul <brianp@vmware.com>

(cherry picked from commit c1a4f249f1)
2010-02-18 12:46:12 -07:00
Jon TURNEY
551c96979e mklib: Teach mklib to fail build if link fails on cygwin
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-02-18 12:41:30 -07:00
Jon TURNEY
c1a4f249f1 configure: PTHREADS should be defined on cygwin, as well
Signed-off-by: Jon TURNEY <jon.turney@dronecode.org.uk>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-02-18 12:41:08 -07:00
José Fonseca
18ff85e91d svga: Upload the dirty ranges instead of the whole buffer. 2010-02-18 18:22:31 +00:00
José Fonseca
12617c7e30 svga: Break uploads of big buffers into smaller pieces.
Fixes crash in Homeworld2 which tries to create a 14MB buffer, because we
now avoid creating GMR buffers larger than 8MB to ensure progress given
we have only a 16MB pool.
2010-02-18 18:22:31 +00:00
José Fonseca
5dbf44953c svga: Note ranges even when there is no hardware buffer around.
Not having a hardware buffer around doesn't change the fact that the
range is dirty and needs to be uploaded eventually.
2010-02-18 18:22:31 +00:00
José Fonseca
a51d638ff3 svga: Further cleanup/comment svga buffer code.
Just cosmetic changes -- no behavior change.
2010-02-18 18:22:30 +00:00
José Fonseca
770945cff4 svga: Temporarily create a sw vertex buf when failed to create a hw buf.
Many apps don't check the return of map buffer so it is better not to
fail.
2010-02-18 18:22:30 +00:00
Brian Paul
a61dce3639 swrast: fix left side clipping
Fixes bug 26623.  Original patch was submitted by Mathias Frohlich
and modified by Brian.

(cherry picked from commit 7c34c237a2)
2010-02-18 09:40:38 -07:00
Jakob Bornecrantz
eaa4066bfc vmware/xorg: Export modinfo just as the other vmware X drivers does 2010-02-18 17:07:32 +01:00
Jakob Bornecrantz
46cf606cd3 st/xorg: Fixup configure
Make sure we always test for XEXT version.
Make sure that the user has a recent version of libkms and libdrm installed.

Not that the st/xorg code requires so new versions to work but these are
needed to make a proper vmwgfx_drv.so driver which is the only real user.
2010-02-18 17:07:32 +01:00
Jakob Bornecrantz
a69a7b9688 st/xorg: A bit more debugging info 2010-02-18 16:13:18 +01:00
Jakob Bornecrantz
eb7590a0d9 st/xorg: Make default of debugging fallbacks smart
Set it to the same as 2d acceleration
2010-02-18 16:13:18 +01:00
Jakob Bornecrantz
86870a691c drm/vmware: Latest interface changes are backwards incopatible
Since the execbuffer change actually changed size off the ioctl
struct and not just a reuse of padded bits, we can't support
old kernels as easily as the scanout change was.
2010-02-18 16:13:18 +01:00
Brian Paul
7c34c237a2 swrast: fix left side clipping
Fixes bug 26623.  Original patch was submitted by Mathias Frohlich
and modified by Brian.
2010-02-18 09:37:58 -07:00
Francisco Jerez
196214bf2b Revert "st/mesa: Make the frontbuffer visible on st_flush(PIPE_FLUSH_FRAME)."
We probably don't want to propagate this condition to the pipe driver,
this reverts commit f455ca6490 and the
dri_update_buffer flush altogether until an agreement is reached.
2010-02-18 14:04:14 +01:00
Kristian Høgsberg
0aa6105711 intel: Include main/hash.h using "" instead of <> 2010-02-18 07:49:55 -05:00
Vinson Lee
82e5a11077 progs/trivial: Update .gitignore. 2010-02-18 01:24:20 -08:00
Vinson Lee
7f7b7b9a02 progs/redbook: Fix array out-of-bounds access. 2010-02-18 01:17:26 -08:00
Keith Whitwell
37e955d491 st/mesa: always call FLUSH_CURRENT before st->pipe->flush()
Undoes part of commit f455ca6 which would permit pipe->flush() to be
called while the VBO module still had its buffers mapped.  Some
drivers care deeply about this.  Sorry for not spotting this earlier.
2010-02-18 09:03:36 +00:00
Vinson Lee
64d18b819b progs/rbug: Silence printf format warning. 2010-02-17 23:22:51 -08:00
Vinson Lee
869896f162 progs/rbug: Add missing headers. 2010-02-17 23:19:24 -08:00
Vinson Lee
9f5640d10b util: Fix typo of debug_dump_float_rgba_bmp. 2010-02-17 23:10:13 -08:00
Vinson Lee
8266f1e5a5 progs/rbug: Use util_format_name(). 2010-02-17 22:55:16 -08:00
Vinson Lee
20a11722a2 progs/rbug: Add missing header. 2010-02-17 22:10:04 -08:00
Vinson Lee
56b7a6f632 progs/rbug: s/read/rbug_read/
read conflicts with read in /usr/include/unistd.h.
2010-02-17 21:50:38 -08:00
Vinson Lee
3f7af84405 svga: Silence uninitialized variable warnings. 2010-02-17 21:39:24 -08:00
Marek Olšák
ca0e88ce92 r300g: add support for all missing non-FP sampler formats
The idea is to directly parse the format description in
r300_translate_texformat and return ~0 if the format is unsupported.
2010-02-18 06:37:43 +01:00
Chia-I Wu
9a939adf7d winsys/drm: Do not use --whole-archive in Makefile.egl.
--whole-archive is not portable.  Have the drivers reference _eglMain as
a poor man's --whole-archive.
2010-02-18 13:07:01 +08:00
Kristian Høgsberg
d449627829 intel: Implement the DRI2 invalidate function properly
This uses a stamp mechanisms to mark the DRI drawable as invalid.
Instead of immediately updating the buffers we just bump the drawable
stamp and call out to DRI2GetBuffers "later".

"Later" used to be at LOCK_HARDWARE time, and this patch brings back
callouts at the points where we used to call LOCK_HARDWARE.  A new function,
intel_prepare_render(), is called where we used to call LOCK_HARDWARE,
and if the buffers are invalid, we call out to DRI2GetBuffers there.

This lets us invalidate buffers only when notified instead of on
every glViewport() call.  If the loader calls the DRI invalidate
entrypoint, we disable viewport triggered buffer invalidation.

Additionally, we can clean up the old viewport mechanism a bit,
since we can just invalidate the buffers and not worry about
reentrancy and whatnot.
2010-02-17 21:53:16 -05:00
Francisco Jerez
56dcd011b5 dri/nouveau: Some multithreaded rendering fixes. 2010-02-17 23:36:29 +01:00
Francisco Jerez
52e3f0949d st/dri2: Flush FRAME instead of RENDER_CACHE on buffer invalidation. 2010-02-17 23:15:48 +01:00
Francisco Jerez
f455ca6490 st/mesa: Make the frontbuffer visible on st_flush(PIPE_FLUSH_FRAME).
So far the frontbuffer was only being flushed on st_glFlush and
st_glFinish, however, a co-state tracker may need to make sure that
any frontbuffer changes are already on its way to the actual front.

The dri2 state tracker will need this for event-driven GL applications
to resize properly (It could also be done calling "dri_flush_frontbuffer",
but that way we would flush unnecessarily in the double-buffered case).

Additionally this patch avoids flushing the mesa rendering cache if
PIPE_FLUSH_RENDER_CACHE wasn't specified.
2010-02-17 23:15:48 +01:00
José Fonseca
13cd4298fb mesa: Take back some assertions.
It seems there are still some places where draw can happen with mapped
buffers... Remove the assertions since there is not much more than can
be done at this moment.

This partially reverts commit af2023e31c.
2010-02-17 20:02:32 +00:00
Ian Romanick
7ccbeb41ac Merge commit '381d5e209815235911c4aab516037c868c8f695f'
This merges the patches from the series "[PATCH 00/14] More
client-side GLX house cleaning" that were posted to the mesa3d-dev
mailing list.  See
http://marc.info/?l=mesa3d-dev&m=126582985214612&w=2

Patches 01 through 04 eliminate a bunch of annoying warnings that I
get when building Mesa.

Patch 05 fixes an inconsistency between the implementation of
glXSwapIntervalMESA and the spec.  I chose to favor the code over the
spec in this case.  This also eliminated a warning.

Patches 06 through 12 clean up the way that context creation is
performed on the client.  When support for GLX_SGIX_fbconfig and the
related GLX 1.3 functions was added, I refactored a bunch
nuts-and-bolts of context creation to CreateContext.  The refactor was
a good idea, I just didn't do it right.

Patches 13 and 14 update glxgears_fbconfig to use GLX 1.3 interfaces.
2010-02-17 11:40:38 -08:00
Brian Paul
0583c29313 progs/demos: update GL version test to accept GL 3.x 2010-02-17 09:02:33 -07:00
Brian Paul
5b392ff49a glsl/apps: print usage info if insufficient args 2010-02-17 08:59:02 -07:00
Brian Paul
6b4a553dd3 st/mesa: replace conditional with assertion
Core Mesa will not call ctx->Driver.CheckQuery() if the Ready flag
is already set.
2010-02-17 08:29:01 -07:00
Chia-I Wu
f4542477cf progs/openvg: Add .gitignore.
Add all OpenVG demos to .gitignore.
2010-02-17 22:32:10 +08:00
Chia-I Wu
915d60dcf5 progs/es1: Update .gitignore.
Add xegl/bindtex to .gitignore.
2010-02-17 22:32:10 +08:00
Keith Whitwell
0c938143db llvmpipe: use ffs technique for full tiles also
Need to compute two masks here for full and partial 16x16 blocks.
Gives a further good improvement for isosurf particularly:

isosurf  97 -> 108
gears   597 -> 611
2010-02-17 12:12:41 +00:00
Chia-I Wu
e16f577142 docs: Update TODOs of egl.html.
Thread-safety is no longer a TODO item.  There are surely bugs to be
fixed though.
2010-02-17 20:00:12 +08:00
Chia-I Wu
4afe24808e egl: Revisit global data locking.
Lock the global mutex in _eglPreloadDrivers and _eglAllocScreenHandle.
Add comments to why certain pathes do not need locking.
2010-02-17 20:00:12 +08:00
Chia-I Wu
655f465467 egl: Always lock a display before using it.
This gives a simple access control to the display.  It is potentially
slow, but a finer grained mutex can always be used in the future.  The
benefit of this simple approach is that drivers need not to worry about
thread-safety.
2010-02-17 20:00:12 +08:00
Chia-I Wu
db5ce8b384 egl: Make eglGetDisplay atomic.
Merge _eglNewDisplay and _eglLinkDisplay into _eglFindDisplay.  Remove
unused _eglUnlinkDisplay.
2010-02-17 20:00:12 +08:00
Chia-I Wu
99bcb1f06d egl: Add a mutex to _EGLDisplay.
A display may be shared by multiple threads.  Add a mutex for access
control.
2010-02-17 20:00:11 +08:00
Chia-I Wu
b3bb180620 egl: eglGetError should return the status of the last call.
Use macros to record the status of the function call before returning.
This is the only way that eglGetError can return the status of the most
recent function call.
2010-02-17 20:00:11 +08:00
Chia-I Wu
3dee01a692 egl: Always record error code.
The error code denotes the success or failure of the most recent
function call.  A call to _eglError should always update the error code.
2010-02-17 20:00:11 +08:00
Chia-I Wu
aed7358e54 egl: Use new error checking macros.
Replace all uses of _EGL_DECLARE_* and _eglCheck* by _EGL_CHECK_*.
2010-02-17 20:00:11 +08:00
Chia-I Wu
f3e03e1277 egl: Add new error checking macros.
Add _EGL_CHECK_* which will replace _EGL_DECLARE_* for error checking.
Move _eglCheck* earlier in the file so that the macros and the functions
are grouped together.
2010-02-17 20:00:10 +08:00
Keith Whitwell
31c816731e llvmpipe: rework do_block_16 to use bitmasks and ffs
Some nice speedups:
   gears:  547 -> 597
   isosurf: 83 -> 98

Others like gloss unchanged.  Could do further work in this direction.
2010-02-17 11:12:04 +00:00
Michal Krol
cb66e9f2b4 glsl/pp: Remove sl_pp_get_extension_state().
Parse extension tokens to track current state of extension enables.
2010-02-17 11:22:01 +01:00
Michal Krol
27a68bd14a glsl/cl: Parse layout qualifiers only when an appropriate extension enabled. 2010-02-17 11:21:59 +01:00
Michal Krol
a21215a74e glsl/cl: Properly emit layout qualifier list. 2010-02-17 11:21:58 +01:00
Vinson Lee
ba0ac64f06 glsl: Silence unused value warning. 2010-02-17 02:10:49 -08:00
Vinson Lee
7eaf33ad03 progs/redbook: Fix memory leaks on error paths. 2010-02-17 01:57:14 -08:00
Johannes Obermayr
41b19c279a nouveau: fix legacy dri driver build 2010-02-17 16:16:50 +10:00
José Fonseca
3b724f91c5 svga: Remove unused buffer download code.
Unnecessary now that we never destroy buffer storage.
2010-02-16 21:24:38 +00:00
José Fonseca
2077f375c7 pipebuffer: Don't synchronize when checking for buffer overflows.
To avoid masking synchronization issues in debug builds.
2010-02-16 21:00:15 +00:00
Michal Krol
055265b0a3 svga: Translate point_sprite rasterizer state. 2010-02-16 19:53:13 +01:00
Brian Paul
de5928a615 sl/pp: re-do extension testing code
The #extension directive should not effect which extension preprocessor
symbols are defined/undefined; only whether/how the compiler accepts
language features defined by the extension.
2010-02-16 10:43:36 -07:00
Francisco Jerez
f7aea808a4 nv40: Fix incorrect so_new() numbering. 2010-02-16 18:37:43 +01:00
Francisco Jerez
8bd62dbd7c nv40: Implement PIPE_CAP_MAX_COMBINED_SAMPLERS. 2010-02-16 18:36:47 +01:00
Kristian Høgsberg
846cf49522 glx: Fix a couple of warnings 2010-02-16 10:38:50 -05:00
Kristian Høgsberg
215d0dae61 glx: Only register wire handlers for the events the server supports 2010-02-16 10:38:50 -05:00
Francisco Jerez
f845e4ff1b st/dri2: Use event-driven buffer validation. 2010-02-16 10:38:50 -05:00
Francisco Jerez
88a560691b dri/nouveau: Use event driven buffer validation. 2010-02-16 10:38:50 -05:00
Francisco Jerez
61d26bc82e dri2: Event driven buffer validation.
When a buffer invalidation event is received from the X server, the
"invalidate" hook of the DRI2 flush extension is executed: A generic
implementation (dri2InvalidateDrawable) is provided that just bumps
the "pStamp" sequence number in __DRIdrawableRec.

For old servers not supporting buffer invalidation events, the
invalidate hook will be called before flushing the fake front/back
buffer (that's typically once per frame -- not a lot worse than the
situation we were in before).

No effort has been made on preserving backwards compatibility with
version 2 of the flush extension, but I think it's acceptable because
AFAIK no released stack is making use of it.

Signed-off-by: Kristian Høgsberg <krh@bitplanet.net>
2010-02-16 10:38:50 -05:00
Kristian Høgsberg
925b901ba3 dri2: Allocate cliprect as part of the __DRIdrawableRec 2010-02-16 10:38:50 -05:00
Kristian Høgsberg
97ec6076f5 glx: Move GetGLXDRIDrawable() prototype to glxclient.h 2010-02-16 10:38:49 -05:00
Kristian Høgsberg
aa0cd707af configure.ac: Lower require dri2proto version to 2.1
Additions after 2.1 are implemented in a conditional way and will be
supported if available.
2010-02-16 10:38:49 -05:00
Brian Paul
107a2ec9ee mesa: Lock mutex around _mesa_HashLookup linked list chase.
Remove const qualifier from _mesa_HashLookup() table parameter to
avoid LOCK/UNLOCK warnings in the function body.

Signed-off-by: Brian Paul <brianp@vmware.com>

(cherry picked from commit 3094adb3ca)
2010-02-16 08:21:38 -07:00
Brian Paul
693f4af63d mesa: Test for failed malloc in _mesa_HashInsert.
Signed-off-by: Brian Paul <brianp@vmware.com>

(cherry picked from commit 7c7247ddbf)
2010-02-16 08:21:28 -07:00
Mike Stroyan
3094adb3ca mesa: Lock mutex around _mesa_HashLookup linked list chase.
Remove const qualifier from _mesa_HashLookup() table parameter to
avoid LOCK/UNLOCK warnings in the function body.

Signed-off-by: Brian Paul <brianp@vmware.com>
2010-02-16 08:18:12 -07:00
Mike Stroyan
7c7247ddbf mesa: Test for failed malloc in _mesa_HashInsert.
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-02-16 08:17:06 -07:00
José Fonseca
af2023e31c vbo: Ensure vertices are always unmapped before the context is flushed.
Purpose is two fold:

- when doing user-space memory management mapping a buffer stored in the
  graphics aperture effectively pins it there, increasing the likelyhood
  of failure of validating other buffers when flushing

- certain hardware/platform combinations do not allow a buffer to be
  simultaneously mapped and validated

This fixes assertion failures in HL Uplink with the svga driver, where
vbo was holding a map to a buffer which was also referred in the command
stream.

Note: this a non-invasive fix and shouldn't be just cherry-picked into
master as-is -- a cleaner fix for this problem should be searched.
2010-02-16 13:24:01 +00:00
José Fonseca
b0f9717105 Revert "progs/redbook: Temporarily disable the demos that extensions not part of windows to fix build."
This reverts commit 1587eff1b6.
2010-02-16 11:23:18 +00:00
Michal Krol
2eedbc94c2 slang: Fix handling of if/elif/else cases.
Once if/elif evalutes to true, all subsequent conditions are always false.
2010-02-16 10:34:07 +01:00
Michal Krol
fa8acb0528 glsl/pp: Do not try to enable extension `all'. 2010-02-16 10:04:58 +01:00
Ben Skeggs
828f545274 nv50: use hw idx buffers where we can 2010-02-16 15:57:59 +10:00
Brian Paul
c6e63f3cc2 progs/redbook: use glew 2010-02-15 18:04:39 -07:00
Ben Skeggs
bd3829b5f5 nouveau: fix for latest libdrm 2010-02-16 10:21:05 +10:00
José Fonseca
33cf477c37 wgl: Be lenient when sharing contexts.
My first reading of MS docs was wrong. It says:

  All rendering contexts of a shared display list must use an identical
  pixel format. Otherwise the results depend on the implementation of
  OpenGL used.

That is, it is OK to share contexts with different pixel formats.

Adobe Premiere Pro tries to do that: share lists between a rgbx8 and a
rgba8 pixel format.
2010-02-15 21:48:13 +00:00
José Fonseca
1587eff1b6 progs/redbook: Temporarily disable the demos that extensions not part of windows to fix build. 2010-02-15 21:47:20 +00:00
José Fonseca
8c7d39cc83 scons: A less magic way of not building progs by default.
The problem with the old way is that passing 'progs/subdir' as argument
would fail.
2010-02-15 20:48:24 +00:00
Michal Krol
ee67167358 glsl/pp: Fix handling of if/elif/else cases.
Once if/elif evalutes to true, all subsequent conditions are always false.
2010-02-15 21:33:22 +01:00
José Fonseca
672f6bb545 wgl: Be lenient when sharing contexts.
My first reading of MS docs was wrong. It says:

  All rendering contexts of a shared display list must use an identical
  pixel format. Otherwise the results depend on the implementation of
  OpenGL used.

That is, it is OK to share contexts with different pixel formats.

Adobe Premiere Pro tries to do that: share lists between a rgbx8 and a
rgba8 pixel format.
2010-02-15 19:34:38 +00:00
Brian Paul
b90f265fbf progs/redbook: test image for new redbook tests 2010-02-15 09:55:44 -07:00
Brian Paul
ce65a8debe progs/redbook: add additional tests for GL 1.4 2010-02-15 09:55:01 -07:00
Brian Paul
3be1c11001 docs: document glMultiDrawElements() fix
(cherry picked from commit ab6bcef99a)
2010-02-15 08:57:34 -07:00
Brian Paul
36a54885a4 vbo: fix broken glMultiDrawElements()
Seems to be a regression from commit 60b08eb1fd.

(cherry picked from commit c5a4cfb03f)
2010-02-15 08:57:17 -07:00
Brian Paul
ab6bcef99a docs: document glMultiDrawElements() fix 2010-02-15 08:56:39 -07:00
Brian Paul
c5a4cfb03f vbo: fix broken glMultiDrawElements()
Seems to be a regression from commit 60b08eb1fd.
2010-02-15 08:52:48 -07:00
Thomas Hellstrom
df944efdbf st/xorg, vmware/xorg: Fix xnfcalloc arguments.
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
2010-02-15 14:26:25 +01:00
Vinson Lee
e045af4146 glu/sgi: Add assert to check for null pointer dereference. 2010-02-15 02:14:02 -08:00
Vinson Lee
a05fdbcb71 mesa: Remove pointless comparison of unsigned integer with a negative constant. 2010-02-15 02:01:20 -08:00
Vinson Lee
f0e1499805 glsl/pp: Add asserts to check for null pointer deferences. 2010-02-15 00:30:31 -08:00
Vinson Lee
6536cdf183 draw: Add assert to check input of memcpy. 2010-02-14 22:58:26 -08:00
Vinson Lee
026d4b5b91 glu/sgi: Move initialization of members to top of Curve constructor.
This is a modification of commit 53d448657b.

The members cpts and spts are possibly used as arguments later in
the constructor.
2010-02-14 22:28:32 -08:00
Vinson Lee
4bbcc11f43 glu/sgi: Initialize members of class Curvelist. 2010-02-14 22:18:41 -08:00
Vinson Lee
53d448657b glu/sgi: Initialize members of class Curve. 2010-02-14 22:04:59 -08:00
Vinson Lee
9867b6eaad glu/sgi: Initialize member of class Pool. 2010-02-14 21:45:01 -08:00
Vinson Lee
86d98fa4a2 glx: Silence uninitialized variable warning. 2010-02-14 21:03:23 -08:00
Brian Paul
08cfe3ab42 st/mesa: minor assorted clean-ups 2010-02-14 21:58:45 -07:00
Brian Paul
f4ded0ea5c st/mesa: change some function return types 2010-02-14 21:57:15 -07:00
Brian Paul
e90bc2e2ce st/mesa: move per-fragment shader fields to local vars 2010-02-14 21:57:14 -07:00
Brian Paul
33681bcf56 st/mesa: use _mesa_clone_fragment_program() 2010-02-14 21:57:14 -07:00
Brian Paul
630b83be84 r600: use new program cloning functions 2010-02-14 21:57:14 -07:00
Brian Paul
79d4954f4f r300: use new program cloning functions 2010-02-14 21:57:14 -07:00
Brian Paul
7a38d8d9a5 glsl: use new program cloning functions 2010-02-14 21:57:14 -07:00
Brian Paul
848835a3d8 mesa: added _mesa_clone_vertex/fragment_program()
To reduce casting elsewhere...
2010-02-14 21:57:14 -07:00
Vinson Lee
7851856a60 r600: Silence uninitialized variable warnings. 2010-02-14 20:49:09 -08:00
Marek Olšák
d3d3345cb8 r300g: fix the size of constant buffers
4 more piglit tests pass, sweet.
2010-02-15 04:03:12 +01:00
José Fonseca
21fe86b036 python/retrace: Reconstruct blend state from binary blobs. 2010-02-15 00:25:43 +00:00
José Fonseca
e918519fe9 python: Reconstruct blend state objects from binary blobs. 2010-02-15 00:22:59 +00:00
José Fonseca
dcdf94c87c trace: Dump blend state as a binary blob.
Gallium interfaces are too fluid -- XML or not is just too much work
trying to accommodate for differences in traces.

SWIG generated bindings are also full of quirks, making unmarshalling
the XML from too hard.

Finally, this is the first step for faster tracing.
2010-02-15 00:22:29 +00:00
José Fonseca
1fc94ab3df trace: Fix constant buffer unwrapping.
Pointer unwrapping should happen before dump the pointer, so that
the real pipe driver pointers are shown, instead of the trace driver's.
2010-02-15 00:19:22 +00:00
José Fonseca
d70c769075 util: Avoid dumping masked state. Other minor improvements. 2010-02-14 23:54:22 +00:00
José Fonseca
270279ac99 os: A stream for debug logging.
Just a wrapper around os_log_message. Although it would probably make
more sense to be the other way around.

Also some comment fixes.
2010-02-14 23:53:42 +00:00
José Fonseca
d422310498 trace: No need to dump reference counts. 2010-02-14 23:25:34 +00:00
José Fonseca
c2b0484e58 python: Pretty-printing of blend state. 2010-02-14 23:25:34 +00:00
José Fonseca
165b824343 util: Helper functions to dump all state objects. 2010-02-14 23:25:34 +00:00
José Fonseca
64606231b8 os: Add a growable string stream. 2010-02-14 23:25:34 +00:00
José Fonseca
78200989d3 os: Complement/improve stream inline helpers. 2010-02-14 23:25:34 +00:00
José Fonseca
33682e5510 os: Fix bad calloc. 2010-02-14 23:25:33 +00:00
José Fonseca
dbc7b3da3e trace: Update for os_stream changes. 2010-02-14 23:25:33 +00:00
José Fonseca
323c6f8a2e util: Update for os_stream changes. 2010-02-14 23:25:33 +00:00
José Fonseca
2b4575f16d os: Make streams abstract.
Also replace windows kernel stream with null implementation. It was
severely limited and no easy means to test it now.
2010-02-14 23:25:33 +00:00
Vinson Lee
e7660a5442 glut: Silence uninitialized variable warning. 2010-02-14 13:47:58 -08:00
Vinson Lee
0b58d029b9 llvmpipe: Silence unused value warning. 2010-02-14 13:23:21 -08:00
Vinson Lee
7e64701263 svga: Silence uninitialized variable warning. 2010-02-14 13:10:08 -08:00
Marek Olšák
558c15995f r300: add half_float_vertex support 2010-02-14 21:58:52 +01:00
Pauli Nieminen
6e958832af mesa: Don't pass paramter to __builtin_clz which would hve undefined result.
__builtin_clz with parameter 0 has undefined value. When
using -O3 optimizing this would result to too large next
power of two value.

Fix is to check if passed value is 1 and modify formula
for that case.
2010-02-14 19:55:58 +02:00
Marek Olšák
7344e20ce4 r300g: set the correct tiling flags for renderbuffers
MACRO_SWITCH is applied to samplers but not renderbuffers. This commit
fixes incorrect rendering to large and small mipmaps where the large ones
are macrotiled and the small ones are not and both are emitted
in the same CS.

Note that this is still disabled by default (rework of texture transfers
is next).
2010-02-14 18:47:09 +01:00
Marek Olšák
c608e19328 r300g: add macrotiling support to texture setup 2010-02-14 18:44:33 +01:00
Marek Olšák
f7db96cd8f radeong: flush when changing tiling flags of BO referenced by CS 2010-02-14 18:20:18 +01:00
Marek Olšák
f22ddd8e47 r300g: accelerate blitting for all formats by faking the texture format 2010-02-14 18:15:13 +01:00
Brian Paul
2523172a5e src/glu/mesa: fix mem leak (bug 26559) 2010-02-14 10:05:42 -07:00
Brian Paul
d4d0629fcd src/glu/mini: fix mem leak (bug 26559) 2010-02-14 10:05:42 -07:00
Brian Paul
291bd19a1a progs/objviewer: close file (bug 26559) 2010-02-14 10:05:42 -07:00
Brian Paul
e84eec0003 progs/fp: close file (bug 26559) 2010-02-14 10:05:42 -07:00
Marek Olšák
71ac9551c4 r300g: fix texture formats: A4R4G4B4_UNORM, A1R5G5B5_UNORM, R5G6B5_UNORM 2010-02-14 17:50:29 +01:00
José Fonseca
fe889a89d2 scons: Control caching via new SCONS_CACHE_DIR environment variable.
This serves several purposes:
- disable caching in situations were is it useless or undesired
- share caches among all trees
- simplify purging the cache (when it's a single location)
- move the cache out of the tree, since that slows downs IDEs considerably

To retain previous behavior just define do

  export SCONS_CACHE_DIR=$PWD/build/cache

before invoking scons.
2010-02-14 15:34:39 +00:00
José Fonseca
abdcdb3db7 llvmpipe: s/debug_dump_/util_dump_/ 2010-02-14 15:21:06 +00:00
José Fonseca
da8de038da gallivm: s/debug_dump_/util_dump_/ 2010-02-14 15:20:57 +00:00
José Fonseca
c16a8e0dd5 util: Rename u_debug_dump.[ch] -> u_dump.[ch].
I have more plans for this than mere debugging -- it will be an helper
to provide human readible representations of all gallium state for
the python state tracker.
2010-02-14 15:20:34 +00:00
José Fonseca
db18996d3d mesa: Add missing include. 2010-02-14 13:28:29 +00:00
José Fonseca
fd3237c97d gallium: Remove previously forgotten pf_name() prototype. 2010-02-14 13:28:17 +00:00
José Fonseca
13701aae40 draw: Use util_format_name(). 2010-02-14 13:27:00 +00:00
José Fonseca
c667a5b95d util: Use util_format_name(). 2010-02-14 13:26:51 +00:00
José Fonseca
8f2b2d113f cell: Use util_format_name(). 2010-02-14 13:26:46 +00:00
José Fonseca
9189d04cdb llvmpipe: Use util_format_name(). 2010-02-14 13:26:37 +00:00
José Fonseca
db2df0aa9b nv: Use util_format_name(). 2010-02-14 13:26:30 +00:00
José Fonseca
06f76e4a6b r300g: Use util_format_name(). 2010-02-14 13:25:22 +00:00
José Fonseca
6f5e0539dc trace: Use util_format_name(). 2010-02-14 13:25:06 +00:00
José Fonseca
ee65faffc1 xorg: Use util_format_name(). 2010-02-14 13:24:58 +00:00
José Fonseca
d468791cc8 mesa: Use util_format_name(). 2010-02-14 13:24:43 +00:00
José Fonseca
5784381b1e util: Add pf_name() replacement: util_format_name(). 2010-02-14 13:23:32 +00:00
José Fonseca
c3168e050e makefiles: Don't complaint about changing configs if the same one is reselected.
Otherwise it creates unnecessary pain when automating builds in a build
server/farm.
2010-02-14 13:15:49 +00:00
José Fonseca
4ab3f0edef python/retrace: Interpret pipe_screen::context_create(). 2010-02-14 12:48:11 +00:00
José Fonseca
11a981fda1 trace: Fix generated XML. 2010-02-14 12:47:40 +00:00
José Fonseca
f1848977e8 python: Tell swig how to index per-rendertarget blend state. 2010-02-14 12:06:37 +00:00
José Fonseca
04cc5055db python: Pass p_format.h as-is to swig now that it has no inlines. 2010-02-14 11:26:58 +00:00
José Fonseca
50812e633f progs/gallium/python: New home for python statetracker scripts. 2010-02-14 11:16:41 +00:00
Vinson Lee
0a3e362175 glut: Silence uninitialized variable warning. 2010-02-14 02:04:17 -08:00
Vinson Lee
3a299071d4 r300: Silence uninitialized variable warning. 2010-02-14 00:56:57 -08:00
Vinson Lee
4f131356cc r600: Silence uninitialized variable warning. 2010-02-14 00:45:23 -08:00
Vinson Lee
ec5e54a40a glu/sgi: Initialize members of class Curvelist. 2010-02-13 23:56:48 -08:00
Vinson Lee
1462c1299c llvmpipe: Silence uninitialized variable warning. 2010-02-13 23:48:40 -08:00
Vinson Lee
71e750f482 softpipe: Silence uninitialized variable warnings. 2010-02-13 22:51:34 -08:00
Marek Olšák
260ec80f11 st/python: fix build error after gallium-screen-context merge 2010-02-14 03:20:09 +01:00
Marek Olšák
804a6d6a68 r300g: fix scons build 2010-02-14 03:20:01 +01:00
Brian Paul
85425b3b60 softpipe: fix broken cubemap / mipmap selection code
This is a quick-fix for the time being...

The per-face mipmap LOD computation was invalid at cube edges.  In
mip_filter_nearest/linear() we were trying to compute LOD using
texcoords that were sometimes indexes into different cube faces.
The subtraction used to compute the partial derivatives basically
gave random values, so the LOD was unpredictable.  This fix simply
uses the same cube face for all four pixels in the quad.  The per-
face texcoords all reference the same cube face so the partial
deriviates are computed properly.

A more elaborate fix would involve computing the LOD at the same
time as we choose the cube faces.  But for now, this solution works
well and allows the piglit/cubemap test to pass.

(cherry picked from commit 1ff9cd5079)
2010-02-13 17:47:23 -07:00
Brian Paul
1ff9cd5079 softpipe: fix broken cubemap / mipmap selection code
This is a quick-fix for the time being...

The per-face mipmap LOD computation was invalid at cube edges.  In
mip_filter_nearest/linear() we were trying to compute LOD using
texcoords that were sometimes indexes into different cube faces.
The subtraction used to compute the partial derivatives basically
gave random values, so the LOD was unpredictable.  This fix simply
uses the same cube face for all four pixels in the quad.  The per-
face texcoords all reference the same cube face so the partial
deriviates are computed properly.

A more elaborate fix would involve computing the LOD at the same
time as we choose the cube faces.  But for now, this solution works
well and allows the piglit/cubemap test to pass.
2010-02-13 17:45:05 -07:00
Karl Schultz
b30898f4ab mesa: Fix compiler warnings
Add explicit casts, fix constant types, fix variable types.
Fixes about 340 warnings in MSFT Visual Studio.
2010-02-13 17:34:04 -07:00
Brian Paul
5fd2b46a20 docs: document GL_ARB_fragment_coord_conventions 2010-02-13 14:06:25 -07:00
Brian Paul
31ed663a43 mesa: enable GL_ARB_fragment_coord_conventions for sw drivers
This extension is now implemented in the GLSL compiler so it can be
enabled by other drivers where applicable.
2010-02-13 14:03:02 -07:00
Brian Paul
c2c4935cb8 glsl: implement layout qualifiers
For GL_ARB_fragment_coord_conventions.

This only applies to gl_FragCoord and controls pixel center origin and
pixel center integer.  For example:

layout (origin_upper_left, pixel_center_integer) varying vec4 gl_FragCoord;

This features introduces the idea of re-declaring variables with a changed
type.  This may also apply to arrays in some cases but that's not
implemented at this time.
2010-02-13 13:57:33 -07:00
Brian Paul
26661ac0e1 glsl: added type layout field and new type compare func
Note: because of a weird dependency checking bug, a 'make clean' may be
needed before recompiling.
2010-02-13 13:52:39 -07:00
Brian Paul
b947b1d433 mesa: copy frag coord layout fields too 2010-02-13 13:51:38 -07:00
Brian Paul
46f788c2e5 glsl/cl: implement parsing for layout qualifiers
For GL_ARB_fragment_coord_conventions support.
2010-02-13 13:50:45 -07:00
Brian Paul
3b53b7e8b0 glsl/pp: fix incorrect extension enable flag for warn mode 2010-02-13 13:48:32 -07:00
José Fonseca
744994a9c6 mesa: Export GL_EXT_texture_cube_map.
Still used by some applications.
2010-02-13 15:44:37 +00:00
José Fonseca
a583c3ab47 wgl: Implement wglSwapMultipleBuffers. 2010-02-13 15:43:49 +00:00
José Fonseca
6b1193820f svga: Fix texture border color.
Also opposite ordering.
2010-02-13 15:43:33 +00:00
José Fonseca
4a2b54cbdb mesa: Export GL_EXT_texture_cube_map.
Still used by some applications.
2010-02-13 15:10:57 +00:00
José Fonseca
6bd6a15ab3 wgl: Implement wglSwapMultipleBuffers. 2010-02-13 15:10:57 +00:00
José Fonseca
c1a5c9bb4c svga: Fix texture border color.
Also opposite ordering.
2010-02-13 15:10:57 +00:00
Marek Olšák
43b4d2a048 r300g: do not invalidate texture caches when only sampler state is changed 2010-02-13 15:44:43 +01:00
Marek Olšák
8eb4cd5b82 r300g: cleanup the emission of RS block state
Emit as few regs as possible.
2010-02-13 15:44:43 +01:00
Marek Olšák
67049b59fd r300g: cleanup the emission of framebuffer state
Some emits are not needed anymore.
2010-02-13 15:44:43 +01:00
Marek Olšák
8e2f9f4009 r300g: disable independent blend enables
Not supported by r300.
2010-02-13 15:44:43 +01:00
Marek Olšák
75910e96dc r300g: emit INDEPENDENT_COLORFORMAT_ENABLE only on r5xx 2010-02-13 15:44:42 +01:00
Vinson Lee
bf1096a778 mesa: s/abort/sys.exit/
Python does not have the function abort.
2010-02-13 00:05:29 -08:00
Vinson Lee
672f98baf7 mesa: Remove unnecessary header. 2010-02-12 23:47:45 -08:00
Vinson Lee
1213eb6cb4 i965: Remove unnecessary headers. 2010-02-12 23:37:36 -08:00
Vinson Lee
4123df2074 st/xlib: Remove unnecessary header. 2010-02-12 23:24:22 -08:00
Vinson Lee
fcd8ffe8e1 dri: Remove unnecessary headers. 2010-02-12 23:18:08 -08:00
Vinson Lee
e7a53c78ae mesa: Remove unnecessary headers. 2010-02-12 23:04:20 -08:00
Vinson Lee
f618641631 svga: Silence uninitialized variable warning. 2010-02-12 22:33:37 -08:00
Corbin Simpson
6a07a1738c util: Properly init memory for blitter CSOs.
Fixes misrender on r300g.
2010-02-12 20:48:46 -08:00
Brian Paul
282dafcdc7 st/mesa: restore draw rasterization stage after rasterpos
This fixes invalid calls to rastpos_point/line/tri() that can occur
when glRasterPos() is called while in feedback or selection mode.

(cherry picked from commit b3c7dc6ff2)
2010-02-12 17:22:10 -07:00
Brian Paul
b3c7dc6ff2 st/mesa: restore draw rasterization stage after rasterpos
This fixes invalid calls to rastpos_point/line/tri() that can occur
when glRasterPos() is called while in feedback or selection mode.
2010-02-12 17:18:21 -07:00
José Fonseca
a4865e82ef scons: Undo bad merge from cherry-pick. 2010-02-12 23:52:18 +00:00
José Fonseca
cd5d760889 svga: A few more tweaks to blend color state emission. 2010-02-12 23:48:22 +00:00
José Fonseca
6af833add2 svga: Clamp max cube texture levels to supported max 2d levels. 2010-02-12 23:46:58 +00:00
José Fonseca
2bb4d75f28 svga: Report the 2d/3d texture sizes supported by the host. 2010-02-12 23:46:55 +00:00
José Fonseca
a80d988144 wgl: Go into dormant state when DLL is unloaded unclealy.
When our DLL is unloaded, even if we leave the data structures in memory
for sake of future calls, the MS CRT will destroy the heap. Instead we
make all calls no-ops by setting stw_dev to NULL.
2010-02-12 23:38:19 +00:00
José Fonseca
57617c8eba scons: Target Windows7. 2010-02-12 23:38:19 +00:00
José Fonseca
a1025ec041 svga: A few more tweaks to blend color state emission. 2010-02-12 23:17:04 +00:00
Brian Paul
ff37205f93 st/mesa: improved draw_range_elements code
Don't use pipe->draw_range_elements() if min_index=max_index=~0 since
that doesn't provide any useful info.

Also, implement the loop around pipe->draw_range_elements() when
nr_prims > 1.
2010-02-12 15:42:12 -07:00
Brian Paul
b9b4e7724e st/mesa: rename state -> tgsi, updated comments 2010-02-12 15:42:10 -07:00
Brian Paul
cd0a32924d st/mesa: remove unused var 2010-02-12 15:42:10 -07:00
Vinson Lee
4be324386c intel: Remove unused variable. 2010-02-12 14:37:07 -08:00
Brian Paul
2d6f5dd62b cell: fix-up C, CPP flags
Flags like -Wmissing-prototypes don't apply to g++.
2010-02-12 15:25:12 -07:00
Brian Paul
3798cc8157 cell: implement PIPE_CAP_MAX_COMBINED_SAMPLERS query 2010-02-12 15:24:24 -07:00
Brian Paul
8a61690e84 cell: remove -mcpu=cell from CFLAGS
This reverts part of commit ebe2f76095
and allows things to build here.
2010-02-12 15:16:44 -07:00
José Fonseca
3a4068474c svga: Clamp max cube texture levels to supported max 2d levels. 2010-02-12 21:31:18 +00:00
José Fonseca
1ae976be4a svga: Report the 2d/3d texture sizes supported by the host. 2010-02-12 21:31:14 +00:00
Kristian Høgsberg
2f517b8e5a intel: Avoid dri_bo_flink() in intel_update_renderbuffers()
Now that we track the global name in struct intel_region, we can just
look it up there.
2010-02-12 16:30:39 -05:00
Kristian Høgsberg
2d99588b35 intel: Track named regions and make sure we only have one region per named bo 2010-02-12 16:30:39 -05:00
Kristian Høgsberg
93931d9e68 dri: Store the loader private passed in at dri context creation
We just threw it away before, but we haven't had a use for it yet.
2010-02-12 16:30:38 -05:00
Roland Scheidegger
b685927156 svga: emit blend color 2010-02-12 22:12:55 +01:00
Zack Rusin
fd40b9ff32 st/dri: don't expose visuals we'll have trouble supporting
without getBuffersWithFormat some visuals will just cause headaches (crashes),
so if we're running on an older system simply don't advertise them.
2010-02-12 16:00:45 -05:00
Zack Rusin
59b4146a5d st/dri, st/xorg: fix buffers that have attachements of different depth
we actually need to specify the formats for different attachements, otherwise
if the color buffer is 24bpp and the app asks for 16bpp depth buffer than
we end up fetching the depth from the drawable which is 24bpp and end up
creating the wrong depth buffer. use the new getBuffersWithFormat extension
to pass the depth correctly.
2010-02-12 16:00:22 -05:00
Zack Rusin
df0c8d029d st/dri: don't expose visuals we'll have trouble supporting
without getBuffersWithFormat some visuals will just cause headaches (crashes),
so if we're running on an older system simply don't advertise them.
2010-02-12 15:49:03 -05:00
Zack Rusin
3477dc4c48 st/dri, st/xorg: fix buffers that have attachements of different depth
we actually need to specify the formats for different attachements, otherwise
if the color buffer is 24bpp and the app asks for 16bpp depth buffer than
we end up fetching the depth from the drawable which is 24bpp and end up
creating the wrong depth buffer. use the new getBuffersWithFormat extension
to pass the depth correctly.
2010-02-12 15:48:52 -05:00
Roland Scheidegger
7082c47d14 svga: enable code to emit blend color 2010-02-12 21:43:45 +01:00
Roland Scheidegger
6602889d82 Merge branch 'gallium-dynamicstencilref' 2010-02-12 21:39:29 +01:00
Vinson Lee
af1052e280 progs/tests: Add checks for GL_NV_vertex_program. 2010-02-12 11:59:37 -08:00
Jerome Glisse
3a916b0e81 Revert "r600c: substract vbo offset to vbo size"
This reverts commit 325614a882.
Ok this was already fixed this commit actualy broke things
2010-02-12 19:26:09 +01:00
Patrice Mandin
536ae20f80 nouveau: nv30: it may have 8 texture samplers (not 4), but shader engine has 16 texture units
Signed-off-by: Patrice Mandin <patmandin@gmail.com>
2010-02-12 19:22:41 +01:00
Brian Paul
0087f9dc06 cell: adjust structure padding
The size of some core Gallium state structures has changed so the
padding on some cell structs needed to be adjusted to keep them
a multiple of 16 bytes.
2010-02-12 11:07:51 -07:00
Brian Paul
e4afe725ee cell: remove unused var 2010-02-12 11:06:19 -07:00
Brian Paul
6c35e178d3 cell: include cell_context.h 2010-02-12 11:06:04 -07:00
Brian Paul
0ad0d8125a cell: re-fix undeclared var 2010-02-12 09:47:34 -07:00
Brian Paul
8a92c2b23c cell: declare stencil_value variable 2010-02-12 09:43:18 -07:00
Jerome Glisse
325614a882 r600c: substract vbo offset to vbo size
To avoid kernel complaining and to set proper boundary on
vbo, substract the vbo offset to the vbo size.
2010-02-12 17:06:19 +01:00
Andre Maasikas
0426bccadd r600: be more exact in vb size calculation
to make kernel cs checker happier, last attribs don't need full stride of
space. Calculate as count-1*stride + size of attrib
2010-02-12 10:21:44 -05:00
Andre Maasikas
841333cd21 r600: support GL_SHORT attributes
normalized seems to work with this setting.
2010-02-12 10:21:23 -05:00
Andre Maasikas
08545799e3 r600: be more exact in vb size calculation
to make kernel cs checker happier, last attribs don't need full stride of
space. Calculate as count-1*stride + size of attrib
2010-02-12 16:23:49 +02:00
Andre Maasikas
eeb49d3ad8 r600: support GL_SHORT attributes
normalized seems to work with this setting.
2010-02-12 16:23:49 +02:00
José Fonseca
e541dceb67 wgl: Go into dormant state when DLL is unloaded unclealy.
When our DLL is unloaded, even if we leave the data structures in memory
for sake of future calls, the MS CRT will destroy the heap. Instead we
make all calls no-ops by setting stw_dev to NULL.
2010-02-12 13:59:16 +00:00
Michal Krol
69dd99ba86 Revert "util: Fix descriptors for R32_FLOAT and R32G32_FLOAT formats."
This reverts commit aa0b671422.
2010-02-12 14:45:51 +01:00
José Fonseca
fea7a70a1a scons: Target Windows7. 2010-02-12 13:22:59 +00:00
Michal Krol
aa0b671422 util: Fix descriptors for R32_FLOAT and R32G32_FLOAT formats.
Fill in ones for missing components.
2010-02-12 13:32:35 +01:00
Patrice Mandin
1dd6e0b673 nouveau: nv30: Define number of texture samplers
Signed-off-by: Patrice Mandin <patmandin@gmail.com>
2010-02-12 13:23:48 +01:00
José Fonseca
e475ae920a wgl: Do not reach out and destroy contexts on cleanup.
Simply skip cleanup when contexts are still active.

This addresses two issues:

- in some situations the ICD DLL may be unloaded before the DLL that is
  using GL contexts is, so we may receive GL calls after stw_cleanup.

- when aborting (exception, or control-c) the contexts may have been left
  in an inconsistent state and attempting to destroy can cause
  unpredictable results.
2010-02-12 11:40:05 +00:00
José Fonseca
8ce747defa gdi: Never fail at DLL load time.
Windows doesn't really expect things to fail at this point -- it
will try many times until it finally gives up, worse, something bad
happens.

The WGL state tracker will gracefully decline to do work even when it
is loaded.
2010-02-12 11:40:02 +00:00
José Fonseca
e6b66210de wgl: Fail gracefully whenever 3D could not be enabled for some reason. 2010-02-12 11:39:58 +00:00
José Fonseca
ea8f7bd2e4 svgadump: Several improvements to shader dumping. 2010-02-12 11:10:41 +00:00
José Fonseca
426f607aaa wgl: Do not reach out and destroy contexts on cleanup.
Simply skip cleanup when contexts are still active.

This addresses two issues:

- in some situations the ICD DLL may be unloaded before the DLL that is
  using GL contexts is, so we may receive GL calls after stw_cleanup.

- when aborting (exception, or control-c) the contexts may have been left
  in an inconsistent state and attempting to destroy can cause
  unpredictable results.
2010-02-12 11:03:33 +00:00
Vinson Lee
d0ec18e111 glu/sgi: Initialize member of class primStream. 2010-02-12 00:41:01 -08:00
Vinson Lee
b5b1b452cd glu/sgi: Initialize members of class Arc. 2010-02-12 00:36:00 -08:00
Vinson Lee
977fa27360 glu/sgi: Initialize member of class Bin. 2010-02-12 00:28:44 -08:00
Ben Skeggs
ba3c874f08 nouveau: use AVAIL_RING() 2010-02-12 16:03:20 +10:00
Ben Skeggs
6af75a0ff4 nouveau: switch to nouveau_bo_new_tile() 2010-02-12 16:03:20 +10:00
Brian Paul
04d35714a6 svga: check min_index, max_index before assertions
It's possible for min_index and max_index to be ~0 if the min/max
values were not actually set or computed in the state tracker.
Skip some assertions in that case.

This only effects the debug build error checking.

(cherry picked from commit 408f32dc16)
2010-02-11 16:54:48 -07:00
Karl Schultz
9209843878 main: Fix compiler warning. No need to convert/store depthScale as GLfloat just to convert it back to GLuint to call unpack_depth_span.
Also removes a difference between the 24/8 and 8/24 texstore routines.
2010-02-11 16:49:41 -07:00
Brian Paul
408f32dc16 svga: check min_index, max_index before assertions
It's possible for min_index and max_index to be ~0 if the min/max
values were not actually set or computed in the state tracker.
Skip some assertions in that case.

This only effects the debug build error checking.
2010-02-11 16:47:34 -07:00
Roland Scheidegger
ebe12d5006 gallium: make max_anisotropy a unsigned bitfield member
saves us a dword in sampler state, hw can't do non-integer aniso degree anyway.
To allow aniso 1x (which seems of dubious value but some hardware (radeons)
have such a mode, and even d3d allows specifiying it) redefine anisotropic
filtering as disabled only if max_anistropy is 0.
2010-02-12 00:43:38 +01:00
Ian Romanick
381d5e2098 glxgears_fbconfig: Use glXCreateWindow and glXDestroyWindow 2010-02-11 15:40:29 -08:00
Ian Romanick
6518f6037c glxgears_fbconfig: Use GLX 1.3 name for function poiner types 2010-02-11 15:40:29 -08:00
Ian Romanick
d46d30f997 glx: Pass fbconfig ID or visual ID to CreateContext
Pass either the fbconfig ID or the visual ID, as appropriate, to
CreateContext.  Now CreateContext does not derefernce fbconfig or vis
(which no longer exists as a parameter).
2010-02-11 15:40:29 -08:00
Ian Romanick
c3db1d621e glx: Use the screen parameter everywhere instead of vis->screen, etc. 2010-02-11 15:40:29 -08:00
Ian Romanick
52cf8db428 glx: Move work of converting a visual to an fbconfig
For the direct rendering case, the DRI createContext function wants an
fbconfig.  When glXCreateContext is called, we have to convert the
visual to an fbconfig.  This work was done in CreateContext, but it
makes more sense for it to be done in glXCreateContext.
2010-02-11 15:40:29 -08:00
Ian Romanick
bc7b2f0dc3 glx: Re-indent CreateContext after the previous commit 2010-02-11 15:40:29 -08:00
Ian Romanick
2243029eee glx: Handle imported contexts outside of CreateContext
A long time ago I was a bit over-agressive in refactoring context
creation into a single function.  The creation code for
glXImportContextEXT does not belong  in CreateContext because it does
not use any GLX protocol.  The big if-statement for the import case
routed around almost the entire function anyway.
2010-02-11 15:40:29 -08:00
Ian Romanick
7bcfb66000 glx: Pass screen number as parameter to CreateContext
Passing the screen parameter to CreateContext will simplify a couple
of changes that are coming.
2010-02-11 15:40:29 -08:00
Ian Romanick
8bffadbc83 glx: Pass opcode to CreateContext instead of use_glx_1_3 parameter
Passing the opcode directly instead of having CreateContext infer it
from the value of fbconfig and the use_glx_1_3 flag will simplify some
changes that are coming.
2010-02-11 15:40:29 -08:00
Ian Romanick
68fef18439 glx: Fix interval test in glXSwapIntervalMESA
It appears that, in spite of what the spec says, the interval
parameter to glXSwapIntervalMESA has been an unsigned int since
day-1.  This made the 'if (interval < 0)' test useless.  The test is
removed and the spec is updated to note that the interval is an
unsigned value.
2010-02-11 15:40:29 -08:00
Ian Romanick
1add5354d0 glx: Change type to eliminate 'comparison between signed and unsigned' warning 2010-02-11 15:40:29 -08:00
Ian Romanick
71a6fb15ce glx: Add casts to eliminate 'comparison between signed and unsigned' warnings 2010-02-11 15:40:28 -08:00
Ian Romanick
26b2bee79d glx: Eliminate several 'unused variable' warnings in glxcmds.c. 2010-02-11 15:40:28 -08:00
Ian Romanick
2b4e009ed5 glx: Use wrapper macro to detect direct rendering
The wrapper macro GC_IS_DIRECT is used in CreateContext and a couple
other places to eliminate the need for some of the '#ifdef
GLX_DIRECT_RENDERING' madness.  There appear to be a *LOT* of places
in glxcmds.c where '#ifdef GLX_DIRECT_RENDERING' is missing.
2010-02-11 15:40:28 -08:00
Karl Schultz
2d1088cc17 Turn off 64-bit portability problems detection. 2010-02-11 15:55:04 -07:00
Roland Scheidegger
16d520f6d6 nouveau: fix compile errors... 2010-02-11 23:11:03 +01:00
Kristian Høgsberg
c7ab5994ee glapi: Avoid #including gl.h
It's only used for a couple of integer types and and might conflict
with other client API header files.
2010-02-11 17:04:06 -05:00
Kristian Høgsberg
cc57baff5f i915: Remove always-true irq_active struct intel_screen field 2010-02-11 16:56:44 -05:00
Kristian Høgsberg
c9b0f04b1f i915: Remove a few DRI1 era struct intel_screen fields 2010-02-11 16:54:20 -05:00
Kristian Høgsberg
5777dee02c i915: Drop intelScreenPrivate typedef and just call it struct intel_screen 2010-02-11 16:49:26 -05:00
Kristian Høgsberg
cbfd4147ca i915: Remove unused intelRegion struct
Phew, sure is nice to only have one struct called intel region.
2010-02-11 16:49:07 -05:00
Roland Scheidegger
67479eea36 nv50: adapt to stencil ref changes 2010-02-11 22:48:39 +01:00
Roland Scheidegger
dc8c0959bd nv40: adapt to stencil ref changes 2010-02-11 22:48:31 +01:00
Kristian Høgsberg
fa43956b5c i915: Remove left-over drmUnmap() 2010-02-11 16:34:11 -05:00
Roland Scheidegger
bedb6faec0 nv30: adapt to stencil ref changes
not sure if this has any hope of working
2010-02-11 20:55:33 +01:00
Brian Paul
362fa6763c mesa: additional constant/limit assertions 2010-02-11 11:34:54 -07:00
Brian Paul
0be04f710e svga: implement PIPE_CAP_MAX_COMBINED_SAMPLERS query 2010-02-11 11:34:54 -07:00
Roland Scheidegger
ed0f3b08b6 gallium: make u_blitter code save/restore stencil ref values 2010-02-11 19:01:10 +01:00
Karl Schultz
207ad94a89 Add git tips 2010-02-11 10:56:30 -07:00
Roland Scheidegger
bf4b0773c5 r300g: adapt to stencil ref changes 2010-02-11 18:48:57 +01:00
Roland Scheidegger
94c035f61d cell: adapt to stencil ref changes
not betting this compiles, some of the code handling stencil test seems
incomplete and/or never called?
2010-02-11 18:18:11 +01:00
Roland Scheidegger
0b659dee69 i965g: adapt to stencil ref changes
while there also potentially fix logic ops (were never enabled before)
2010-02-11 18:16:52 +01:00
Roland Scheidegger
388109c04d i915g: adapt to stencil ref changes 2010-02-11 18:16:09 +01:00
Roland Scheidegger
263406addb gallium: give pipe_stencil_ref its own cso_save/restore functions
seems cleaner, and other dynamic state like viewport is handled that way too
2010-02-11 18:15:10 +01:00
Brian Paul
6352f4c854 st/mesa: fix gallium texture level selection for RTT
Fixes invalid texture level when rendering to a texture where
GL_BASE_LEVEL > 0.

This will be cherry-picked to the 7.7 branch after additional
testing.
2010-02-11 09:40:52 -07:00
José Fonseca
94028edfc5 gdi: Never fail at DLL load time.
Windows doesn't really expect things to fail at this point -- it
will try many times until it finally gives up, worse, something bad
happens.

The WGL state tracker will gracefully decline to do work even when it
is loaded.
2010-02-11 16:38:16 +00:00
José Fonseca
7fec5f88a5 wgl: Fail gracefully whenever 3D could not be enabled for some reason. 2010-02-11 16:38:13 +00:00
Brian Paul
3c28fad20b mesa: remove darwin-x86ppc and dangling darwin refs in Makefile 2010-02-11 09:04:03 -07:00
Brian Paul
d23fefe217 docs: remove old CVS references 2010-02-11 09:02:53 -07:00
José Fonseca
be29a60f9e Revert "llvmpipe: Move tile coordinate assertion into a more useful place."
This reverts commit 8c0391726a.

Too pendantic.
2010-02-11 12:14:01 +00:00
José Fonseca
c72e8b3edd scons: Fix drm/intel build. 2010-02-11 11:51:32 +00:00
José Fonseca
9381dd590f llvmpipe: Handle TGSI_TOKEN_TYPE_PROPERTY.
Avoids assertion failures with certain shaders.
2010-02-11 11:08:30 +00:00
José Fonseca
8c0391726a llvmpipe: Move tile coordinate assertion into a more useful place. 2010-02-11 10:59:41 +00:00
José Fonseca
764c172aa9 llvmpipe: Clamp both extremes of triangles to framebuffer size.
Fix segmentation fault when triangles crossed the axis.
2010-02-11 10:58:46 +00:00
José Fonseca
128d93a009 gallivm: TGSI_OPCODE_CONT is not deprecated.
Note that with FIXME instead of an assertion failure.

Addresses fdo 25956.
2010-02-11 10:08:52 +00:00
Ben Skeggs
16a91bd2fd nouveau: remove u_simple_screen.h includes 2010-02-11 15:21:31 +10:00
Roland Scheidegger
b75adabc89 gallium: also save/restore stencil_ref in cso_save/restore_depth_stencil_alpha
makes life of state trackers easier
2010-02-11 04:06:01 +01:00
Vinson Lee
7c2634dd71 i965g: ifdef out unused functions. 2010-02-10 19:03:18 -08:00
Corbin Simpson
229db2b8ad r300g: Work around "defect" in r300compiler.
r300compiler doesn't handle half swizzles for vert shaders, which don't
have them. So, for now, disable them.
2010-02-10 18:40:12 -08:00
Vinson Lee
218590f707 st/mesa: Silence uninitialized variable warning in st_cb_bitmap.c. 2010-02-10 18:37:46 -08:00
Vinson Lee
19045d3749 swrast: Silence uninitialized variable warnings in ss_tritmp.h. 2010-02-10 18:30:46 -08:00
Vinson Lee
8df7e20788 os: Do not use Pthreads barrier functions on Mac OS X.
Pthreads barrier functions are not available on some POSIX platforms.
2010-02-10 18:12:10 -08:00
Vinson Lee
57732d83e5 ffb: Fix build. 2010-02-10 16:14:28 -08:00
Brian Paul
4b1241bf76 gallium: cast to silence waring 2010-02-10 16:44:05 -07:00
Brian Paul
f6bcce0308 gallium: use os_time.h 2010-02-10 16:43:50 -07:00
Brian Paul
bcace317c7 gallium: use os_time.h in pb_bufmgr_cache.c
Untested, but seems straightforward.
2010-02-10 16:41:43 -07:00
Brian Paul
43ba0d7451 gallium: use os_time.h in u_timed_winsys.c 2010-02-10 16:37:18 -07:00
Brian Paul
eaf3ae58a9 scons: add another prefix for mingw32 on Fedora
(cherry picked from commit f1afb352da)
2010-02-10 16:34:24 -07:00
Ian Romanick
5325340fb3 dri: Fix one last copy-and-paste brain damage from a previous commit 2010-02-10 15:16:46 -08:00
José Fonseca
2311e2adf0 scons: User friendly message for code generated files 2010-02-10 22:32:50 +00:00
Karl Schultz
2717d9066d Merge branch 'master' of git+ssh://git.freedesktop.org/git/mesa/mesa 2010-02-10 15:22:07 -07:00
Karl Schultz
450524a87c Update Visual Studio Project files to compile the shader compiler and build the prebuilt shader header files. 2010-02-10 15:21:06 -07:00
Corbin Simpson
412ffb7a3a r300g: Fix typo.
Thanks to Uros Bizjak for catching it.
2010-02-10 12:35:39 -08:00
Corbin Simpson
92ea8834d8 r300/compiler: r500-fs: Properly set HW register swizzles.
Fixes fallout from 9a1bf52c.
2010-02-10 12:35:30 -08:00
José Fonseca
f6a16dfa97 scons: Only build progs when explicitly requested in the command line. 2010-02-10 20:23:10 +00:00
Roland Scheidegger
9381a2777c svga: adapt to stencil ref changes
also add some disabled code to handle blendcolor?
2010-02-10 21:21:30 +01:00
Roland Scheidegger
6a509ec6dd llvmpipe: adapt to stencil ref changes
since the driver doesn't actually handle stencil yet the code won't do much.
2010-02-10 21:20:24 +01:00
Roland Scheidegger
4ea2f61e5a identity: adapt to stencil ref changes 2010-02-10 21:18:12 +01:00
Roland Scheidegger
5365d41895 fo: adapt to stencil ref changes 2010-02-10 21:17:46 +01:00
Roland Scheidegger
dfc02e3784 st/mesa: more fixes for stencil ref change.
compiles. Might need to do something to make it possible to save/restore
stencil ref.
2010-02-10 21:14:18 +01:00
José Fonseca
b44c444a0f llvmpipe: Map rendertargets when bound as textures.
Fixes gearbox segfault (fdo 25960). Corruption remains.
2010-02-10 20:12:44 +00:00
Ian Romanick
96728bb4f3 dri: Fix copy-and-paste brain damage in previous commit
A number of places in 3cce4a1e10 use
TRUE instead of GL_TRUE.  This causes build failures in all of the
drivers that I don't typically build.  Win.

Reported by sungami on IRC.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2010-02-10 11:43:02 -08:00
Ian Romanick
6bd9da01ea intel: Don't expose GLX_SWAP_EXCHANGE_OML
We can't always guarantee that the swap will happen by exchange, so we
can't expose this mode.  GLX_SWAP_UNDEFINED_OML already covers the
case where the swap *might be* by exchange.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kristian Høgsberg <krh@bitplanet.net>
2010-02-10 10:50:28 -08:00
Ian Romanick
bb65a1d009 intel: Expose a minimal number of configs with accumulation buffer
Expose one config per color depth that includes accumulation buffer.
We could probably expose only one config with accumulation buffer, but
that would require figuring out the actual color depth.  This is
easier and only exposes 2 useless configs.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kristian Høgsberg <krh@bitplanet.net>
2010-02-10 10:50:28 -08:00
Ian Romanick
3cce4a1e10 dri: Allow selective generation of accum. buffer configs
Modify the interface to driCreateConfigs allowing drivers to not
expose configs with an accumuation buffer.  All of the drivers calling
function have been updated to pass true for the accumulation
selector.  This maintains the current behavior.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kristian Høgsberg <krh@bitplanet.net>
Reviewed-by: Corbin Simpson <MostAwesomeDude@gmail.com>
2010-02-10 10:50:28 -08:00
Ian Romanick
73e24cd5a7 intel: Stop exposing useless 24 depth/0 stencil configs
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kristian Høgsberg <krh@bitplanet.net>
2010-02-10 10:50:28 -08:00
Ian Romanick
6d91f9a024 intel: Remove redundant init of depth_bits / stencil_bits in intelInitScreen2
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kristian Høgsberg <krh@bitplanet.net>
2010-02-10 10:50:28 -08:00
Ian Romanick
066f45c7a1 intel: Update comment in intelInitScreen2 to noting DRI2 protocol issues
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kristian Høgsberg <krh@bitplanet.net>
2010-02-10 10:50:28 -08:00
Roland Scheidegger
0786f38b46 trace: adapt to stencil ref changes 2010-02-10 19:07:26 +01:00
Roland Scheidegger
658e94578f softpipe: adapt to stencil ref changes 2010-02-10 18:59:43 +01:00
unknown
b91bb45899 Merge branch 'master' of git+ssh://git.freedesktop.org/git/mesa/mesa 2010-02-10 10:55:01 -07:00
Brian Paul
3251f31d59 glsl/pp: fix extension enable/disable options
Now the #extension name: disable/enable flags do the right thing.

Fixes glean/glsl1 "Preprocessor test (extension test 3)"
2010-02-10 10:49:50 -07:00
unknown
c3b62372db Add new symbol to exports list 2010-02-10 10:49:11 -07:00
Roland Scheidegger
903bb045b5 gallium: adapt state trackers to stencil ref change 2010-02-10 18:46:43 +01:00
Michal Krol
8b1c332a77 Simplify GLSL extension mechanism.
Since extension name and extension name string are the same, collapse
them into one name.
2010-02-10 18:04:07 +01:00
Michal Krol
c1395a71ac glsl/pp: Fix ifdef directive for extension names. 2010-02-10 17:55:29 +01:00
Brian Paul
eb095b67ad glsl: GLSL extensions have the GL_ prefix
Both the #extension directive name and the preprocessor symbol start
with the GL_ prefix.  For example:

...

New glean/glsl1 tests have been added to test the #extension feature.
2010-02-10 08:28:37 -07:00
Zack Rusin
f88b43e8d0 st/xorg: fix a silly offset bug in xv
we were multiplying the difference in the wrong direction.
2010-02-10 09:26:54 -05:00
Michal Krol
67007670bb mesa: Enable true refcounting for NullBufferObj.
This object can be shared with another context, so we cannot just
delete it when the owning context is being destroyed.

Ensuring that buffer objects are properly refcounted guarantees
NullBufferObj is destroyed when all references to it are removed.
2010-02-10 14:12:11 +01:00
Michal Krol
e8865f199d mesa: Protect buffer objects reference counting with a mutex. 2010-02-10 14:12:10 +01:00
Kristian Høgsberg
3a0e4eb94c r600: Fix typo in __DRI_TEXTURE_FORMAT_RGBA rename
Oops, I n00bed it.
2010-02-10 07:56:51 -05:00
José Fonseca
ba33fed610 llvmpipe: Fix null pointer dereference when no depth buffer is bound. 2010-02-10 11:25:26 +00:00
José Fonseca
5e6a900510 llvmpipe: Leave depth buffer in swizzled format.
This fixes several assertion failures due to only Z32 being supported.
2010-02-10 11:01:26 +00:00
Vinson Lee
7a593afa17 glu/sgi: Initialize member of class Uarray. 2010-02-10 01:25:23 -08:00
Vinson Lee
58c991a640 llvmpipe: Remove unnecessary headers. 2010-02-10 00:35:48 -08:00
Zack Rusin
08e2eab8a4 scons: export drawllvm after actually checking that llvm is present 2010-02-10 00:08:36 -05:00
Kristian Høgsberg
c19dab7c59 egl_dri2: Only allocate config if we're going to keep it
Small optimization.
2010-02-09 21:24:15 -05:00
Kristian Høgsberg
c3c1a7e1d9 egl_dri2: Initialize config attributes with visual id and class from X 2010-02-09 21:24:15 -05:00
Kristian Høgsberg
368bb3dc2b eglinfo: Also print visual type, assuming X visual types
This may not make a lot of sense for non-X EGL, but for EGL under X
it's very useful.
2010-02-09 21:24:14 -05:00
Kristian Høgsberg
360faf80ca egl_dri2: Allow pbuffer and pixmap surfaces for all configs 2010-02-09 21:24:14 -05:00
Zack Rusin
2d3262d47d st/xorg: fix a silly offset bug in xv
we were multiplying the difference in the wrong direction.
2010-02-09 21:15:22 -05:00
Pauli Nieminen
77e6fb17d9 radeon: Fix printf formatings to match te values. 2010-02-10 03:20:11 +02:00
Pauli Nieminen
42026a8ccf radeon: Define EXT_framebuffer_object constants to match hw.
This hides the assertion failure in glean/fbo test. Underlying
problem when same texture is set twice to different attachments
will cause assertion.
2010-02-10 03:20:11 +02:00
Brian Paul
4bce2fb30e mesa: move all limit/constant assertions into check_context_limits() 2010-02-09 18:08:04 -07:00
Francisco Jerez
96100f39be Drop incorrectly revived files during the 'gallium-nopointsizeminmax' merge. 2010-02-10 00:43:43 +01:00
Corbin Simpson
dbc1340191 r300g: One less assert.
This entire codepath needs to be cleaned to be more pliant towards
shader failure.
2010-02-09 13:58:53 -08:00
Thomas Hellstrom
3470d821ba vmware: Update vmwgfx_drm.h to kernel version.
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
2010-02-09 22:54:15 +01:00
Corbin Simpson
8c85002951 r300g: Don't write non-existent bit on non-r500.
Might help with compiz being funky with MRTs.
2010-02-09 13:53:30 -08:00
Corbin Simpson
67b60b9934 r300g: Correct colorbuffer measurements.
Also clarify changes from pointminmax.
2010-02-09 13:50:54 -08:00
Corbin Simpson
5a27a77d00 r300g: Be ever-so-slightly more useful on bad shaders. 2010-02-09 13:50:38 -08:00
Kristian Høgsberg
1ebc568154 configure.ac: Enable egl demos when --enable-egl is passed 2010-02-09 15:55:25 -05:00
Kristian Høgsberg
ab487f7ffa xeglgears: Add test case for eglBindTexImage() 2010-02-09 15:55:25 -05:00
Kristian Høgsberg
bba5a98dfd egl_dri2: Implement eglBindTexImage() 2010-02-09 15:55:25 -05:00
Kristian Høgsberg
debf00e5fc dri_interface: Introduce DRI tokens for the texBuffer texture formats
This used to take GLX tokens, but the DRI interface can't depend on GLX
defines.  We fix this by introducing DRI tokens that have the same value
as the GLX texture format tokens.
2010-02-09 15:55:25 -05:00
Kristian Høgsberg
8c593d3ea9 egl_dri2: Use a helper function for looking up and binding extensions 2010-02-09 15:55:24 -05:00
Roland Scheidegger
98f8c4d0bb docs: fix up documentation for stencil ref value changes
Also fix and clarify depth/stencil/alpha documentation a bit.
2010-02-09 21:48:43 +01:00
Roland Scheidegger
c59446a493 gallium: make valuemask/writemask in pipe_stencil_state bitfield members
More consistent with other state data, might allow some compilers to pack
the struct better (doesn't matter for gcc).
2010-02-09 21:26:35 +01:00
Roland Scheidegger
1a859ecf4a gallium: don't put stencil ref value in pipe_depth_stencil_alpha_state
This will make driver's life a bit harder, however it makes sense that stencil
reference value is not part of the pipe_depth_stencil_alpha_state, because
it often (there are some algorithms which require this) changes more frequently
than the rest of the dsa state. This is also encouraged by some graphic APIs.
Treat it similar to pipe_blend_color.
2010-02-09 21:23:27 +01:00
Brian Paul
ed46e90f05 gallium/auxiliary: add -D__STDC_CONSTANT_MACROS
Not sure why this is needed now, after the gallivm re-org.
2010-02-09 13:10:07 -07:00
Brian Paul
822d951b5d llvmpipe: remove .s rule (already in Makefile.template) 2010-02-09 13:08:23 -07:00
Brian Paul
aa4ed6a0e6 llvmpipe: lp_tile_surface.c isn't committed yet 2010-02-09 13:07:58 -07:00
Pauli Nieminen
4767d27ee3 radeon: Add some debug output for fbo support 2010-02-09 21:38:47 +02:00
Pauli Nieminen
9e587dbd78 r200: Fix UMS notto emit stp.
Polgon stipples are handled by kernel in UMS. Mark the
state as never to be emited for UMS.
2010-02-09 21:38:47 +02:00
Roland Scheidegger
653a83445f Merge branch 'gallium-nopointsizeminmax'
Conflicts:
	src/gallium/drivers/nv10/nv10_state.c
	src/gallium/drivers/nv20/nv20_state.c
	src/gallium/drivers/nv50/nv50_program.c
2010-02-09 19:32:21 +01:00
Brian Paul
b0613d8767 docs: fix typo: s/osdemo/osdemos/
(cherry picked from commit 0371956d66)
2010-02-09 11:21:41 -07:00
Brian Paul
0371956d66 docs: fix typo: s/osdemo/osdemos/ 2010-02-09 11:21:15 -07:00
Chris Li
a8f4904fb3 gallium: Adding the %.s rule to generate asm code
Signed-off-by: José Fonseca <jfonseca@vmware.com>
2010-02-09 17:19:30 +00:00
Chris Li
62d1e40e0d gallium: Using the proper pattern rules for Makefile template.
The .o.c rule is consider obsolete.

Signed-off-by: José Fonseca <jfonseca@vmware.com>
2010-02-09 17:19:30 +00:00
Chris Li
8b6ec94aec llvmpipe: Make llvm unit test depend on libllvmpipe.a
Signed-off-by: José Fonseca <jfonseca@vmware.com>
2010-02-09 17:19:29 +00:00
Roland Scheidegger
dd7be07c96 st/mesa: fix wrong initialization of MaxPointSize 2010-02-08 18:48:08 +01:00
Jakob Bornecrantz
3bf13656d3 st/xorg: Include cursorstr.h 2010-02-06 16:58:32 +00:00
Brian Paul
fa4083d38b docs: updates to 7.7.1 release notes 2010-03-10 14:14:04 -07:00
Brian Paul
d311ded31d gallium/util: added surface dump code for unix 2010-03-10 10:39:46 -07:00
Brian Paul
34f0207161 st/mesa: fix incorrect glCopyPixels between window/FBO
There was a DrawBuffer/ReadBuffer typo and we were neglecting to invert
the texture coords when copying from a window to an FBO.

Plus, add some surface dump/debug code (disabled).
2010-03-10 10:39:45 -07:00
Brian Paul
8d3f629a13 st/mesa: fix incorrect glDrawPixels into FBO
We weren't inverting the textured quad when drawing into an fbo.
2010-03-10 10:39:45 -07:00
Thomas Hellstrom
b98ef495d4 st/xorg Avoid advertizing rotation / reflection support.
We don't support it yet since we don't implement the shadow allocate
functions.

Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
2010-03-06 15:52:31 +01:00
Michel Dänzer
21c91b410a st/xorg: Work around cursor reference counting bugs in older X servers.
Could result in use of freed memory and consequently random crashes, e.g. on
screen resize.
2010-03-10 13:16:00 +01:00
Thomas Hellstrom
a8f3b3f88a st/xorg, vmware: Make throttling configurable.
The xorg state tracker gets two new options to let the user choose
whether to enable / disable dirty throttling and swapbuffer throttling.
The default value of these options are enabled, unless the winsys
supplies a customizer with other values. The customizer record has been
extended to allow this, and also to set winsys-based throttling on a per-
context basis.

The vmware part of this patch disables the dirty throttling if the kernel
supports command submission throttling, and also in that case sets kernel
based throttling for everything but swapbuffers. The vmware winsys does not
set throttling per context, even if it theoretically could, but instead
sets throttling per screen. This should perhaps be changed, should the
xorg state tracker start to use multiple rendering contexts. Kernel throttling
is off by default for all new screens/contexts, so the dri state tracker
is not affected.

This significantly improves interactivity of the vmware xorg driver.

Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
2010-03-06 11:03:55 +01:00
Thomas Hellstrom
e8a8c5e339 svga: Add a winsys callback to get the svga_winsys_context
The winsys may need to extract the svga_winsys_context from a
pipe_context. Add a function to enable that functionality.

Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
2010-03-06 11:03:54 +01:00
Keith Whitwell
7941d31ee6 svga: Don't do culling while the software pipeline is active.
It does it for us, and additionally introduces potentially
back-facing triangles.
2010-03-09 19:19:56 +01:00
Brian Paul
842351dd76 softpipe: zero-out entire clear_flags array in sp_tile_cache_flush_clear()
Before, we only cleared the flags for the active tiles (the ones inside
the framebuffer bound).  The problem is if we later bound a different,
larger surface to the tile cache we'd have some stale clear-flags still
set (and mistakenly clear some tiles in the new surface).

Fixes fd.o bug 26932.

(cherry picked from commit e1762fb870)
2010-03-08 11:40:40 -07:00
Brian Paul
d74929702f st/mesa: don't detach renderbuffer, surface in st_finish_render_texture()
There's no reason to release the renderbuffer from the framebuffer object
or release the gallium surface in this function (they're reference counted).
In fact, we don't want to do this because we may later use the texture as a
pixel source (ex: glBlitFramebuffer) and need the surface.

Fixes fd.o bug 26923 and is part of the fix for bug 26932.

(cherry picked from commit 80dc54e308)
2010-03-08 11:40:25 -07:00
Brian Paul
1e431f0454 mesa: s/GL_DEPTH_STENCIL/GL_DEPTH_COMPONENT/ for MESA_FORMAT_Z16 renderbuffer
MESA_FORMAT_Z16 has no stencil bits.

(cherry picked from commit 614f490ca9)
2010-03-08 10:00:17 -07:00
Alex Deucher
4cc8d1d79f r600: recalculate point size, if point min/max size changes 2010-03-08 11:31:06 -05:00
Alex Deucher
3d2bc6848a r600: no need to flush on context init 2010-03-08 11:30:54 -05:00
Maciej Cencora
d5327538e7 r300: recalculate point size, if point min/max size changes
Fixes two wine d3d9 unit tests
2010-03-08 11:29:12 -05:00
Maciej Cencora
86ac140937 r300: no need to flush on context init 2010-03-08 11:28:57 -05:00
Maciej Cencora
b584e780ab r300: remove unnecessary code
_tnl_UpdateFixedFunctionProgram is already called in r300_draw.c
2010-03-08 11:28:39 -05:00
Alex Deucher
981e8a2087 r600: add new rs880 pci id 2010-03-03 14:11:10 -05:00
Brian Paul
72d380b363 glx: replace assertion with conditional
See fd.o bug 26832.
2010-03-02 07:38:12 -07:00
Dave Airlie
cf8af9bcf1 r600: fix blender picking.
This fixes the sw fallback for GL_SELECT picking modes.

Fixes object picking blender + depthpick test

http://bugs.freedesktop.org/show_bug.cgi?id=26419

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-03-02 14:14:47 +10:00
Alex Deucher
7123f3d77a r600: enable OQ on rv740 on drms with working pipe config 2010-02-26 15:39:40 -05:00
Klaus Schnass
2edb1b9534 r600: fail to validate unsupported texture formats 2010-02-26 15:39:17 -05:00
Markus Fleschutz
69334d6784 glx: fix incorrect array stack memory allocation
The array stack space wasn't allocated to the proper size.  Fixes out of
bounds memory writes when the client/array stack depth exceeds one.

See fd.o bug 26768.
2010-02-26 10:38:21 -07:00
Brian Paul
61482ddc1c mesa: fix _BaseFormat assignment in _mesa_soft_renderbuffer_storage()
The rb->InternalFormat field will be set by the caller if the allocation
succeeds.  Until then, this field's value can't be used.  Fixes a failed
assertion with FlightGear.

(cherry picked from commit fe25476c04)
2010-02-26 09:14:12 -07:00
Brian Paul
b0e84e22d5 mesa: use simplified _BaseFormat value in render-to-texture code
Fixes fd.o bug 26762.

(cherry picked from commit c9e8ff1976)
2010-02-26 09:10:27 -07:00
Jakob Bornecrantz
c0e8d443fe st/xorg: Re-enable crtc on resize 2010-02-25 16:52:02 +01:00
Jakob Bornecrantz
b95d4cd680 st/xorg: Fix copy-topy 2010-02-25 16:52:02 +01:00
Jakob Bornecrantz
6ef1d60407 vmware/core: Support drm interface version 1.0.0 2010-02-06 03:36:47 +01:00
Jakob Bornecrantz
6a4cd124af vmware/core: Use correct flags in scanout code 2010-02-06 03:36:47 +01:00
Jakob Bornecrantz
6ffb6318a0 vmware/core: Handle new scanout field 2010-02-06 03:36:47 +01:00
Jakob Bornecrantz
a9d61c286d vmware/core: Update header to latest version 2010-02-06 03:36:46 +01:00
Jakob Bornecrantz
7afcfa0683 vmware/core: Remove old ioctl structs not used
Leftover that was never used in this driver
2010-02-06 03:36:46 +01:00
Michal Krol
72fa4ef649 llvmpipe: Remove reference to prefilter field. 2010-02-09 16:27:16 +01:00
Kristian Høgsberg
2ecbe4e208 glx: Fix TOP setting in src/glx Makefile
Argh, forgot to commit this fix before pushing.
2010-02-09 10:21:45 -05:00
Kristian Høgsberg
6e8897ff9f Retire miniglx and move the actual glx code up to src/glx 2010-02-09 09:58:36 -05:00
Kristian Høgsberg
538539d879 egl_dri2: Fix initialization with EGL_DEFAULT_DISPLAY 2010-02-09 09:51:05 -05:00
Brian Paul
a1a441179b fix bug in perspective corrected interpolants for lines 2010-02-09 15:33:06 +01:00
Brian Paul
fd6701029b progs/tests: add line drawing option to cylwrap.c 2010-02-09 15:33:03 +01:00
Brian Paul
22a3a817aa progs/tests: add x/y rotation to cylwrap.c 2010-02-09 15:33:00 +01:00
Brian Paul
dd98a979b6 st/mesa: remove special-case cyl-wrap code
Cylinder wrap mode works with perspective interpolation now.
2010-02-09 15:32:56 +01:00
Michal Krol
5fbb62f761 softpipe: Properly implement cylindrical wrapping. 2010-02-09 15:32:53 +01:00
Michal Krol
00bd85e574 Revert "softpipe: Implement cylindrical wrapping for linear interpolator."
This reverts commit 444cd62ca33a45bd39e8408979a0a01c246c6381.
2010-02-09 15:32:50 +01:00
Brian Paul
86921aaf3f progs/tests: new test program for exercising cylindrical tex wrap mode 2010-02-09 15:32:47 +01:00
Brian Paul
ae4dde6598 st/mesa: check for PROG_PARAM_BIT_CYL_WRAP flag 2010-02-09 15:32:43 +01:00
Brian Paul
4a9f1eed2b mesa: add back-door support for cylindrical texture wrap mode
If the texture priority field is 0.125 set the PROG_PARAM_BIT_CYL_WRAP
flag.  The gallium state tracker will look for this flag.

This feature is only for testing purposes and may be remove at some
point.  But if it's useful we could write a GL/Mesa extension to
expose it properly.
2010-02-09 15:32:40 +01:00
Michal Krol
9a8473da83 gallium: Remove prefilter member from pipe_sampler_state struct. 2010-02-09 15:32:36 +01:00
Michal Krol
63d6097910 docs: Document TGSI Declaration token. 2010-02-09 15:29:52 +01:00
Michal Krol
e04c8ecc61 softpipe: Implement cylindrical wrapping for linear interpolator. 2010-02-09 15:29:49 +01:00
Michal Krol
607a830fe2 tgsi: Gather cylindrical wrap info in tgsi_shader_info struct. 2010-02-09 15:29:46 +01:00
Michal Krol
33a9fb35dd tgsi: Add ureg_DECL_fs_input_cyl().
Allows one to declare fragment shader inputs with cylindrical wrap info.
2010-02-09 15:29:42 +01:00
Michal Krol
6f6d740c85 gallium: Add cylindrical wrap info to TGSI declaration. 2010-02-09 15:29:39 +01:00
Michal Krol
5ee856e195 tgsi: Remove tgsi_dump_c.[ch].
Little utility after development stabilisation, use tgsi_dump instead.
2010-02-09 15:29:34 +01:00
Michal Krol
01d7e3d5a2 mesa: Enable true refcounting for NullBufferObj.
This object can be shared with another context, so we cannot just
delete it when the owning context is being destroyed.

Ensuring that buffer objects are properly refcounted guarantees
NullBufferObj is destroyed when all references to it are removed.
2010-02-09 14:52:52 +01:00
Michal Krol
eeec2c3d95 mesa: Protect buffer objects reference counting with a mutex. 2010-02-09 14:46:32 +01:00
José Fonseca
829d9bb733 mesa: Ensure object refcount is null when destroying the buffer.
Lets see if this is not too pedantic. Obj pointers are never exposed to
GL apps so it should be possible to get this right.

Furthermore apps with GL widgets and test suits create and destroy many
contexts and objects, so bad reference counting is not really an option.
2010-02-09 11:52:08 +00:00
José Fonseca
05ac187f30 mesa: Fix null buffer object reference counting.
Always use _mesa_reference_buffer_object, and never call
ctx->Driver.DeleteBuffer() directly to prevent dangling pointers to the
null buffer object.

This fixes crash/assertions in sharedtex_mt and Autodesk Mudbox.
2010-02-09 11:52:05 +00:00
José Fonseca
1c39dbb90c mesa: Always do proper ref counting of shared state. 2010-02-09 11:52:02 +00:00
José Fonseca
b750786fb1 svga: Actually call fence_reference in texture downloads. 2010-02-09 11:51:33 +00:00
Vinson Lee
ad93f3e489 progs/xdemos: Silence uninitialized variable warning. 2010-02-09 01:35:14 -08:00
Vinson Lee
70f8aaa0c3 r300g: Fix off-by-one errors in array bounds assertions. 2010-02-09 01:26:11 -08:00
Zack Rusin
43f8a82a76 scons: don't assume llvm is always present 2010-02-09 00:00:35 -05:00
Zack Rusin
85c7ec70ad llvmpipe: switch to using dynamic stack allocation instead of registers
with mutable vars we don't need to follow the phi nodes. meaning that
control flow becomes trivial as we don't have scan the rest of the tgsi
to figure out the variable usage anymore. futhermore the memory2register
pass promotes alloca/store/load to registers while inserting the right phi
nodes. so we get simplicity and performance.
2010-02-08 21:50:33 -05:00
Vinson Lee
257267ee98 identity: Remove unnecessary header. 2010-02-08 18:22:29 -08:00
Vinson Lee
a131941e43 softpipe: Remove unnecessary headers. 2010-02-08 18:14:49 -08:00
Brian Paul
38076c9950 gallivm: added lp_bld_misc.cpp to sources list 2010-02-08 17:51:48 -07:00
Brian Paul
69c0d08678 llvmpipe: include gallivm/lp_bld_misc.h 2010-02-08 17:40:02 -07:00
Brian Paul
7d36b678c5 gallivm: added gallivm/lp_bld_misc.cpp to Makefile 2010-02-08 17:39:08 -07:00
Brian Paul
6c28cc27eb llvmpipe: remove files moved to gallivm/ from llvmpipe/Makefile 2010-02-08 17:38:35 -07:00
Brian Paul
b014d71fd4 llvmpipe: s/textured/texture/ 2010-02-08 17:34:59 -07:00
Brian Paul
4aeacdf853 llvmpipe: added counters for color tile clear, load, store 2010-02-08 16:57:23 -07:00
Brian Paul
a8270c7c29 llvmpipe: use new os time functions 2010-02-08 16:57:23 -07:00
Francisco Jerez
8b0b5ace48 glx: Fix SwapBuffers regression introduced by 01923fb72d.
After that commit, some dri2 protocol symbols were being checked from
places that weren't including dri2proto.h, effectively disabling some
valuable SwapBuffers codepaths.
2010-02-08 23:29:15 +00:00
Zack Rusin
c61bf36393 llvmpipe: export the tgsi translation code to a common layer
the llvmpipe tgsi translation is a lot more complete than what was in
gallivm so replacing the latter with the former. this is needed since
the draw llvm paths will use the same code. effectively the proven
llvmpipe code becomes gallivm.
2010-02-08 18:22:11 -05:00
Corbin Simpson
74d23546c7 radeong: Provide drm_api::destroy hook.
Pedantic Corbin is pedantic.
2010-02-08 14:03:28 -08:00
Corbin Simpson
184cefcd8c radeong: Always return something for create_screen.
Prevents a segfault on e.g. r600.
2010-02-08 13:37:55 -08:00
Keith Whitwell
361d73fcfc st/dri: fix compile breakage 2010-02-08 19:45:02 +00:00
Keith Whitwell
0b99303d1c egl: re-fix context_create typo 2010-02-08 17:17:59 +00:00
Keith Whitwell
3703e259d9 svga: remove dead debug sleep 2010-02-08 17:17:59 +00:00
Keith Whitwell
a23357ca60 gallium: remove softpipe references in other drivers 2010-02-08 17:17:59 +00:00
Keith Whitwell
6447b20ce0 drm/radeon: remove softpipe references 2010-02-08 17:17:58 +00:00
Marc Dietrich
ebe2f76095 cell: fix the usual cell breakage
also update the cell config a bit

Signed-off-by: Brian Paul <brianp@vmware.com>
2010-02-08 07:47:04 -07:00
Keith Whitwell
7f41f5447c gallium: squash-merge of gallium screen context
Squashed commit of the following:

commit 009598122adf5cad42bf9af067eccaf8e89e1233
Author: Christoph Bumiller <e0425955@student.tuwien.ac.at>
Date:   Mon Feb 8 11:03:26 2010 +0000

    nouveau: fix gallium-screen-context branch fallout

commit 7b2ffc2019d72e833afea7eebf3e80121187375d
Merge: 51e190e c036d13
Author: Keith Whitwell <keithw@vmware.com>
Date:   Fri Feb 5 09:55:02 2010 +0000

    Merge commit 'origin/master' into gallium-screen-context

    Conflicts:
    	src/gallium/winsys/drm/nouveau/drm/nouveau_drm_api.c

    This branch has got a pretty tortured history now, I expect
    a squash merge will be appropriate when it is done.

commit 51e190e95acf120f72768fafb29e9721e358df1b
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 17:58:02 2010 +0000

    gallium: fix some build issues

commit f524bdaa723fb181637ad30c6ad708aeedabe25b
Merge: f906212 3aba0a2
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 17:51:32 2010 +0000

    Merge commit 'origin/master' into gallium-screen-context

commit f9062126883199eabf045714c717cd35f4b7b313
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 17:17:12 2010 +0000

    gallium/docs: small description of screen::create_context

commit efcb37bd3d5ed37f06c6105bd2d750b374ec0927
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 16:42:42 2010 +0000

    drm/radeon: more dead create_context wrapper removal

commit 6badc0dd9e06cf2ec936940bcf12b9ef5324b301
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 16:42:30 2010 +0000

    drm/i965: more dead create_context wrapper removal

commit cf04ebd5a54b18b2d894cfdab2b0f2fd55626ffc
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 16:42:05 2010 +0000

    st/python: more dead create_context wrapper removal

commit 444f114c3516abf71c430e6e9d0d2ae3b80679d3
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 16:37:58 2010 +0000

    idenity: wrapped context creation

commit 5a6d09cb9e468d1ee6c8d54b887618819d8d94f2
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 16:28:47 2010 +0000

    ws/gdi: remove dead context_create wrapper

commit 132b55f4bec39386ac625f09aaa11f609664024c
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 16:27:52 2010 +0000

    ws/gdi: remove dead context_create wrapper

commit 56d2d21a0cdcb197a364049d354c2f15a4fc026a
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 16:25:38 2010 +0000

    st/xorg: use screen::context_create

commit 838c5cfe56b2af6c644909bed3c5e7cdd64c336a
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 16:23:20 2010 +0000

    glx/xlib: simplify creation of trace-wrapped contexts

    Trace screen knows how to properly wrap context creation in the
    wrapped screen, so nothing special to do here.

commit c99404c03ebaec4175f08a2f363e43c9085f2635
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 16:18:24 2010 +0000

    st/python: no need to special case context creation for trace

commit 193a527a682b6877bb1faecd8092df4dfd055a18
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 16:15:30 2010 +0000

    drm/radeon: remove dead create_context declaration

commit bb984eecc25cf23bc77e1c818b81165ba1a07c9a
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 16:14:58 2010 +0000

    nv/drm: remove dead create_context ref

commit e809313a44287dc4e16c28e9e74ef3b2b5271aa1
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 16:12:51 2010 +0000

    st/egl: remove a layer of wrappers around screen::create_context

commit 39caa6672a04122f185c22e17aab86d1c40938bf
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 16:05:28 2010 +0000

    r300g: fill in screen::context_create

commit 407f12556d16ba0656774d8a1d9ebda22f82f473
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 16:04:04 2010 +0000

    cell: adapt for screen::create_context, untested

commit d02b0c6ce321a04c76fdabb09e0e4380ce1c1376
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 15:50:24 2010 +0000

    drm/nv: adapt for screen::create_context

    All contexts now created directly through the screen, so remove
    equivalent code here.

    Remove apparently un-needed array of contexts in the winsys.

commit 53eec5b1349aa1b6892a75a7bff7e7530957aeae
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 15:50:08 2010 +0000

    stw: adapt for screen::create_context, untested

commit c6a64de3eb381bc9a88e9fbdecbf87d77925aaf5
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 15:49:20 2010 +0000

    trace: expose the wrapped context's priv data

    If we are going to keep this priv idea, really want an accessor
    function for it so that trace and other drivers can wrap that.

commit 75d6104e11d86ec2b0749627ed58e35f856ee6eb
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 15:47:55 2010 +0000

    nv30: adapt to screen::context_create

commit 12f5deb6ed9723e9b5d34577052b8365813ca14e
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 15:44:47 2010 +0000

    nv40: adapt to screen::context_create

commit 14baccaa3b6bbb3b91056126f6521828e786dc62
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 15:35:27 2010 +0000

    nv50: adapt to screen::create_context

    Not build tested.  Need to figure out how to build nouveau.

commit a0e94505ccd2d7f3e604465a2ac302f1286b73b6
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 15:22:27 2010 +0000

    llvmpipe: update for screen::create_context, untested

commit 0eae17107c950346030e4f7e0ec232f868d3893d
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 15:16:57 2010 +0000

    xlib/llvmpipe: remove dead winsys context creation path

commit 2f69f9ffaa7e2a01d2483277246ed13051ae4ca3
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 14:58:27 2010 +0000

    gallium: convert most code to use screen::create_context

    I wish I could build all of gallium at once to find breakages.

commit d7b57f4061b82322cbcae176125913d9f0dea6c1
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 12:46:21 2010 +0000

    glx: permit building with older protocol headers

    I'd like to be able to build mesa on current distro releases without
    having to upgrade from the standard dri2proto and glproto headers.  With
    this change I'm able to build on ancient releases such as Ubuntu 9-10...

    In general, it would be nice to be able to build-test mesa to check for
    unintended breakages without having to follow the external dependencies
    of every group working on the codebase.

commit 57adedd6fb06c98572ed8d4aef19203df4c4eea2
Merge: da71847 e1906ae
Author: Keith Whitwell <keithw@vmware.com>
Date:   Thu Feb 4 11:38:15 2010 +0000

    Merge commit 'origin/master' into gallium-screen-context

    Conflicts:
    	src/gallium/drivers/softpipe/sp_video_context.h
    	src/gallium/drivers/trace/tr_context.c
    	src/gallium/state_trackers/wgl/shared/stw_context.c
    	src/gallium/winsys/gdi/gdi_softpipe_winsys.c

commit da71847ea6414d7e352c6094f8963bb4eda344dc
Author: José Fonseca <jfonseca@vmware.com>
Date:   Sat May 2 08:57:39 2009 +0100

    wgl: Use pipe_screen::context_create.

commit 2595a188f93fd903600ef5d8517737ee0592035d
Author: José Fonseca <jfonseca@vmware.com>
Date:   Sat May 2 08:56:47 2009 +0100

    trace: Implement pipe_screen::context_create.

commit f3640e4ae37a5260cbfba999d079f827de0a313a
Author: José Fonseca <jfonseca@vmware.com>
Date:   Sat May 2 08:56:17 2009 +0100

    softpipe: Implement pipe_screen::context_create.

commit 347266bddc8bd39c711bacb2193793759d0f3696
Author: José Fonseca <jfonseca@vmware.com>
Date:   Sat May 2 08:55:31 2009 +0100

    gallium: New pipe_screen::context_create callback.
2010-02-08 13:05:36 +00:00
Keith Whitwell
01923fb72d glx: permit building with older protocol headers
I'd like to be able to build mesa on current distro releases without
having to upgrade from the standard dri2proto and glproto headers.  With
this change I'm able to build on ancient releases such as Ubuntu 9-10...

In general, it would be nice to be able to build-test mesa to check for
unintended breakages without having to follow the external dependencies
of every group working on the codebase.

Seems to introduce no changes to the build of libglapi.a when tested against
new versions of the headers.
2010-02-08 13:05:35 +00:00
Joakim Sindholt
e891a9cc3a progs/demos: update .gitignore 2010-02-08 12:33:02 +01:00
Vinson Lee
7da1a528b8 progs/xdemos: Silence uninitialized variable warning. 2010-02-08 01:53:31 -08:00
Dave Airlie
eaf8fe657f radeon: fix UMS since stp addition.
UMS doesn't need the STP atom.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-08 17:18:02 +10:00
Pauli Nieminen
1a45c2bce7 mesa: Fix mesa_next_pow_two to return same value if parameter is pow2.
Without subtracting one pow2 value would be rounded up to next pow2
which is not correct behaviour for the function.
2010-02-07 13:13:24 +02:00
Pauli Nieminen
ce1f351963 r200: Fix LOD min/max emit.
Just emit minLod and maxLod to correct reisters.

Fixes lodclamp and levelclamp test cases from piglit.
2010-02-07 13:13:24 +02:00
Pauli Nieminen
0943706d35 r100/r200/r300/r600: Set MaxCombinedTextureImageunits.
Fixes glActiveTexture to set GL_INVALID_ENUM when trying
to activate texture unit that is not available.

piglit test case general/texunit passes now.
2010-02-07 13:13:23 +02:00
Pauli Nieminen
76a9831b2b r200: Fix lod bias correction.
glean/pointSprite shows that rv280 is trying to read from better
quality mipmap level. We have to correct default lod bias to match
required texture selection.
2010-02-07 13:13:23 +02:00
Vinson Lee
bfa877cdd3 llvmpipe: Silence GCC 'type qualifiers ignored on function return type' warnings. 2010-02-07 00:09:46 -08:00
Vinson Lee
4f3a023ba4 svga: Remove unnecessary header. 2010-02-07 00:05:02 -08:00
Vinson Lee
290487ce3c llvmpipe: Remove unnecessary headers. 2010-02-07 00:02:05 -08:00
Marek Olšák
5201e94801 r300g: cleanup XXXs in the DSA state 2010-02-06 23:25:29 -08:00
Marek Olšák
2f5fcce933 r300g: make a local copy of framebuffer state
The previous more direct approach was simply incorrect.

piglit/levelclamp passes again.
2010-02-06 23:25:29 -08:00
Marek Olšák
c8b34616b3 r300g: fix color channel masks
glean/maskedClear passes again.
2010-02-06 23:25:29 -08:00
Marek Olšák
93b9d91124 r300g: remove useless GA_COLOR_CONTROL emit
Already emitted in r300_emit_draw_xxx.
2010-02-06 23:25:29 -08:00
Marek Olšák
f02aec35e7 r300g: add L8_SRGB and A8L8_SRGB texture formats 2010-02-06 23:25:29 -08:00
Pauli Nieminen
198e810a20 r200: Add some debug output to texture function. 2010-02-06 19:25:14 +02:00
Pauli Nieminen
db3460e31c r300: Fix emit size prediction to know about primitive splitting.
Fixes ut2004 warnings about overflowing command buffer.
2010-02-06 19:25:13 +02:00
Pauli Nieminen
cdb0a51e8a radeon: Add some debug output to texture function.\n 2010-02-06 19:25:13 +02:00
Pauli Nieminen
e6f2819e7a radeon: Use _mesa_next_pow_two_32 instead of own implementation. 2010-02-06 19:25:13 +02:00
Pauli Nieminen
d41740e969 mesa/main: Add function to find next higher power of two.
With gcc implementation uses __builtin_clr which counts number of
leading zeros.

Fallback implementation uses bit manipulation. First it duplicates
the highest bit to all lower bits and then adds one to get the power
of two number.
2010-02-06 19:24:44 +02:00
Pauli Nieminen
f8969dd24f radeon: Add some debug output to miptree code. 2010-02-06 19:14:21 +02:00
Pauli Nieminen
9d5f882503 radeon: Remove the loop from stride size calculation.
Changed stride size calculation to do the math by rounding
the value instead of loop. r600 minimum stride is 256 which
might might cause up to about 60 rounds of the loop.
2010-02-06 19:14:20 +02:00
Alan Coopersmith
78572ebcb3 Gallium: Add Solaris atomic function definitions to u_atomic.h
Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
2010-02-06 08:54:44 -08:00
Damien Lespiau
fd2378e4b0 intel: Allow L8 PBO blit uploads.
Bug #32810
2010-02-06 16:43:58 +01:00
Eric Anholt
c8433af711 i965: Keep the CURBE BO mapped and memcpy instead of subdataing.
For the tiny bis of data we generally upload through the CURBEs, the
overhead of the kernel's pagetable trickery is actually rather high.
This improves cairo-gl gnome-terminal-vim performance by 3.8%.
2010-02-06 14:10:07 +01:00
Eric Anholt
3e498207d1 i965: Reset the "need new CURBE BO" flag when we make a new CURBE bo.
Improves cairo-gl gnome-terminal-vim times by 11%.
2010-02-06 14:10:07 +01:00
Eric Anholt
67e5fd7397 intel: Check aperture size when doing a blit glClear.
Fixes failure in cairo-gl firefox-planet-gnome.
2010-02-06 14:10:07 +01:00
Eric Anholt
12d0721ae1 intel: Allow PBO acceleration for GL_RGBA8 MESA_FORMAT_ARGB8888.
This improves firefox-talos-svg runtimes on cairo-gl by 14%.
2010-02-06 14:10:07 +01:00
Vinson Lee
507faae9e3 llvmpipe: Silence GCC 'no previous prototype' warning. 2010-02-06 00:48:18 -08:00
Vinson Lee
4e907e8bd6 i965g: Remove unnecessary headers. 2010-02-05 23:39:34 -08:00
Alan Coopersmith
8a985a988b eglplatform.h: recognize __unix as well for Solaris & other SVR4 platforms
Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
2010-02-05 19:38:16 -08:00
Jakob Bornecrantz
45c4addea7 vmware/core: Support drm interface version 1.0.0 2010-02-06 01:30:29 +01:00
Jakob Bornecrantz
1eba0eb37d vmware/core: Use correct flags in scanout code 2010-02-06 01:29:47 +01:00
Dave Airlie
d87fb5e003 radeon: fix UMS since stp addition.
UMS doesn't need the STP atom.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-08 12:07:04 +02:00
Pauli Nieminen
4be7922a8e r200: Fix UMS notto emit stp.
Polgon stipples are handled by kernel in UMS. Mark the
state as never to be emited for UMS.
2010-02-08 12:07:04 +02:00
Eric Anholt
a1cac0732b intel: Check aperture size when doing a blit glClear.
Fixes failure in cairo-gl firefox-planet-gnome.
(cherry picked from commit 67e5fd7397)

Conflicts:

	src/mesa/drivers/dri/intel/intel_blit.c
2010-02-06 17:45:34 +01:00
Eric Anholt
fb32e0fcc5 intel: Respect texture tiling when doing a PBO blit teximage upload.
Bug #26008.  Fixes piglit pbo-teximage-tiling-2.
(cherry picked from commit 22bbc97994)
2010-02-06 17:45:34 +01:00
Eric Anholt
9564a6fa13 intel: Set the region's tiling to none when attaching a PBO to a region.
Note that when detaching the PBO from the region and making a new BO
for the region, we don't make it tiled even if the region originally
was.

Fixes piglit pbo-teximage-tiling.
(cherry picked from commit f20e83210e)
2010-02-06 17:45:34 +01:00
Eric Anholt
0b9990b2fd intel: Fix PBO blit ReadPixels from an FBO.
Bug #25921 -- clutter PBO usage gave unreliable results.
(cherry picked from commit 63b10e8fe7)

Conflicts:

	src/mesa/drivers/dri/intel/intel_pixel_read.c
2010-02-06 17:16:51 +01:00
Eric Anholt
8ce99c85e7 i965: Fix loads of non-relative-addr constants after a reladdr load.
Fixes piglit vp-arl-constant-array-huge-overwritten.
(cherry picked from commit d5b964234c)
2010-02-06 17:08:53 +01:00
Jakob Bornecrantz
a2c402ba53 vmware/core: Handle new scanout field 2010-02-06 01:34:12 +01:00
Jakob Bornecrantz
1ceb906c12 vmware/core: Update header to latest version 2010-02-06 01:34:12 +01:00
Zack Rusin
fb1fe8e76f gallium/tgsi: fix soa dependencies in mul and cmp instructions
master has this done in a lot nicer way, this is a simple patch to
stop the bleeding in a minimally intrusive manner.
2010-02-05 19:32:01 -05:00
Zack Rusin
8109b6d313 gallium/python: support two more formats in retrace dumps
dump PIPE_FORMAT_R8G8B8A8_UNORM and PIPE_FORMAT_R16G16B16_SNORM formats.
2010-02-05 19:29:34 -05:00
Zack Rusin
f8b05566aa gallium/python: support two more formats in retrace dumps
dump PIPE_FORMAT_R8G8B8A8_UNORM and PIPE_FORMAT_R16G16B16_SNORM formats.
2010-02-05 19:25:01 -05:00
Zack Rusin
a6148b8eba gallium/draw: fix overflowing element indices
we piggy back flags in the top four bits of the element indices, so if
the maximum index stored in any of the elements is greater than
sizeof(ushort) - sizeof(flags we piggy back) then we overflow. fix it by
simply falling back to the slow path if we notice the overflow.
2010-02-05 19:25:01 -05:00
Brian Paul
337d3b2b39 st/mesa: allow negative index for PROGRAM_STATE_VAR
The piglit vp-address-01 test uses negative address-relative
offsets.  In this test we're indexing into PROGRAM_STATE_VAR
which, in turn, contains references to ENV vars.

We previously fixed this issue for PROGRAM_CONSTANT.

piglit/vp-address-01 (the version from Feb 5) passes now.

(cherry picked from commit 64be837b0b)
2010-02-05 14:59:04 -07:00
Brian Paul
a636f5b4d0 mesa: debug output for ARL 2010-02-05 14:58:46 -07:00
Brian Paul
64be837b0b st/mesa: allow negative index for PROGRAM_STATE_VAR
The piglit vp-address-01 test uses negative address-relative
offsets.  In this test we're indexing into PROGRAM_STATE_VAR
which, in turn, contains references to ENV vars.

We previously fixed this issue for PROGRAM_CONSTANT.

piglit/vp-address-01 (the version from Feb 5) passes now.
2010-02-05 14:54:00 -07:00
Brian Paul
e070c1d183 tgsi: disable inf/nan checking
Inf/NaN can happen normally.  Only check for those values
when we need to debug something.
2010-02-05 14:48:42 -07:00
Brian Paul
1a366701b8 docs: Fix a typo in mesa3d.org HTML.
Signed-off-by: Brian Paul <brianp@vmware.com>

(cherry picked from commit e6ee4b49c4)
2010-02-05 13:18:31 -07:00
Brian Paul
a199ccc272 osmesa: Add OSMesaColorClamp and OSMesaGetProcAddress to symbol defs.
Without this patch, the two symbols get an underscore prepended
and an "@4" appended when compiling with VC8.

Signed-off-by: Brian Paul <brianp@vmware.com>

(cherry picked from commit e65029e9b3)
2010-02-05 13:18:18 -07:00
Tom Fogal
e6ee4b49c4 docs: Fix a typo in mesa3d.org HTML.
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-02-05 13:17:37 -07:00
Brian Paul
45ceabf794 progs/demos: fix typo 2010-02-05 13:16:39 -07:00
Tom Fogal
e65029e9b3 osmesa: Add OSMesaColorClamp and OSMesaGetProcAddress to symbol defs.
Without this patch, the two symbols get an underscore prepended
and an "@4" appended when compiling with VC8.

Signed-off-by: Brian Paul <brianp@vmware.com>
2010-02-05 13:15:33 -07:00
Brian Paul
3ca6cb3440 softpipe: fix bug in perspective corrected interpolants for lines
Thanks to Michal for finding this.

This will get fixed on the gallium-cylindrical-wrap branch and
then merged to master.
2010-02-05 12:57:54 -07:00
Kristian Høgsberg
077bc2fda2 egl_dri2: Use pkg-config cflags and libs from configure output
Running pkg-config in Makefiles is bad form, since it doesn't respect the
PKG_CONFIG_PATH value set at ./configure time.
2010-02-05 13:55:45 -05:00
Patrice Mandin
e423df0f0c nouveau: Fix warning for void function returning value. Add missing include for pipe_reference_init function.
Signed-off-by: Patrice Mandin <patmandin@gmail.com>
2010-02-05 19:42:33 +01:00
Kristian Høgsberg
da73c4d5fe glapi: Add back the reduced Noop dispatch
This got "simplified" away in e4f168a6f4.
2010-02-05 12:01:28 -05:00
Kristian Høgsberg
697e22146d glx: Don't mark the XF86DRI functions PUBLIC 2010-02-05 12:01:28 -05:00
Kristian Høgsberg
832f2d3c39 egl_dri2: Log both driver and core extensions 2010-02-05 12:01:28 -05:00
Kristian Høgsberg
9c94faeff1 egl_dri2: Audit and fix errors paths 2010-02-05 12:01:28 -05:00
Kristian Høgsberg
f27b4fadca egl_dri2: Just cast the pointer difference to an int 2010-02-05 12:01:27 -05:00
Brian Paul
f1d544d6a6 st/mesa: 'fix' point coord semantic info
This fixes the progs/glsl/pointcoord.c demo.  But this isn't a proper fix.
We really need a TGSI_SEMANTIC_POINT_COORD label so that the draw module
can determine which fragment input / vertex output slot needs to be set
up with the point coordinate info.  We've been using generic slot 0 so far.

This would also require telling the draw module about fragment shaders
(something it doesn't have at this time).
2010-02-05 10:00:00 -07:00
Brian Paul
cea2b8d656 tgsi: remove special-case code for fragment position
Since the origin_lower_left / pixel_center_origin changes, we need
to use the fragcoord info that's set up in setup_fragcoord_coeff().
The code in exec_declaration() was clobbering the the interpolated
fragment position.

Fixes progs/glsl/fragcoord.c demo.
2010-02-05 10:00:00 -07:00
Chris Li
476b668ccc allow make to build lp_test_* for llvmpipe
Signed-off-by: José Fonseca <jfonseca@vmware.com>
2010-02-05 15:34:28 +00:00
José Fonseca
ad60552ca1 llvmpipe: Disable multithreading on windows. 2010-02-05 13:56:01 +00:00
José Fonseca
e95e5caee6 os: Don't assert on missing implementation of barrier init/destroy. Just usage. 2010-02-05 13:54:21 +00:00
José Fonseca
8eda504203 Merge remote branch 'origin/master' 2010-02-05 13:50:24 +00:00
José Fonseca
a1af8eec66 Merge remote branch 'origin/lp-binning'
Conflicts:
	src/gallium/auxiliary/util/u_dl.c
	src/gallium/auxiliary/util/u_time.h
	src/gallium/drivers/llvmpipe/lp_state_derived.c
	src/gallium/drivers/llvmpipe/lp_state_surface.c
	src/gallium/drivers/llvmpipe/lp_tex_cache.c
	src/gallium/drivers/llvmpipe/lp_tile_cache.c
2010-02-05 13:48:35 +00:00
Pauli Nieminen
6785a8aaf4 r200: Optimize polygon stipple emit.
Only emit polygon stipple when the state is enabled.
2010-02-05 15:26:19 +02:00
Pauli Nieminen
05b0408489 r200: Add trace logging to r200PointSize. 2010-02-05 15:26:19 +02:00
Keith Whitwell
c036d13d7d Merge commit 'fj/mesa-next' 2010-02-05 09:50:21 +00:00
Pauli Nieminen
69f20294cd r100: Add the polygon stipple state to the state list.
This fixes glean paths test case.
2010-02-05 11:31:24 +02:00
Pauli Nieminen
34b36277b7 r100: Add the polygon stipple state to the state list.
This fixes glean paths test case.
2010-02-05 11:28:01 +02:00
Chia-I Wu
4f47684f75 egl: Add debug messages to config validation and matching.
It might be desirable find out which attribute went wrong.
2010-02-05 14:19:54 +08:00
Chia-I Wu
a37dc17c12 egl: Clean up eglconfig.h.
Update the comments to macros/functions.  Remove unused
_eglSetConfigAttrib.
2010-02-05 13:42:02 +08:00
Chia-I Wu
1b2b08c5f3 docs: Update the developer section of egl.html.
Mainly to add a subsection about EGL_RENDER_BUFFER.
2010-02-05 12:48:49 +08:00
Chia-I Wu
5f08eff2a7 egl: Remove egl_xdri.
egl_xdri steals code from src/glx/x11/.  This makes it broken from time
to time when there is a bigger change to the GLX code.  As egl_dri2 has
been merged, which also functions as a DRI2 driver loader, remove
egl_xdri for good.
2010-02-05 12:48:49 +08:00
Chia-I Wu
cb260e1d18 egl: Update the comments to typecast macros.
Put a note that the macros define functions and should not be ended with
a semicolon when used.
2010-02-05 11:45:01 +08:00
Chia-I Wu
a35e63382e egl_dri2: Use _EGL_DRIVER_STANDARD_TYPECASTS.
It saves the driver from defining the boring typecasts itself.
2010-02-05 11:45:01 +08:00
Chia-I Wu
b31255fbfd egl: Clarify IsLinked and IsBound.
Both a link and a binding creates a reference to the resource.  Drivers
should not destroy the resource when there is a reference.  The
difference is better described in doc/egl.html.
2010-02-05 11:45:01 +08:00
Chia-I Wu
fc5ca85a63 egl_dri2: Do not destroy linked resources.
A linked resource is stil owned by the display.
2010-02-05 11:45:01 +08:00
Chia-I Wu
7e7c1ba40b egl_dri2: Fix a snprintf warning.
The subtraction between two pointers has type unsigned int (only on
x86-64?), while the format string expects an int.
2010-02-05 11:44:49 +08:00
Chia-I Wu
8d411c9a12 egl_dri2: Add a debug print for DRI2 extensions. 2010-02-05 11:44:16 +08:00
Chia-I Wu
2eb7a2fccd configure.ac: Check for xcb-dri2 to enable EGL dri2 driver.
Check that xcb-dri2 is available before including EGL dri2 driver into
EGL_DRIVERS_DIRS.
2010-02-05 11:43:54 +08:00
Kristian Høgsberg
c6e830c393 egl: Implement eglCopyBuffers for DRI2, make pixmap and pbuffers actually work 2010-02-04 21:50:23 -05:00
Brian Paul
4ac9c80e5b mesa: change ctx->Driver.ProgramStringNotify() to return GLboolean
GL_TRUE indicates that the driver accepts the program.
GL_FALSE indicates the program can't be compiled/translated by the
driver for some reason (too many resources used, etc).

Propogate this result up to the GL API: set GL_INVALID_OPERATION
error if glProgramString() was called.  Set shader program link
status to GL_FALSE if glLinkProgram() was called.

At this point, drivers still don't do any program checking and
always return GL_TRUE.
2010-02-04 16:53:27 -07:00
Pauli Nieminen
0f763c5b00 r200: Add the polygon stipple state to the state list.
This fixes glean paths test case.
2010-02-04 23:59:21 +02:00
Pauli Nieminen
77768cdd73 r200: Add logging for glPolygonStripple. 2010-02-04 23:59:20 +02:00
Pauli Nieminen
66229ea184 radeon: Make debugging automaticaly increase logging verbosity for debug build.
DEBUG preprocessor macro is set by configure script when
--enable-debug is passed for configure. Radeon then just
increase debugging verbosity if DEBUG is set in compile
time.
2010-02-04 23:59:20 +02:00
Pauli Nieminen
c8ea0212fe r200: Add the polygon stipple state to the state list.
This fixes glean paths test case.
2010-02-04 23:56:37 +02:00
Francisco Jerez
5b6b67eb3f Nuke the nv0x-nv2x gallium pipe drivers. 2010-02-04 22:15:22 +01:00
Francisco Jerez
bfb5dc68fc Import a classic DRI driver for nv0x-nv2x. 2010-02-04 22:14:39 +01:00
Roland Scheidegger
68f93ea3eb gallium: add point_quad_rasterization bit to rasterizer state
This determines if points should be rasterized according to GL point rules
or as normal quads (GL point sprites / d3d points / d3d point sprites).
2010-02-04 21:35:28 +01:00
Kristian Høgsberg
42fa009e64 egl: Add driver for EGL on X with DRI2 2010-02-04 15:03:45 -05:00
José Fonseca
7b6fa78d86 scons: Eliminate mixed space/tabs. 2010-02-04 19:37:56 +00:00
José Fonseca
9f151f93e6 scons: Only override scons CC selection in the embedded platform. 2010-02-04 19:37:30 +00:00
José Fonseca
838d9884be trace: util_stream -> os_stream 2010-02-04 18:45:25 +00:00
José Fonseca
c75d64490e auxiliary: util_stream -> os_stream 2010-02-04 18:44:51 +00:00
José Fonseca
0eb8e77ffb os: Ensure header includes are outside extern "C" {}. 2010-02-04 18:24:57 +00:00
José Fonseca
5ee324ad3c util: Reimplement u_time on top of os_time. 2010-02-04 18:24:36 +00:00
José Fonseca
b7b7ea9532 gallium: Add a define for deprecated function attribute. 2010-02-04 18:24:17 +00:00
José Fonseca
2ef6d311b7 os: Time abstractions.
Simplified version of u_time.[ch]
2010-02-04 18:23:49 +00:00
Roland Scheidegger
2c326e7266 gallium: add point size clamp to implementation limits in vertex shader
The point size min/max registers (unused by mesa state tracker) were removed
since most hardware couldn't do much with them. However, we don't want to have
to rely on hw to do point size clamping correctly to implementation
dependent limits, hence have to do that in the vertex shader. This should also
solve a potential problem with (non-AA) points smaller than 1.0 which according
to OGL still have size 1.0.
Note that OGL point rendering is odd, in particular point sprites are rasterized
differently to points. Some hardware might support those different modes, but in
any case the different clamping values used for smooth/multisampled/sprite
enabled points might help a bit for hw which rasterizes points the same as point
sprites.
Also tweak mesa's ff to vertex shader translation so don't have to clamp twice in
case of point attenuation.
2010-02-04 19:23:09 +01:00
José Fonseca
24ea02553e os/os_memory_aligned.h: fix memory allocation alignment for 64 bits
Based on Andreia Gaita <shana@jitted.com>'s patch.
2010-02-04 18:07:22 +00:00
Brian Paul
3aba0a2875 i965g: include u_inlines.h 2010-02-04 10:07:08 -07:00
Alex Deucher
339d42b4e6 r600: reduce number of cache flushes
We don't need to flush so often. Next step
would be to move the flushing to the drm and only
flush after each command buffer rather than each
draw.
2010-02-04 10:46:36 -05:00
José Fonseca
f769ab0fa6 util: Disable u_time.c implementation for embedded.
This needs to go into OS module.
2010-02-04 14:39:30 +00:00
José Fonseca
d015dfb45a trace: Use u_time. 2010-02-04 14:39:30 +00:00
José Fonseca
47a080df15 gallium: Don't try to auto-detect the OS when embedded os is already pre-defined. 2010-02-04 14:39:30 +00:00
José Fonseca
9cd2abdf8b llvmpipe: Disable unit tests on embedded platforms. 2010-02-04 14:39:30 +00:00
José Fonseca
5cf88a4787 scons: Promote EMBEDDED from subsystem to full os. 2010-02-04 14:39:30 +00:00
José Fonseca
063f1238d1 util: Add missing include. 2010-02-04 14:39:30 +00:00
José Fonseca
1207098dee os: Add missing dummy threading definitions. 2010-02-04 14:39:30 +00:00
Pauli Nieminen
f1b07f0220 swrast/sse: Fix _mesa_sse_transform_pointsX_3d_no_rot
PXOR user in code were causing the lowest SP float register to have NaN
values which made all math operations in that slot fail. Correct istruction
to clear float registers is XORPS which handles single precission floats
correctly.

Fixes progs/tests/fog in swrast SSE mode.

Now the correct commit instead of 66d09e4a2a which is not even close
of correct fix for the bug.
2010-02-04 13:13:52 +02:00
Pauli Nieminen
7d6cbcdd9a swrast/sse: Fix _mesa_sse_transform_pointsX_3d_no_rot
PXOR user in code were causing the lowest SP float register to have NaN
values which made all math operations in that slot fail. Correct istruction
to clear float registers is XORPS which handles single precission floats
correctly.

Fixes progs/tests/fog in swrast SSE mode.

Now the correct commit instead of 9d9c1f17dc which is not even close
of correct fix for the bug.
2010-02-04 13:07:04 +02:00
José Fonseca
5a743d9c51 scons: Have MinGW target MSVCRT 7.0
Necessary for _aligned_malloc/free().
2010-02-04 10:38:35 +00:00
José Fonseca
ef67ad05cb scons: Use only the shared object name when linking progs.
Otherwise the whole path gets baked into the executable.
2010-02-04 09:23:30 +00:00
Vinson Lee
7713069ae3 st/mesa: Remove unnecessary headers. 2010-02-03 22:57:38 -08:00
Vinson Lee
d1487dcb20 svga: Remove unnecessary header. 2010-02-03 22:44:50 -08:00
Vinson Lee
c28dd492cd util: Remove unnecessary header. 2010-02-03 22:42:02 -08:00
Chia-I Wu
9a3de505dc egl: Convert drivers to use typecast macros.
Use macros to define the standard typecasts.  This saves lots of
typings.
2010-02-04 14:36:48 +08:00
Chia-I Wu
bdb9e202de egl: Add macros to define typecast functions.
There are standard typecast functions that are common to most drivers.
They are used to typecast, for example, an _EGLSurface to a
driver-defined type.

This commits define _EGL_DRIVER_STANDARD_TYPECASTS and
_EGL_DRIVER_TYPECAST that should hopefully save some typings for driver
writers.
2010-02-04 14:36:48 +08:00
Vinson Lee
23b597cb6c identity: Remove unnecessary header. 2010-02-03 22:36:10 -08:00
Vinson Lee
18e00e5863 llvmpipe: Remove unnecessary header. 2010-02-03 22:33:58 -08:00
Pauli Nieminen
9d9c1f17dc Revert "mesa: fix transform_points_3d_no_rot using undefined values in %xmm0"
This reverts commit 4c31632817.
2010-02-04 05:00:02 +02:00
Pauli Nieminen
66d09e4a2a Revert "mesa: fix transform_points_3d_no_rot using undefined values in %xmm0"
This reverts commit 4c31632817.
2010-02-04 04:58:55 +02:00
Chia-I Wu
997316838d st/egl: Add missing headers to kms display.
Add stdio.h and util/u_inlines.h to native_kms.c.
2010-02-04 10:50:22 +08:00
Vinson Lee
4d01e8e26f st/egl: Add missing headers. 2010-02-03 18:36:07 -08:00
Vinson Lee
821b3e2302 winsys: Add missing headers. 2010-02-03 18:29:18 -08:00
Igor Oliveira
f225042a86 egl: fix implicit declaration of pipe_texture_reference adding u_inlines.h 2010-02-04 10:10:17 +08:00
Igor Oliveira
88af76ce94 egl: fix wrong argument. Use loader_data instead of loader 2010-02-04 10:09:37 +08:00
Dave Airlie
3584a44270 gallium: fix more missing includes from various places
nouveau/ dri st / vmware
2010-02-04 10:52:43 +10:00
Dave Airlie
adf4c1ae10 nouveau: include stdio.h and u_inlines.h in all context files since embedded changes
fixes nouveau build for me.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-04 10:03:39 +10:00
Brian Paul
b2a30497cc mesa: increase number of texture units to MAX_COMBINED_TEXTURE_IMAGE_UNITS
We were misinterpretting GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS previously.

It's the number of texture units for which we need to keep state; not
just the total number of texture units addressable by the vertex shader
plus fragment shader.

Since sw Mesa independently supports 16 texture units in vertex shaders
and 16 texture units in fragment shaders, the max combined units is 32.

Note that the docs for glActiveTexture() indicate the max legal unit is
MAX(GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS, MAX_TEXTURE_COORDS) - 1.

A new piglit test (texunits.c) tests the various texture unit limits.

I'm pretty sure I've got this all right now, but additional reviews
are welcome...
2010-02-03 15:48:42 -07:00
Brian Paul
ea81daf954 mesa: re-dimension RasterTexCoords and CoordReplace
These are limited to the number of texture coordinate units.
2010-02-03 15:48:42 -07:00
Brian Paul
89c8ff3382 mesa: added texcoord unit assertion 2010-02-03 15:48:42 -07:00
Brian Paul
82a2d3564a mesa: use Elements() instead of MAX_TEXTURE_COORD_UNITS 2010-02-03 15:48:42 -07:00
Brian Paul
a32e7c487c mesa: added tex unit assert, use Elements() macro 2010-02-03 15:48:42 -07:00
Brian Paul
cd130b0319 mesa: check for invalid texture coord unit in glGet queries 2010-02-03 15:48:42 -07:00
Brian Paul
60527ff32a mesa: check/clamp texture/program matrix accesses
Further testing should reveal if any these assertions are hit...
2010-02-03 15:48:42 -07:00
Brian Paul
d82c371344 mesa: add error check for querying invalid texture matrix 2010-02-03 15:48:42 -07:00
Brian Paul
a06575aed6 mesa: use Elements() as limit in loops over texture/program matrix stacks 2010-02-03 15:48:42 -07:00
Brian Paul
376ae23c3a mesa: add out of bounds assertions for accessing texture matrix stack 2010-02-03 15:48:41 -07:00
José Fonseca
7bd949734c util: Cast to match the MSVC intrinsics.
The cast is not optional in C++.
2010-02-03 22:16:39 +00:00
José Fonseca
e0da333d6b util: Don't include system headers inside extern "C" { ... }
That breaks when some of the system headers have C++ code.
2010-02-03 22:15:53 +00:00
José Fonseca
45dac0d82a Merge branch 'gallium-embedded' 2010-02-03 18:54:13 +00:00
Brian Paul
f1afb352da scons: add another prefix for mingw32 on Fedora 2010-02-03 11:46:36 -07:00
Roland Scheidegger
8091e73cc2 docs: clean up TGSI_SEMANTIC_PSIZE description
there was some confusion between point size state and point size output.
2010-02-03 18:27:32 +01:00
Roland Scheidegger
c2b85e335d docs: fix point sprite documentation 2010-02-03 17:39:47 +01:00
Roland Scheidegger
4a4daa75a8 gallium: clean up point sprite rasterizer state
Don't need sprite coord origin per coord.
Also, don't need separate sprite enable bit - if all coords have it diabled,
then there are no point sprites (technically, there's a distinction in pre-GL3,
but it only differs in having more leniency in clamping to max size, something
the state tracker would need to handle and the hardware won't bother anyway).
Also, use packed field for the per-coord enables.
All in all, should save 3 dwords in rasterizer state (from 10 down to 7).
2010-02-03 17:25:14 +01:00
José Fonseca
976afaf98f gallium/docs: Document the OS module. 2010-02-03 15:56:36 +00:00
Brian Paul
f8d824e09a tgsi: added debugging code to catch divide by zero 2010-02-03 08:50:32 -07:00
Brian Paul
9ca6cf0f54 tgsi: convert CHECK_INF_OR_NAN to inline function
And disable with if (0).  Inf/NaN can occur normally during program
execution.  Only enable the check code when needed during debugging.
2010-02-03 08:47:09 -07:00
Francisco Jerez
2ec50d256d mesa: Factor out the fb initialization details from _mesa_new_framebuffer.
This should make things easier for drivers wanting to work with a
"subclass" of gl_framebuffer.

The complementary "_mesa_initialize_framebuffer" function is now
called "_mesa_initialize_window_framebuffer" for the sake of
symmetry.

Signed-off-by: Brian Paul <brianp@vmware.com>
2010-02-03 08:30:09 -07:00
Brian Paul
e4c3abbf55 tgsi: fix XPD when dst reg is a src reg
Store XPD results in temporaries before writing to the dest register.
This issue has already been fixed in Mesa/master for XPD (and all
other instructions?).

Fixes progs/demos/bump.c when using TGSI interpreter (GALLIUM_NOSSE=1).

A new glean/glsl1 test has been added to test this case.
2010-02-03 08:17:37 -07:00
José Fonseca
b724694f3a os: Also add the aligned memory prototypes to the embedded section. 2010-02-03 12:57:49 +00:00
José Fonseca
6b424a0550 util: Reimplement all utility functions in terms of the new OS abstraction. 2010-02-03 12:13:06 +00:00
José Fonseca
0b0e705712 os: New OS abstraction module. 2010-02-03 12:11:58 +00:00
Keith Whitwell
64da2aeebc vbo: fix void * arithmetic warning 2010-02-03 11:52:14 +00:00
Francisco Jerez
db0eb3a437 vbo: Fix up in-place splitting for non-contiguous/indexed primitives.
The in-place splitting code wasn't dealing with index buffers at all
(and it was being called from vbo_split_prims for too big index
buffers, causing some occasional corruption).

Additionally, it wasn't taking into account primitives arrays with
non-contiguous indices (e.g. given prim[0].start = 0 and prim[1].start
= max_verts, it would happily call back the driver with (max_index -
min_index) still greater than max_verts, causing infinite recursion).

It still doesn't handle too large indexed vertex buffers: use
vbo_split_copy for that.
2010-02-03 11:38:38 +00:00
José Fonseca
630c375fe9 trace: Include the appropriate header instead of defining prototypes.
Avoids header when the header was included before.
2010-02-03 11:06:23 +00:00
Keith Whitwell
9f1ee5a864 progs/fpglsl: couple more tests 2010-02-03 10:36:55 +00:00
Keith Whitwell
d7b1610ced progs/fpglsl: fp-tris for glsl 2010-02-03 10:36:55 +00:00
Keith Whitwell
84d41f3c7f svga: fix TXD and TXL opcode translation 2010-02-03 10:36:55 +00:00
Keith Whitwell
0748fc4f03 svga: deriv insns not valid in dynamic flow control either 2010-02-03 10:36:55 +00:00
Keith Whitwell
a9cdae2ae0 svga: texture from lod zero inside dynamic branching
Texture derivatives are potentially undefined inside dynamic branches,
so hardwire lod zero in this case.  Treating all if/endif and loop
constructs as dynamic branches.
2010-02-03 10:36:55 +00:00
Keith Whitwell
fc3efccdc6 svga: better method for generating white fs color outputs 2010-02-03 10:36:55 +00:00
Keith Whitwell
9b23e1f9a3 mesa/st: bump the gallium version number
This is a very informal version number, but there have been enough
changes that a bump is appropriate at this time.
2010-02-03 10:36:55 +00:00
Keith Whitwell
aac76dcea9 st/mesa: remove some floating point divides in viewport calculation
Compiler can't usually turn x/2.0f into x * 0.5f, though we're happy
with either.
2010-02-03 10:36:55 +00:00
José Fonseca
bd03025621 gallium-docs: Fix typo. 2010-02-03 09:04:46 +00:00
Dave Airlie
f9d734c309 r300: fix compiler bugs introduced with MRT changes.
the first looks like a definite bug, the second I'm not so confident
of but it works.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-02-03 18:58:11 +10:00
Chia-I Wu
0d089cbb48 egl: Rename _eglPreloadForEach callbacks.
Rename _eglPreloadFile to _eglLoaderFile, and _eglPreloadFile to
_eglLoaderFile.  There are several _eglPreload* functions.  The
callbacks do not belong to them and it should be better to give them a
different prefix.
2010-02-03 14:16:16 +08:00
Chia-I Wu
8e6a964411 egl: Fix a potential segfault in driver suffix matching.
The driver suffix might be NULL on some platforms.  Perform the matching
only when there is a suffix.
2010-02-03 14:16:16 +08:00
Chia-I Wu
2287f4c52a egl: Remove unnecessary #ifdef's.
There were some refactorings with the addition of EGL_DRIVERS_PATH.
They made some platform #ifdef's unnecessary.
2010-02-03 14:16:15 +08:00
Chia-I Wu
6fd8b6a9e2 egl: Ignore certain environment variables when setuid/setgid.
Specifically, ignore EGL_DRIVERS_PATH when an application is
setuid/setgid.  And ignore EGL_DRIVER when there is a slash in it.
2010-02-03 14:16:15 +08:00
Chia-I Wu
5d8646c41f egl: Add EGL_DRIVERS_PATH environment variable.
EGL_DRIVERS_PATH gives a list of colon-separated directories.  The given
directories will be searched when preloading drivers.

This is based on Mike Stroyan's patch, which honors the variable in
_eglPreloadDisplayDrivers.  It is extended to honor the variable also in
_eglPreloadUserDriver and _eglPreloadDefaultDriver in this version.
2010-02-03 14:16:15 +08:00
Brian Paul
6f2e9651a1 draw: remove old hard-coded shader length limits 2010-02-02 21:34:06 -07:00
Brian Paul
439036739d tgsi: added tgsi_alloc_tokens() 2010-02-02 21:23:23 -07:00
Brian Paul
c173eb990a draw: re-implement free_bit() with ffs() 2010-02-02 21:17:56 -07:00
Brian Paul
3d5e26ebec draw: comments and var renaming 2010-02-02 21:16:25 -07:00
Brian Paul
5670b44f82 tgsi: fix comment 2010-02-02 18:54:53 -07:00
Brian Paul
256f7f5ab2 draw: add const qualifiers, fix return types 2010-02-02 18:54:53 -07:00
Brian Paul
d6e55520e4 softpipe: remove unnecessary #include 2010-02-02 18:54:53 -07:00
Brian Paul
c740a7da61 draw: new, updated comments
Try to avoid future confusion between different, but similar functions.
2010-02-02 18:54:53 -07:00
Brian Paul
60b815604e llvmpipe: fix (potentially) broken AA points, AA lines
This patch duplicates the softpipe fix seen in the preceeding commit.
2010-02-02 18:54:53 -07:00
Brian Paul
54d7ec8e76 softpipe: fix broken AA points, AA lines
This fixes a regression when the geometry shaders branch was merged
to master with commit 89d8577fb3.

progs/demos/pointblast and progs/redbook/anti work again.
2010-02-02 18:54:53 -07:00
Corbin Simpson
797dcc04e5 gallium/docs: Opcode refs.
There is a very real possibility that I may be enjoying this too much.
2010-02-02 17:07:26 -08:00
Corbin Simpson
17c2a44761 gallium/docs: TGSI notes on replication to dst, and also cleanups.
Slowly, surely, I'm making this better.
2010-02-02 17:03:42 -08:00
Corbin Simpson
62ca7b85ae gallium/docs: Start turning notes into docs.
Yeah, what's that? You can read it? It's got, hmm, *readability*? Nice,
ain't it. :3
2010-02-02 17:03:41 -08:00
Corbin Simpson
8580522b14 gallium/docs: Add opcode formatting. 2010-02-02 17:03:41 -08:00
Brian Paul
3e572eb25e gallium/docs: default Z texture tuple is (z,z,z,1) for OpenGL 2010-02-02 16:27:07 -07:00
Brian Paul
3a3d8fb72e gallium/docs: s/convensions/conventions/ 2010-02-02 16:20:26 -07:00
Corbin Simpson
95dad1fa1c r300g: Texture format cleanups, per docs.
texenv is perfect now.
2010-02-02 13:03:31 -08:00
José Fonseca
aa8b49c9ca gallium: Move some compiler portability stuff into p_compiler.h 2010-02-02 20:55:08 +00:00
Corbin Simpson
516e7159ae gallium/docs: Did somebody call for a table? 2010-02-02 12:44:22 -08:00
Scott Moreau
3fedfc7128 Track frag shader changes introduced by commit 4769566500
Signed-off-by: Corbin Simpson <MostAwesomeDude@gmail.com>
2010-02-02 11:52:17 -08:00
Keith Whitwell
141b5775c0 svga: fix TXD and TXL opcode translation 2010-02-02 18:01:52 +00:00
Keith Whitwell
c0d5f1d3ad svga: deriv insns not valid in dynamic flow control either 2010-02-02 17:45:32 +00:00
José Fonseca
25357696c3 gallium: Move deprecated pipe/internal/p_winsys_screen.h inside util/u_simple_screen.h 2010-02-02 16:09:56 +00:00
Francisco Jerez
88593fff49 mesa: Add a BITSET_FFS function.
It will be useful for the nouveau DRI driver and IMHO there's no
reason to keep it private.

Signed-off-by: Brian Paul <brianp@vmware.com>
2010-02-02 08:53:57 -07:00
Keith Whitwell
70947e531e svga: texture from lod zero inside dynamic branching
Texture derivatives are potentially undefined inside dynamic branches,
so hardwire lod zero in this case.  Treating all if/endif and loop
constructs as dynamic branches.
2010-02-02 15:34:01 +00:00
José Fonseca
2aaca1df9d gallium: Move p_thread.h and p_atomic.h out of gallium interfaces.
Into os/os_thread.h and util/u_atomic.h respectively.
2010-02-02 15:18:01 +00:00
Brian Paul
4778f46bb5 gallium/docs: table of texture formats and (x,y,z,w) tuples returned by TEX
Maybe someone can convert this into a real table instead of just
preformatted text.
2010-02-02 08:14:43 -07:00
José Fonseca
38f6f23fcf gallium: Make pipe_atomic a regular int32_t. 2010-02-02 14:43:48 +00:00
José Fonseca
28486880ca gallium: pipe/p_inlines.h -> util/u_inlines.h 2010-02-02 14:42:17 +00:00
Corbin Simpson
4fea39721d r300compiler: Add MRT number to debugging output. 2010-02-02 04:53:13 -08:00
Corbin Simpson
4769566500 r300compiler, r300 classic, r300g: Add support for MRTs in the frag shader.
This maybe breaks the vert compiler. Hopefully not.
2010-02-02 04:53:12 -08:00
Michal Krol
ad83f3bf0a tgsi: ureg_DECL_gs_input() accepts shader semantics. 2010-02-02 10:42:13 +01:00
Igor Oliveira
301a9437cc vega: implement tgsi_ureg shaders cache 2010-02-02 00:21:56 -05:00
Igor Oliveira
231d5457b2 vega: change tgsi asm by tgsi_ureg 2010-02-02 00:21:52 -05:00
Pauli Nieminen
7b92cb45b2 r200: Fix EXT_fogcoord rendering.
The fogcoord calue was not pushed to GPU because of implicit float to int conversion.
Fix is to use float pointer to buffer object so no conversion is done in assigment.
2010-02-02 06:09:36 +02:00
Pauli Nieminen
edad20fff1 r200: Fix EXT_fogcoord rendering.
The fogcoord calue was not pushed to GPU because of implicit float to int conversion.
Fix is to use float pointer to buffer object so no conversion is done in assigment
2010-02-02 05:53:13 +02:00
Corbin Simpson
565f0cef26 r300g: Fix funky segfault. 2010-02-01 19:48:24 -08:00
Chia-I Wu
01dcadab8b st/egl: Wrong context might be used in eglBindTexImage.
If the pbuffer surface is current, gctx is set to the current context.
Make sure it is set to OpenGL ES 1 context again before binding.
2010-02-02 11:35:11 +08:00
Chia-I Wu
7fc35811c4 docs: Update for EGL environment variables.
Mention that EGL_DRIVER should be a full path, and add a link from
envvars.html to egl.html.
2010-02-02 11:06:29 +08:00
Chia-I Wu
5fa4ea2934 progs/es2: Fix an assertion failure in tri.
EGL_SURFACE_TYPE is a config attribute, not a surface attribute.  Thanks
to Mike Stroyan for pointing out this error.
2010-02-02 10:45:00 +08:00
Brian Paul
bdf975e9ad st/mesa: fix texture deallocation bug
This fixes a bug reported by Christoph Bumiller on mesa3d-dev.

When a texture is first created as RGBA, then re-defined with
glTexImage(internalFormat=GL_DEPTH_COMPONENT) we failed to deallocate
the original texture.  When this texture was bound as a FBO surface,
the depth/Z surface format was RGBA instead of Z.  Depending on the
driver this led to a failed assertion or FBO validation failure.

This patch does three things:

1. Remove ancient code that mysteriously tested if we were replacing
the smallest mipmap level and tested if the texture was not a cube map
texture.  I can't see any reason for those tests.

2. Move the width=height=depth=0 test to after the code which frees
texture data.  Calling glTexImage with width=height=depth=0 and data=NULL
is a way to free a single mipmap level.

3. Update the code comments.

There are no apparent conform, glean or piglit regressions from this change.

(cherry picked from commit 43e4b58422)
2010-02-01 19:04:16 -07:00
Brian Paul
04b14e26a2 progs/tests: add another FBO test to exercise a RGBA vs. Z texture bug
See comments in file for more details.
2010-02-01 19:02:52 -07:00
Brian Paul
43e4b58422 st/mesa: fix texture deallocation bug
This fixes a bug reported by Christoph Bumiller on mesa3d-dev.

When a texture is first created as RGBA, then re-defined with
glTexImage(internalFormat=GL_DEPTH_COMPONENT) we failed to deallocate
the original texture.  When this texture was bound as a FBO surface,
the depth/Z surface format was RGBA instead of Z.  Depending on the
driver this led to a failed assertion or FBO validation failure.

This patch does three things:

1. Remove ancient code that mysteriously tested if we were replacing
the smallest mipmap level and tested if the texture was not a cube map
texture.  I can't see any reason for those tests.

2. Move the width=height=depth=0 test to after the code which frees
texture data.  Calling glTexImage with width=height=depth=0 and data=NULL
is a way to free a single mipmap level.

3. Update the code comments.

There are no apparent conform, glean or piglit regressions from this change.
2010-02-01 18:55:54 -07:00
Brian Paul
a2ddb3d209 mesa: change _mesa_find_free_register() to find multiple free regs
Before, _mesa_find_free_register() would scan the given shader to
find a free/unused register of the given type.  But subsequent calls
would return the same register again.  This caused a failure in the
_mesa_remove_output_reads() function which sometimes needs several
free temps.

Now use a new function which build a vector of 'used' flags and another
function which searches that vector for an unused register starting at
a position that's incremented for each call.

Fixes fd.o bug 26317.  Note that a regression test for this has been
added to the glean/glsl1 test.

(cherry picked from commit e0d01c9d7f)
2010-02-01 18:00:12 -07:00
Brian Paul
e0d01c9d7f mesa: change _mesa_find_free_register() to find multiple free regs
Before, _mesa_find_free_register() would scan the given shader to
find a free/unused register of the given type.  But subsequent calls
would return the same register again.  This caused a failure in the
_mesa_remove_output_reads() function which sometimes needs several
free temps.

Now use a new function which build a vector of 'used' flags and another
function which searches that vector for an unused register starting at
a position that's incremented for each call.

Fixes fd.o bug 26317.  Note that a regression test for this has been
added to the glean/glsl1 test.
2010-02-01 17:31:24 -07:00
Brice Goglin
eef7b39a36 Prepare changelog for upload 2010-02-01 22:55:49 +01:00
José Fonseca
b90b3667a1 mesa: Ensure object refcount is null when destroying the buffer.
Lets see if this is not too pedantic. Obj pointers are never exposed to
GL apps so it should be possible to get this right.

Furthermore apps with GL widgets and test suits create and destroy many
contexts and objects, so bad reference counting is not really an option.
2010-02-01 21:41:04 +00:00
José Fonseca
0123a2d042 mesa: Fix null buffer object reference counting.
Always use _mesa_reference_buffer_object, and never call
ctx->Driver.DeleteBuffer() directly to prevent dangling pointers to the
null buffer object.

This fixes crash/assertions in sharedtex_mt and Autodesk Mudbox.
2010-02-01 21:41:04 +00:00
José Fonseca
51a2cc5499 mesa: Always do proper ref counting of shared state. 2010-02-01 21:41:04 +00:00
Brice Goglin
04f4a8921b New upstream snapshot 2010-02-01 22:38:35 +01:00
Brice Goglin
7078992fea Merge branch 'upstream-experimental' into debian-experimental 2010-02-01 22:37:11 +01:00
Corbin Simpson
9a1bf52c18 r300g: Inline immediates where possible.
Oh look, more gears. Seems to work just fine though.
2010-02-01 12:48:33 -08:00
Keith Whitwell
e1906ae98e st/mesa: remove duplicate calculation of fp input mapping
This was being calculated the same way in two different places.
Now just do it in st_translate_fragment_program().
2010-02-01 20:42:34 +00:00
Keith Whitwell
d51b04320d st/mesa: remove dead stfp input_map array
Was being calculated and not used.  Also was probably incorrect...
2010-02-01 20:33:53 +00:00
Brian Paul
12ffee5d58 mesa: added _mesa_print_vp/p_inputs() functions (debug aids) 2010-02-01 13:12:53 -07:00
Brian Paul
04c3888cb6 glslcompiler: add glapi_nop.o to OBJECTS 2010-02-01 13:07:07 -07:00
José Fonseca
57839d11ff gallium: Use MSVC atomic intrinsics directly instead of the Windows header wrappers. 2010-02-01 16:12:44 +00:00
José Fonseca
1776e738fb gallium: Remove unnecessary includes. Add others to compensate. 2010-02-01 16:11:46 +00:00
José Fonseca
b232b68cdc mesa: Add missing includes. 2010-02-01 15:12:20 +00:00
José Fonseca
854627387d llvmpipe: Add missing includes. 2010-02-01 15:11:34 +00:00
José Fonseca
f6cecbb361 i915: Add missing includes. 2010-02-01 15:11:18 +00:00
José Fonseca
ad9cc55bed util: Add missing includes. 2010-02-01 15:11:06 +00:00
José Fonseca
06f198285d draw: Add missing includes. 2010-02-01 15:10:51 +00:00
José Fonseca
7827bc73c7 gallium: Drop mutex-based pipe_atomic implementation.
First step to severe the dependency in OS abstractions from the Gallium
interfaces.
2010-02-01 14:23:36 +00:00
Vinson Lee
5cc20a06b0 mesa: Remove unnecessary headers. 2010-02-01 00:43:33 -08:00
Vinson Lee
e3a99e8522 glx: Remove unnecessary headers. 2010-02-01 00:22:50 -08:00
Vinson Lee
12f66b6dc9 st/dri: Remove duplicate type qualifier. 2010-01-31 23:52:48 -08:00
Vinson Lee
dfd76c0044 i965g: Add missing va_end. 2010-01-31 23:47:07 -08:00
Vinson Lee
2de590eacd r300g: Fix memory leak on memory allocation failure. 2010-01-31 22:38:25 -08:00
Vinson Lee
0df64f4bac r600: Remove duplicate assignment. 2010-01-31 22:33:01 -08:00
Vinson Lee
19af9ea792 egl: Remove unnecessary headers. 2010-01-31 21:56:53 -08:00
Marcin Kościelnicki
de917c1c61 nv04: Update to new nouveau_class.h
Signed-off-by: Francisco Jerez <currojerez@riseup.net>
2010-02-01 01:30:19 +01:00
Marcin Slusarz
112def3c17 nv50/nv40/nv30: fix small memory leak of nouveau_resources on screen_destroy
Signed-off-by: Francisco Jerez <currojerez@riseup.net>
2010-02-01 01:28:06 +01:00
Francisco Jerez
71b32cc838 nv10, nv20: Fix build. 2010-02-01 01:26:36 +01:00
Chia-I Wu
eb961f81d5 egl: Clean up surface attributes.
Add missing attributes and use correct types in _EGLSurface.  Remove
ifdef tests that serve no purpose.  Update _eglQuerySurface and
_eglSurfaceAttrib for missing queries and checks.
2010-01-31 22:21:26 +08:00
Chia-I Wu
0135e5d6c8 egl: Add support for more EGLImage extensions to EGL core.
Add support EGL_KHR_vg_parent_image and EGL_KHR_gl_*.  This is as simple
as adding some flags that can be enabled.  Individual drivers need to
implement the extensions before enbaling the flags.
2010-01-31 22:20:42 +08:00
Vinson Lee
f8f2520e88 st/mesa: Remove unnecessary headers. 2010-01-31 02:34:51 -08:00
Vinson Lee
980fa564e4 mesa: Remove unnecessary headers. 2010-01-31 02:30:12 -08:00
Vinson Lee
c8f781e0ad i965: Silence uninitialized variable warning. 2010-01-31 00:44:57 -08:00
Vinson Lee
d36e90f580 r300g: Silence uninitialized variable warning. 2010-01-30 22:50:35 -08:00
Chia-I Wu
bbdce27649 egl: Surface type validaction should depend on extensions supported.
EGL_SCREEN_BIT_MESA is a valid bit only when EGL_MESA_screen_surface is
supported.
2010-01-31 14:46:15 +08:00
Chia-I Wu
216925ccd1 egl: Initialize display configs with the display.
This changes _eglInitConfig to take the display as its argument.
2010-01-31 14:46:14 +08:00
Chia-I Wu
d69242be55 egl: Initialize display resources with their display.
Change _eglInitSurface, _eglInitContext, and _eglInitImage to take an
_EGLDisplay instead of an _EGLDriver.  This is a more natural form, and
plus, the display encodes information such as the extensions supported
that might be required for attribute list parsing.
2010-01-31 14:46:14 +08:00
Chia-I Wu
e694ccad80 egl: Refactor _eglInitImage.
Refactor attribute list parsing code to _eglParseImageAttribList.
2010-01-31 14:46:14 +08:00
Chia-I Wu
caa5c8dfe8 egl: Refactor _eglInitContext.
Refactor attribute list parsing code to _eglParseContextAttribList.  Add
a check to make sure the config supports the client API.
2010-01-31 14:46:14 +08:00
Chia-I Wu
6f1529293f egl: Refactor _eglInitSurface.
Refactor attribute list parsing code to _eglParseSurfaceAttribList.
2010-01-31 14:46:13 +08:00
Vinson Lee
5ad488908b i915: Set bit field of length 1 light_twoside to unsigned. 2010-01-30 22:36:54 -08:00
Vinson Lee
bc783f3d38 glut: Remove unnecessary headers. 2010-01-30 22:24:34 -08:00
José Fonseca
bee9964b29 Merge remote branch 'origin/master' into lp-binning
Conflicts:
	Makefile
	src/gallium/auxiliary/util/u_surface.c
	src/gallium/drivers/llvmpipe/lp_flush.c
	src/gallium/drivers/llvmpipe/lp_setup.c
	src/gallium/drivers/llvmpipe/lp_state_derived.c
	src/gallium/drivers/llvmpipe/lp_state_fs.c
	src/gallium/drivers/llvmpipe/lp_state_surface.c
	src/gallium/drivers/llvmpipe/lp_tex_cache.c
	src/gallium/drivers/llvmpipe/lp_texture.c
	src/gallium/drivers/llvmpipe/lp_tile_cache.c
	src/mesa/state_tracker/st_cb_condrender.c
2010-01-31 05:36:33 +00:00
Vinson Lee
8a2cf4549a radeon: Remove unnecessary headers. 2010-01-30 21:32:09 -08:00
Vinson Lee
1a0d1fa36d r600: Remove unnecessary headers. 2010-01-30 21:11:04 -08:00
Vinson Lee
b41f963136 r300: Remove unnecessary headers. 2010-01-30 20:49:42 -08:00
Vinson Lee
391892b0d8 r200: Remove unnecessary headers. 2010-01-30 20:43:23 -08:00
Vinson Lee
12eb32e342 r128: Remove unnecessary headers. 2010-01-30 20:24:13 -08:00
Chia-I Wu
996fd61442 egl: Remove code blocks that are commented out.
They are either unit tests or to demonstrate how functions are supposed
to be used.  The unit test is outdated and it should be better to take a
look at any of the working drivers to see how a function is used.
2010-01-31 11:31:58 +08:00
Chia-I Wu
89e6eb5fbe progs/egl: Update eglinfo to display more attributes.
Add config caveat, bind-to-texture, and renderable type.  Remove double
buffer and stereo attributes.
2010-01-31 11:20:15 +08:00
Chia-I Wu
66f0517695 st/egl: Do not ignore configs without a renderable type.
Configs without a renderable type are still informative for programs
such as eglinfo.
2010-01-31 11:20:15 +08:00
Chia-I Wu
6d12c7083e st/egl: Remove egl_g3d_get_current_context.
There is now _eglGetAPIContext that can return the current context of
the given API.
2010-01-31 11:20:15 +08:00
Vinson Lee
c6e26d76c7 intel: Remove unnecessary headers. 2010-01-30 19:11:31 -08:00
Vinson Lee
6e0f702b23 i965: Remove unnecessary headers. 2010-01-30 19:01:19 -08:00
Vinson Lee
c641703f21 i915: Remove unnecessary headers. 2010-01-30 18:54:56 -08:00
Eric Anholt
22bbc97994 intel: Respect texture tiling when doing a PBO blit teximage upload.
Bug #26008.  Fixes piglit pbo-teximage-tiling-2.
2010-01-30 15:12:23 -08:00
Corbin Simpson
a794c660d3 Revert "r300g: Don't handle SHADOW_AMBIENT."
This reverts commit 627a45848f.

I was wrong. Who could have known? :3
2010-01-30 14:30:13 -08:00
Eric Anholt
a44219c554 intel: Fix inverting of inversion test for windows in glClear cleanup.
Bug #26290.
2010-01-30 12:38:31 -08:00
Corbin Simpson
b6ac2403ac r300g: Independent blend enables only work on r500. 2010-01-30 12:33:44 -08:00
Corbin Simpson
627a45848f r300g: Don't handle SHADOW_AMBIENT.
Bisected so that only this commit has to be reverted if I'm wrong.

...Pfft, like I'm ever wrong. :3
2010-01-30 12:23:43 -08:00
Corbin Simpson
f7467f7437 r300g: Fix comment on SHADOW_AMBIENT. 2010-01-30 12:23:24 -08:00
Corbin Simpson
268cc5ff38 gallium-docs: Fix missing PIPE_CAPs.
Hmm, need to cross-ref those TGSI things. My work is never done... :3
2010-01-30 12:16:10 -08:00
Corbin Simpson
bfbec0818f r300g: Dual-source blending isn't possible, period. 2010-01-30 12:03:20 -08:00
Mathias Fröhlich
5a64bdaa01 r300g: Add alpha render targets.
Signed-off-by: Corbin Simpson <MostAwesomeDude@gmail.com>
Tested-by: Mathias Fröhlich <Mathias.Froehlich@gmx.net>
2010-01-30 11:40:41 -08:00
Chia-I Wu
7056a74734 progs/es1: Add bindtex.
It is ported from progs/egl/xeglbindtex.c.  With the OpenGL ES port, the
OpenGL version is removed.
2010-01-30 23:16:17 +08:00
Chia-I Wu
5714e674c7 st/egl: eglBindTexImage should bind to an OpenGL ES texture.
The spec says that it only works with OpenGL ES.
2010-01-30 23:15:21 +08:00
Chia-I Wu
2c3a23a96f egl: Remove my_strdup.
There is already _eglstrdup for the main library's use.
2010-01-30 23:02:45 +08:00
Chia-I Wu
6fc304456e egl: Remove unused VisibleRefCount. 2010-01-30 22:58:03 +08:00
Chia-I Wu
00e1790f32 egl: Rename Binding to CurrentContext in _EGLSurface.
A context can be bound to a surface just like it can be bound to a
thread.  CurrentContext is a more consistent name.
2010-01-30 22:57:18 +08:00
Chia-I Wu
94cb321b5d egl: Clean up header inclusions.
Mainly to remove eglcurrent.h and egldisplay.h from eglglobals.h.
2010-01-30 22:55:49 +08:00
Roland Scheidegger
847ac8ec5f gallium: fix blend state cso
if independent blend state was disabled, only the data from first rt was
stored, however the comparison used the full state, hence there never was
a match and always a new object was created.
Fixes a huge performance drop with llvmpipe due to recompilation.
2010-01-30 01:58:00 +01:00
Brian Paul
b8d4cbd7e2 progs/demos: new image dissolve demo
Dissolve between two images using a random pattern in the stencil
buffer and a varying stencil ref value.
2010-01-29 14:01:34 -07:00
Brian Paul
98f3f1c695 gallium: document pipe_context::get_query_result() 2010-01-29 14:01:34 -07:00
Keith Whitwell
3fc73c389a Merge commit 'lb2/arb_fragment_coord_conventions' 2010-01-29 20:24:26 +00:00
Corbin Simpson
882279d31a docs: Mark what I've been up to.
Brian, feel free to split/revert if you disagree.
2010-01-29 09:54:42 -08:00
Jakob Bornecrantz
f5145a6ec3 vmware/core: Remove old ioctl structs not used
Leftover that was never used in this driver
2010-01-29 17:14:53 +01:00
José Fonseca
ddedfe12d4 svga: Actually call fence_reference in texture downloads. 2010-01-29 16:23:46 +00:00
Brian Paul
e94021660b progs/tests: added a few more files to .gitignore 2010-01-29 08:43:28 -07:00
Brian Paul
6fea2be795 tnl: check that state is validated before drawing
(cherry picked from commit 9fd3c74724)

Conflicts:

	src/mesa/tnl/t_draw.c
2010-01-29 08:40:46 -07:00
Brian Paul
987dd63b90 st/mesa: check that state is validated before drawing
(cherry picked from commit 4d1234e222)

Conflicts:

	src/mesa/state_tracker/st_draw.c
2010-01-29 08:39:47 -07:00
Brian Paul
5ce9183c1c vbo: fix missing state validation bugs
Commit 2708ddfb06 caused a few regressions.
We need to check/validate state after calling bind_arrays() because
it might set the _NEW_ARRAYS flag if the varying VP inputs change.

The symptom of this problem was some attribute arrays being ignored
(or interpreted as constant-valued) in glDrawRangeElements or
glMultiDrawElements.

A follow-on patch will add some additional asserts to try to catch
this kind of thing in the future.

(cherry picked from commit 3cba779e16)
2010-01-29 08:38:21 -07:00
Brian Paul
a38859569d mesa: do state validation in _mesa_valid_to_render()
...rather than checking/validating before all the calls to
_mesa_valid_to_render() and valid_to_render().

The next patch will actually fix some bugs...

(cherry picked from commit 23eda89ec8)
2010-01-29 08:38:11 -07:00
Brian Paul
364b008d18 docs: Fixed Windows build for 7.7.1
(cherry picked from commit a0518e66b2)
2010-01-29 08:37:31 -07:00
Brian Paul
ee5e84eba6 windows: assorted build fixes
These changes were originally submitted by Karl Schultz for Mesa 7.7-rc2
but weren't applied.

(cherry picked from commit 82c76cd16f)
2010-01-29 08:37:15 -07:00
Rodolfo Ribeiro Gomes
81cca6d453 glx: fix possible memory leaks in dri2CreateScreen()
Original patch fixed up by Brian Paul.
2010-01-29 08:36:47 -07:00
Brian Paul
4886f677ec mesa: Warn when indices are out of bounds, but do not skip the draw in debug builds.
The driver (or preferably the hardware) should handle out of bounds
indices.

If there are problems then it's better to detect those in the debug
builds.

(cherry picked from commit e3257912e0)
2010-01-29 08:31:48 -07:00
Brian Paul
cb5447f79c glsl: fix preprocessor bug involving //-style comments in macro definitions
See comments for details.
2010-01-29 08:26:23 -07:00
Brian Paul
9fd3c74724 tnl: check that state is validated before drawing 2010-01-29 08:24:36 -07:00
Brian Paul
4d1234e222 st/mesa: check that state is validated before drawing 2010-01-29 08:24:36 -07:00
Brian Paul
3cba779e16 vbo: fix missing state validation bugs
Commit 2708ddfb06 caused a few regressions.
We need to check/validate state after calling bind_arrays() because
it might set the _NEW_ARRAYS flag if the varying VP inputs change.

The symptom of this problem was some attribute arrays being ignored
(or interpreted as constant-valued) in glDrawRangeElements or
glMultiDrawElements.

A follow-on patch will add some additional asserts to try to catch
this kind of thing in the future.
2010-01-29 08:24:36 -07:00
Brian Paul
23eda89ec8 mesa: do state validation in _mesa_valid_to_render()
...rather than checking/validating before all the calls to
_mesa_valid_to_render() and valid_to_render().

The next patch will actually fix some bugs...
2010-01-29 08:24:36 -07:00
Luca Barbieri
b2299d80b4 softpipe: support all TGSI fragment coord conventions (v4)
Changes in v4:
- Rebase and modify for changes in previous patches

Changes in v3:
- Use positive caps instead of negative caps

Changes in v2:
- Now takes the fragment convention directly from the fragment shader

Adds internal support for all fragment coord conventions to softpipe.

This patch is not required for use with the current state trackers, but it
allows softpipe to run any TGSI program and enhances performance.
2010-01-29 14:14:29 +01:00
Luca Barbieri
62c673b6ac st/mesa: Gallium support for ARB_fragment_coord_conventions (v4)
Changes in v4;
- Implemented Brian Paul's style suggestions

Changes in v3:
- Use positive caps instead of negative ones

Changes in v2:
- Updated formatting

The state tracker will use the TGSI convention properties if the hardware
exposes the appropriate capability, and otherwise adjust WPOS itself.

This will also fix some drivers that were previously broken due to their
incorrect, inadvertent, use of conventions other than upper_left+half_integer.
2010-01-29 14:14:29 +01:00
Luca Barbieri
6c403750d6 tgsi: add caps for fragment coord conventions (v3)
Changes in v3:
- Renumber caps to accomodate caps to add to master in the meantime
- Document caps
- Add unsupported caps to *_screen.c too

Changes in v2:
- Split for properties patch
- Use positive caps instead of negative caps

This adds 4 caps to indicate support of each of the fragment coord
conventions.

All drivers are also modifed to add the appropriate caps.

Some drivers were incorrectly using non-Gallium-default conventions,
and caps for them have them set so that they will behave correctly
after the later state tracker patches.

This drivers are softpipe/llvmpipe (uses integer rather than half
integer) and pre-nv50 Nouveau (uses lower left rather than upper left).

Other drivers might be broken. With this patchset, fixing them is
only a matter of exposing the appropriate caps that match the behavior
of the existing code.

Drivers are encouraged to support all conventions themselves for better
performance, and this feature is added to softpipe in a later patch.
2010-01-29 14:13:14 +01:00
Luca Barbieri
73317139a4 tgsi: add properties for fragment coord conventions (v3)
Changes in v3:
- Documented the new properties
- Added comments for property values
- Rebased to current master

Changes in v2:
- Caps are added in a separate, subsequent patch

This adds two TGSI fragment program properties that indicate the
fragment coord conventions.

The properties behave as described in the extension spec for
GL_ARB_fragment_coord_conventions, but the default origin in
upper left instead of lower left as in OpenGL.

The syntax is:
PROPERTY FS_COORD_ORIGIN [UPPER_LEFT|LOWER_LEFT]
PROPERTY FS_COORD_PIXEL_CENTER [HALF_INTEGER|INTEGER]

The names have been chosen for consistency with the GS properties
and the OpenGL extension spec.

The defaults are of course the previously assumed conventions:
UPPER_LEFT and HALF_INTEGER.
2010-01-29 14:13:14 +01:00
Luca Barbieri
3cea5525d0 mesa: don't expose GL_ARB_fragment_coord_conventions until the GLSL part is done
Exposing it was incorrect, as the GLSL part of the extension is
missing.

We still keep the ARB_fragment_coord_conventions field, so that the
ARBfp parser can know whether to accept or reject the keywords.
2010-01-29 14:13:13 +01:00
Alan Hourihane
7683271e63 another gcc 4.2.x check for mstackrealign 2010-01-29 10:22:50 +00:00
Vinson Lee
df8273494e glu/sgi: Remove unnecessary headers. 2010-01-28 18:07:04 -08:00
Vinson Lee
548b9c4ece svga: Remove unnecessary headers. 2010-01-28 17:32:33 -08:00
Vinson Lee
7280c4c9fe softpipe: Remove unnecessary header. 2010-01-28 15:56:50 -08:00
Vinson Lee
1a2f9d722e llvmpipe: Remove unnecessary header. 2010-01-28 15:54:57 -08:00
Vinson Lee
fc4939bff9 egl: Remove unnecessary headers. 2010-01-28 15:39:11 -08:00
Vinson Lee
d40070029f progs/tests: Remove unnecessary headers. 2010-01-28 15:11:39 -08:00
Vinson Lee
bbb41153c2 progs/glsl: Fix bump GLSL compilation error on Mac OS. 2010-01-28 14:58:24 -08:00
Vinson Lee
77b1f2fbcf progs/glsl: Remove unused variable in bump.c. 2010-01-28 14:54:10 -08:00
Vinson Lee
07fb52bcf6 progs/glsl: Remove unnecessary header from samplers.c. 2010-01-28 14:22:15 -08:00
Corbin Simpson
0087322729 r300g: Clean up blend masks, change caps.
progs/tests/drawbuffers should work, except I can't test it. GG new
shader parser. GG.
2010-01-28 13:39:47 -08:00
Corbin Simpson
2e481e9fad gallium-docs: Minor grammar, need to talk about dual-source blends. 2010-01-28 13:37:09 -08:00
Corbin Simpson
505a43aff2 gallium-docs: Clean up constantbuf info a bit.
Hmm, does this belong in context, next to set_constant_buffer? Maybe
a paragraph in shaders might be useful.
2010-01-28 12:35:12 -08:00
Corbin Simpson
a5f7c63fc0 gallium-docs: Add PIPE_CAP info. 2010-01-28 12:22:51 -08:00
José Fonseca
6e68898b05 softpipe: Flush draw module when fragment pipeline state changes. 2010-01-28 20:22:44 +00:00
José Fonseca
1befcd5a2a softpipe: Flush draw module before switching framebuffer.
Otherwise geometry might end up in the wrong rendertarget.
2010-01-28 20:22:44 +00:00
José Fonseca
12ba355978 llvmpipe: Use assert instead of abort. Only verify functions on debug builds. 2010-01-28 20:22:43 +00:00
José Fonseca
a0907a645f llvmpipe: Fix memory leak. 2010-01-28 20:22:43 +00:00
José Fonseca
1acf7a09e7 llvmpipe: Use the generic conversion routine for depths.
This allows for z32f depth format to work correctly.
2010-01-28 20:22:43 +00:00
José Fonseca
14dc02a1b2 llvmpipe: Be more conservative with the supported formats.
We'll likely support much more formats, but doing this allows to run
more testsuites without immediately hit assertion failures.
2010-01-28 20:22:43 +00:00
José Fonseca
88cf87bd56 llvmpipe: Unmapping vertex/index buffers does NOT flush draw module anymore.
Not since 6094e79f4e.

Drivers now need to flush draw module explicitely (which explains why
all those previous commits adding draw_flushes calls were necessary).

This is a good thing, but it's tricky to get this right in face of user buffers
(it's not even clear who has the responsibility to flush when a user buffer
is seen -- statetracker or pipe driver), so just force flush (temporarily)
since it's not a bottleneck now.
2010-01-28 20:22:43 +00:00
José Fonseca
31b3420688 llvmpipe: Treat state changes systematically.
That is:
- check for no op
- update/flush draw module
- update bound state and mark it as dirty

In particular flushing the draw module is important since it may contain
unflushed primitives which would otherwise be draw with wrong state.
2010-01-28 20:22:43 +00:00
José Fonseca
4e95983fa8 llvmpipe: Flush draw module before switching framebuffer.
Otherwise geometry will end up in the wrong rendertarget.
2010-01-28 20:22:43 +00:00
José Fonseca
4e506eac8f llvmpipe: add LP_DEBUG env var
Cherry-picked from dec35d04ae.
2010-01-28 20:22:43 +00:00
Brian Paul
46167149ce llvmpipe: fix broken TGSI_OPCODE_FRC codegen 2010-01-28 20:22:42 +00:00
Brian Paul
96ec4eb755 llvmpipe: fix broken lp_build_abs() 2010-01-28 20:22:42 +00:00
José Fonseca
e20547042c llvmpipe: Fix yet another copynpaste typo in lp_build_log2_approx.
Now fslight looks perfect.
2010-01-28 20:22:42 +00:00
José Fonseca
0451d0fd01 llvmpipe: Fix lp_build_polynomial comment. 2010-01-28 20:22:42 +00:00
José Fonseca
aa8b23e077 llvmpipe: Fix typo in lp_build_log constant. 2010-01-28 20:22:42 +00:00
José Fonseca
4eb48a3af7 llvmpipe: Fix bad SI -> FP conversion into lp_build_log2_approx.
It should be a bitcast  as the integer value is actually an encoded FP
already.
2010-01-28 20:22:42 +00:00
Eric Anholt
f20e83210e intel: Set the region's tiling to none when attaching a PBO to a region.
Note that when detaching the PBO from the region and making a new BO
for the region, we don't make it tiled even if the region originally
was.

Fixes piglit pbo-teximage-tiling.
2010-01-28 10:55:25 -08:00
Eric Anholt
c9886d535e i915: Remove unused initial and current state, now that there's nothing else. 2010-01-28 10:55:25 -08:00
Eric Anholt
f9439e4a46 intel: Remove long-disabled meta readpixels, and associated meta support. 2010-01-28 10:55:25 -08:00
Jakob Bornecrantz
c75e238434 st/xorg: Update to new libkms interface but be backwards compatible 2010-01-28 18:37:54 +00:00
Alan Hourihane
32e6043150 define own embedded target and cleanup previous commit. 2010-01-28 17:26:05 +00:00
Alan Hourihane
75cd6f3ece Don't define HAVE_POSIX_MEMALIGN for embedded target. 2010-01-28 17:23:31 +00:00
Jakob Bornecrantz
8db8adfd01 st/xorg: Update to new libkms interface but be backwards compatible 2010-01-28 18:02:10 +01:00
Keith Whitwell
8e240d7e0e svga: remove sleep in DEBUG_FLUSH path 2010-01-28 17:13:50 +00:00
José Fonseca
40298bf272 python/retrace: Dump all vertices for verbosity level 3. 2010-01-28 17:13:49 +00:00
Roland Scheidegger
9b346f83a7 Merge commit 'origin/perrtblend'
Conflicts:
	src/gallium/drivers/softpipe/sp_screen.c
	src/gallium/include/pipe/p_defines.h
2010-01-28 17:23:58 +01:00
Roland Scheidegger
2fa34bf44c gallium: remove PIPE_CAP_S3TC, and add PIPE_CAP_DUAL_SOURCE_BLEND
there's no point in keeping deprecated PIPE_CAPS around since there's no
stable interface (yet).
Reuse the enum for PIPE_CAP_DUAL_SOURCE_BLEND. Drivers advertizing this
will accept the pipe blendfactors with SRC1 in them and be able to do dual
source blending (src color from pixel shader output 0, and blendfactor with
SRC1 will come from output 1, only one render target may be bound when using
any of these blend factors).
2010-01-28 17:11:49 +01:00
Alan Hourihane
bd60e6cd5c add PIPE_SUBSYSTEM_EMBEDDED when embedded platform used 2010-01-28 15:34:10 +00:00
Michal Krol
9e895831bc tgsi: Constants declared with ureg_DECL_constant() are one-dimensional.
This is to maintain backward compatibility with drivers
that don't support arrays of constant buffers.
2010-01-28 14:08:22 +01:00
Michal Krol
3ba2ab3a23 tgsi: Add ureg_property_gs_output_prim/max_vertices(). 2010-01-28 14:08:19 +01:00
Michal Krol
6522804cb3 docs: Implement constant buffer CAPs. 2010-01-28 14:08:16 +01:00
Michal Krol
3320acb67d softpipe: Report some sane values for constant buffer CAP queries. 2010-01-28 14:08:12 +01:00
Michal Krol
25123e0c88 gallium: Add CAPs for constant buffers. 2010-01-28 14:08:08 +01:00
Michal Krol
7c5f255201 gallium: Rename PIPE_MAX_CONSTANT to PIPE_MAX_CONSTANT_BUFFERS. 2010-01-28 14:08:03 +01:00
Michal Krol
333c035a51 regress: Add vertex shaders tests for constant buffers. 2010-01-28 14:07:58 +01:00
Michal Krol
9851644435 gallium: Enable multiple constant buffers for vertex and geometry shaders. 2010-01-28 14:07:53 +01:00
Michal Krol
44ac4c4e2c regress: Add fragment shader test for one-dimensional constant buffers. 2010-01-28 14:07:48 +01:00
Michal Krol
4771e536e1 regress: Add two-dimension constant buffer test. 2010-01-28 14:07:45 +01:00
Michal Krol
91d58c3520 python: Link to ws2_32 on windows. 2010-01-28 14:07:42 +01:00
Michal Krol
dcf8543ab3 tgsi: Handle two-dimensional constants in text parser. 2010-01-28 14:07:38 +01:00
Michal Krol
d96bb01d2d regress: Fix shader header. 2010-01-28 14:07:34 +01:00
Michal Krol
835bab0143 gallium: Implement 2D constant buffers for fragment shader in softpipe. 2010-01-28 14:07:29 +01:00
Michal Krol
4367de152c tgsi: Handle 2-D declarations. 2010-01-28 14:07:24 +01:00
Michal Krol
0adfdaeaa1 gallium: Add tgsi_declaration_dimension token.
This will allow us to declare two-dimensional constant buffers.
2010-01-28 14:07:19 +01:00
Corbin Simpson
241a0b8cf3 radeong: Slight improvement to buffer creation. 2010-01-28 03:05:46 -08:00
Corbin Simpson
f0a3f824ac gallium-docs: Moar buffer info.
Oh look, that one question about map_buffer_range is answered.
2010-01-28 03:05:46 -08:00
Corbin Simpson
2102ee204c gallium-docs: Start doc'ing screen buffers. 2010-01-28 03:05:46 -08:00
Corbin Simpson
12f97d9c09 r300g: Fix bizarre half-flushes with immd mode. 2010-01-28 03:05:46 -08:00
Corbin Simpson
b9ae570bab r300g: Atomize framebuffers.
There might be some optimizations possible here...
2010-01-28 03:05:46 -08:00
Chia-I Wu
14cbf324dc docs: Update the developer section of egl.html.
Mainly to add a subsection on the lifetime of display resources.
2010-01-28 18:10:05 +08:00
Vinson Lee
51ab599ddb scons: Do not use linker option '-Bsymbolic' on Mac OS X.
ld on Mac OS X does not recognize the option '-Bsymbolic'.
2010-01-28 01:34:40 -08:00
Chia-I Wu
6baa2c8d02 egl: Migrate drivers to use _eglBindContext.
_eglMakeCurrent is a big hammer that is not easy to use.  Migrate
drivers to use _eglBindContext and un-export _eglMakeCurrent.
2010-01-28 17:28:48 +08:00
Chia-I Wu
45ba533243 egl: Correctly unbind contexts in eglReleaseThread.
MakeCurrent unbinds the current context of the current API.  Modify the
current API to make sure all contexts are correctly unbound.
2010-01-28 17:28:48 +08:00
Chia-I Wu
17330479b3 egl: eglMakeCurrent should accept an uninitialized display.
When no context or surface are given, the display is allowed to be
uninitialized.  Most drivers cannot handle an uninitialized display.
But they are updated to at least throw a fatal message.
2010-01-28 17:28:47 +08:00
Chia-I Wu
959481ad70 egl: Add _eglBindContext.
It works similar to _eglMakeCurrent, except that the old context and
surfaces are returned instead of destroyed.  _eglMakeCurrent is now
calling the new _eglBindContext.
2010-01-28 17:28:47 +08:00
Chia-I Wu
a933259daa egl: Use a boolean to indicate whether a display is initialized.
The driver pointer of the display was used to decide whether a display
is initialized.  Use a boolean for that purpose allows accessing the
driver of an uninitialized display.
2010-01-28 17:28:47 +08:00
Vinson Lee
8f81769148 scons: Fix GLEW build on Mac OS X. 2010-01-28 01:19:53 -08:00
Vinson Lee
5dcc088bf1 tgsi: Silence uninitialized variable warning. 2010-01-28 00:40:43 -08:00
Vinson Lee
1eb1d4e238 radeon: Silence "format" compiler warnings. 2010-01-28 00:33:30 -08:00
Vinson Lee
347cd2b0d5 st/xorg: Remove unnecessary headers. 2010-01-28 00:25:20 -08:00
Vinson Lee
4030cd5a2d st/dri: Remove unnecessary headers. 2010-01-28 00:20:22 -08:00
Vinson Lee
c2bd1657a8 llvmpipe: Remove unnecessary headers. 2010-01-27 18:08:37 -08:00
Brian Paul
714d3ec9bc swrast: s/FIXED_TO_FLOAT/FixedToFloat/ 2010-01-27 17:48:34 -07:00
Brian Paul
36a0819ff4 llvmpipe: added debug option to disable LLVM optimization passes 2010-01-27 17:16:42 -07:00
Vinson Lee
978568c647 r300g: Remove unnecessary headers. 2010-01-27 16:12:51 -08:00
Brian Paul
a0518e66b2 docs: Fixed Windows build for 7.7.1 2010-01-27 17:08:03 -07:00
Brian Paul
82c76cd16f windows: assorted build fixes
These changes were originally submitted by Karl Schultz for Mesa 7.7-rc2
but weren't applied.
2010-01-27 17:04:49 -07:00
Rodolfo Ribeiro Gomes
50e890bc51 glx: fix possible memory leaks in dri2CreateScreen()
Original patch fixed up by Brian Paul.
2010-01-27 17:04:49 -07:00
Brian Paul
dd89ac249c mesa: fix int/uint comparison warnings
Reported by Karl Schultz.
2010-01-27 17:04:30 -07:00
Brian Paul
20fbb24b67 mesa: fix double->float assignment warnings, int/uint comparison warnings
Reported by Karl Schultz.
2010-01-27 17:04:30 -07:00
Brian Paul
6703fb1917 mesa: fix double->float assignment warnings
Reported by Karl Schultz.
2010-01-27 17:04:30 -07:00
Brian Paul
ca0d048e4e mesa: fix int/uint comparison warnings
Reported by Karl Schultz.
2010-01-27 17:04:30 -07:00
Brian Paul
28bd4a1d81 tnl: fix double->float and int/uint conversion warnings
Reported by Karl Schultz.
2010-01-27 17:04:30 -07:00
Brian Paul
880411c72a swrast: silence double->float assignment warnings
Reported by Karl Schultz.
2010-01-27 17:04:30 -07:00
Brian Paul
4e5364d6fc mesa: more info in glActiveTexture error msg 2010-01-27 17:04:30 -07:00
Brian Paul
f103f7e460 configs: added vega to default GALLIUM_STATE_TRACKERS_DIRS 2010-01-27 17:04:30 -07:00
Vinson Lee
83e6ba564c i965g: Remove unnecessary headers. 2010-01-27 15:54:21 -08:00
Vinson Lee
f7f59b50ce util: Remove unnecessary header. 2010-01-27 15:35:58 -08:00
Vinson Lee
00c3607917 tgsi: Remove unnecessary header. 2010-01-27 15:32:48 -08:00
Vinson Lee
83d2b4d4a6 gallium/draw: Remove unnecessary headers. 2010-01-27 15:06:13 -08:00
Vinson Lee
01ed5c6ef5 r300g: Silence GCC "missing braces around initializer" warning. 2010-01-27 14:04:53 -08:00
Brian Paul
e95ad2a2b5 llvmpipe: count/report time spent in LLVM compilations 2010-01-27 13:49:43 -07:00
Brian Paul
5460da5436 gallium/util: comments for time-related functions 2010-01-27 13:46:43 -07:00
Brian Paul
99f1e32fad gallium/util: print dlerror() info upon dlopen() failure 2010-01-27 13:46:23 -07:00
Alex Deucher
bba9557019 r600: fix warning 2010-01-27 12:20:04 -05:00
Alex Deucher
2041d3e4b7 r600: rv670 support 8 tex instructions just like other r6xx
also clarify some other const values.
2010-01-27 12:19:54 -05:00
Alex Deucher
ccb4ba3e3b r600: fix warning 2010-01-27 12:18:02 -05:00
Alex Deucher
1fdf04ade3 r600: rv670 support 8 tex instructions just like other r6xx
also clarify some other const values.
2010-01-27 12:16:50 -05:00
Andre Maasikas
77b7b3a1ab r600: increase max texture units to 16 2010-01-27 11:38:29 -05:00
Andre Maasikas
0dab80fbfb r600: fix XPD with writemask
same variable used for 2 different temp registers
fixes e.g. glsl/bump
2010-01-27 11:38:16 -05:00
Brian Paul
b8656c4825 cell: remove commas from structs wrapped in PIPE_ALIGN_TYPE macro
This avoids the need to make PIPE_ALIGN_TYPE a variadic macro.
2010-01-27 09:26:39 -07:00
José Fonseca
e3257912e0 mesa: Warn when indices are out of bounds, but do not skip the draw in debug builds.
The driver (or preferably the hardware) should handle out of bounds
indices.

If there are problems then it's better to detect those in the debug
builds.
2010-01-27 16:25:31 +00:00
José Fonseca
15fe491822 svga: Prevent buffer overflow in buffer ranges.
Do this by extending the nearest range to cover the new range.

This fixes an access fault in Call of Duty which was doing many disjoint
glBufferSubData calls.
2010-01-27 15:41:25 +00:00
José Fonseca
ac597f5acc svga: Fix PIPE_LOGICOP_INVERT.
Actually the current XOR implementation is an INVERT.

This fixes rectangle selection in Maya.
2010-01-27 14:45:56 +00:00
Keith Whitwell
5cb255f0d7 svga: better path for generating white pixels for xor logicop workaround 2010-01-27 14:26:48 +00:00
Alan Hourihane
1ecf505087 Duplicate CCVERSION check code to compensate for different env CC. 2010-01-27 12:46:46 +00:00
Andre Maasikas
07d47cb92d r600: increase max texture units to 16 2010-01-27 11:22:56 +02:00
Andre Maasikas
fb24c2678a r600: fix XPD with writemask
same variable used for 2 different temp registers
fixes e.g. glsl/bump
2010-01-27 10:22:32 +02:00
Brice Goglin
adcbe9af69 Prepare changelog for upload 2010-01-27 09:14:43 +01:00
Brice Goglin
527f2433fc New upstream snapshot 2010-01-27 09:14:16 +01:00
Brice Goglin
81f129113a Merge branch 'mesa_7_7_branch' of git://anongit.freedesktop.org/mesa/mesa into debian-experimental
Conflicts:
	progs/tests/getprocaddress.c
	progs/tests/vparray.c
	progs/trivial/tri-fbo-tex-mip.c
	progs/trivial/tri-fbo-tex.c
	scons/gallium.py
2010-01-27 09:12:04 +01:00
Brice Goglin
9abcffc1c6 Merge branch 'debian-unstable' into debian-experimental
Conflicts:
	debian/changelog
2010-01-27 09:09:36 +01:00
Vinson Lee
2a06221822 softpipe: Remove unnecessary header. 2010-01-26 23:28:23 -08:00
Vinson Lee
aa2423b5b3 i915g: Remove unnecessary headers. 2010-01-26 23:26:41 -08:00
Vinson Lee
7d29afb3a2 scons: Use '-Werror=' option on GCC 4.2.x and greater.
The existing code only checked for GCC 4.2.x and 4.3.x.
2010-01-26 22:56:58 -08:00
Corbin Simpson
fc20efe8e5 r300g: Turn the RS block into an atom.
At least one extraneous dirty was eliminated, as well as the chance for
avoiding dirty on shader change.
2010-01-26 22:08:11 -08:00
Corbin Simpson
60aa7f1f80 r300g: Make vertex_format into an atom.
Some delicious hax here.
2010-01-26 21:49:02 -08:00
Corbin Simpson
e62520de70 r300g: Kill dead code for hashing custom state.
It just wasn't meant to be.
2010-01-26 21:41:44 -08:00
Corbin Simpson
15e283669a r300g: Add A8_UNORM texture format.
Keeps teeworld happy.
2010-01-26 20:11:39 -08:00
Dave Airlie
395e08a839 radeon/r200/r300: don't clean non-emitted state.
So if we don't actually emit an atom to the hw because we don't
need it in the current state (e.g. lighting related atoms when
lighting is off) then don't mark it as clean, because when
lighting gets switched on we won't emit it at all.

This fixes funky gears colors.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-01-27 12:48:47 +10:00
Dave Airlie
e6df209490 radeon: remove unused file 2010-01-27 12:48:41 +10:00
Dave Airlie
2f28ca0a27 radeon/r200/r300: don't clean non-emitted state.
So if we don't actually emit an atom to the hw because we don't
need it in the current state (e.g. lighting related atoms when
lighting is off) then don't mark it as clean, because when
lighting gets switched on we won't emit it at all.

This fixes funky gears colors.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-01-27 12:32:46 +10:00
Dave Airlie
0580e488da radeon: remove unused file 2010-01-27 12:32:44 +10:00
Eric Anholt
2792baec34 intel: Remove dead code from having to clip copyteximage source rect.
mesa core does it now.  If only it did so for other entrypoints.
2010-01-26 18:27:07 -08:00
Eric Anholt
c8e6a0f2f8 intel: Use a handy helper in glReadPixels source clipping. 2010-01-26 18:02:21 -08:00
Eric Anholt
41f4d82ba8 intel: Clean up stale comments about cliprects. 2010-01-26 18:02:21 -08:00
Eric Anholt
a389d6bd56 intel: Remove the remaining cliprects code from DRI1. 2010-01-26 18:02:20 -08:00
Eric Anholt
ee454f0ba4 intel: Remove DRI1 junk from spans code.
This reduces the driver size by over 1%.
2010-01-26 18:02:20 -08:00
Eric Anholt
348fadc5df intel: Remove DRI1 junk from blit glBitmap. 2010-01-26 18:02:20 -08:00
Eric Anholt
3f912e0b3a intel: Remove DRI1 junk from CopyPixels. 2010-01-26 18:02:20 -08:00
Eric Anholt
3efd88f183 intel: Remove DRI1 junk from glClear blit implementation. 2010-01-26 18:02:20 -08:00
Eric Anholt
a3d8e7e481 i965: Remove DRI1 leftovers from stipple offset handling. 2010-01-26 18:02:20 -08:00
Vinson Lee
25b8ce3a6a i965g: Silence uninitialized variable warning. 2010-01-26 17:00:15 -08:00
Vinson Lee
6ab9740b7a softpipe: Remove unused variables. 2010-01-26 16:45:32 -08:00
Vinson Lee
1187a3c957 st/mesa: Silence uninitialized variable warning. 2010-01-26 16:39:25 -08:00
Eric Anholt
63b10e8fe7 intel: Fix PBO blit ReadPixels from an FBO.
Bug #25921 -- clutter PBO usage gave unreliable results.
2010-01-26 16:30:12 -08:00
Igor Oliveira
db89bf4002 docs: add documentation to double opcodes
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-01-26 17:18:44 -07:00
Eric Anholt
ab53f71015 i965: Add support for EXT_draw_buffers2. 2010-01-26 14:43:23 -08:00
Eric Anholt
f62c2a0bb8 i965: Fix fp fragment.position handling and enable HW part of ARB_fcc.
As with swrast, this fixes the default pixel center behavior which was
broken, and implements the previous behavior for integer.  Fixes
piglit fp-arb-fragment-coord-conventions-none.  The extension won't be
exposed until we get the GLSL part implemented.

The DRI1 origin_x/y parts are dropped since they're no longer relevant.
2010-01-26 13:30:26 -08:00
Eric Anholt
11c581c6ce swrast: Implement ARB_fragment_coord_conventions but don't enable.
This brings swrast's support up to the state of gallium, and fixes the
default center behavior of fragment.position.xy in piglit
fp-arb-fragment-coord-conventions-none.

The extension is not enabled currently because the GLSL part of the
extension isn't supported, so piglit
glsl-arb-fragment-coord-conventions-define fails as would any serious
test of the GLSL part.
2010-01-26 13:30:26 -08:00
Alan Hourihane
dea98eb792 support an 'embedded' platform target which turns off most parts of the
build.
2010-01-26 20:59:12 +00:00
Alan Hourihane
46f453b298 Check for __USE_MISC for defining uint & ushort 2010-01-26 20:59:11 +00:00
José Fonseca
5435f790fd python: Add missing library on debug builds. 2010-01-26 20:37:35 +00:00
Brian Paul
43867acb6a Merge branch 'mesa_7_7_branch'
Merging was easier than cherry picking in this instance.
2010-01-26 13:25:53 -07:00
Erik Wien
68ca19afd7 mesa: Don't bind DRAW/READ_FRAMEBUFFER separately without FBO blit support
If GL_EXT_framebuffer_blit was not supported _mesa_DeleteFramebuffersEXT
would raise an error when deleting the currently bound framebuffer. This
because it tried to bind the default DRAW- and READ_FRAMEBUFFER separately.
This patch binds the default FRAMEBUFFER instead in that case.

Encountered in the fbo/fbo-copyteximage piglit test on R600.

Patch cleaned up a bit by Brian Paul.
2010-01-26 13:19:32 -07:00
Jesse Barnes
06d228d8b9 intel: make sure we update the renderbuffers after a swap
Now that LOCK_HARDWARE is gone, we don't have a convenient place to
update the renderbuffers everywhere we need them.  So grab new buffers
when we invalidate the old ones until we optimize things further.
2010-01-26 22:18:27 +02:00
Alan Hourihane
550fc19a5f add missing SCons.Util 2010-01-26 19:57:34 +00:00
Brian Paul
cbecb8fc8e vbo: if 'end' is out of bounds, clamp it
If we determine that the 'end' parameter to glDrawElements() is out of
bounds, clamp it to the max legal index value.
2010-01-26 12:49:48 -07:00
Brian Paul
645e297a00 vbo: clamp DrawElements start/end to max possible values
Some apps are sloppy with their start/end values.  Clamp them to
max possible values to prevent problems later.
2010-01-26 12:47:54 -07:00
Alan Hourihane
18bb614acf fix typo 2010-01-26 19:18:32 +00:00
Alan Hourihane
6544be6223 Allow the environment to override certain flags. 2010-01-26 19:14:50 +00:00
Alan Hourihane
1019f0de11 only use -Werror flags with gcc 4.2.x and 4.3.x.
could use a better test here though.
2010-01-26 19:14:49 +00:00
Aaron Plattner
cec0e7c086 glxgears: Support GLX_EXT_swap_control for querying the current swap interval.
Signed-off-by: Aaron Plattner <aplattner@nvidia.com>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-01-26 12:00:51 -07:00
Brian Paul
af1e9403e7 mesa: remove redundant _MaxElement computation
Eric added some new code to check if offset < obj_size before computing
_MaxElement but my original code was still present afterward and it
clobbered the _MaxElement value.

Not sure if this came from a bad merge or what.
2010-01-26 10:53:40 -07:00
Brian Paul
782f66c8a2 progs/tests: use glDrawRangeElements() in bufferobj.c 2010-01-26 10:48:00 -07:00
Christoph Bumiller
a5d67dc011 nv50: supports independent blend enables 2010-01-26 18:33:05 +01:00
Roland Scheidegger
1a9d01dcde gallium: add the new PIPE_CAP blend bits to more drivers
some drivers will complain if they don't know the cap bit
2010-01-26 17:32:57 +01:00
Brian Paul
1d8b308cbf docs: document Intel, R300 env vars 2010-01-26 09:12:32 -07:00
Corbin Simpson
786bd78be4 r300g: Per-MRT blending is not supported. 2010-01-26 07:35:33 -08:00
Roland Scheidegger
9bc80ff174 mesa/st: code cleanups for new blend functionality
minor code changes, style and comment fixes
2010-01-26 15:35:31 +01:00
Chia-I Wu
092b1ca989 egl: Remove _eglOpenDriver and _eglCloseDriver.
_eglCloseDriver is no-op and _eglOpenDriver does nothing but call
_eglMatchDriver.  Export _eglMatchDriver directly.
2010-01-26 18:46:06 +08:00
Chia-I Wu
545eaf83b5 egl: Fix a segfault when a display is initialized again.
Reset dpy->MaxConfigs so that dpy->Configs is re-allocated.
2010-01-26 18:46:05 +08:00
Chia-I Wu
a1717970e7 egl: Remove _eglGetCurrentSurface and _eglGetCurrentDisplay.
They have little use in drivers since drivers need to work for multiple
current contexts.
2010-01-26 18:46:05 +08:00
Chia-I Wu
11cf3cb2c4 egl: Fix leaks in eglReleaseThread.
There may be multiple bound contexts that should be unbound.
2010-01-26 18:46:05 +08:00
Chia-I Wu
7c09296d4c egl: Refactor _eglMakeCurrent.
Refactor _eglMakeCurrent into _eglCheckMakeCurrent,
_eglBindContextToSurface, and _eglBindContextToThread.
2010-01-26 18:46:05 +08:00
Chia-I Wu
6f6f3e4227 egl: Add _eglGetAPIContext.
It will return the currently bound context of the given API.
2010-01-26 18:46:05 +08:00
Chia-I Wu
f65ed0a309 egl: Use a boolean to indicate whether a resource is linked.
An unlinked resource may still be a current resource such as current
surfaces.  There might still be a need to know which display the
unlinked resource belongs to.
2010-01-26 18:46:05 +08:00
Chia-I Wu
d21ee93fdb egl: Mark _eglCheckResource as PUBLIC.
To support extensions such as GL_OES_EGL_image, the drivers need a way
to check if a given EGLImageKHR is valid.
2010-01-26 18:46:05 +08:00
Vinson Lee
c73dbce891 glsl/pp: Silence GCC "no previous prototype" warning. 2010-01-26 00:47:31 -08:00
Eric Anholt
7aed23c362 intel: Don't do client-side frame throttling with DRI2 SwapBuffers.
The server side does the throttling on our behalf now by putting the
client to sleep, so we don't need our previous hacks for limiting the
number of outstanding frames.  Same effect as
7d4e674b21.
2010-01-25 22:57:33 -08:00
Eric Anholt
c7fc9bfb22 Revert "intel: Use the new DRI2 flush invalidate entrypoint to signal frame done."
This reverts commit 7d4e674b21.  It broke
throttling in the non-new-DRI2 case.
2010-01-25 22:57:33 -08:00
Eric Anholt
5e1851b144 i965: Remove unnecessary malloc/free in VS binding table setup. 2010-01-25 22:57:30 -08:00
Eric Anholt
a098fd71d7 i965: Fix build after merge of mesa stable branch. 2010-01-25 22:27:46 -08:00
Chia-I Wu
74aa773f7c docs: Mention EGL and OpenGL ES in 7.8 release notes. 2010-01-26 11:35:30 +08:00
Chia-I Wu
146931769c glx: Build GLX normally.
GLX was built specially and before Mesa core because libglapi.a could
not be built with IN_DRI_DRIVER defined.  This is no longer the case
since 6e99e6ddbf.

It works fine in my (limited) testing with both direct and indirect
rendering.  I also compare the outputs after preprocessing (gcc -E) with
or without this commit, and they are identical.
2010-01-26 11:03:54 +08:00
Chia-I Wu
a6342afe50 docs: Update EGL documentation.
Add --enable-gallium-swrast to the example.  Document missing
--with-egl-driver-dir and update TODOs.
2010-01-26 10:55:28 +08:00
Chia-I Wu
0d2d40451d egl/xdri: Update with glxclient.h change.
__glXFindDisplay is no longer static since
7a9329ba99.
2010-01-26 10:48:16 +08:00
Robert Bragg
7a9329ba99 mesa: misc GLX_INTEL_swap_event fixes
Fixup a few issues found through testing:
  - update GLX names to match glproto
  - register DRI2WireToEvent so it actually gets called

Signed-off-by: Robert Bragg <robert@linux.intel.com>
2010-01-25 15:40:56 -08:00
Brian Paul
9b22427911 Merge branch 'mesa_7_7_branch'
Conflicts:

	src/mesa/drivers/dri/intel/intel_screen.c
	src/mesa/drivers/dri/intel/intel_swapbuffers.c
	src/mesa/drivers/dri/r300/r300_emit.c
	src/mesa/drivers/dri/r300/r300_ioctl.c
	src/mesa/drivers/dri/r300/r300_tex.c
	src/mesa/drivers/dri/r300/r300_texstate.c
2010-01-25 14:46:17 -07:00
Alex Deucher
7e7f8815fb r300: rv350+ support FLT16_2/4 vertex formats 2010-01-25 16:19:19 -05:00
Corbin Simpson
5fe71949d9 r300g: Finish and enable immediate mode.
Based on Marek's immd-mode patch.
2010-01-25 11:30:39 -08:00
Corbin Simpson
1571602153 radeong: Make sure that we're not emitting relocations for local buffers.
Split from Marek's immd-mode patch.
2010-01-25 11:30:39 -08:00
Corbin Simpson
c486bfb463 radeong: Make is_r3xx inline to avoid warnings.
Split from Marek's immd-mode patch.
2010-01-25 11:30:39 -08:00
Corbin Simpson
67149051be radeong: Clean up domain usages.
Split from Marek's immd-mode patch.
2010-01-25 11:30:39 -08:00
Corbin Simpson
72778a9d25 Revert "r300g,radeong: finish and enable the immediate mode"
This reverts commit 112239e9a6.
2010-01-25 11:30:38 -08:00
Roland Scheidegger
df4395198c softpipe: enable new blend functionality
works with tests/drawbuffers2
2010-01-25 20:20:52 +01:00
Jakob Bornecrantz
6749310d3f st/xorg: Fix crash on resize with libkms 2010-01-25 20:12:59 +01:00
Roland Scheidegger
5fae36147e st/mesa: handle EXT_draw_buffers2 per rendertarget blend enables / colormasks
uses the new gallium per-rt blend functionality
2010-01-25 19:27:05 +01:00
Igor Oliveira
0d051af612 vega: fix incorrect samplers, textures indexes in blend_bind_samplers()
Fixes fd.o bug 25863.

Signed-off-by: Brian Paul <brianp@vmware.com>
2010-01-25 09:53:53 -07:00
Roland Scheidegger
0d3a6a505d vega: don't enable blending if not necessary
In some places blending was enabled even though it wasn't necessary.
Also remove a (bogus) reenabling of color writes, which wasn't really used.
2010-01-25 16:52:14 +01:00
Roland Scheidegger
dbc0e24ab8 xorg: do not enable unnecessary blending for xv 2010-01-25 16:43:33 +01:00
Roland Scheidegger
13b74b585a trace: adapt to blend changes 2010-01-25 16:41:57 +01:00
Roland Scheidegger
6893948d48 svga: adapt to blend changes 2010-01-25 16:39:39 +01:00
Roland Scheidegger
4e6bfa6de1 softpipe: adapt to blend changes 2010-01-25 16:39:16 +01:00
Roland Scheidegger
e908abf174 nouveau: adapt drviers to blend changes 2010-01-25 16:38:32 +01:00
Roland Scheidegger
d241964e47 r300g: adapt to blend changes 2010-01-25 16:37:51 +01:00
Roland Scheidegger
4e0c825a79 i965g: adapt to blend changes 2010-01-25 16:37:27 +01:00
Roland Scheidegger
bc160fc9b2 i915g: adapt to blend changes 2010-01-25 16:37:09 +01:00
Roland Scheidegger
88388b99fb cell: adapt to blend changes 2010-01-25 16:36:37 +01:00
Roland Scheidegger
99e28d4ee3 llvmpipe: adapt to blend changes 2010-01-25 16:35:56 +01:00
Roland Scheidegger
3770769f21 st/python: adapt to blend changes 2010-01-25 16:34:29 +01:00
Roland Scheidegger
feefa7a510 vega: adapt to blend changes 2010-01-25 16:33:09 +01:00
Roland Scheidegger
92676b9fe6 xorg: adapt to blend changes 2010-01-25 16:32:18 +01:00
Roland Scheidegger
cbb8d35a3a gallium: fix cast for size calc of pipe_blend_state 2010-01-25 16:31:21 +01:00
Luca Barbieri
9328f3a670 Fix compressed texture loads for non-minimal pitches again
My commit eea6a7639f does a memcpy of height
lines, but that's wrong because the texture has a block layout and we
must thus use the number of vertical blocks instead of the height.

Signed-off-by: Brian Paul <brianp@vmware.com>
2010-01-25 08:11:49 -07:00
Chia-I Wu
2204447de3 winsys/drm: Correctly install EGL drivers.
Remove extraneous quotes that prevent some drivers to be installed when
there are more than one display in EGL_DISPLAYS.
2010-01-25 23:06:05 +08:00
José Fonseca
cb64ca5066 pipebuffer: Reapply the mesa_7_7_branch's changes.
After the last mesa_7_7_branch merge the old master code remained,
instead of the newer mesa_7_7_branch's code. This commit makes both
branches match, modulo interface changes.

Note: future mesa_7_7_branch -> master merges will most likely hit
conflicts in these files. Unless otherwise stated, the mesa_7_7_branch
is the reference.
2010-01-25 13:17:47 +00:00
José Fonseca
4c082faa7e llvmpipe: Remove lp_tex_sample_c.c again.
Popped back to life in some merge. Not necessary even as a reference,
since it is identical to softpipe's sp_tex_sample.c with renamed symbols.
2010-01-25 11:54:54 +00:00
Jakob Bornecrantz
6877c5de3c vmware/xorg: Do buffer round-robin logic differently 2010-01-25 12:27:47 +01:00
Jakob Bornecrantz
0b482c4fbe st/xorg: Improve options and print them to log
Set 2D acceleration to off by default
Get fallback debugging from the Xorg config
Also print if 3D acceleration is enabled
2010-01-25 11:24:56 +01:00
Jakob Bornecrantz
a3b783ea29 vmware/xorg: Export pci_probe function for ugly chain-loading 2010-01-25 11:24:55 +01:00
Jakob Bornecrantz
36fd55f9f0 st/xorg: Export helper function for detecting modesetting 2010-01-25 11:24:55 +01:00
Jakob Bornecrantz
16cf7e14a6 st/xorg: Fix warning 2010-01-25 11:24:55 +01:00
Corbin Simpson
8cf1af4507 gallium-docs: Add note on scissor. 2010-01-25 01:12:30 -08:00
Marek Olšák
112239e9a6 r300g,radeong: finish and enable the immediate mode
Nearly 100% performance increase in glxgears.
2010-01-24 23:03:29 -08:00
Marek Olšák
9f8ec53312 r300g: fix zero-area scissor 2010-01-24 23:03:29 -08:00
Marek Olšák
b7a002df1e r300g,radeong: set tiling flags in libdrm 2010-01-24 23:03:29 -08:00
Marek Olšák
8505996430 radeong: do not emit a zero-sized command stream
Fixing a hardlock introduced in fcbd285e42 and
reproducible with piglit/bugs/fdo23489.
2010-01-24 23:03:29 -08:00
Chia-I Wu
4aed0944f4 egl: Native types are renamed in EGL 1.3.
Rename Native*Type to EGLNative*Type.
2010-01-25 11:59:12 +08:00
Chia-I Wu
dbb866ab33 egl: Make resource void pointer in _eglCheckResource.
This emphasizes the fact that the resource to be checked could really be
invalid and have an unknown type.
2010-01-25 11:44:13 +08:00
Chia-I Wu
3f932a4440 egl: Install EGL headers.
Install EGL (and KHR) headers along with the library.
2010-01-25 11:34:59 +08:00
Chia-I Wu
a1c4a8a3c8 egl: Add support for EGL_KHR_image.
Individual drivers still need to implement the API hooks.
2010-01-25 11:28:27 +08:00
Chia-I Wu
95f8f75ad8 egl: Update headers.
Update to the current versions found at
http://www.khronos.org/registry/egl/.  There is one modification in
khrplatform.h for GCC visibility.
2010-01-25 11:28:27 +08:00
Igor Oliveira
daea9270f8 egl: check if driver_name is null 2010-01-25 10:30:51 +08:00
Brian Paul
47d30b0c2c st/mesa: fix int->uint conversion for negative scissor bound values
Based on a patch by Xavier Chantry <chantry.xavier@gmail.com>:

If x+width or y+height is negative, then maxx or maxy will get a bogus value
when converting that to unsigned. Fix this by setting 0 as minimal value.

This was also triggered by teeworlds, but only with some combination of
resolution and map section. For example upper part of dm2 at 1280x1024.
2010-01-24 18:18:17 -07:00
Brian Paul
e88d6fe299 mesa: move _mesa_debug() call earlier in _mesa_Scissor
Part of a patch from Xavier Chantry <chantry.xavier@gmail.com>
2010-01-24 17:54:47 -07:00
Xavier Chantry
fdfa4c8529 st/mesa: fix unsigned/signed breakage in scissor
commit 53174afeeb introduced a portability change that converted GLint x,y
to GLuint. That breaks when x and y are negative, which seems to be allowed,
and which at least one game uses : teeworlds.

Rather than simply reverting the change, it seems possible to convert the
16bit unsigned to GLint so that comparisons are made between signed integers
instead.  This hopefully does not break anything while keeping MSVC happy.

Signed-off-by: Xavier Chantry <chantry.xavier@gmail.com>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-01-24 16:45:49 -07:00
Marcin Slusarz
9e1550dbaf nv50: fix uninitialized variable in nv50_revdep_reorder
"unsafe" is never initialized, but used
(found by valgrind)
2010-01-25 09:45:23 +10:00
Marcin Slusarz
0ef781c1ae nv50: fix crash in nv50_pre_pipebuffer_map (nv50_screen->cur_ctx)
nv50_pre_pipebuffer_map references screen->cur_ctx which points
to freed memory after the context is destroyed.
This crash is easily triggerable by progs/xdemos/glxcontexts.
2010-01-25 09:44:34 +10:00
Marcin Slusarz
74989972ba nouveau/winsys: be nice and close the device on destroy 2010-01-25 09:43:59 +10:00
Marcin Slusarz
283b21d02b nouveau: fix winsys object leak 2010-01-25 09:43:33 +10:00
Christoph Bumiller
833acea8f6 nv50: fix handling of FragCoord input 2010-01-24 15:17:57 +01:00
Christoph Bumiller
49dde55b96 nv50: only flush texture caches on st request 2010-01-24 15:17:53 +01:00
Christoph Bumiller
d6fd31a8d4 nv50: implement render_condition
Still not handling queries on multiple contexts though.
2010-01-24 15:13:17 +01:00
Chia-I Wu
21b2c0a6e5 egl: Add and use make_library_path.
Add a platform specific function to turn a library name to a library
path.  It is used to convert EGL_DRIVER or the default driver to a
library path that can be loaded.
2010-01-24 21:27:52 +08:00
Chia-I Wu
cecc33cd4f egl: Remove _eglFindAPIs.
This function is not used and should have been removed by last commit.
My mistake.
2010-01-24 20:55:17 +08:00
Chia-I Wu
cf7c1ea4f1 egl: Remove unused helper functions.
_eglFillInConfigs and _eglFindAPIs have no user in Mesa and are unlikely
to find one soon.  It should be fine to remove them.
2010-01-24 20:52:30 +08:00
Chia-I Wu
56b93a25ea egl: Remove unused casting functions.
_eglUIntToPointer and _eglPointerToUInt are no longer used.
2010-01-24 20:38:16 +08:00
Chia-I Wu
ecb3b3102a egl: Make surfaces and contexts resources.
Turn _EGLSurface and _EGLContext into _EGLResource so that they can be
managed uniformly.
2010-01-24 20:38:16 +08:00
Chia-I Wu
7abf42626f egl: Add _EGLResource and _EGLResourceType.
Resources are objects managed by a display.  They can be linked to or
unlinked from a display.  It is also possible to check if a resource is
valid.
2010-01-24 20:38:15 +08:00
Chia-I Wu
b4d2c97a2d egl: Move surface functions in egldisplay.[ch] to eglsurface.[ch]
Move functions to where they should be.  There should be no real change
here.
2010-01-24 20:38:15 +08:00
Chia-I Wu
5e66d18932 egl: Move context functions in egldisplay.[ch] to eglcontext.[ch].
Move functions to where they should be.  There should be no real change
here.
2010-01-24 20:38:15 +08:00
Chia-I Wu
7be4d6b5f7 mesa/es: Improve Makefile rules.
Make sure glapi headers are cleaned when "make clean".  Make sure all
sources depend on subdirs-stamp-tmp so that sources/headers are
generated first.

subdirs-stamp-tmp will be removed after a successful build.  It might be
a problem when a build fails.  But it is much better than where we
currently are: glapi headers are never cleaned or re-generated.
2010-01-24 20:15:25 +08:00
Vinson Lee
e85cb98a16 r200: Silence fprintf format warning. 2010-01-24 00:17:00 -08:00
Vinson Lee
e02dc13952 x86: Do not build read_rgba_span_x86.S on Mac OS X.
read_rgba_span_x86.S uses the pseudo-ops .hidden and .type which are
not recognized on Mac OS X.
2010-01-23 23:18:33 -08:00
Vinson Lee
f429b80fff x86: Do not use .hidden pseudo-op on Mac OS X.
The .hidden directive is an unknown pseudo-op on Mac OS X.
2010-01-23 23:12:34 -08:00
Vinson Lee
bc75ec0f38 glapi: Do not use .type pseudo-op on Mac OS X.
The .type directive is an unknown pseudo-op on Mac OS X.
2010-01-23 22:59:31 -08:00
Vinson Lee
6b55aacccb scons: Do not use ld options start-group and end-group on Darwin.
Mac OS X ld does not support these options.
2010-01-23 21:43:26 -08:00
Dave Airlie
e9bb06441e r300g: avoid the use of goto
I was being lazy on Sunday morning, Droste on irc called me on it ;-)
2010-01-24 15:37:23 +10:00
Vinson Lee
d57ba16ae3 scons: Define _DARWIN_C_SOURCE on Darwin builds. 2010-01-23 21:05:58 -08:00
Dave Airlie
232ddfec24 r300g: fix flushing harder.
I swear ipers runs here after this commit.

After we flush we need to redo the space check
2010-01-24 15:00:06 +10:00
Vinson Lee
7f2f42dd80 progs/demos: Remove unnecessary header from shadowtex.c. 2010-01-23 20:56:49 -08:00
Vinson Lee
b62b524fee r300: Remove unnecessary headers. 2010-01-23 20:43:27 -08:00
Vinson Lee
fb6bff3712 intel: Remove unnecessary headers. 2010-01-23 14:33:29 -08:00
Chia-I Wu
28c3e57c83 egl: Install drivers to ${libdir}/egl.
Install EGL drivers to EGL_DRIVER_INSTALL_DIR, which is default to
${libdir}/egl.
2010-01-23 20:30:11 +08:00
Chia-I Wu
6c4431c092 st/vega: Clean up Makefile. 2010-01-23 20:15:28 +08:00
Chia-I Wu
60cd2449f8 st/es: Pass -linker and -ldflags to mklib. 2010-01-23 20:15:24 +08:00
Vinson Lee
146a77af3f radeon: Remove unused variable. 2010-01-23 02:14:56 -08:00
Dave Airlie
3b002c9f75 r300: fix wrong call in last commit 2010-01-23 20:07:08 +10:00
Vinson Lee
4bad0aef40 tdfx: Remove unnecessary headers. 2010-01-23 01:54:53 -08:00
Vinson Lee
283d9565bf sis: Remove unnecessary headers. 2010-01-23 01:40:44 -08:00
Dave Airlie
76bc66b664 r300g: fix up buffer emission ordering.
This fixes the code space checking VBOs, then resetting the space list
and space checking other buffers. it fixes demos/ipers

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-01-23 19:35:42 +10:00
Vinson Lee
09a142e5db savage: Remove unnecessary headers. 2010-01-23 00:38:14 -08:00
Vinson Lee
ca54a5b920 mga: Remove unnecessary headers. 2010-01-23 00:19:29 -08:00
Vinson Lee
634ec5c2ab i965: Remove unnecessary headers. 2010-01-22 23:53:39 -08:00
Vinson Lee
329c1b5910 i915: Remove unnecessary headers. 2010-01-22 23:22:16 -08:00
Dave Airlie
9a62f0ce3b r300: only enable half floats on r500s.
Thank to MAD for point it out.
2010-01-23 12:57:51 +10:00
Dave Airlie
782b6885c2 Merge branch 'arb_half_float_vertex' 2010-01-23 12:29:33 +10:00
Chia-I Wu
0928418922 Revert "add segl"
This reverts commit fe33b7083b.  It was
not supposed to be pushed yet.
2010-01-23 10:33:03 +08:00
Dave Airlie
d82b8038fd r300: half float support
Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-01-23 12:28:33 +10:00
Dave Airlie
96f2f0daea i965: add support for ARB_half_float_vertex
enables the extension on i965 and adds support to the draw upload for
the vertex format.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-01-23 12:28:32 +10:00
Dave Airlie
cfe884e203 mesa: add core support for ARB_half_float_vertex.
Adds the extension to the list + support to the APIs.

also add t_draw.c support to convert for sw rast.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-01-23 12:28:32 +10:00
Dave Airlie
1ac5fd594a glapi: add GL_HALF_FLOAT enum support.
Regenerate enums files and GLX indirect.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-01-23 12:28:32 +10:00
Dave Airlie
dcaf6687e8 progs: add trivial ARB_half_float_vertex support.
This is just a trivial port of vp-array.c

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-01-23 12:28:28 +10:00
Chia-I Wu
4b770d1a11 glapi: Include glheader.h in glapi_nop.c.
In addition to OpenGL headers, glheader.h also defines OpenGL ES types
that are used in core Mesa or ES overlay.
2010-01-23 10:24:49 +08:00
Chia-I Wu
fe33b7083b add segl 2010-01-23 10:10:47 +08:00
Brian Paul
2292c93bc0 glapi: define GLfixed, GLclampx types for ES 1
I'm not 100% sure this is the best fix, but it seems OK.
2010-01-22 18:47:25 -07:00
Brian Paul
f6a49ac217 svga: fix up breakage from earlier 7.7 merge 2010-01-22 18:35:36 -07:00
Brian Paul
46c7cd665c st/mesa: fix incorrect freeing of drawpixels vertex shaders
These shaders are not st_vertex_shaders, but tgsi ureg shaders.
Fixes fd.o bug 25959.
2010-01-22 17:56:37 -07:00
Julien Cristau
5aee9e344b Remove myself from Uploaders 2010-01-23 01:46:41 +01:00
Brian Paul
dd618a006a gallium/util: add missing util/u_bitmask.c to Makefile 2010-01-22 17:20:37 -07:00
Brian Paul
5e78903952 gallium/util: fix incorrect shift in a4r4g4b4_put_tile_rgba()
Fixes fd.o bug 23313.
2010-01-22 17:17:05 -07:00
Brian Paul
b23b13b690 mesa: use memcpy() in _mesa_ProgramEnv/LocalParameters4fvEXT() 2010-01-22 16:24:15 -07:00
Brian Paul
ffe4e2a667 mesa: use switch in _mesa_DeletePrograms() 2010-01-22 16:18:56 -07:00
Brian Paul
7b5ad23c7f Merge branch 'mesa_7_7_branch'
Conflicts:

	src/mesa/shader/prog_execute.c
2010-01-22 16:09:03 -07:00
Brian Paul
099e8ec54d mesa: re-implement _mesa_ProgramEnvParameter4fvARB() with memcpy()
This is faster and ensures that NaN floats get stored properly.
Before, NaN values (which might be used with UP2H, UP2US, UP4B and
UP4UB) weren't getting stored properly with gcc -O3.

This is the second part of the fix for the piglit fp-unpack-01 failure
(bug 25973).
2010-01-22 15:41:11 -07:00
Brian Paul
8d1a01d370 mesa: use new fetch_vector1ui() function for 'unpack' GPU instructions
The UP2H, UP2US, UP4B and UP4UB instructions interpret the float
registers as integers.  With gcc -O3 some bits were getting mixed up
somewhere.  This is part of the fix for the piglit fp-unpack-01 test
failure (bug 25973).
2010-01-22 15:36:38 -07:00
Brian Paul
efde2df114 xlib/softpipe: more buffer free fixes
The previous memory leak fix didn't always work properly.
Now check the xm_buffer::smh field (now documented!) to
see if the buffer points to shared memory.
2010-01-22 13:07:07 -07:00
Alan Hourihane
d88b219cf3 Remove obsolete file 2010-01-22 19:33:04 +00:00
Brian Paul
1e4b81267c gallium/aux: re-add pb_buffer_fenced.[ch] accidentally remove during merge 2010-01-22 12:27:25 -07:00
Brian Paul
cd8614b028 Merge branch 'mesa_7_7_branch'
Conflicts:
	src/gallium/auxiliary/draw/draw_context.c
	src/gallium/auxiliary/draw/draw_pt_fetch_shade_pipeline.c
	src/gallium/auxiliary/pipebuffer/Makefile
	src/gallium/auxiliary/pipebuffer/SConscript
	src/gallium/auxiliary/pipebuffer/pb_buffer_fenced.c
	src/gallium/auxiliary/tgsi/tgsi_scan.c
	src/gallium/drivers/i915/i915_surface.c
	src/gallium/drivers/i915/i915_texture.c
	src/gallium/drivers/llvmpipe/lp_setup.c
	src/gallium/drivers/llvmpipe/lp_tex_sample_c.c
	src/gallium/drivers/llvmpipe/lp_texture.c
	src/gallium/drivers/softpipe/sp_prim_vbuf.c
	src/gallium/state_trackers/xorg/xorg_dri2.c
	src/gallium/winsys/drm/intel/gem/intel_drm_api.c
	src/gallium/winsys/drm/nouveau/drm/nouveau_drm_api.c
	src/gallium/winsys/drm/radeon/core/radeon_drm.c
	src/gallium/winsys/drm/vmware/core/vmw_screen_dri.c
	src/mesa/state_tracker/st_cb_clear.c
2010-01-22 12:17:02 -07:00
Brian Paul
64871747bb gallium/draw: apply DRAW_PIPE_FLAG_MASK to all vertex elements
Depending on first/last provoking vertex either the first or last
element/index may have the extra DRAW_PIPE_x flags.  Mask off those
bits for all vertex elements to be safe (esp. for the quad case).
This may be overly cautious, but it's a cheap operation.

Fixes a segfault caused by large/bogus vertex indexes otherwise.
2010-01-22 11:49:51 -07:00
Brian Paul
5ab0d49a07 gallium/draw: added comments, whitespace fixes 2010-01-22 11:39:19 -07:00
Alan Coopersmith
2b20b60427 mesa: Add "shader/" path to #include statements in shader parser/lexer sources
Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>

Note sure why the compiler's -I paths aren't doing the job, but this is OK.

Signed-off-by: Brian Paul <brianp@vmware.com>
2010-01-22 10:38:06 -07:00
Brian Paul
e4f168a6f4 glapi: clean-up and simplify glapi_nop.c code
Removed _glapi_noop_enable_warnings() and _glapi_set_warning_func().
Just check the DEBUG env vars and call fprintf(stderr) with a warning
message instead.
2010-01-22 09:56:55 -07:00
Brian Paul
126aff18aa glapi: split the no-op dispatch code into new glapi_nop.c file
This unclutters the glapi.c file a bit.
2010-01-22 09:32:12 -07:00
Brian Paul
ea5918be0e glapi: fix int->pointer conversions warnings in no-op functions 2010-01-22 08:15:14 -07:00
Brian Paul
2f1a49e335 progs/xdemos: add z/Z keys for scaling the rendering 2010-01-22 08:08:45 -07:00
Brian Paul
5023a7f53f gallium/draw: fix-up comments, whitespace 2010-01-22 08:08:45 -07:00
Brian Paul
3c31b1b6d1 gallium/draw: replace int with boolean 2010-01-22 08:08:45 -07:00
Ruediger Oertel
96280c2a41 Fix PowerPC related typo in spantmp2.h
Signed-off-by: Matthias Hopf <mhopf@suse.de>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-01-22 08:07:41 -07:00
Andre Maasikas
69e26a08c6 r600: enable sampler lod* bits
bits, settings derived from testing, might contain some errors...
2010-01-22 16:57:47 +02:00
Andre Maasikas
70ccca4251 r600: update vport z & clipping when depth_clamp is changed
fixes piglit depth_clamp
2010-01-22 14:14:01 +02:00
Andre Maasikas
9bf40cea00 r600: fix brownbag, only align if we are dealing with cubemap 2010-01-22 13:49:12 +02:00
Andre Maasikas
714d9c21ec r600: cubemap levels seem to be aligned to 8 images 2010-01-22 13:33:15 +02:00
Andre Maasikas
278ad74fe0 radeon/fbo: flush rendering before generating mipmaps
or maybe should flush(also) in finish_render_texture...
2010-01-22 12:58:27 +02:00
Andre Maasikas
7c6f51cdcc radeon/fbo: use correct depth texture offset for depth textures 2010-01-22 12:38:34 +02:00
Andre Maasikas
defd45e95e r600: enable draw_offset
fixes some fbo cases (mipmaps, cube textures ..)
2010-01-22 12:38:19 +02:00
Chia-I Wu
cec2eeb33e docs: Update sourcetree.html for EGL and the state trackers. 2010-01-22 18:10:52 +08:00
Chia-I Wu
3c967a9207 st/egl_g3d: Rename to st/egl.
Simply the name to egl.
2010-01-22 16:45:28 +08:00
Chia-I Wu
3a4b7d3071 winsys/drm: Update the options of mklib in Makefile.egl_g3d.
Pass -linker, -ldflags, and $(MKLIB_OPTIONS) to mklib.
2010-01-22 16:44:13 +08:00
Chia-I Wu
3b0ffd5a36 egl: Remove egl_softpipe.
With the addition egl_x11_swrast, egl_softpipe is sort of deprecated.
The new driver serves the same purpose as egl_softpipe does.  It is
based on egl_g3d and provides more features.
2010-01-22 16:44:13 +08:00
Chia-I Wu
a1306f4ef6 winsys/drm: Add swrast.
The swrast winsys always returns NULL when drm_api_create is called.
2010-01-22 16:44:09 +08:00
José Fonseca
383f460cf7 vmware/core: Update for pipebuffer changes.
In particular, delay patching GMR relocations until the buffers are
validated, since the buffers relative offset can only be established then.
2010-01-22 09:41:52 +01:00
Vinson Lee
3f6d732bfb st/mesa: Remove unnecessary header from st_cb_viewport.c. 2010-01-21 23:41:57 -08:00
Chia-I Wu
52d7b2cede st/egl: Remove the egl state tracker.
The egl_g3d state tracker has support for KMS, and the support is based
on the egl state tracker.  As egl_g3d provides more features, it should
be better to keep only egl_g3d to unify the efforts.
2010-01-22 15:37:56 +08:00
Vinson Lee
8bc3c06d86 progs/trivial: Remove unnecessary header from tri-fbo-tex-mip.c. 2010-01-21 23:24:40 -08:00
Chia-I Wu
2a928899e3 egl: Remove USING_EGL and the related drivers.
They do not build for a long while and there seems to be no active
users.  It might be better for them to live in the git histroy.
2010-01-22 15:16:31 +08:00
Chia-I Wu
324fdf7364 egl: Remove the demo driver.
The demo driver has outdated.  It is suggested to look at any of the
drivers that is functioning.
2010-01-22 15:10:09 +08:00
Vinson Lee
a1c5d8f61d i915g: Remove unnecessary header. 2010-01-21 23:09:06 -08:00
Vinson Lee
cea9250ff0 pipebuffer: Remove unnecessary header. 2010-01-21 23:07:29 -08:00
Chia-I Wu
cfb1ed3977 st/egl_g3d: Use glxinit.c from egl_xdri.
It is used to fetch the GLX visuals/fbconfigs.  Use egl_xdri's version
to avoid duplication.  It might be better to rewrite that part though.
2010-01-22 15:06:06 +08:00
Chia-I Wu
29732f982c docs: Update the status of egl_xdri.
Mention that it also supports DRISW.
2010-01-22 15:06:06 +08:00
Chia-I Wu
18b63b55d5 egl_xdri: Add support for DRISW.
Try DRISW if both DRI2 and DRI fail.  It can also be forced by setting
EGL_SOFTWARE.  When DRISW is used, single-buffered modes are ignored.
2010-01-22 15:03:45 +08:00
Vinson Lee
dc544ad9c6 draw: Remove unnecessary headers. 2010-01-21 22:57:12 -08:00
Chia-I Wu
caa75a7ce0 egl_xdri: Flush commands on context switch and buffer swap.
The corresponding DRI functions does not flush for us.
2010-01-22 14:54:41 +08:00
Chia-I Wu
3c9bf648ac egl_xdri: Report only OpenGL support.
It reported OpenGL ES support because some demos did not set
EGL_RENDERABLE_TYPE correctly.  The demos are fixed.
2010-01-22 14:54:40 +08:00
Chia-I Wu
fe0e35aba8 egl_xdri: Do not reinitialize in __glXInitialize.
__glXInitialize should return the same GLX display for the same X
display.  This issue is triggered by
a35f6bb207.
2010-01-22 14:54:40 +08:00
Chia-I Wu
0e54f9c529 egl_glx: Report only OpenGL support.
It reported OpenGL ES support because some demos did not set
EGL_RENDERABLE_TYPE correctly.  The demos are fixed.
2010-01-22 14:24:46 +08:00
Chia-I Wu
2279fa3c06 egl: Update driver Makefiles.
Update to use the new Makefile.template.
2010-01-22 13:29:23 +08:00
Chia-I Wu
e63272050f egl: Add Makefile.template for EGL drivers. 2010-01-22 12:02:00 +08:00
Chia-I Wu
883b57e66c winsys/drm: Update Makefile.template.
Mainly to respect LDFLAGS and remove unused target $(LIBNAME_EGL).  This
is based on the patch by Tomáš Chvátal <scarabeus@gentoo.org>.
2010-01-22 11:28:48 +08:00
Brian Paul
3bca8691b5 llvmpipe: use some local vars to index step arrays
Saves a few more cycles.
2010-01-21 19:10:03 -07:00
Brian Paul
1d23954a08 llvmpipe: s/inline/INLINE/ 2010-01-21 19:05:54 -07:00
Brian Paul
e24ea786fa llvmpipe: consolidate lp_scene_alloc_aligned() calls
Use just one call instead of four.  Good for a few more fps.
2010-01-21 19:04:55 -07:00
Brian Paul
798a9d3f94 llvmpipe: re-use a1 var in linear_coef() 2010-01-21 18:25:31 -07:00
Vinson Lee
e8b5203fbb svga: Remove unused variable. 2010-01-21 17:24:07 -08:00
Alan Coopersmith
f8107a45ce Fix typo in configure message for gcc -fvisibility=hidden
Need to use $CC for a shell variable, not $(CC) for a make variable
which the shell interprets as running the command "CC".

Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
2010-01-21 16:43:59 -08:00
Brian Paul
ff9b55da9a llvmpipe: area is an int here, not float 2010-01-21 17:31:43 -07:00
José Fonseca
a626565178 vmware/core: Flush preemptively the FIFO commands to keep the GMR working set within reasonable bounds. 2010-01-21 15:51:37 -08:00
José Fonseca
beb8e8f2f2 vmware/core: Put GMR pool size in a define. 2010-01-21 15:47:52 -08:00
José Fonseca
e45579e50b vmw/wgl: Update for pipebuffer changes.
This is a minimum change to keep things building and running minimally -- it
might cause applications to fail to allocate buffers due to out of
GMR memory.

A proper update will be commited later.
2010-01-21 15:27:26 -08:00
Brian Paul
a904a7b990 llvmpipe: manually unroll the inputs.step[] setup code
Good for a few more fps in some tests.
2010-01-21 16:21:33 -07:00
José Fonseca
31e49dc54e svga: Remove duplicate code. 2010-01-21 15:18:40 -08:00
José Fonseca
50edefec2d svga: Remove unused code. 2010-01-21 15:18:40 -08:00
José Fonseca
9782d7cdf3 svga: Don't swap buffers to system memory -- winsys' responsibility. 2010-01-21 15:18:40 -08:00
José Fonseca
c4ceba1141 pipebuffer: Release the lock during map wait. Cleanups. 2010-01-21 15:18:40 -08:00
José Fonseca
3498616b03 pipebuffer: Swap buffers out to system memory when running out of memory. 2010-01-21 15:18:40 -08:00
José Fonseca
0bc8851884 svga: Avoid synchronization issues when doing SW TNL. 2010-01-21 15:18:40 -08:00
José Fonseca
8410f7cde3 mesa: Use pipe_buffer_write_nooverlap where appropriate. 2010-01-21 15:18:40 -08:00
José Fonseca
37246f854b util: Set DISCARD & UNSYNCHRONIZED when uploading vertices sequentially. 2010-01-21 15:18:40 -08:00
José Fonseca
1797494946 util: Use pipe_buffer_write_nooverlap in blits / mipmap generation. 2010-01-21 15:18:40 -08:00
José Fonseca
a8477fb00c gallium: New inline to write buffers which avoids synchronization. 2010-01-21 15:18:40 -08:00
José Fonseca
707b28136f gallium: Set PIPE_BUFFER_USAGE_DISCARD flag in pipe_buffer_write. 2010-01-21 15:18:40 -08:00
José Fonseca
13c2475339 gallium: Remove temporary hack for the absence of a discard flag.
PIPE_BUFFER_USAGE_DISCARD flag now exists.
2010-01-21 15:18:40 -08:00
José Fonseca
0ae076bf40 svga: Follow buffer usage semantics properly.
It's necessary to download buffers from the host always, except if the
buffer is undefined, because:
- just PIPE_BUFFER_USAGE_CPU_WRITE doesn't guarantee all data is written
  -- old contents may still pierce through
- PIPE_BUFFER_USAGE_DISCARD refers to a range, not the whole buffer, so
  unless we track which parts have been modified and not we still need
  to download the data.
2010-01-21 15:18:40 -08:00
Vinson Lee
efc08bddb7 st/xorg: Remove unnecessary headers. 2010-01-21 15:05:21 -08:00
Brian Paul
e5829ccc2b progs/demos: call glutDestroyWindow() upon exit 2010-01-21 15:41:03 -07:00
Brian Paul
cd9d9e2436 llvmpipe: added simple perf/statistics counting facility
Currently counting number of tris, how many tiles of each size are
fully covered, partially covered or empty, etc.

Set LP_DEBUG=counters to enable.  Results are printed upon context
destruction.
2010-01-21 15:39:57 -07:00
Roland Scheidegger
2cf8164065 r200: fix CS section size mismatch
Partial fix for fdo bug 25544

The tex handling will still need CS drm changes,
see bug 25544 for more.
2010-01-21 17:33:51 -05:00
Vinson Lee
4222bf3d3c llvmpipe: Remove unnecessary headers. 2010-01-21 14:31:15 -08:00
Vinson Lee
c50fe2c55c svga: Remove unnecessary headers. 2010-01-21 12:12:11 -08:00
Roland Scheidegger
629bb3fa32 docs: enhance blend documentation 2010-01-21 20:48:13 +01:00
Roland Scheidegger
c6c9d3b091 docs: clean up sampler description 2010-01-21 20:22:24 +01:00
Roland Scheidegger
eba1e2a447 gallium: adapt util code to blend changes 2010-01-21 19:56:29 +01:00
Brian Paul
d65d5d2993 gallium: fix conditional rendering comment 2010-01-21 11:52:54 -07:00
Brian Paul
6c1549a77d gallium/docs: document conditional rendering 2010-01-21 11:52:36 -07:00
Roland Scheidegger
41667a9a3e gallium: new PIPE_CAP bits for the independent blend functionality 2010-01-21 19:45:43 +01:00
Brian Paul
6d4805b363 gallium: updated comments, whitespace fixes 2010-01-21 11:35:33 -07:00
Brian Paul
dc2914ab26 mesa: minor whitespace fix 2010-01-21 09:44:42 -07:00
Luca Barbieri
e59353f592 mesa: support for GL_ARB_fragment_coord_conventions
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-01-21 09:41:28 -07:00
Brian Paul
1ca2285511 progs/fp: testcases for GL_ARB_fragment_coord_conventions
Based on a patch from Luca Barbieri but moved the comments after
the !!ARBfp1.0 header
2010-01-21 09:38:50 -07:00
Brian Paul
24d3a7a251 docs: remove old pbuffer info 2010-01-21 08:16:54 -07:00
Brian Paul
aeff9f9725 docs: added target attribute to external URLs 2010-01-21 08:14:42 -07:00
Brian Paul
656834a871 docs: add links to the egl, openvg, opengles pages
And move the GLSL link up the use User Topics section.
2010-01-21 08:14:29 -07:00
Brian Paul
074abd889f softpipe: added region assertions in softpipe_get_tex_transfer() 2010-01-21 08:04:15 -07:00
Brian Paul
ed9bd82656 docs: new Mesa source tree overview page.
This has been sitting around for a while.  Incomplete, but a good start.
2010-01-21 08:04:15 -07:00
Chia-I Wu
4736e1cbbd dri: Remove unnecessary glapi headers.
They are not used at all.
2010-01-21 17:49:59 +08:00
Chia-I Wu
bdd2500805 Do not include glapi/dispatch.h outside Mesa core.
Include the glapi*.h directly instead.  glapi/dispatch.h became a Mesa
core header since 22884db174.
2010-01-21 17:48:38 +08:00
Chia-I Wu
1af67195b3 docs: Update documentation for OpenVG and OpenGL ES.
Update the instructions and add references to egl.html.
2010-01-21 15:59:06 +08:00
Chia-I Wu
ada46053a4 docs: Add documentation for EGL.
This is a short guide to EGL.  The drivers that are to be removed soon
are not mentioned in the guide.
2010-01-21 15:58:47 +08:00
Vinson Lee
e19b3c01f4 mach64: Remove unnecessary headers. 2010-01-20 22:52:49 -08:00
Vinson Lee
7c66211b7d i810: Remove unnecessary headers. 2010-01-20 22:02:51 -08:00
Alan Coopersmith
208e815c88 gallium/i965: Make brw_batchbuffer prototypes match in source & header
Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-01-20 18:06:34 -08:00
Brian Paul
63f249bf90 llvmpipe: optimize tile writing code
The code which converts/copies color tiles to the linear layout has
been rewritten.  There's less arithmetic and better loop unrolling,
and possibly a better memory access pattern.
Some demos, like gears, are about 20% faster now.
2010-01-20 17:48:13 -07:00
Brian Paul
7319ae0954 llvmpipe: remove tile clipping code
The surface is always a multiple of the tile size now.
2010-01-20 17:47:26 -07:00
Brian Paul
0706dae088 llvmpipe: align display target size to multiple of tile size
This will allow us to skip clipping tiles to surface bounds.
2010-01-20 17:44:12 -07:00
Vinson Lee
0bc2cbf82a ffb: Remove unnecessary headers. 2010-01-20 16:27:44 -08:00
Brian Paul
58903b3781 llvmpipe: put TILE_SIZE #define in its own header
To avoid including lp_tile_soa.h in other places.
2010-01-20 17:23:11 -07:00
Brian Paul
9b534400d9 llvmpipe: add makefile rule for generating .s files 2010-01-20 17:19:00 -07:00
Corbin Simpson
c1334ce235 radeong: Fix EGL driver names.
Using "radeon" instead of "radeong" because we don't have classic EGL.
2010-01-20 12:22:05 -08:00
Tomas Chvatal
1ffb72a6bf Fix touching live system during install. 2010-01-20 12:22:05 -08:00
Brian Paul
4d2dc9da82 llvmpipe: updated comment 2010-01-20 11:32:48 -07:00
Brian Paul
a416123f5b xlib/softpipe: fix buffer memory leak
Fixes leak caused by window resize.
2010-01-20 10:34:45 -07:00
Roland Scheidegger
04cb5dfb1e llvmpipe: adapt to per-rendertarget blend changes 2010-01-20 18:27:53 +01:00
Roland Scheidegger
bef610f693 gallium: prepare for per-rendertarget blend enables, writemasks, blend funcs
GL 3.0 (EXT_draw_buffers2) and other APIs allow independent blend enables and
write masks per render target, ARB_draw_buffers_blend (and other APIs) also
allow independent blend functions. Things like dithering, logic ops however
are not extended to be per rendertarget, that might be conceptually possible
however it doesn't look like any API wants to expose this.
2010-01-20 18:26:49 +01:00
Alex Deucher
156c90e5c3 r200: re-adding missing pitch alignment check in blit code
lost after switch to common code
2010-01-20 11:19:06 -05:00
Brian Paul
05208b298d mesa: replace questionable CPU_TO_LE32 macro with function 2010-01-20 08:18:33 -07:00
Alan Coopersmith
506e27b972 Copy __FUNCTION__ portability #defines from mesa/compiler.h to eglcompiler.h
Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-01-20 23:18:07 +08:00
Brian Paul
65d2a26637 st/mesa: fix format logic in compatible_src_dst_formats()
We need to consider the user-requested formats, not the actual device-
chosen formats.  See code comments for more details.
2010-01-20 08:09:53 -07:00
Brian Paul
4e34c5d0b5 docs: updated Mesa mailing list info 2010-01-20 08:09:53 -07:00
Alex Deucher
67aa704112 r200: fix some breakage after move to common blit code 2010-01-20 10:00:50 -05:00
Jakob Bornecrantz
9f728ed1c9 st/xorg: Fic bug and close drm_api at proper place 2010-01-20 14:55:07 +00:00
Alex Deucher
5a99ca490f r200: fix typo in 76cf261832
noticed by Maciej on IRC.
2010-01-20 09:06:49 -05:00
Chia-I Wu
c8b694b2c2 st/egl_g3d: Add support for driver probe.
Hook the drv->Probe callback to allow the drivers to probe displays.
The loading of state trackers is delayed to avoid unnecessary loading.
2010-01-20 18:15:30 +08:00
Chia-I Wu
11f4360f2e st/egl_g3d: Add support for probe to native displays.
The functions can be used to check if a display is supported without
creating a struct native_display.  It uses a probe object that can be
shared across drivers.
2010-01-20 18:15:26 +08:00
Chia-I Wu
c5766c4ae3 egl: Add a simple cache for driver probe.
In current design, multiple drivers will probe the same display and the
best driver is determined.  The cache can be used by the drivers to
store and share the probed data.
2010-01-20 17:44:12 +08:00
Chia-I Wu
cf22fd5e5b egl: Improve driver matching.
Make drv->Probe return a score so that the matching can be done by
finding the driver with the highest score.
2010-01-20 17:44:11 +08:00
Chia-I Wu
925f8113be egl: Rename _EGL_PLATFORM_X to _EGL_PLATFORM_POSIX.
The macro is used to determine if dlfcn.h or dirent.h is available.
POSIX is a better name than X in such case.
2010-01-20 17:44:11 +08:00
Chia-I Wu
f0c2871bf4 egl: Remove unused driver and display functions.
Remove _eglPreloadDriver, _eglLookupDriver, and _eglSplitDisplayString.
2010-01-20 17:40:07 +08:00
Chia-I Wu
57929eda3e egl: Use _eglPreloadDrivers.
Replace the use of _eglPreloadDriver by _eglPreloadDrivers.  The latter
supports EGL_DISPLAY which have a better chance to "just work".
2010-01-20 17:40:07 +08:00
Chia-I Wu
b3bcd33f7a egl: Add _eglPreloadDrivers.
It can be used to load the user driver specified by EGL_DRIVER, or a set
of drivers specified by EGL_DISPLAY, or the default driver, and in that
order.
2010-01-20 17:40:00 +08:00
Vinson Lee
e3cb614f93 softpipe: Remove unnecessary headers. 2010-01-20 00:08:54 -08:00
Vinson Lee
ac2a665fd7 i915g: Remove unnecessary headers. 2010-01-19 22:47:03 -08:00
Chia-I Wu
f291200a4b st/egl_g3d: Do not reuse the pipe transfer in ximage.
A pipe transfer is supposed to be temporary.  It should be created
before X*PutImage and destroyed afterwards.
2010-01-20 13:30:55 +08:00
Alan Coopersmith
77c0800381 mklib: Fix static library generation/installation on Solaris
Change ar flag from -v (-verbose) to -c (silence console output)
so that it stops causing make_ar_static_lib() to return a bunch
of output other than the resulting library file.

Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
2010-01-19 19:06:06 -08:00
Alan Coopersmith
917b6d2a4b Remove hardcoded -Wall from Radeon DRI makefiles
Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-01-19 19:05:52 -08:00
Corbin Simpson
d4a3f7d3ca r300g: Move GB_AA_CONFIG to its eventual new home. 2010-01-19 18:15:17 -08:00
Corbin Simpson
fcbd285e42 r300g: Make invariant state into an atom. 2010-01-19 18:15:17 -08:00
Chia-I Wu
5e8240320a Merge remote branch 'origin/opengl-es-v2' 2010-01-20 10:02:15 +08:00
Brian Paul
1658f80153 util/blit: document params to util_blit_pixels_writemask() 2010-01-19 18:01:02 -07:00
Brian Paul
031f23ac3a mesa: added comment about future FBO formats 2010-01-19 18:01:02 -07:00
Marek Olšák
cd232ae22f st/mesa: enable EXT_framebuffer_multisample
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-01-19 18:01:02 -07:00
Alex Deucher
76cf261832 r100/r200: fix Y coord flipping in accelerated blits 2010-01-19 19:13:26 -05:00
Brian Paul
ec459f2aec llvmpipe: asst. task-related clean-ups 2010-01-19 16:58:25 -07:00
Alex Deucher
1bb6b1d9db r100/r200: fix dst pitch in blit code 2010-01-19 18:52:19 -05:00
Alex Deucher
f965345ea5 r200: add missing symlink to radeon_tex_copy.c 2010-01-19 18:48:36 -05:00
Maciej Cencora
1f0709fd8f r100/r200: align to pitch updates in blit interface 2010-01-20 00:09:11 +01:00
Maciej Cencora
2706bc6a88 r200: use common glCopyTex(Sub)Image code 2010-01-19 23:38:35 +01:00
Maciej Cencora
5170d2452b r100: use common glCopyTex(Sub)Image code 2010-01-19 23:38:35 +01:00
Maciej Cencora
8a4d7393bd radeon/r300/r600: share common glCopyTex(Sub)Image code 2010-01-19 23:38:34 +01:00
Maciej Cencora
0aed44f8a3 r600: align to r300 changes in the blit code
Pitch here means aligned width, not aligned width * bpp.
2010-01-19 23:38:34 +01:00
Maciej Cencora
0174dac5f3 r300/r600: move some bo offsets checking to blit code
In preperation for texcopy code sharing.
2010-01-19 23:38:34 +01:00
Maciej Cencora
ac8afd401f r600: prepare for some code sharing 2010-01-19 23:38:34 +01:00
Maciej Cencora
f54e96c597 r300: check if blitting for given format is supported earlier
Prevents failing assertions at later stage.
2010-01-19 23:38:33 +01:00
Maciej Cencora
acac99e35a r300: use nearest texture filtering for accelerated blits 2010-01-19 23:38:33 +01:00
Maciej Cencora
f2fea26269 r300: fix Y coord flipping in accelerated blits 2010-01-19 23:38:33 +01:00
Maciej Cencora
11affafc75 radeon: use mesa provided _mesa_tex_target_to_face function 2010-01-19 23:38:33 +01:00
Maciej Cencora
9363a813f1 r300: prepare for texcopy code sharing 2010-01-19 23:38:33 +01:00
Maciej Cencora
f542fde77e radeon: add blit function to vtbl 2010-01-19 23:38:09 +01:00
Jakob Bornecrantz
bea9ed4dc6 svga: Do a more propper creation of textures from handles 2010-01-19 23:30:31 +01:00
Jakob Bornecrantz
c78fe6e050 st/xorg: Don't leak BusID buffer 2010-01-19 23:30:30 +01:00
Eric Anholt
8f7dfe3025 intel: Remove dead note_fence vtbl hook. 2010-01-19 12:09:29 -08:00
Eric Anholt
a45f24c0a4 i965: Improve the hashing of brw_state_cache keys to include the cache_id.
No measurable difference on cairoperf.
2010-01-19 11:35:33 -08:00
Eric Anholt
d1cefabf98 i965: Remove obsolete comment about the state atoms. 2010-01-19 11:32:57 -08:00
Eric Anholt
fb4901593c i965: Upload as many VS constants as possible through the push constants.
The pull constants require sending out to an overworked shared unit
and waiting for a response, while push constants are nicely loaded in
for us at thread dispatch time.  By putting things we access in every
VS invocation there, ETQW performance improved by 2.5% +/- 1.6% (n=6).
2010-01-19 11:31:23 -08:00
Eric Anholt
62a96f74c9 i965: Allow for variable-sized auxdata in the state cache.
Everything has been constant-sized until now, but constant buffer
handling changes will make us want some additional variable sized
array.
2010-01-19 11:31:05 -08:00
Eric Anholt
7d4e674b21 intel: Use the new DRI2 flush invalidate entrypoint to signal frame done.
Previously for frame throttling we would wait on the first batch after
a swap before emitting another swap, because we had no hook after a
swap was emitted.  This meant that if an app managed to squeeze
everything it for a frame had into one batch, it would lock-step with
the GPU.  With the swapbuffers changes, we now have the entrypoint we
want.

This takes the WoW intro screen from 25% GPU idle and visibly jerky to
4-5% GPU idle and rather smooth.  Other apps such as OpenArena have
run into this problem as well.
2010-01-19 11:07:51 -08:00
Brian Paul
d8d80a8d74 llvmpipe: fix-up comment 2010-01-19 11:58:43 -07:00
Alan Coopersmith
a7aaf052f9 Sun compilers now support some gcc __attribute__ values
Sun cc 5.9 and later (__SUNPRO_C >= 0x590) support __attribute__ calls
for aligned, always_inline, noinline, pure, const, and malloc.

This commit includes updates to files that were regenerated by gl_XML.py
after adding the __SUNPRO_C checks to it

Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-01-19 10:15:55 -08:00
Alan Coopersmith
adda7f3215 Check if gcc supports -fvisibility=hidden before adding to CFLAGS
Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
2010-01-19 10:15:55 -08:00
Brian Paul
aec3fe82e4 softpipe: remove redundant assignments
We initialized width/height/depth from pt->width0/height0/depth0 above.
2010-01-19 11:14:00 -07:00
Brian Paul
1073e39ab9 llvmpipe: re-order file list, fix indentation 2010-01-19 09:45:51 -07:00
Brian Paul
0fccfc9cc0 llvmpipe: remove unneeded DEBUG checks, use step var 2010-01-19 09:30:44 -07:00
Brian Paul
75f262b8b4 llvmpipe: updated comments 2010-01-19 09:30:13 -07:00
Jakob Bornecrantz
65354a7e3d st/xorg: Pass kernel driver name to drmOpen 2010-01-19 17:12:12 +01:00
Jakob Bornecrantz
a5fb5d6a54 st/drm: Expose kernel driver name
Based on patch by Chia-I Wu <olvaffe@gmail.com>

Expose the name of the kernel driver as accepted by drmOpenByName.
2010-01-19 17:10:04 +01:00
Ben Skeggs
116a02be22 st/dri: update dri2 drawables when viewport is changed
Fixes gnome-shell on nouveau, as well as window resize with various
other applications.

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-01-19 17:06:22 +01:00
Luca Barbieri
e88294328c glx: Set GL context to null in __glXSetCurrentContextNull
__glXSetCurrentContextNull currently does not set the GL context to null
in the direct rendering case.

This can result in a segfault trying to flush an invalid old context
in glXMakeCurrent.

This fixes a crash starting the Unigine demos (they still don't work due
to missing extensions though).

Signed-off-by: Brian Paul <brianp@vmware.com>
2010-01-19 08:59:37 -07:00
José Fonseca
7a39a5c1cb wgl: Check for PIPE_TEXTURE_USAGE_DISPLAY_TARGET support in exported color pixel formats.
Since all formats we export have PFD_DRAW_TO_WINDOW flag.
2010-01-19 06:14:12 -08:00
José Fonseca
5e870f4fe9 wgl: Don't export pure-stencil pixel formats.
They cause DCT's conform to always fail.
2010-01-19 06:14:12 -08:00
José Fonseca
e5da7b8548 softpipe: Fix vertex buffer memory leak. 2010-01-19 06:14:12 -08:00
Vinson Lee
faa99dd31d unichrome: Remove unnecessary headers. 2010-01-19 00:45:16 -08:00
Vinson Lee
45a27eacd6 mesa: Remove unnecessary header from attrib.c. 2010-01-18 22:50:08 -08:00
Alex Deucher
ef631104d5 r100/r200/r600: fix typo in 2b1d5ea4f0 2010-01-19 01:47:04 -05:00
Vinson Lee
2613fa815a mesa: Remove unnecessary header from blend.c. 2010-01-18 22:45:23 -08:00
Alex Deucher
2b1d5ea4f0 r100/r200/r600: check if blitting for given format is supported earlier
based on Maciej's r300 patch.
2010-01-19 01:42:41 -05:00
Alex Deucher
a67cd1994f r100/r200: add blit support for ARGB4444 2010-01-19 01:26:35 -05:00
Vinson Lee
c4ad036ce1 mesa: Remove unnecessary headers from buffers.c. 2010-01-18 22:17:03 -08:00
Vinson Lee
7366d8e7d2 mesa: Remove unnecessary header from convolve.c. 2010-01-18 21:56:58 -08:00
Vinson Lee
08063ba449 mesa: Fix typo of 'unknown' in debug.c. 2010-01-18 21:41:31 -08:00
Vinson Lee
b36b85f9d0 mesa: Remove unnecessary headers from debug.c. 2010-01-18 21:37:18 -08:00
Vinson Lee
6deb8c9831 mesa: Remove unnecessary header from depthstencil.c. 2010-01-18 21:34:25 -08:00
Vinson Lee
2660511ea9 mesa: Remove unnecessary headers from dlist.c. 2010-01-18 21:31:02 -08:00
Vinson Lee
7395ab042a mesa: Remove unnecessary header from drawpix.c. 2010-01-18 21:22:47 -08:00
Vinson Lee
0b3109aa05 mesa: Remove unnecessary header from enable.c. 2010-01-18 21:17:45 -08:00
Vinson Lee
536e3c9168 mesa: Remove unnecessary headers from fbobject.c. 2010-01-18 21:14:04 -08:00
Vinson Lee
b6dce54214 mesa: Remove unnecessary header from formats.c. 2010-01-18 21:07:53 -08:00
Vinson Lee
2cbc3e0a20 mesa: Remove unnecessary header from image.c. 2010-01-18 21:02:19 -08:00
José Fonseca
65fa11959f softpipe: Skip depth testing for PIPE_S8_UNORM. 2010-01-18 20:34:19 -08:00
José Fonseca
8fb92e96e9 mesa: Handle PIPE_FORMAT_B8G8R8X8_UNORM. 2010-01-18 20:34:19 -08:00
José Fonseca
bcadde2068 pipebuffer: Ensure buffer size/alignment is not zero. 2010-01-18 20:34:19 -08:00
José Fonseca
dc298559c6 svga: Ensure buffer size/alignment is not zero. 2010-01-18 20:34:19 -08:00
Vinson Lee
ebd1075598 mesa: Remove unnecessary headers from lines.c. 2010-01-18 19:32:51 -08:00
Vinson Lee
d0125e3c29 mesa: Remove unnecessary header from mipmap.c. 2010-01-18 19:23:47 -08:00
Vinson Lee
ed5a116eb4 mesa: Remove unnecessary header from pixel.c. 2010-01-18 19:20:56 -08:00
Vinson Lee
2f83948370 mesa: Remove unnecessary headers from pixelstore.c. 2010-01-18 19:14:23 -08:00
Vinson Lee
419ae5a483 mesa: Remove unnecessary header from points.c. 2010-01-18 19:10:05 -08:00
Vinson Lee
80ea879cfa mesa: Remove unnecessary header from polygon.c. 2010-01-18 19:03:54 -08:00
Alex Deucher
f6d529083f r60: Add relocs for CB_TILE/FRAG
as per 46dc6fd3ed
2010-01-18 22:00:05 -05:00
Vinson Lee
6603550353 mesa: Remove unnecessary header from state.c. 2010-01-18 18:54:54 -08:00
Vinson Lee
ec29ba12a6 mesa: Remove unnecessary headers from texcompress.c. 2010-01-18 18:52:24 -08:00
Vinson Lee
f8db32acbd st/dri: Add comment for intentional fallthrough in case statement. 2010-01-18 18:14:03 -08:00
Corbin Simpson
09f69b1e5d docs: Clarify PIPE_TEXTURE_USAGE_DYNAMIC. 2010-01-18 18:06:55 -08:00
Corbin Simpson
f90733c116 docs: Use proper XOR symbol. 2010-01-18 18:06:55 -08:00
Alex Deucher
daccc962a1 r100: add blit support
Only enabled with KMS.
2010-01-18 20:56:58 -05:00
Alex Deucher
1ced546577 r200: add blit support
Only enabled with KMS.
2010-01-18 20:56:58 -05:00
Corbin Simpson
047719182f docs: Spacing in TGSI formulae.
Some of those still look atrocious. :T
2010-01-18 17:31:56 -08:00
Corbin Simpson
28fd246634 docs: Grammar and refs in Rasterizer. 2010-01-18 17:17:09 -08:00
Corbin Simpson
2598f00078 docs: Cleanup Rasterizer a bit.
I'm getting better at this, I think.
2010-01-18 17:12:13 -08:00
Corbin Simpson
2b4ad02321 docs: Fix terms and refs.
I fail at Sphinx-style ReST.
2010-01-18 16:40:39 -08:00
Brian Paul
9a23d810be llvmpipe: tweak a comment 2010-01-18 17:39:54 -07:00
Corbin Simpson
4f52dfeda2 docs: Slowly keep fleshing out more info. 2010-01-18 15:30:28 -08:00
Corbin Simpson
9811ebf61f docs: PIPE_TEXTURE_USAGE info.
From IRC with Jakob.
2010-01-18 15:30:28 -08:00
Eric Anholt
0714474ae2 i965: Clean up constbuf handling by splitting reladdr/non-reladdr loads.
The codepaths in the function were almost entirely different.
2010-01-18 13:52:47 -08:00
Eric Anholt
c653f5f387 i965: Only set up the stack register if it's going to get used. 2010-01-18 13:52:47 -08:00
Eric Anholt
d5b964234c i965: Fix loads of non-relative-addr constants after a reladdr load.
Fixes piglit vp-arl-constant-array-huge-overwritten.
2010-01-18 13:52:47 -08:00
Brian Paul
89bb07730b util: fix broken util_ringbuffer_dequeue()
The tests for an empty ring buffer were incorrect.
Fixes glxinfo segfaults.

Plus, add a new assertion.
2010-01-18 14:35:43 -07:00
Christoph Bumiller
c6559b7e01 nv50: fix constant vtxattr methods
This function was untested, sorry.
2010-01-18 21:40:30 +01:00
Brian Paul
62623c4dc5 llvmpipe: added show_tiles and show_subtiles debug options
These options draw lines over the tiles to show the 64x64 tile
bounds and 16x16 sub-tile bounds.  For debugging/visualization.
2010-01-18 13:10:14 -07:00
Christoph Bumiller
0d6e3dd84d nv50: make instanced drawing work with edge flags
And fix some obvious mistakes introduced in the
previous instancing commit.
2010-01-18 19:53:29 +01:00
Christoph Bumiller
e74db4f20f nv50: cannot exit shaders on a control flow instruction
Fixes lockup triggered by this ingenious shader:
   1: CALL :3
   2: END
   3: BGNSUB ...
2010-01-18 19:53:29 +01:00
Marcin Slusarz
9fb9c9f9ca nv50: fix nv50_program->immd memory leak 2010-01-18 19:53:29 +01:00
Brian Paul
28576c9ac5 st/mesa: change instruction count assertion to > 0
Shaders should at least have an END instruction.
2010-01-18 11:26:57 -07:00
Michal Krol
7472cd0f1f tgsi: Fix behaviour of dimension index.
The dimension index always addresses the second-dimension axis.
2010-01-18 19:13:49 +01:00
Michal Krol
463351ea6c tgsi: Allow TEMPORARY registers as indirect address into source operands. 2010-01-18 19:13:45 +01:00
Michal Krol
4698a865e0 tgsi: Add ureg_DECL_immediate_block_uint().
Allows declaring a contiguous block of immediates. Useful for
relative indexing.
2010-01-18 19:13:42 +01:00
Brian Paul
4c041fac96 glsl: remove __inline directive
It makes no difference with gcc -O3, for example.
2010-01-18 11:06:57 -07:00
Marcin Slusarz
e978b24c87 st/dri: fix optionCache memory leaks
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-01-18 10:48:06 -07:00
Marcin Slusarz
23ae318200 glxgears: unbind current context before "destroying" it
glXDestroyContext does not destroy the context if it's still
connected to some window. Unbind context from window to test it.

Signed-off-by: Brian Paul <brianp@vmware.com>
2010-01-18 10:44:53 -07:00
Brian Paul
0766780a98 st/mesa: updated comments and whitespace 2010-01-18 10:43:33 -07:00
Marcin Slusarz
e5347ca94d st/mesa: fix memory leak in st_translate_mesa_program
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-01-18 10:39:27 -07:00
Alex Deucher
3310fe0e91 r600: fix some warnings 2010-01-18 11:21:19 -05:00
Jerome Glisse
1560183536 r600: Update default state size to account for the new relocation
the new relocation for CB_COLOR0_FRAG & CB_COLOR0_TILE add 4
dwords to the default command stream. Increase the prediction
default size to take this into account
2010-01-18 15:32:24 +01:00
Jerome Glisse
46dc6fd3ed r6xx/r7xx: emit relocation for FRAG & TILE buffer
FRAG & TILE buffer are unused but still they need
to be associated with a valid relocation so that
userspace can't try to abuse them to overwritte
GART and then try to write anywhere in system
memory.
2010-01-18 12:14:07 +01:00
Andre Maasikas
7b82f0f67e r600: fix shadow_ambient shader
rtype enums are different, DST_REG_OUTPUT got SRC_REG_CONSTANT in some
shaders and produced invalid output/hang
as TEX output is temp register always set out src to SRC_REG_TEMPORARY
2010-01-18 12:49:06 +02:00
Corbin Simpson
0857f38c39 radeong: Don't allocate HW BOs for constantbufs.
We have broken 1000 FPS. Hell yes.

Heavily inspired by Marek's patch, but using pipebuffer instead of
a roll-your-own malloc.
2010-01-18 02:35:08 -08:00
Marek Olšák
673ae6266e r300g: fix polygon offset
As per classic r300.

Not sure why glean/polygonOffset still fails, but we do emit the same register
values as in classic.
2010-01-18 02:35:08 -08:00
Marek Olšák
d3d41cbc35 r300g: fix vertex data swizzle 2010-01-18 02:35:08 -08:00
Marek Olšák
cd553ec8be r300g: do not align compressed textures to a tile size 2010-01-18 02:35:08 -08:00
Chia-I Wu
064eb0a095 st/egl_g3d: Clean up for x11_drawable_get_depth.
Fix a wrong comment and remove an unnecessary #include.
2010-01-18 17:15:57 +08:00
Corbin Simpson
a16d353b5e dri: Add an MSAA-enabled factor to DRI configs.
4 samples should be enough for GLUT to be satisfied, and I think most
of the HW that does any MSAA, can do it.

Note that any pipe that doesn't multisample can just ignore the
corresponding flag in pipe_rasterizer_state.
2010-01-18 01:13:33 -08:00
Corbin Simpson
c273ab007d dri: Properly calculate number of modes for MSAA.
Split from the next patch for bisection purposes only.
2010-01-18 01:13:33 -08:00
Corbin Simpson
58a7d8db98 radeong: Check DRM version, and report stats. 2010-01-18 01:13:33 -08:00
Corbin Simpson
11a2bbc3e9 radeong: Use vram_size instead of vram_visible.
The kernel will decide on its own what to give us.
2010-01-18 01:13:33 -08:00
Chia-I Wu
8311a49b2d progs/egl: Pass EGLDisplay to eglCopyBuffers.
X Display was wrongly passed to eglCopyBuffers.
2010-01-18 17:07:19 +08:00
Chia-I Wu
ede755af4c st/egl_g3d: Add support for eglCopyBuffers.
It uses a slow path to copy the render buffer of the surface to the
target pixmap.  We might be able to create a pipe context for
EGLDisplay's use and use a blitter context for the purpose.  It is left
for a future consideration.
2010-01-18 17:07:06 +08:00
Chia-I Wu
f8244e2946 st/egl_g3d: Add is_pixmap_supported to native display interface.
The function may be used to support, for example,
EGL_MATCH_NATIVE_PIXMAP and EGL_KHR_image_pixmap.
2010-01-18 17:04:02 +08:00
Chia-I Wu
fda897ad71 st/egl_g3d: Update validate to use an attachment mask.
A validate call asks for the buffers of a native surface.  Using a mask
to represent the interested buffers is more intuitive.  It also rules
out corner cases such as a single attachment being listed multiple
times.
2010-01-18 14:28:13 +08:00
Chia-I Wu
1ed6311945 st/vega: Fix window resizing with egl_g3d.
egl_g3d calls st_set_framebuffer_surface on window resize.  It updates
the renderbuffer's geometry and makes st_resize_framebuffer a no-op.
This commit improves the no-op check a little bit.  It can do better
after gallium-fb-dimensions is merged.
2010-01-18 12:07:57 +08:00
Chia-I Wu
ef517c9385 st/vega: Call screen->update_buffer instead of winsys->update_buffer.
This removes the last reference to winsys and is per mesa/st.
2010-01-18 11:57:30 +08:00
Chia-I Wu
3b71386426 tgsi: Add missing semantic name in text parser.
This time, INSTANCEID is missing...
2010-01-18 11:57:30 +08:00
Jakob Bornecrantz
90cdf0d67c cso: Add set_vertex_samplers function 2010-01-18 00:12:42 +00:00
Jakob Bornecrantz
2a60302e51 softpipe: Fix leak in vbuf draw module 2010-01-18 00:12:42 +00:00
Christoph Bumiller
1448d2f252 nv50: implement instanced drawing
Too bad we don't have hw array divisors or a method for
setting startInstance.
2010-01-17 17:48:01 +01:00
Jakob Bornecrantz
a4bbabf494 softpipe: Move st/python's malloc winsys to softpipe
Users of softpipe can still specify thier own winsys
but now there is a default one also that uses malloc.
This allows the malloc winsys to be shared with other
users of softpipe.
2010-01-17 16:44:39 +00:00
Jakob Bornecrantz
0e4e2c57d1 st/xlib: Make glXGetProcAddressARB visible 2010-01-17 16:44:39 +00:00
Jakob Bornecrantz
876a6b4865 gallium: Support swig "compiler" in p_compiler.h 2010-01-17 16:44:39 +00:00
Jakob Bornecrantz
31c626811a i965g: Link against drm_intel instead of drm_radeon 2010-01-17 16:44:25 +00:00
Corbin Simpson
945cea01d9 r300g: Check for bogus texture targets. 2010-01-17 01:13:45 -08:00
Marek Olšák
b62d339301 r300g: fix the rasterization of secondary color
When the secondary color is used, the primary color must always be rasterized
regardless of whether it is used or not.
2010-01-17 01:10:58 -08:00
Marek Olšák
7d3090f0fe r300g: fix vertex colors with 8 bits per channel
The piglit BGRA tests pass now.
2010-01-17 01:10:32 -08:00
Marek Olšák
c4a2f13a5c r300g: simplify is_format_supported 2010-01-17 01:04:30 -08:00
Marek Olšák
8959608051 r300g: output texture debug messages if only RADEON_DEBUG=tex is set 2010-01-17 01:03:50 -08:00
Marek Olšák
08edbe9f14 r300g: move debug flags into r300_screen 2010-01-17 01:02:12 -08:00
Marek Olšák
21f3bbf149 r300g: disable the MIP filter for NPOT textures
Safety first.
2010-01-17 01:01:25 -08:00
Marek Olšák
37897a65e2 r300g: fix the CS size when emitting invariant state 2010-01-17 01:00:35 -08:00
Alan Coopersmith
816cb90e7c radeon_compiler: include main/compiler.h for compiler portability macros
Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
Reviewed-by: Corbin Simpson <MostAwesomeDude@gmail.com>
2010-01-17 00:55:39 -08:00
Corbin Simpson
c69bd0ead7 r300g: Stop using indices.
Sorry, it was a good game, but it just doesn't work.
2010-01-16 18:17:40 -08:00
Corbin Simpson
eedebfa579 r300g: Respect fill modes in indices fallback. 2010-01-16 18:17:40 -08:00
Keith Whitwell
591401ff05 llvmpipe: use new u_ringbuffer for scene queue 2010-01-17 00:30:23 +00:00
José Fonseca
ba5d600c90 Merge remote branch 'origin/master' into lp-binning
Conflicts:
	src/gallium/drivers/llvmpipe/lp_quad.h
	src/gallium/drivers/llvmpipe/lp_setup.c
2010-01-16 23:21:06 +00:00
Keith Whitwell
164fd16cfb util: add generic ringbuffer utitilty 2010-01-16 21:15:55 +00:00
Chia-I Wu
dee52d5bd3 gallium: Fix uninitialized instance divisor and index. 2010-01-16 18:18:09 +01:00
Christoph Bumiller
83387cb6c4 nv50: fix tile flags for scanout tex usage 2010-01-16 18:07:31 +01:00
Christoph Bumiller
0ae3db1734 nv50: handle all and more system values 2010-01-16 18:07:31 +01:00
Christoph Bumiller
4c223aaa3b nv50: hook up geometry programs 2010-01-16 18:07:31 +01:00
Christoph Bumiller
bbb615382d nv50: support for geometry programs in nv50_program 2010-01-16 18:07:31 +01:00
Christoph Bumiller
e791e6f27c nv50: get access to primitive input space
Vertex data in geometry programs is located in p[] space.
The base address in p[] for vertex i is located in vertex
attribute space, i.e. a[i << 2].

This means p[] is always accessed with an address register,
and I had to to mess with their allocation once again.

Also fixes negative offsets e.g. CONST[ADDR[0].x - 3].
2010-01-16 18:07:30 +01:00
Julien Cristau
b1a8810204 Rename the build directory to not include DEB_BUILD_GNU_TYPE for no good reason. Thanks, Colin Watson! 2010-01-16 16:48:55 +00:00
Alex Deucher
8d24273750 r600: remove stray END_BATCH in blit code 2010-01-16 08:45:08 -05:00
Jakob Bornecrantz
a5c03bd6f1 draw: Fix memory leak in gs code 2010-01-16 10:44:57 +00:00
Dave Airlie
66e561a036 i965g: make xorg state tracker build i965g_drv.so
don't make modesetting_drv.so anymore
2010-01-16 19:28:45 +10:00
Alex Deucher
8b704396a3 r600: improve blit support
- fill in more src/dst formats
- disable depth copies for now
- set proper data formats in render target regs
- fill in additional default state

The swizzles on some of the less used mesa formats
are probably wrong.
2010-01-15 23:06:18 -05:00
Andre Maasikas
7283a246ce r600: add initial blit support 2010-01-15 23:06:05 -05:00
Alex Deucher
ec8ce40083 r600: add r600_blit.c
Unfinished.
2010-01-15 23:05:56 -05:00
Patrice Mandin
923aab93d9 nouveau: nv30: Remove useless variables fs, txp. Also do not change txf, as bit 13 is in the texture format
Signed-off-by: Patrice Mandin <patmandin@gmail.com>
2010-01-15 22:29:13 +01:00
Brian Paul
fdfe06ad80 llvmpipe: implement scissor test in triangle setup 2010-01-15 12:06:00 -07:00
Brian Paul
adb48d5350 llvmpipe: remove lp_rast_triangle::min/max fields
These values aren't needed outside the do_triangle_ccw() function.
2010-01-15 11:52:14 -07:00
Brian Paul
47fee14687 llvmpipe: skip 4x4 in/out test code
It's a litte faster to just do the in/out testing in the shader
jit code.
2010-01-15 11:35:30 -07:00
Brian Paul
12ba9e99db llvmpipe: added comment about lookup-tables vs. computation 2010-01-15 11:26:35 -07:00
Brian Paul
4bef3575e6 llvmpipe: change 'in' to boolean, add comments 2010-01-15 11:25:13 -07:00
Brian Paul
2797f2bf57 llvmpipe: generate two shader varients, one omits triangle in/out testing
When we know that a 4x4 pixel block is entirely inside of a triangle
use the jit function which omits the in/out test code.

Results in a few percent speedup in many tests.
2010-01-15 11:21:16 -07:00
Michal Krol
e124080cd6 util: Handle FORMAT_Z32_FLOAT in util_pack_z(). 2010-01-15 19:00:15 +01:00
Michal Krol
1433a2d935 util: Handle the remaining formats in pipe_put_tile_rgba(). 2010-01-15 19:00:11 +01:00
Michal Krol
d29e72633c util: Fix encoding for R8G8B8A8_UNORM formats and friends. 2010-01-15 19:00:09 +01:00
Michal Krol
42d55953b1 tgsi: Add ureg_property_gs_input_prim(). 2010-01-15 19:00:06 +01:00
Michal Krol
181adca5d6 tgsi: Add ureg_src_dimension(). 2010-01-15 19:00:03 +01:00
Michal Krol
857b37980c regress: Add .gitgnore for *.png files. 2010-01-15 18:59:59 +01:00
Michal Krol
b96976cc7c draw: Add missing header include. 2010-01-15 18:59:55 +01:00
Brian Paul
3b1920a349 llvmpipe: asst code changes in lp_state_fs.c 2010-01-15 10:25:59 -07:00
Roland Scheidegger
bf575b6c27 gallium: document set_constant_buffer 2010-01-15 18:25:14 +01:00
Roland Scheidegger
5e5d0ad081 Merge branch 'gallium-noconstbuf'
Conflicts:
	src/gallium/drivers/softpipe/sp_draw_arrays.c
	src/mesa/state_tracker/st_draw_feedback.c
2010-01-15 18:09:45 +01:00
Brian Paul
345178a7fc llvmpipe: put labels on some value refs 2010-01-15 10:04:16 -07:00
Roland Scheidegger
1c4ad77812 gallium: remove set_edgeflags from docs 2010-01-15 17:55:42 +01:00
Brian Paul
f97eeeec6b llvmpipe: add extra flags to DEFINES, no CFLAGS
Doesn't make any real difference but -D flags are put into DEFINES
everywhere else.
2010-01-15 09:16:34 -07:00
Brian Paul
5d57e70ffa configs: remove -ansi from linux-debug
-ansi implies -std=c89 but that conflicts with the -std=c99 flag
which is also provided.

Allows the r300g driver to compile.
2010-01-15 09:02:56 -07:00
Michal Krol
d1767bfdab tgsi: Fix sanity checks for indirect registers. 2010-01-15 11:44:23 +01:00
Chia-I Wu
8cfdbfbcbd st/egl_g3d: Avoid validation upon buffer swap or flush frontbuffer.
With screen->update_buffer being hooked, leave the job to the state
trackers.
2010-01-15 18:12:23 +08:00
Chia-I Wu
b2c7b08299 st/egl_g3d: Hook to update_buffer of the pipe screen.
It is a notification from the client APIs that the surface size might
have changed.
2010-01-15 18:12:20 +08:00
Chia-I Wu
51b00574a2 st/egl_g3d: Always override flush_frontbuffer.
Instead of letting the native displays install their own version of
flush_frontbuffer, always override the callback with a version that
calls the flush_frontbuffer of the native surface.
2010-01-15 17:42:57 +08:00
Michal Krol
6664a6dd7f st/mesa: Initialise vertex element instance divisor to 0. 2010-01-15 07:52:18 +01:00
Luca Barbieri
f7748d72b4 draw: Add GALLIUM_DUMP_VS environment variable.
Add GALLIUM_DUMP_VS to dump the vertex shader to the console like
GALLIUM_DUMP_FS in softpipe.
2010-01-15 07:30:17 +01:00
Brian Paul
8b29d39e99 progs/trival: updated tri-scissor-tri.c test
The scissor left/right/bottom/top bounds can be moved by pressing
the l/r/b/t and L/R/B/T keys.
2010-01-14 19:22:38 -07:00
Brian Paul
4461442849 llvmpipe: implement scissor testing
The scissor test is implemented as another per-quad operation in
the JIT code.  The four scissor box params are passed via the
lp_jit_context.  In the JIT code we compare the quad's x/y coords
against the clip bounds and create a new in/out mask that's AND'd
with the main quad mask.

Note: we should also do scissor testing in the triangle setup code
to improve efficiency.  That's not done yet.
2010-01-14 19:15:00 -07:00
Brian Paul
ca12e30d97 llvmpipe: minor comment update 2010-01-14 19:08:19 -07:00
Brian Paul
16ecd2f078 llvmpipe: clean-up, fixing up frame dump/debug code 2010-01-14 19:05:55 -07:00
Brian Paul
4f5675e94b gallium/util: added debug_dump_texture() and ppm output
Now we can get dump debug images on Linux too.
2010-01-14 19:04:42 -07:00
Jakob Bornecrantz
ccc888c39e st/xorg: If dri2 version is 2 support version 1 as well
Thanks to X server commit 2e2c5b216cc1c7a9bc26bd2c68226aaed5fc52ca
it is possible to be ABI compatible in version 2 with version 1 of
the DRI2 interface.
2010-01-15 01:38:04 +00:00
Jakob Bornecrantz
3e1241d4f8 st/xorg: Set enforce version to 1 if not defined 2010-01-15 01:38:04 +00:00
Thomas Hellstrom
ae97520e37 ws/vmware: Check DRM version also when bootstrapping in dri2 mode.
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
2010-01-18 15:56:57 +01:00
Thomas Hellstrom
5f2d60a715 st/dri: Don't request a fake front if the server adds one automatically.
We use the presence of the getBuffersWithFormat extension function to
detect whether the server automatically adds a front.

Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
2010-01-18 13:39:25 +01:00
Vinson Lee
d773f28ff2 mesa: Remove unnecessary headers from texformat.c. 2010-01-18 00:47:56 -08:00
Vinson Lee
39824945fa mesa: Remove unnecessary headers from texgetimage.c. 2010-01-18 00:14:51 -08:00
Vinson Lee
6938dccf1a mesa: Remove unnecessary header from teximage.c. 2010-01-17 22:31:53 -08:00
Vinson Lee
c847e7d07b mesa: Remove unnecessary header from texobj.c. 2010-01-17 20:50:15 -08:00
Vinson Lee
59eed7a201 mesa: Remove unnecessary header from texparam.c. 2010-01-17 16:21:11 -08:00
Vinson Lee
3e876431d0 mesa: Remove unnecessary headers from texstate.c. 2010-01-17 16:08:59 -08:00
Vinson Lee
6b6ac9aca0 mesa: Use preprocessor to comment out code. 2010-01-17 15:48:39 -08:00
Vinson Lee
ae943f8e20 mesa: Remove unnecessary headers from vtxfmt.c. 2010-01-17 01:49:16 -08:00
Vinson Lee
97e44cde17 mesa: Remove unnecessary headers from arbprogparse.c. 2010-01-16 23:41:05 -08:00
Vinson Lee
97fc7ae69f mesa: Remove unnecessary header from nvvertparse.c. 2010-01-16 16:15:37 -08:00
Vinson Lee
5a4d5b694c glsl: Remove unnecessary header from prog_execute.c. 2010-01-16 16:06:58 -08:00
Vinson Lee
148498d8cc glsl: Remove unnecessary header from prog_statevars.c. 2010-01-16 15:51:52 -08:00
Vinson Lee
0d62242082 glsl: Remove unnecessary headers from shader_api.c. 2010-01-16 15:35:56 -08:00
Vinson Lee
1f7762f62b glsl: Remove unnecessary header from slang_emit.c. 2010-01-16 15:00:29 -08:00
Vinson Lee
89950fbe24 st/mesa: Remove unnecessary header from st_cb_drawpixels.c. 2010-01-16 13:29:15 -08:00
Vinson Lee
59db91e2ee glsl: Remove unnecessary header from slang_builtin.c. 2010-01-16 02:20:51 -08:00
Vinson Lee
535084996b glsl: Remove unnecessary headers from slang_compile.c. 2010-01-16 02:16:24 -08:00
Vinson Lee
1d3bdc2090 glsl: Remove unnecessary header from slang_link.c. 2010-01-16 02:02:49 -08:00
Vinson Lee
10bd931949 glsl: Remove unnecessary header from slang_log.c. 2010-01-16 01:50:08 -08:00
Vinson Lee
533b6e8deb st/mesa: Remove unnecessary header from st_atom_framebuffer.c. 2010-01-16 01:39:04 -08:00
Vinson Lee
3eb85bf7d9 st/mesa: Remove unnecessary header from st_atom_pixeltransfer.c. 2010-01-16 00:52:34 -08:00
Vinson Lee
bc639f291b st/mesa: Remove unnecessary header from st_atom_sampler.c. 2010-01-16 00:45:36 -08:00
Vinson Lee
227fc5a308 st/mesa: Remove unnecessary header from st_atom_shader.c. 2010-01-16 00:36:31 -08:00
Vinson Lee
cc2f2268f5 st/mesa: Remove unnecessary headers from st_cb_accum.c. 2010-01-16 00:30:25 -08:00
Vinson Lee
e1d4781cd4 st/mesa: Remove unnecessary headers from st_cb_bitmap.c. 2010-01-16 00:08:54 -08:00
Vinson Lee
cc770c8409 st/mesa: Remove unnecessary headers from st_cb_blit.c. 2010-01-15 23:17:00 -08:00
Vinson Lee
6906bf08cc st/mesa: Remove unnecessary headers from st_cb_clear.c. 2010-01-15 23:02:07 -08:00
Vinson Lee
668d871d95 st/mesa: Remove unnecessary headers from st_cb_drawpixels.c. 2010-01-15 22:55:47 -08:00
Alex Deucher
adcde22952 r600: fill in some missing XRGB tex formats 2010-01-15 23:04:19 -05:00
Alex Deucher
81eed59a2c r600: set tiling correctly for texturing from depth buffer 2010-01-15 23:04:09 -05:00
Alex Deucher
114ab07aee r600: fix typo in SQ setup 2010-01-15 23:04:00 -05:00
Vinson Lee
56cd5806e8 st/mesa: Remove unnecessary header from st_cb_fbo.c. 2010-01-15 18:24:12 -08:00
Vinson Lee
a9f6255431 st/mesa: Remove unnecessary headers from st_cb_feedback.c. 2010-01-15 18:20:56 -08:00
Vinson Lee
2d2d890048 st/mesa: Remove unnecessary header from st_cb_program.c. 2010-01-15 16:28:56 -08:00
Vinson Lee
fbda223893 st/mesa: Remove unnecessary header from st_cb_queryobj.c. 2010-01-15 16:27:28 -08:00
Brian Paul
f595e72337 tgsi: fix detection of front-facing attribute
This code was not updated when we added TGSI_SEMANTIC_FACE a while ago.
2010-01-15 14:57:58 -07:00
Brian Paul
2c5aa02e20 swrast: add missing call to _swrast_depth_bounds_test()
We were calling this from the CI span function, but not the RGBA
span function.

I don't know of a test program for the GL_EXT_depth_bounds_test
extension...
2010-01-15 14:25:33 -07:00
Brian Paul
7385681797 swrast: fix broken _swrast_depth_clamp_span()
The integer Z clamping range depends on the number of bits
in the Z buffer because that's the scale factor used when we
transform NDC coords by the viewport/depth range.

Fixes fd.o bug #25972 but only for Z buffers up to a depth
of 30 bits.  Beyond that we get into messy integer overflow
issues and things fall apart.
2010-01-15 14:19:25 -07:00
Vinson Lee
79a5a28390 st/mesa: Remove unnecessary header from st_cb_rasterpos.c. 2010-01-14 23:05:42 -08:00
Vinson Lee
9c2ef74a76 st/mesa: Remove unnecessary headers from st_cb_readpixels.c. 2010-01-14 23:03:37 -08:00
Vinson Lee
cde041cd13 st/mesa: Remove unnecessary header from st_cb_strings.c. 2010-01-14 22:30:00 -08:00
Vinson Lee
644572a372 st/mesa: Remove unnecessary headers from st_cb_texture.c. 2010-01-14 22:27:13 -08:00
Vinson Lee
4f8baf7dce st/mesa: Remove unnecessary headers from st_cb_viewport.c. 2010-01-14 19:00:27 -08:00
Vinson Lee
53c6c38412 st/mesa: Remove unnecessary headers from st_context.c. 2010-01-14 18:53:51 -08:00
Vinson Lee
604e9ec2c4 st/mesa: Remove unnecessary header from st_draw_feedback.c. 2010-01-14 18:46:51 -08:00
Vinson Lee
9e7778d7aa st/mesa: Remove unnecessary header from st_extensions.c. 2010-01-14 18:34:59 -08:00
Vinson Lee
8a8a27b01a st/mesa: Remove unnecessary header from st_format.c. 2010-01-14 18:19:39 -08:00
Vinson Lee
eaedc1bb3e st/mesa: Remove unnecessary headers from st_framebuffer.c. 2010-01-14 18:10:06 -08:00
Vinson Lee
6890b06982 st/mesa: Remove unnecessary headers from st_gen_mipmap.c. 2010-01-14 17:54:47 -08:00
Brian Paul
dfd6e762e7 llvmpipe: remove redundant code in llvmpipe_set_blend_color() 2010-01-14 16:21:49 -07:00
Jakob Bornecrantz
877cadb655 r300g: Build driver by default
Do the auto trick that is used for both i915, i965 and svga.
2010-01-14 22:51:25 +00:00
Jakob Bornecrantz
b01ffb12ed Merge branch 'mesa_7_7_branch'
Conflicts:
	src/gallium/auxiliary/pipebuffer/pb_buffer_fenced.c
	src/gallium/auxiliary/util/Makefile
	src/gallium/drivers/r300/r300_state_derived.c
2010-01-14 22:31:04 +00:00
Brian Paul
4414a1a73c llvmpipe: assorted clean-ups in texture code 2010-01-14 14:19:16 -07:00
Michal Krol
ffd2848056 gallium: Document drawing commands. 2010-01-14 18:55:52 +01:00
Michal Krol
5184b02b07 Merge branch 'instanced-arrays'
Conflicts:
	src/gallium/drivers/softpipe/sp_draw_arrays.c
2010-01-14 18:11:41 +01:00
Corbin Simpson
1bc77e9931 r300g: Cleanup from last few commits.
Strangely enough, the code solidified pretty quickly.
2010-01-14 09:01:37 -08:00
Łukasz Krotowski
60628c65c9 r300g: Really destroy translated buffer at the end.
Note that indexSize is changed by r300_translate_elts(). Also make sure
it's destroyed on errors.
2010-01-14 09:01:37 -08:00
Brian Paul
7fcfb71931 progs/trivial: test user clip plane in tri-point-line-clipped.c 2010-01-14 09:38:47 -07:00
Brian Paul
0a82692154 progs/trivial: test glPolygonMode(POINT/LINE) with frustum clipping
Note whether the new verts introduced by clipping show up as points
and lines along the edge of the window...
2010-01-14 09:22:30 -07:00
Brian Paul
d6b4655e13 gallium/util: silence warning about array initializers 2010-01-14 09:22:30 -07:00
Chia-I Wu
81430b95d0 egl_g3d: Check if the creation of pipe or st context fails.
It should not return an incomplete EGLContext to the users.
2010-01-14 17:29:48 +08:00
Chia-I Wu
6cb89b23ee st/egl_g3d: Use a sequence number to decide if validation is required.
It is not safe to assume that the native surface has not changed since
the last validation by checking the geometry alone.  Add a sequence
number to "validate" callback for that purpose.  This is inspired by
Luca Barbieri's work.
2010-01-14 17:25:19 +08:00
Vinson Lee
252812bf15 st/mesa: Remove unnecessary header from st_program.c. 2010-01-13 23:28:00 -08:00
Vinson Lee
c109ca9c49 st/mesa: Remove unnecessary header from st_texture.c. 2010-01-13 23:16:05 -08:00
Vinson Lee
6b39e8aeb0 swrast: Remove unnecessary header from s_accum.c. 2010-01-13 23:01:03 -08:00
Vinson Lee
78411881d3 swrast: Remove unnecessary header from s_atifragshader.c. 2010-01-13 22:58:07 -08:00
Vinson Lee
0a70868131 swrast: Remove unnecessary header from s_bitmap.c. 2010-01-13 22:45:54 -08:00
Vinson Lee
886cffb44e swrast: Remove unnecessary headers from s_copypix.c. 2010-01-13 22:43:16 -08:00
Vinson Lee
cf061c24e0 swrast: Remove unnecessary header from s_depth.c. 2010-01-13 22:36:01 -08:00
Vinson Lee
d1631f734a swrast: Remove unnecessary header from s_drawpix.c. 2010-01-13 22:30:04 -08:00
Vinson Lee
f649870c9b swrast: Remove unnecessary header from s_feedback.c. 2010-01-13 22:20:44 -08:00
Corbin Simpson
6a2936b876 gallium/docs: Random things sitting around in my stash. 2010-01-13 20:46:53 -08:00
Corbin Simpson
264e548d86 r300g: Use indices to translate index buffers of ubytes.
progs/redbook/aapoly, among others, works fine now.
2010-01-13 20:44:49 -08:00
Corbin Simpson
8feb27b8ff radeong: Change DRI driver name to radeong. 2010-01-13 18:37:17 -08:00
Corbin Simpson
9bb2b90191 r300g: Disable immediate mode rendering for now.
Will re-enable when the bugs are ironed out.
2010-01-13 18:36:54 -08:00
Brian Paul
2ba1c8189a llvmpipe: use one loop in lp_rast_clear_zstencil()
This is just a tiny bit faster.
2010-01-13 18:58:42 -07:00
Brian Paul
f94a99170e llvmpipe: optimize lp_rast_clear_color() for non-gray colors
This makes a big difference in progs that clear to a non-gray color.
Some demos are 30-50% faster.
2010-01-13 18:54:50 -07:00
Brian Paul
f19f218e7a llvmpipe: minor assorted clean-ups 2010-01-13 18:01:45 -07:00
Brian Paul
bc1b38af71 gallium/draw: s/clipper/clip_stage/ to be consistant with other stages 2010-01-13 17:39:45 -07:00
Brian Paul
c873613403 gallium/draw: whitespace and comments 2010-01-13 17:39:45 -07:00
Brian Paul
ee343feba1 gallium/draw: remove always-true conditional 2010-01-13 17:39:45 -07:00
Brian Paul
8519b244f7 gallium: remove forward struct decl
Other struct types (like pipe_texture) are referenced before they're
defined so no reason to special-case this one.
2010-01-13 17:39:44 -07:00
Jesse Barnes
1cfd769c2e DRI2: don't send DRI2 requests the server doesn't know about
At init time, NULL out the hooks that send the server new requests.
DRI2 never supported these extensions, so this preserves old behavior on
old servers with new Mesa.
2010-01-13 19:01:51 -05:00
Jesse Barnes
62eb28c810 GLX/DRI2: pass X drawable ID instead
These happened to be the same in my testing since I was using apps that
depend on the GLX 1.2 behavior where X and GLX drawables are
interchangeable.
2010-01-13 18:42:55 -05:00
Brian Paul
018b78ad64 llvmpipe: check render targets before other textures 2010-01-13 15:32:55 -07:00
Brian Paul
1287277446 llvmpipe: also check render target textures in lp_setup_is_texture_referenced() 2010-01-13 15:30:42 -07:00
Brian Paul
0b279c5382 llvmpipe: indentation fixes 2010-01-13 15:10:57 -07:00
Brian Paul
db58192cfb llvmpipe: re-get scene pointer after flushing 2010-01-13 15:10:57 -07:00
Brian Paul
d59fe44896 llvmpipe: check for texture usage in all scenes 2010-01-13 15:10:57 -07:00
Brian Paul
a27b12171d llvmpipe: add scene texture referencing code 2010-01-13 15:10:57 -07:00
Brian Paul
592e40aa7b llvmpipe: added scene functions for texture reference counting
When a texture is used in the scene we add it to a list of texture
references.  The lp_scene_is_textured_referenced() function tells
us if a texture is referenced by the scene.
2010-01-13 15:10:57 -07:00
Brian Paul
4769328fe1 llvmpipe: comments 2010-01-13 15:10:57 -07:00
Brian Paul
a36395d487 llvmpipe: comments 2010-01-13 15:10:57 -07:00
Brian Paul
9be1feacf2 llvmpipe: added llvmpipe_texture_const() 2010-01-13 15:10:56 -07:00
Brian Paul
ddb94661a4 llvmpipe: minor comment upgrades 2010-01-13 15:10:56 -07:00
José Fonseca
7df4c88088 llvmpipe: Opaque shader implies complete colormask too. 2010-01-13 22:07:24 +00:00
José Fonseca
a1acbff299 llvmpipe: Reset the bin when shading a whole tile with an opaque shader. 2010-01-13 21:51:47 +00:00
Jesse Barnes
ed59b13da8 GLX: use glproto CFLAGS etc. when building
Roll the glproto check into the dri2proto and libdrm check so we get the
proper CFLAGS and LDFLAGS for the package.
2010-01-13 15:48:14 -05:00
Keith Whitwell
4231006e29 llvmpipe: add bin debugger
Adjust definition of empty_bin according to what's actually in empty
bins.  We often have a state packet before/after load commands.

Still need to do something about the fence packets.
2010-01-13 20:14:04 +00:00
Keith Whitwell
95ee14f147 llvmpipe: implement lp_rast_load_zstencil
Load zbuffer contents for binned scenes that don't start with a clear
and which have a bound zbuffer.
2010-01-13 16:52:44 +00:00
Thomas Hellstrom
a9086f2d17 st/dri: Make sure we always request a fake front.
This should be the correct, but sub-optimal way to handle things on
pre-1.7 servers. For servers that automatically adds a fake front
we should never request the fake front and handle the reply differently.

Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
2010-01-13 17:45:21 +01:00
Brian Paul
0bb5c3060f llvmpipe: added debug warning 2010-01-13 09:32:21 -07:00
Brian Paul
4439aab7b7 llvmpipe: comments and LLVMValueRef naming 2010-01-13 09:32:21 -07:00
Brian Paul
212f3a6cb3 llvmpipe: tweak subpixel_snap() arithmetic
This adjustment fixes some rasterization differences between llvmpipe
and softpipe (and other renderers).
2010-01-13 09:32:21 -07:00
Keith Whitwell
db83ad4b43 llvmpipe: improve empty-bin test further
Remove unused param, add comments.  Thanks to Brian for review.
2010-01-13 16:29:39 +00:00
Keith Whitwell
f4b29e6ad3 llvmpipe: improve empty-bin test
We emit at most two clear packets (color and z respectively).
2010-01-13 15:49:24 +00:00
Keith Whitwell
da45f49cc6 llvmpipe: quick hack to short-circuit empty bins 2010-01-13 15:18:32 +00:00
José Fonseca
1b333453e4 svga: Fix compile_vs error code.
It could erroneously return PIPE_OK in some circumstances.

Make compile_fs code identical.
2010-01-13 13:40:09 +00:00
Michal Krol
ea0cc47a4f svga: Fix call to translate::run(). 2010-01-13 11:13:00 +01:00
Corbin Simpson
aeb34b2489 r300g: Account for CS space used per atom.
Oh yeah, those atoms are startin' to pay off. The main obstacle now
for OA playability is the absurdly low default mouse sensitivity, IMO.
Not totally smooth yet, but getting there.
2010-01-13 01:44:58 -08:00
Corbin Simpson
a930dc7ee9 r300g: Two dirty state optimizations. 2010-01-13 01:07:49 -08:00
Corbin Simpson
ae4eb25132 r300g: DCE in emit. 2010-01-13 00:57:03 -08:00
Vinson Lee
831764fa75 swrast: Remove unnecessary header from s_fragprog.c. 2010-01-12 23:54:15 -08:00
Corbin Simpson
e4e5acc833 r300g: Lower the immd mode threshold. 2010-01-12 22:22:22 -08:00
Vinson Lee
d6588a9372 swrast: Remove unnecessary header in s_lines.c. 2010-01-12 21:59:58 -08:00
Corbin Simpson
c1db20280c r300g: Fix is_r400 status for rs4xx and rc4xx.
As suggested by agd5f.
2010-01-12 21:52:00 -08:00
Vinson Lee
7debc532d5 swrast: Remove unnecessary header from s_points.c. 2010-01-12 21:51:19 -08:00
Corbin Simpson
948b7e97a6 r300g: Switch to immediate mode for tiny renders.
Useful for e.g. blitter.
2010-01-12 21:50:14 -08:00
Vinson Lee
11034bfa97 swrast: Remove unnecessary header from s_readpix.c. 2010-01-12 21:41:09 -08:00
Vinson Lee
a01b9eac04 swrast: Remove unnecessary header from s_texcombine.c. 2010-01-12 20:36:33 -08:00
Vinson Lee
c239f38709 tnl: Remove unnecessary header from t_context.c. 2010-01-12 20:14:36 -08:00
Vinson Lee
2c7cf3f9c9 tnl: Remove unnecessary headers from t_draw.c. 2010-01-12 20:02:44 -08:00
Vinson Lee
dffcbee8e7 tnl: Remove unnecessary header from t_pipeline.c. 2010-01-12 19:55:24 -08:00
Vinson Lee
a24d852630 tnl: Remove unnecessary header from t_rasterpos.c. 2010-01-12 19:49:19 -08:00
Vinson Lee
264f4101cd tnl: Remove unnecessary header from t_vb_program.c. 2010-01-12 19:45:25 -08:00
Marek Olšák
50ae9c6073 r300g: emit blend LTE/GTE thresholds on >=RV350
As per classic r300.
2010-01-12 18:08:58 -08:00
Marek Olšák
46992664d1 r300g: update the texture initialization so that it respects tiling
This is still work-in-progress and tiling is not enabled by default.
2010-01-12 18:08:58 -08:00
Marek Olšák
99ea4c0c7e r300g: add emission of texture tiling bits 2010-01-12 18:08:58 -08:00
Marek Olšák
e279d18232 r300g: add is_r400 flag
r4xx has some additional fragment shader registers compared to r3xx.
2010-01-12 18:08:58 -08:00
Marek Olšák
4c9a8a14e5 r300g: silence a warning 2010-01-12 18:08:58 -08:00
Marek Olšák
f3c4f2ef62 r300g: only emit scissor when needed
Reverting some bits from ce1c493ff8.

Given the latest fixes, it's not needed to always emit scissor, really.
2010-01-12 18:08:57 -08:00
Marek Olšák
a2926a2a8b Revert "r300g: Placate kernel checker by explicitly disabling depth test."
This reverts commit e920ee23b3.

Assuming the FB state is not dirty and the DSA state is, then the depth test
will be re-enabled, making the kernel checker angry. Reverting the commit
fixes piglit/glsl-bug-22603.
2010-01-12 18:08:57 -08:00
Marek Olšák
6633484774 r300g: mark all states as dirty after flush
It fixes almost all regressions introduced lately.
2010-01-12 18:08:57 -08:00
Vinson Lee
c631501003 vbo: Remove unnecessary headers from vbo_exec.c. 2010-01-12 17:07:24 -08:00
Vinson Lee
94d238e757 vbo: Remove unnecessary header from vbo_exec_array.c. 2010-01-12 16:55:36 -08:00
Vinson Lee
37d326503d vbo: Remove unnecessary header from vbo_exec_draw.c. 2010-01-12 16:37:30 -08:00
Brian Paul
7e4c75c040 llvmpipe: fix indentation, comment typo 2010-01-12 17:12:49 -07:00
Brian Paul
ec9cfac768 llvmpipe: debug checks: make sure scene is empty at key points 2010-01-12 17:12:07 -07:00
Brian Paul
c560b97b17 llvmpipe: assert that we're putting data into a valid bin 2010-01-12 17:11:40 -07:00
Brian Paul
214ffad015 llvmpipe: clamp maxx,maxy to framebuffer size (in terms of tiles)
In some corner cases the right-most / bottom-most vertex can be
right on the edge of the framebuffer.  Because the maxx, maxy vals
are computed with a series of float/int, pixel/tile transformations
we can end up with maxx >= scene->x_tiles or maxy >= scene->y_tiles.
This leads to putting data into bins that never get processed, or
reset.  This becomes stale data that can lead to segfaults.

Clamping fixes this.
2010-01-12 17:08:07 -07:00
Brian Paul
de10168a46 llvmpipe: added lp_scene_is_empty() 2010-01-12 17:06:19 -07:00
Brian Paul
4061ca02dd llvmpipe: silence unused var warnings 2010-01-12 13:01:32 -07:00
Michal Krol
8c53a2576e gallium: draw_arrays/elements_instanced() are of type void. 2010-01-12 18:51:27 +01:00
Brian Paul
a32e9b2a2d llvmpipe: remove unused #define 2010-01-12 10:11:36 -07:00
Marcin Slusarz
90762bd355 nv50: fix 2 off by one memory leaks (nv50_miptree_level->image_offset) 2010-01-12 17:39:23 +01:00
Marcin Slusarz
c83093973e nv50: fix memory leak on nv50_pc free 2010-01-12 17:38:52 +01:00
Roland Scheidegger
a407636efb gallium: remove point_size_min and point_size_max from rasterizer state
The state tracker is responsible for clamping to any graphics API enforced
size min/max limits for both the static point_size setting as well as per
vertex point size (in the vertex shader).
Note that mesa state tracker didn't actually use these values.
2010-01-12 15:54:13 +01:00
José Fonseca
26c78a4968 gallium: Rename ALIGN_STACK -> PIPE_ALIGN_STACK for consistency. 2010-01-12 12:15:24 +00:00
José Fonseca
5dfd5ed5e7 gallium: Simplify PIPE_ALIGN_VAR.
gcc allows pre-fix variable attributes.

Suggested by Ian Romanick.
2010-01-12 12:11:04 +00:00
José Fonseca
86bfe974b8 gallium: Generalize the alignment macros to other compilers and any alignment. 2010-01-12 12:11:04 +00:00
Corbin Simpson
ce1c493ff8 r300g: Always emit scissors.
Save some code, improve FPS, and fix piglit tests. Everybody wins.
2010-01-12 02:33:55 -08:00
Chia-I Wu
28272bc472 st/egl_g3d: Get the stapi from the driver.
egl_g3d_get_st was called because the driver argument was not given
before.  It can be fixed now.
2010-01-12 17:56:48 +08:00
Chia-I Wu
3e6139d158 egl: Add _EGLDriver as the first argument to GetProcAddress.
The rest of the driver API has it as the first argument.  It should be
there so that a driver has access to itself.
2010-01-12 17:53:57 +08:00
Chia-I Wu
31d2786239 egl_xdri: Fix build breakage.
driScreen->swapBuffers takes 3 more arguments since
daf7fe69f7.
2010-01-12 17:51:08 +08:00
Vinson Lee
aee9a6f4e1 vbo: Remove unnecessary headers from vbo_save.c. 2010-01-12 00:50:05 -08:00
Vinson Lee
d2271d8a39 vbo: Remove unnecessary header from vbo_save_loopback.c. 2010-01-11 23:53:13 -08:00
Vinson Lee
083dae14bd vbo: Remove unnecessary header from vbo_split_copy.c. 2010-01-11 22:46:30 -08:00
Chia-I Wu
1c1015bd53 st/egl_g3d: Improve comments to the native display interface.
Document the future of __GLcontextModes.  Improve the description of
surface validation and native_flush_frontbuffer.
2010-01-12 14:06:11 +08:00
Vinson Lee
0d65a68f51 x86: Remove unnecessary header from x86_xform.c. 2010-01-11 21:04:16 -08:00
Corbin Simpson
daa446fa83 r300g: Add back dirty state check.
From 07ea7e6c80. This is the only questionable part of that commit,
AFAICT...
2010-01-11 20:54:12 -08:00
Corbin Simpson
e920ee23b3 r300g: Placate kernel checker by explicitly disabling depth test.
This probably should disable stencil, too, if the kernel cares enough.

Note: When atomized, framebuffer setup should go towards the end anyway,
but it *must* follow these test setups anyway.
2010-01-11 20:54:12 -08:00
Corbin Simpson
22d615a9c4 r300g: Avoid segfault on binding null RS state. 2010-01-11 20:54:11 -08:00
Brian Paul
fe0e627685 st/mesa: removed unused var 2010-01-11 21:25:58 -07:00
Brian Paul
935fdbe142 st/mesa: comments, whitespace 2010-01-11 21:25:58 -07:00
Vinson Lee
8e9ceb8309 progs/xdemos: Remove unnecessary header from corender.c. 2010-01-11 20:24:57 -08:00
Vinson Lee
477d51537f progs/trivial: Remove unnecessary headers from tri-fbo-tex.c. 2010-01-11 20:21:50 -08:00
Vinson Lee
7241f5140f progs/trivial: Remove unnecessary header from tri-fbo-tex-mip.c. 2010-01-11 20:15:59 -08:00
Vinson Lee
ae8ed89f24 progs/tests: Remove duplicate included header in vparray.c. 2010-01-11 19:58:08 -08:00
Vinson Lee
6ed607cce6 progs/tests: Add newline to end of printf in vparray.c. 2010-01-11 19:56:04 -08:00
Vinson Lee
7bfa54c6a4 progs/redbook: Remove unnecessary header from aapoly.c. 2010-01-11 19:52:22 -08:00
Vinson Lee
2178abfba3 progs/glsl: Remove duplicate included header from shtest.c. 2010-01-11 19:42:55 -08:00
Vinson Lee
78ddce9fda progs/demos: Remove unnecessary header from morph3d.c. 2010-01-11 19:29:26 -08:00
Chia-I Wu
d8299af4ab docs: Add documentation for OpenGL ES.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 11:25:09 +08:00
Chia-I Wu
76e726515a progs/es2: Correctly set renderable type and client version.
Correctly set EGL_RENDERABLE_TYPE and EGL_CONTEXT_CLIENT_VERSION for
OpenGL ES 2.0.  Because es2_info is copied from es1_info, the fix for it
actually goes to es1_info.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 11:25:09 +08:00
Chia-I Wu
43f67b61fd progs/es1: Bind texture image after rendering.
Unlike FBO, eglBindTexImage is supposed to be called after rendering.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 11:25:09 +08:00
Chia-I Wu
99a37ed195 configure.ac: Fix es state tracker build.
mesa/es should be built before the es state trackers.  This is done by
separating those that need to be built early from SRC_DIRS to CORE_DIRS.
The new variable is not exported, and will be prepended to SRC_DIRS.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 11:25:09 +08:00
Chia-I Wu
3f3340ca16 st/es: Clean up install target.
Use DESTDIR and MINSTALL.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 11:25:09 +08:00
Chia-I Wu
182c382813 st/es: Fix build issue after merge.
In c847a13d38, auxiliaries becomes a
single library;  In e388d62b47, the
default build is changed to have -fvisibility=hidden.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 11:25:09 +08:00
Chia-I Wu
0ce5b128d7 mesa/es: Update sources.mk.
Add/remove files that are unused/used to the omit list.  Finally, they
should all be features that can be omitted.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 11:25:09 +08:00
Chia-I Wu
bffe94d48a mesa/es: Fix build issue after merge.
In cd6b8dd9e8, color read/type fields are
moved;  Based on 068596c9a7 and
cc020425e9, GLSL builtin library is
autogenerated and GLSL libraries are built and used.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 11:25:08 +08:00
Chia-I Wu
562c127693 Merge branch 'master' into opengl-es-v2
Conflicts:
	src/mesa/main/dd.h
2010-01-12 11:25:02 +08:00
Brian Paul
3fce8ad2de Revert "util: Build u_bitmask.o when using make."
This reverts commit 01eff0e6d2.

u_bitmask.c was already in the C_SOURCES list.
2010-01-11 20:19:30 -07:00
Vinson Lee
f07e87ffba progs/tests: Silence fprintf format warning. 2010-01-11 19:16:36 -08:00
Chia-I Wu
077d6dd750 winsys/drm: Use egl_g3d to build EGL drivers.
The new EGL drivers use egl_g3d and respect EGL_DISPLAYS.  They are
named after the display supported and the DRM name.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 11:09:00 +08:00
Chia-I Wu
a68b51deb2 st/egl_g3d: Add support for KMS native display.
The KMS native display implements the modeset interface using DRM
modesetting.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 11:09:00 +08:00
Chia-I Wu
2dcdf19ee3 st/egl_g3d: Add support for EGL_MESA_screen_surface.
This is implemented through the modeset interface.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 11:09:00 +08:00
Chia-I Wu
c67ad0eee8 st/egl_g3d: Update the native display interface for modesetting.
The new interface can be used to implement EGL_MESA_screen_surface.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 11:09:00 +08:00
Chia-I Wu
49381d63e6 st/egl_g3d: New EGL state tracker that uses Gallium.
This new (intermediate) EGL state tracker is the base work for EGL
drivers that uses Gallium.  It makes it easier to support new window
systems.

Currently, there is support only for X11.  This driver supports multiple
APIs (OpenVG, OpenGL, ...) and supports hardware acceleration through
winsys/drm.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 11:08:57 +08:00
Vinson Lee
b4bc208529 progs/demos: Remove unnecessary header from isosurf.c. 2010-01-11 19:03:18 -08:00
Chia-I Wu
6dafd61ab2 winsys/drm: Add name field to drm_api.
The name can be used for driver selection.  It has the same name as the
DRI driver does right now.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 10:55:36 +08:00
Chia-I Wu
39790cab13 egl: EGL_SCREEN_BIT_MESA is a valid bit.
Update _eglValidateConfig so that it passes the test.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 10:55:35 +08:00
Chia-I Wu
472a601966 progs/egl: Fix screen surface demos.
Set the screen surface size to the mode size, as the spec requires the
screen surface size to be larger than the mode size.  Besides, bind the
API to OpenGL as they are written in it.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 10:55:35 +08:00
Chia-I Wu
c657c80180 progs/egl: glGenTextures is called too early in xeglbindtex.
It should be called after eglMakeCurrent.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 10:55:35 +08:00
Chia-I Wu
3bcb08f6c4 progs: Check the number of configs returned by eglChooseConfig.
A successful eglChooseConfig call does not imply there are valid
configs.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 10:55:35 +08:00
Chia-I Wu
033bd95802 progs: Add missing EGL_RENDERABLE_TYPE for EGL demos.
The default value of EGL_RENDERABLE_TYPE is EGL_OPENGL_ES_BIT.  The
proper values should be specified if we are not using OpenGL ES.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 10:55:35 +08:00
Chia-I Wu
2d44b6f884 st/mesa: Remove st_api.c.
st_api.c is supposed to define st_api_OpenGL to advertise OpenGL
support.  However, the linker discards the symbol because it has no
user.  It is better to leave this to other state trackers that link to
libmesagallium.a.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 10:55:35 +08:00
Chia-I Wu
ea014ed461 st/vega: Make it compatible with st_public.h.
It missed a stub for st_get_proc_address, and st_make_current should
return a boolean.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 10:55:35 +08:00
Chia-I Wu
940360a2e5 st/vega: Advertise OpenVG support.
Define st_api_OpenVG to advertise OpenVG support.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-12 10:55:35 +08:00
Zack Rusin
d880b64423 st/xorg: move exaMoveInPixmap before trying to fetch it
as Michel suggested, this is a cleaner way of fixing crashes caused
by exaGetPixmapDriverPrivate returning null since the data hasn't
been moved yet.
2010-01-11 18:27:59 -05:00
Zack Rusin
3447d545d9 st/xorg: fix a rare video crash
sometimes dst isn't present if a window is in a middle of a resize, stop
crashing in those cases and just ignore a frame.
2010-01-11 18:03:49 -05:00
Brian Paul
5cf4630969 llvmpipe: disable the all in/out test code for now
It's still faster not to try to special case the "all pixels are
known to be inside the triangle" case.
2010-01-11 15:30:56 -07:00
Jesse Barnes
f2f83d9a78 GLX: check glproto version
This was a silent dependency before, but now we really need 1.4.11 for
INTEL_swap_event support, so check for it.

Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
2010-01-11 17:30:41 -05:00
Brian Paul
9a10d14a44 llvmpipe: move, update comments 2010-01-11 15:30:17 -07:00
Jesse Barnes
c6ef705e41 Merge branch 'master' of ssh://people.freedesktop.org/~jbarnes/mesa
Conflicts due to DRI1 removal:
	src/mesa/drivers/dri/intel/intel_context.c
	src/mesa/drivers/dri/intel/intel_screen.c
2010-01-11 15:23:29 -05:00
Brian Paul
3b5d849268 llvmpipe: refactor generate_fragment() code
This will make it easier to generate multiple versions of the fragment
code per variant.
2010-01-11 13:16:02 -07:00
Brian Paul
46b5bd6cad llvmpipe: do the all-in test on the scalar c0 instead of vector c0
This still isn't faster, but committing it for posterity.
2010-01-11 12:59:39 -07:00
Brice Goglin
2b5f0b8669 Prepare changelog for upload 2010-01-11 17:52:44 +01:00
Brice Goglin
5be25443dd Merge branch 'debian-unstable' of git+ssh://git.debian.org/git/pkg-xorg/lib/mesa into debian-experimental
Conflicts:
	ChangeLog
	debian/changelog
2010-01-11 17:52:13 +01:00
Brice Goglin
eb1cc8273b New upstream release 2010-01-11 17:49:26 +01:00
Brice Goglin
5144f580d0 Merge branch 'upstream-experimental' into debian-experimental
Conflicts:
	progs/egl/eglgears.c
	progs/egl/eglscreen.c
	progs/fp/Makefile
	progs/fp/SConscript
	progs/rbug/simple_server.c
	progs/tests/getprocaddress.c
	progs/tests/interleave.c
	progs/tests/texwrap.c
	progs/tests/vparray.c
	progs/vp/vp-tris.c
	src/glut/glx/win32_menu.c
2010-01-11 17:47:52 +01:00
Brice Goglin
4afc359cc3 Revert "Bump the libdrm build-dep to 2.4.17 because of the changed radeon API."
This reverts commit ed7cd35ba0.

Only libdrm 2.4.15 is uploaded in Debian for now.
2010-01-11 17:44:11 +01:00
Roland Scheidegger
70c8d2a297 gallium: remove const qualifier from pipe_buffer argument in set_constant_buffer 2010-01-11 16:30:48 +01:00
Chia-I Wu
cca66dbb59 st/xlib: Mark GLX functions as public.
Mark all functions start with glX as public.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-11 10:04:44 -05:00
Chia-I Wu
b1356df647 st: Mark functions in st_public.h and vg_tracker.h as public.
These functions are the API of Gallium state tracker, and are used by
EGL.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-11 10:04:41 -05:00
Chia-I Wu
108c2bf5ab gallium: Add PUBLIC macro for function visibility.
As the default build has -fvisibility=hidden, add a macro to control the
visibility.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-11 10:04:37 -05:00
Chia-I Wu
5ec99c04a9 st/vega: Fix breakage from -fvisibility=hidden.
Mark VG and VGU functions as public.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-11 10:04:28 -05:00
José Fonseca
015a5a126b python: Integrate with llvmpipe if possible.
Temporary. We should soon have the ability to integrate with any driver
via glx extensions.
2010-01-11 14:01:07 +00:00
José Fonseca
f2f1672027 python: Mask out PIPE_TEXTURE_USAGE_DISPLAY_TARGET usage.
As displaying surfaces directly isn't supported by the python state
tracker.
2010-01-11 14:01:07 +00:00
José Fonseca
3e8c82037f python: Prefer PIPE_FORMAT_Z32_UNORM. 2010-01-11 14:01:07 +00:00
José Fonseca
76185ecad6 python: Set PIPE_TEXTURE_USAGE_RENDER_TARGET instead of DISPLAY_TARGET.
As the python state tracker is not integrated with window system an
cannot present surfaces directly.
2010-01-11 14:01:06 +00:00
Corbin Simpson
1c75edf3e8 util: Set flatshade for blitter.
It was bugging me. +1 FPS on softpipe.
2010-01-11 05:43:29 -08:00
Corbin Simpson
2bfb21790c radeong: Check for DONTBLOCK before flushing, remove dead code. 2010-01-11 05:43:29 -08:00
Keith Whitwell
86f450060d llvmpipe: force constant interpolation of flatshade colors
Nice speedup for gears.
2010-01-11 12:12:59 +00:00
Keith Whitwell
ad74ea2869 st/mesa: early exit on error path
Can't rely on asserts having any effect on flowcontrol for release
builds.
2010-01-11 12:02:53 +00:00
Keith Whitwell
094525fb23 llvmpipe: remove opencoded constant 2010-01-11 11:06:15 +00:00
Keith Whitwell
16c1ad54bc llvmpipe: remove scissor cliprect derived state
Was previously calculating the intersection of the scissor rectangle
and the framebuffer dimensions.  Rendering is already restricted to
framebuffer dimensions by other means, so scissor testing (when
implemented) can just use the scissor state directly.
2010-01-11 11:06:15 +00:00
Keith Whitwell
f9626ce10e util/blitter: remove unused variable 2010-01-11 10:56:41 +00:00
Luca Barbieri
eea6a7639f Fix compressed texture loads for non-minimal pitches
The current glCompressedTexImage support in the state tracker assumes
that compressed textures have minimal pitch.

However, in some cases this is not true, such as for mipmaps of non-POT
compressed textures on nVidia hardware.

This patch adds a check and does a memcpy for each line instead of the
whole image in that case.

Signed-off-by: Keith Whitwell <keithw@vmware.com>

Tweaks for C90 compilation.
2010-01-11 10:53:02 +00:00
Vinson Lee
6d6c9c6688 progs/demos: Remove unnecessary header from fbotexture.c. 2010-01-11 00:24:39 -08:00
Corbin Simpson
bfcafbe15d r300g: Don't bother testing for empty scissors.
If somebody goes through that much effort, they probably intended it.
So humor them. :3
2010-01-10 23:38:05 -08:00
Corbin Simpson
973326027f util: Apply Brian's suggested blit improvements.
copypix works just fine.
2010-01-10 23:30:01 -08:00
Dave Airlie
deaa634e02 gallium: u_blitter add overlapping blit support.
the xorg state tracker really wants the driver to handle overlapping
blits, and r300 uses u_blitter for blits. This patch adds overlapping
blit support via a temporary surface when its required.
2010-01-10 23:18:31 -08:00
Corbin Simpson
1e9ffb6340 r300g: Atomize scissors.
Argfl. Some of this code is so questionable.
2010-01-10 23:15:05 -08:00
Corbin Simpson
8ca491386d r300g: Move TCL bypass switch to main context. 2010-01-10 23:15:05 -08:00
Corbin Simpson
47f59cfc8e r300g: Atomize viewport.
Goddammit, some of these hax are really annoying.
2010-01-10 23:15:05 -08:00
Corbin Simpson
e7d760ff09 r300g: Move ROPCNTL to the top of the emit order.
According to the docs, this decreases stalls, and indeed we get a tiny
bit more glxgears from it.
2010-01-10 23:15:05 -08:00
Corbin Simpson
7b569bef15 r300g: Don't avoid rewriting ZTOP.
Simplify the code. Added a comment to keep me from doing it again.
2010-01-10 23:15:05 -08:00
Corbin Simpson
46fafdd455 r300g: Atomize rasterizer.
I want to stab things now.
2010-01-10 23:15:04 -08:00
Marcin Kościelnicki
d9de848de1 nouveau: Make winsys recognise the original NV50. 2010-01-11 15:16:12 +10:00
Dave Airlie
efaba97eaa radeon: fix prediction for r100 inline vert/elt emits.
On r100 we emit the indices inline so we need to account
for that in the emission size.
2010-01-11 13:27:20 +10:00
Dave Airlie
1294df9ca4 radeon: fix bug in realloc code.
This bug was fixed in libdrm ages ago, port to non-kms
2010-01-11 13:27:14 +10:00
Dave Airlie
42f2880ffd radeon: fix prediction for r100 inline vert/elt emits.
On r100 we emit the indices inline so we need to account
for that in the emission size.
2010-01-11 13:24:59 +10:00
Dave Airlie
554043bff7 radeon: fix bug in realloc code.
This bug was fixed in libdrm ages ago, port to non-kms
2010-01-11 13:24:58 +10:00
Ben Skeggs
32da02f7c1 st/dri: update dri2 drawables when viewport is changed
Fixes gnome-shell on nouveau, as well as window resize with various
other applications.

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2010-01-11 11:44:38 +10:00
Vinson Lee
4fe51c7447 glu/sgi: Initialize members of class Mesher. 2010-01-10 16:09:41 -08:00
Vinson Lee
1111b38a1b glu/sgi: Initialize members of class Slicer. 2010-01-10 15:55:52 -08:00
Corbin Simpson
8a2c961798 r300g: Atomize ZTOP.
Also do state-change checks. ZTOP's too important to not check.
2010-01-10 11:49:25 -08:00
Corbin Simpson
07ea7e6c80 r300g: Atomize DSA.
Also a bit of ztop.
2010-01-10 11:17:34 -08:00
Corbin Simpson
249374b853 r300g: Atomize UCP.
Meh.
2010-01-10 11:17:34 -08:00
Corbin Simpson
9d3db601c7 r300g: Atomize blend color. 2010-01-10 11:17:34 -08:00
Corbin Simpson
d496399156 r300g: Start using atoms.
No benefits yet.
2010-01-10 11:17:34 -08:00
José Fonseca
12576556e4 llvmpipe: Update instructions.
Explain how to build for windows. Both MSVC 9 and cross MinGW supported.

Stop documenting LLVM 2.5 as supported. It still supported at the moment
but it will soon stop being.
2010-01-10 18:37:42 +00:00
Keith Whitwell
c1a0441602 llvmpipe: initial mrt support
Non-mrt apps work, and the code looks correct, but not many mrt test apps
handy atm...
2010-01-10 17:22:09 +00:00
Chia-I Wu
d4c1ee0534 egl: Clean up the Makefile rules.
This allows libEGL to be built as a static library and removes libX11
from the dependencies.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-11 01:11:05 +08:00
Chia-I Wu
064242ae9f egl_softpipe: Remove the unnecessary call to _eglSwapBuffers.
The call to _eglSwapBuffers is unnecessary, and the function is missing
when -fvisibility=hidden.  Also remove the extraneous braces and indent
the block.
2010-01-11 01:06:47 +08:00
José Fonseca
cdc11056de llvmpipe: Yet another hack to get release LLVM static libraries to link in debug builds. 2010-01-10 11:20:11 +00:00
Vinson Lee
b9bd96608c glu/sgi: Include missing header file. 2010-01-10 03:03:14 -08:00
José Fonseca
a921458c16 scons: LLVM <-> MSVC integration tweaks. 2010-01-10 10:51:42 +00:00
José Fonseca
74f520861f gallium: Remove dead code. 2010-01-10 10:44:25 +00:00
José Fonseca
dc6bcc92ee gallium: Provide alternative stdint.h and stdbool.h C99 headers, instead of ad-hoc definitions.
Everybody is using the C99's integer types. Everybody except Microsoft,
which in turns means everybody is including their own definitions of C99
integer types for MSVC, causing duplicate definitions when linking two
projects. This is the case of building Gallium and LLVM with MSVC.

Shipping alternative stdint.h and stdbool.h headers for MSVC allows us
to share a single definition. It also removes clutter from the Gallium
headers.
2010-01-10 10:39:29 +00:00
Vinson Lee
199dedd6dd progs/demos: Check upper bounds of input in manywin.c. 2010-01-10 01:57:13 -08:00
Vinson Lee
0c7814fe23 progs/demos: Bounds check input to fire.c. 2010-01-10 00:40:46 -08:00
Vinson Lee
9e98c1fbf6 glu/sgi: Initialize members of class Renderhints. 2010-01-10 00:14:33 -08:00
Vinson Lee
a5815c36f7 glu/sgi: Initialize members of class StoredVertex. 2010-01-09 23:55:05 -08:00
Vinson Lee
61afd1158f glu/sgi: Include missing header file. 2010-01-09 23:53:54 -08:00
Vinson Lee
f8737bda37 glu/sgi: Initialize member of class O_pwlcurve. 2010-01-09 23:25:49 -08:00
Maciej Cencora
0b7b76fb16 r300: minor accelerated blit fixes 2010-01-09 19:53:17 +01:00
Maciej Cencora
cf1748053a r300: fallback on depth buffer blits
Depth buffer accelerated blits aren't implemented yet.
2010-01-09 19:52:42 +01:00
Vinson Lee
683e3cb8db progs/tests: Silence 'missing initializer' warnings. 2010-01-08 23:08:57 -08:00
Vinson Lee
223c8482ca progs/glsl: Silence uninitialized variable warning. 2010-01-08 22:10:52 -08:00
Vinson Lee
3b82de92a0 progs/demos: Add missing initializers in engine.c. 2010-01-08 22:02:49 -08:00
Vinson Lee
4775723d2f r300g: Silence unused variable warnings. 2010-01-08 21:43:54 -08:00
Vinson Lee
20d6360db7 tgsi: Silence uninitialized variable warnings. 2010-01-08 20:24:05 -08:00
Timo Aaltonen
ed7cd35ba0 Bump the libdrm build-dep to 2.4.17 because of the changed radeon API. 2010-01-09 02:24:49 +02:00
Brian Paul
f4321fbd96 llvmpipe: optimize case when all four pixels are inside the triangle
When the incoming c0,c1,c2 values are equal to INT_MIN it means that
all pixels are inside the triangle.  Thus we can skip the detailed
pixel inside/outside triangle tests.  Use the new lp_build_if()/endif()
functions to generate the branching code.

The code is disabled ATM however because it's actually a little slower
than the original code.  A little more tuning may fix that though...
2010-01-08 14:49:34 -07:00
Brian Paul
5208af7853 llvmpipe: fix more if/else/endif design bugs 2010-01-08 12:47:30 -07:00
Brian Paul
855d7f51e4 llvmpipe: move some fields to the private lp_build_flow_if struct 2010-01-08 11:32:36 -07:00
Brian Paul
af31e65b55 llvmpipe: free the phi array 2010-01-08 11:20:38 -07:00
Brian Paul
70b8d59792 llvmpipe: checkpoint if/else/endif contructs work
The LLVM IR looks correct now.  Basic blocks are where they're supposed
to be and the Phi functions have the right (var,block) information.
2010-01-08 11:06:16 -07:00
Kristian Høgsberg
7c50d29f7c intel/DRI2: add DRI2flushExtension support with invalidate hook
Needed to support the SwapBuffers code properly.

Signed-off-by: Kristian Høgsberg <krh@bitplanet.net>
2010-01-08 12:40:58 -05:00
Jesse Barnes
c642f3941b xdemos/glsync: handle no sync method better
Print out count, finish rendering, etc.  Makes the -sn option more useful.
2010-01-08 12:37:44 -05:00
Jesse Barnes
0269dc19b5 xdemos/glsync: check glXMakeCurrent return value
Since this program is used for testing, catching this case can be helpful.
2010-01-08 12:37:43 -05:00
Jesse Barnes
f860aac0d8 xdemos/glsync: Make glsync test draw a rectangle
Doing simple buffer clears isn't enough to actually allocate render buffers, we
need to do real drawing.
2010-01-08 12:37:43 -05:00
Jesse Barnes
f35f666f81 xdemos/glsync: Add swap interval support to glsync test 2010-01-08 12:37:43 -05:00
Jesse Barnes
7f170573ea DRI2/GLX: add INTEL_swap_event support
Add event support for the GLX swap buffers event, along with DRI2 protocol
support for generating GLX swap buffers events in the direct rendered case.

Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
2010-01-08 12:37:43 -05:00
Jesse Barnes
efc82e7c70 DRI2: add SwapInterval support
Add support for the DRI2SwapInterval protocol request.  This allows
direct rendered clients to control their swap interval per the
SGI_swap_control extension.

Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
2010-01-08 12:33:32 -05:00
Jesse Barnes
daf7fe69f7 DRI2: add OML_sync_control support
Add OML_sync_control support, along with a simple program for testing
it.  This means adding support for the DRI2GetMSC, DRI2WaitMSC and
DRI2WaitSBC requests.

Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
2010-01-08 12:31:10 -05:00
Jesse Barnes
a35f6bb207 DRI2: add SwapBuffers support
Support the new DRI2 protocol request, DRI2SwapBuffers, in both direct
and indirect rendering context.  This request allows the display server
to optimize back->front swaps (e.g. through page flipping) and allows us
to more easily support other GLX features like swap interval and the OML
sync extension in DRI2.

Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
2010-01-08 12:29:50 -05:00
Christoph Bumiller
99637ba80e nv50: handle TGSI_OPCODE_UMAD,UMUL,NOT and fix SAD 2010-01-08 18:23:12 +01:00
Christoph Bumiller
222738fcf5 nv50: free src temp_temps on emit 2010-01-08 18:23:08 +01:00
Christoph Bumiller
a5f771d758 nv50: try to honor sprite coord mode 2010-01-08 18:23:04 +01:00
José Fonseca
080c40ab32 Merge remote branch 'origin/master' into lp-binning
Conflicts:
	src/gallium/auxiliary/util/u_surface.c
	src/gallium/drivers/llvmpipe/Makefile
	src/gallium/drivers/llvmpipe/SConscript
	src/gallium/drivers/llvmpipe/lp_bld_arit.c
	src/gallium/drivers/llvmpipe/lp_bld_flow.c
	src/gallium/drivers/llvmpipe/lp_bld_interp.c
	src/gallium/drivers/llvmpipe/lp_clear.c
	src/gallium/drivers/llvmpipe/lp_context.c
	src/gallium/drivers/llvmpipe/lp_context.h
	src/gallium/drivers/llvmpipe/lp_draw_arrays.c
	src/gallium/drivers/llvmpipe/lp_jit.c
	src/gallium/drivers/llvmpipe/lp_jit.h
	src/gallium/drivers/llvmpipe/lp_prim_vbuf.c
	src/gallium/drivers/llvmpipe/lp_setup.c
	src/gallium/drivers/llvmpipe/lp_setup_point.c
	src/gallium/drivers/llvmpipe/lp_state.h
	src/gallium/drivers/llvmpipe/lp_state_blend.c
	src/gallium/drivers/llvmpipe/lp_state_derived.c
	src/gallium/drivers/llvmpipe/lp_state_fs.c
	src/gallium/drivers/llvmpipe/lp_state_sampler.c
	src/gallium/drivers/llvmpipe/lp_state_surface.c
	src/gallium/drivers/llvmpipe/lp_tex_cache.c
	src/gallium/drivers/llvmpipe/lp_tex_cache.h
	src/gallium/drivers/llvmpipe/lp_tex_sample.h
	src/gallium/drivers/llvmpipe/lp_tile_cache.c
2010-01-08 15:42:57 +00:00
Brian Paul
fd70841121 Merge branch 'mesa_7_7_branch'
Conflicts:

	src/mesa/drivers/dri/i965/brw_wm_emit.c
2010-01-08 08:21:12 -07:00
José Fonseca
9cdf6f025b scons: Set the default windows platform to be windows userspace.
I thought I had done this ages ago.
2010-01-08 14:31:25 +00:00
Dan Nicholson
674c76310f mesa: Ensure libmesagallium.a is finished building before descending
Signed-off-by: Dan Nicholson <dbn.lists@gmail.com>
2010-01-08 06:09:19 -08:00
Dan Nicholson
a1de400e8d mklib: Extract archives into temporary directories
When static libraries are created from other archives, objects are
extracted and then deleted when the static library is done. This can
race when there are multiple static libraries being created from the
same archives as with libmesa.a and libmesagallium.a.

Should fix this issue with parallel jobs:

make[5]: *** No rule to make target
> `../../../../../../src/mesa/libmesagallium.a', needed by
> `radeon_dri.so'. Stop

Signed-off-by: Dan Nicholson <dbn.lists@gmail.com>
Reported-and-Tested-by: Sedat Dilek <sedat.dilek@gmail.com>
2010-01-08 06:01:22 -08:00
Michal Krol
dddd5a36ac tgsi: Cleanup dot-product opcodes in interpreter. 2010-01-08 12:03:55 +01:00
Vinson Lee
3c42e403de r300: Move initial declaration outside for loop. 2010-01-08 01:13:46 -08:00
Francisco Jerez
95f603a5f3 nv20: Fix build for the latest nouveau_class.h changes. 2010-01-08 04:42:28 +01:00
José Fonseca
d699b6720c scons: Don't build xlib when dri is enabled.
Hopefully adddresses fdo 25828.
2010-01-08 01:25:27 +00:00
José Fonseca
ba33ef0011 lvmpipe: Initialize all coordinates.
Fixes assertion failure with fp-incomplete-tex (fdo 24298).
2010-01-08 01:15:17 +00:00
José Fonseca
c6509f89b4 scons: Output a meaningful message when xlib libGL.so can't be built. 2010-01-08 00:50:09 +00:00
José Fonseca
de22c940a1 scons: Use static glew library on Unices to avoid binary compatability issues
Fixes bug 25926.
2010-01-08 00:33:58 +00:00
Keith Whitwell
45fe1d7d00 st/xorg: remove unused xorg_exa_get_pixmap_handle function 2010-01-07 22:08:23 +00:00
Brian Paul
5dd9e23d62 docs: document Gallium SSE codegen for XPD bug fix 2010-01-07 14:55:27 -07:00
Brian Paul
8647aa1d8d tgsi: fix SSE code emit for XPD
Rearrange things so that the writes to the dest registers happen
after we've fetched/used all src registers.

The problematic instruction was:  XPD TEMP[2].xyz, TEMP[0], TEMP[2];
Note that the dst reg is also a src reg.

This fixes bad shading with progs/glsl/bump.c since Eric's changes to the
Mesa program optimizer in commit d6690ce15f.
The optimizer rearranges some registers so we occasionally wind up with
something like the above.
2010-01-07 14:49:14 -07:00
Christoph Bumiller
7fc5fcada5 nv50: preallocate TEMPs written first time in a subroutine
Otherwise we risk overwriting them with temporary GPRs if
they're not used immediately after the CALL.
2010-01-07 21:19:58 +01:00
Christoph Bumiller
a009fa4305 nv50: handle TGSI_OPCODE_SAD,UADD 2010-01-07 21:19:58 +01:00
Christoph Bumiller
d550de2342 nv50: handle TGSI_OPCODE_IMAX,IMIN,UMAX,UMIN 2010-01-07 21:19:58 +01:00
Christoph Bumiller
607b9c2e09 nv50: handle integer SET operations 2010-01-07 21:19:58 +01:00
Christoph Bumiller
ccc7d0cb7a nv50: handle TGSI_OPCODE_SHL,ISHR,USHR 2010-01-07 21:19:58 +01:00
Christoph Bumiller
152b3bd6ef nv50: handle TGSI_OPCODE_F2I,F2U,I2F,U2F plus src mods 2010-01-07 21:19:58 +01:00
Eric Anholt
46f5579826 intel: Remove leftover symlinks from DRI1 removal. 2010-01-07 11:21:29 -08:00
Brian Paul
7335d8006f tgsi: add assertion to verify legal register file
This assertion fails with piglit glsl-vs-mov-after-deref test
because we're double freeing the memory.  It seems there's some
confusion between what's placed in the hash table and what isn't.
2010-01-07 11:18:12 -07:00
Brian Paul
0c6794c46f tgsi: fix incorrectly placed braces, add more braces to be clear 2010-01-07 10:57:33 -07:00
Brian Paul
16b5d2eba3 tgsi: move register checking code before check_register_usage()
check_register_usage() frees the scan_register *reg data so we were
reading from freed memory.  This fixes a valgrind error found with
piglit's glsl-vs-mov-after-deref test.
2010-01-07 10:55:00 -07:00
Brian Paul
b841c2756e swrast: fix color masking for glAccum(GL_RETURN)
Should fix fdo bug 25837.
2010-01-07 09:43:11 -07:00
Brian Paul
fa47eff55b i810: use ColorMask[0] 2010-01-07 09:40:08 -07:00
Brian Paul
7c55fe9bfd progs/fp: increase buffer size to read larger shaders 2010-01-07 09:20:48 -07:00
Brian Paul
c642c246d7 gallium/util: remove useless assertions 2010-01-07 09:20:48 -07:00
Brian Paul
c3e846af30 gallium/util: update comment: s/src_pitch/src_stride 2010-01-07 09:20:48 -07:00
Brian Paul
f39bae8e68 gallium/util: make src_y unsigned like the other x/y params 2010-01-07 09:20:48 -07:00
José Fonseca
8081c1eaa5 llvmpipe: Remove TGSI sampler pointers from JIT context too. 2010-01-07 16:16:45 +00:00
José Fonseca
12c6b871a3 llvmpipe: Remove more loose ends of TGSI exec sampling. 2010-01-07 16:10:04 +00:00
Kristian Høgsberg
27fe7a7303 configure: Fix matching for dri driver to actually work
The shell case statement obviously only evaluates the first matching
block.  Thanks to Julien Cristau for spotting the bug.
2010-01-07 10:44:44 -05:00
Brian Paul
c9a210f158 makefile: added src/glsl/Makefile.template to tarball list 2010-01-07 08:43:24 -07:00
Keith Whitwell
150108024d i965g: updates for draw retval 2010-01-07 15:37:41 +00:00
José Fonseca
7bd7e2da75 llvmpipe: Axe texture sampling code inherited from softpipe.
Was used only as a reference, since texture sampling is now code generated.
Already axed in the lp-binning branch too.

This fixes the llvmpipe build after recent sampling changes.
2010-01-07 15:35:24 +00:00
Brian Paul
2b7a4b2c0e progs/fp: remove invalid tri-inv.c test
INV is not a valid instruction.
2010-01-07 08:22:39 -07:00
Michal Krol
4440428faa gallium: Fix texture sampling with explicit LOD in softpipe. 2010-01-07 13:48:41 +01:00
Michal Krol
4bfe1c955f gallium: Pass per-element (not per-quad) LOD bias values down to texture sampler. 2010-01-07 12:48:10 +01:00
Michal Krol
e313dabdc7 tgsi: Cleanup exec_tex(). 2010-01-07 11:10:24 +01:00
Michal Krol
8d38ef4551 svga: Fix fs key size computation and key comparison.
This also allows us to have texture_target
back as a bitfield and save us a few bytes.
2010-01-07 07:58:07 +01:00
Vinson Lee
d42467687e progs/demos: Assert that input to malloc is valid. 2010-01-06 21:39:44 -08:00
Jakob Bornecrantz
61f7252448 Revert "pipebuffer: Multi-threading fixes for fencing."
This reverts commit 5b64d94390.
2010-01-07 05:14:20 +01:00
Thomas Hellstrom
cb51f02678 Revert "st/dri: no need to request fake front buffer, only handle it being returned"
This reverts commit 1336989ec6.

The commit breaks frontbuffer rendering and the possibility to do
on-demand frontbuffer requests on all Xservers prior to 1.7.

The commit should be conditioned on a dri2 version check.
I've submitted a patch to Xserver to bump dri2 minor, and it's acked by Ian.

To be able to check the version from within the state tracker, we will
probably need another dri2 extension function that returns the server
version. The protocol has support for it.

Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
2010-01-11 21:36:51 +01:00
Thomas Hellstrom
01eff0e6d2 util: Build u_bitmask.o when using make.
Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
2010-01-11 21:36:51 +01:00
Vinson Lee
45ac10fe6a progs/xdemos: Check for string overflow. 2010-01-06 18:19:46 -08:00
Vinson Lee
25ffd76278 progs/xdemos: Check for string overflow. 2010-01-06 18:08:41 -08:00
Vinson Lee
468f270f3f svga: Silence uninitialized variable warning. 2010-01-06 17:51:08 -08:00
Brian Paul
ef7eb62423 meta: remove F suffix from _mesa_Ortho() params
_mesa_Ortho() takes GLdoubles.
2010-01-06 18:22:06 -07:00
Brian Paul
73bd400016 docs: document a mipmap generation bug fix 2010-01-06 18:20:17 -07:00
Brian Paul
cb3cb96fbd meta: move destination vertex/projection setup out of _mesa_meta_GenerateMipmap
Based on a patch submitted by Pierre Willenbrock <pierre@pirsoft.de>
2010-01-06 18:20:17 -07:00
Brian Paul
06970b2ccb meta: set viewport and projection matrix in _mesa_meta_GenerateMipmap
This fixes mipmap levels being clipped to the last viewport.

Based on a patch submitted by Pierre Willenbrock <pierre@pirsoft.de>
2010-01-06 18:20:17 -07:00
Brian Paul
baeb3a2351 llvmpipe: checkpoint commit of new if/else/endif flow control
Totally untested at this point.  More work to do.
2010-01-06 17:53:12 -07:00
Andre Maasikas
49653c01e8 r600: adjust after radeon mipmap changes in 7118db8700
R600_OUT_BATCH_RELOC doesn't really use offset so set it
in TEX_RESOURCE2
+ typo fix
2010-01-06 19:52:24 -05:00
Brian Paul
8485811f10 tnl: set FOGC result to (f,0,0,1)
Fixed FDO bug 23397.
2010-01-06 17:43:56 -07:00
Vinson Lee
4c45810d57 progs/xdemos: Remove comma at end of enumerator list. 2010-01-06 15:35:18 -08:00
Vinson Lee
96a4e4552d progs/xdemos: Use temporary variables.
This was missed from the previous commit to glxheads.c.
2010-01-06 15:33:13 -08:00
Vinson Lee
c1dad22d71 progs/glsl: Prevent possible string overflow. 2010-01-06 15:25:42 -08:00
Vinson Lee
f4952f040b progs/xdemos: Prevent possible string overflow. 2010-01-06 14:56:43 -08:00
Brian Paul
db7f9b053b llvmpipe: more comments in flow builder code 2010-01-06 14:11:54 -07:00
Marek Olšák
6f498a7eff r300g: add back-face color VS outputs
Required for two-sided lighting. BTW we are approaching softpipe-level
quality. ;)
2010-01-06 12:49:16 -08:00
Marek Olšák
7679ac2caa r300g: fix SWTCL stream locations of texture coordinates
It might have caused hardlocks when TCL was bypassed, not sure.
2010-01-06 12:49:15 -08:00
Marek Olšák
1a4f242be6 r300g: if no DS buffer is set, disable reading from and writing to it
It fixes another "Bad CS" issue.
2010-01-06 12:49:15 -08:00
Marek Olšák
26f67a272b r300g: disable the rasterization of WPOS if it's unused by the FS 2010-01-06 12:49:15 -08:00
Marek Olšák
bf60eb3fec r300g: add WPOS 2010-01-06 12:49:15 -08:00
Marek Olšák
dc7f309f9c r300/compiler: add full viewport transformation support in WPOS codegen 2010-01-06 12:49:15 -08:00
Marek Olšák
ddfc4e31ad r300g: consolidate params 2010-01-06 12:49:15 -08:00
Marek Olšák
e78648db0a r300g: fix outputting depth in the FS 2010-01-06 12:49:15 -08:00
Marek Olšák
7c902b43d8 r300g: optimize blending by conditionally disabling reads from the colorbuffer 2010-01-06 12:49:15 -08:00
Marek Olšák
6b9b3213c5 r300g: optimize blending by discarding pixels that don't change the colorbuffer
Let's get some performance out of the blender.
2010-01-06 12:49:14 -08:00
Marek Olšák
717c28055a r300g: fix blending when SRC_ALPHA_SATURATE is used 2010-01-06 12:49:14 -08:00
Marek Olšák
a6d91a141f util/blitter: allow NULL CSOs to be saved 2010-01-06 12:49:14 -08:00
Keith Whitwell
8e559e05a8 softpipe: fix draw return value 2010-01-06 18:05:08 +00:00
Pierre Ossman
c9befda13a r600: float texture component ordering
The ordering of texture components was
backwards for the floating point textures.

Signed-off-by: Pierre Ossman <pierre@ossman.eu>
2010-01-06 12:42:49 -05:00
Brian Paul
60f5608bd7 r300g: add missing is_anistropic param 2010-01-06 10:36:51 -07:00
Brian Paul
4e8d67af57 llvmpipe: flow-control comments 2010-01-06 10:16:34 -07:00
Keith Whitwell
b08583da46 llvmpipe: fix double free 2010-01-06 17:13:37 +00:00
Keith Whitwell
601969c587 llvmpipe: rename some functions 2010-01-06 17:13:28 +00:00
Keith Whitwell
c9240c4c8f llvmpipe: remove dead code 2010-01-06 17:00:26 +00:00
Keith Whitwell
72120292b9 llvmpipe: restrict header visibility 2010-01-06 16:56:28 +00:00
Brian Paul
d8331aaf5b svga: make texture_target a ubyte, not a bitfield
gcc won't let us take the address of a bitfield in the svga_fs_key_size()
function.
2010-01-06 09:54:36 -07:00
Roel Kluin
324568f79d mesa: test index bounds before array element
Check whether the index is within bounds before accessing the array.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-01-06 09:47:37 -07:00
Roel Kluin
5db710a823 win32_menu: add missing parentheses in mapMenu()
`|' has higher precedence than `?'.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-01-06 09:46:55 -07:00
Roel Kluin
2b4acd26b1 nv50: add missing parentheses in nv50_query_result()
NOUVEAU_BO_RD is defined (1 << 2), and `|' has higher precedence than `?'
so the second argument of nouveau_bo_map was always 0.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Signed-off-by: Brian Paul <brianp@vmware.com>
2010-01-06 09:46:53 -07:00
Keith Whitwell
5ce0380a0f llvmpipe: merge setup and draw vbuf submodules
The setup tiling engine is now plugged directly into the draw module
as a rendering backend.

Removed a couple of layering violations such that the setup code no
longer reaches out into the surrounding llvmpipe state or context.
2010-01-06 16:44:43 +00:00
Brian Paul
439b34c9dd gallium/docs: finish up description of pipe_rasterizer_state fields 2010-01-06 09:42:53 -07:00
Brian Paul
251363e8f1 configs: set INTEL_LIBS, INTEL_CFLAGS, etc 2010-01-06 08:22:11 -07:00
Michal Krol
ace932450c util: Fix format descriptor table entries. 2010-01-06 16:11:28 +01:00
Michal Krol
4e014c0a14 pipe_sampler_state::compare_mode is not a boolean enable flag.
It's a 1-bit enum.
2010-01-06 16:11:26 +01:00
Michal Krol
4fd566ea31 util: Handle the remaining format cases in pipe_tile_raw_to_rgba(). 2010-01-06 16:11:24 +01:00
Michal Krol
955f51270b Make sure we use only signed/unsigned ints with bitfields.
Seems to be the only way to stay fully portable.
2010-01-06 16:11:21 +01:00
Jakob Bornecrantz
de37a00d27 util: Add u_bitmask to make build 2010-01-06 15:32:42 +01:00
Brian Paul
e4b7d9ea35 i965: fix invalid assertion in emit_xpd(), again 2010-01-06 07:18:09 -07:00
Brian Paul
1b5476a353 i965g: fix invalid assertion in emit_xpd(), again 2010-01-06 07:18:04 -07:00
José Fonseca
e32487b8a1 Merge remote branch 'origin/mesa_7_7_branch'
Conflicts:
	configs/default
	src/gallium/auxiliary/pipebuffer/pb_buffer_fenced.c
	src/mesa/main/version.h
2010-01-06 13:52:22 +00:00
José Fonseca
aaf7ecfd81 glew: Update to version 1.5.2. 2010-01-06 12:23:37 +00:00
José Fonseca
5b64d94390 pipebuffer: Multi-threading fixes for fencing.
I had this patch on my hard drive for long time. It doesn't fully
address SVGA multi-threading issues, but causes no regressions, so decided
to commit while it still applies cleanly.

Attention: merging this into master will cause issues due to recent
changes in reference counting to fix strict aliasing rules violation.
2010-01-06 12:18:16 +00:00
Luca Barbieri
f023473748 gallium: remove PIPE_TEX_FILTER_ANISO
This patch removes PIPE_TEX_FILTER_ANISO.

Anisotropic filtering is enabled if and only if max_anisotropy > 1.0.
Values between 0.0 and 1.0, inclusive, of max_anisotropy are to be
considered equivalent, and meaning to turn off anisotropic filtering.

This approach has the small drawback of eliminating the possibility of
enabling anisotropic filter on either minification or magnification
separately, which Radeon hardware seems to support, is currently
support by Gallium but not exposed to OpenGL.  If this is actually
useful it could be handled by splitting max_anisotropy in two values
and adding an appropriate OpenGL extension.

NOTE: some fiddling & reformatting by keithw to get this patch to
apply.  Hopefully nothing broken in the process.
2010-01-06 10:35:47 +00:00
Brian Paul
a6975507ad docs: added more GL3 items 2010-01-05 21:25:56 -07:00
Brian Paul
d4f2d6556e mesa: added GL_MAJOR_VERSION and GL_MINOR_VERSION queries
New in GL 3.0.
2010-01-05 21:24:48 -07:00
Brian Paul
3510a1b0c5 mesa: call _mesa_compute_version() to set context's version info 2010-01-05 21:23:59 -07:00
Brian Paul
29f50f61ea mesa: added version.c to build 2010-01-05 21:23:16 -07:00
Brian Paul
e0b9e33afb mesa: added _mesa_compute_version() in new version.c file 2010-01-05 21:23:01 -07:00
Brian Paul
e16fd07225 mesa: added version fields to GLcontext 2010-01-05 21:17:55 -07:00
Brian Paul
88330c6438 gallium/util: replace 8 with PIPE_MAX_COLOR_BUFS 2010-01-05 17:07:44 -07:00
Brian Paul
2fbc3931fc gallium/util: comments and whitespace fixes 2010-01-05 16:55:35 -07:00
Brian Paul
9089436930 docs: added link to wiki page about missing Mesa features 2010-01-05 16:03:11 -07:00
Brian Paul
15b05c54b7 i965g: fix invalid assertion in emit_xpd()
Invalid assertion found by Roel Kluin <roel.kluin@gmail.com>
2010-01-05 15:54:50 -07:00
Brian Paul
e555146fa3 i965: fix invalid assertion in emit_xpd()
Invalid assertion found by Roel Kluin <roel.kluin@gmail.com>
2010-01-05 15:53:05 -07:00
Roel Kluin
766f3ccbda tdfx: condition always evaluates to false in SetupDoubleTexEnvVoodoo3()
This can never be true.

Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
2010-01-05 14:42:28 -07:00
Eric Anholt
5a7c2a99a6 i965: Fix build after blind merge of mesa 7.7 by Brian. 2010-01-05 11:09:21 -08:00
Brian Paul
9f544394c1 st/mesa: fix broken translation of negative register indexes
A src register's index can be negative if we're doing indirect
addressing into the constant buffer.  Ex: MOV OUT[1], CONST[ADDR[0].x-3]

This fixes the piglit vp-arl-neg-array.vpfp test.

Before this change we were going out of bounds of the t->constants[]
array and getting garbage that later triggered an assertion.
2010-01-05 11:44:19 -07:00
Brian Paul
487a14b476 ARB prog parser: regenerated parser file 2010-01-05 11:44:19 -07:00
Brian Paul
f0f68b1e4c ARB prog parser: fix parameter binding type
References to program local and enviroment parameters are put into the
unified program parameters list as PROGRAM_STATE_VAR entries which point
into the local or environment arrays.  So the param_binding_type field
should be PROGRAM_STATE_VAR.

This fixes the piglit vpfp-generic vp-arl-env-array.vpfp and
vp-arl-local-array.vpfp test failures.
2010-01-05 11:44:19 -07:00
Brian Paul
e3514b7338 ARB prog parser: regenerated parser files 2010-01-05 11:44:19 -07:00
Brian Paul
7c6ae4c6c8 ARB prog parser: add allowSwizzle param to initialize_symbol_from_const()
We need to disable constant consolidation when building an array of
constants which might be indexed indirectly.

Fixes regression in piglit vpfp-generic vp-arl-constant-array.vpfp
test caused by earlier constant consolidation patch.
2010-01-05 11:44:19 -07:00
Brian Paul
37f6929d29 mesa: whitespace changes and comments 2010-01-05 11:44:19 -07:00
Brian Paul
f27e39aa4e mesa: change constant search behaviour in _mesa_add_unnamed_constant()
Only search for an existing, matching constant if swizzleOut is non-null.
We need to be able to disable constant consolidation when building an
array of constants which will be indexed indirectly.
2010-01-05 11:44:19 -07:00
Maarten Maathuis
c77ade8fed nouveau: rewrite nouveau_stateobj to use BEGIN_RING properly
- The previous solution was hacky and didn't do subchannel autobinding.
- The beheaviour should match what libdrm_nouveau does closely.
- The solution remains statically sized, but when debugging is on it will check
for abuse.

Signed-off-by: Maarten Maathuis <madman2003@gmail.com>
2010-01-05 19:13:34 +01:00
Marcin Slusarz
29d2ab37e6 nouveau: kill nouveau_push.h and use libdrm versions of BEGIN_RINGs, etc 2010-01-05 19:13:34 +01:00
Maarten Maathuis
c306ef5e81 nv50: remove vtxbuf stateobject after a referenced vtxbuf is mapped
- This avoids problematic "reloc'ed while mapped" messages and
some associated corruption as well.

Signed-off-by: Maarten Maathuis <madman2003@gmail.com>
2010-01-05 19:13:34 +01:00
José Fonseca
38d8b18003 svga: Remove stale references to delete shader results.
To ensure that a new result that happens to have the same address
of the old one will be detected as a change.
2010-01-05 17:56:26 +00:00
José Fonseca
8ebef37c7b svga: Rebind shaders when tokens change.
Even shader ID doesn't change. Otherwise the token change is not
effective.

This reverts regression from commit
cdb445f3a9. Regression could be seen in
Quake3's loading screen -- the upper right corner of the screen would
be black.
2010-01-05 17:32:53 +00:00
Corbin Simpson
3e18bad36d Merge branch 'gallium-docs' 2010-01-05 08:37:49 -08:00
Chia-I Wu
897cb8950a egl: Fix breakage from -fvisibility=hidden.
Mark EGL API and driver functions as PUBLIC.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-05 11:23:52 -05:00
Corbin Simpson
467cccf0a7 docs: Don't check in generated docs.
Per ML discussion.
2010-01-05 08:22:52 -08:00
Corbin Simpson
acb8073d07 docs: Stub out list of modules in core distribution of G3D. 2010-01-05 08:22:18 -08:00
Brian Paul
ef1b942691 st/mesa: added PROGRAM_LOCAL_PARAM case in src_register()
Fixes piglit vpfp-generic arl.vpfp failure when using gallium.
2010-01-05 09:14:50 -07:00
Kristian Høgsberg
ae44b92f61 Merge branch 'remove-intel-dri1'
* remove-intel-dri1:
  intel: intelScreenContext() is no longer used
  intel: Remove remaining dri2.enabled tests
  intel: Drop more cliprect bookkeeping
  intel: Remove struct intel_framebuffer
  intel: Remove client-side vblank code
  intel: Drop intelWindowMoved()
  intel: Drop batchbuffer cliprect_mode tracking
  intel: Drop DRI1 static regions
  intel: Use depth buffer from ctx.DrawBuffer in copypix_src_region()
  intel: Drop LOCK/UNLOCK_HARDWARE()
  intel: Drop DRI1 SwapBuffer implementation
  intel: Drop DRI1 CopySubBuffer implementation
  intel: Drop DRI1 support
  Push __driDriverExtensions out of dri_util.c and into the drivers
  Remove leftover __DRI{screen,drawable,context}Private references
  Check for libdrm_$chipset.pc when needed
2010-01-05 10:31:11 -05:00
Chia-I Wu
e5d351dcfd Add es state tracker to autoconf.
mesa/es is needed in SRC_DIRS to build es state tracker.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-05 08:08:34 -07:00
Chia-I Wu
976c858acc Clean up ES_FILES.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-05 08:08:30 -07:00
Brian Paul
bd96b51303 mesa: bump version to 7.7.1-DEVEL 2010-01-05 07:59:29 -07:00
Keith Whitwell
c727fa6dbf Merge commit 'origin/gallium-draw-retval'
Conflicts:
	src/gallium/drivers/identity/id_context.c
2010-01-05 14:13:40 +00:00
Andre Maasikas
c91ceeec32 r600: adjust after radeon mipmap changes in 7118db8700
R600_OUT_BATCH_RELOC doesn't really use offset so set it
in TEX_RESOURCE2
+ typo fix
2010-01-05 15:36:32 +02:00
Andre Maasikas
750c1e7bb4 r600: support depth compare functions & shadow_ambient 2010-01-05 13:48:04 +02:00
Michal Krol
76ff89d2de gallium: Handle InstanceID as a true 32-bit uint. 2010-01-05 11:48:32 +01:00
Michal Krol
9b21b3c52a Merge branch 'master' into instanced-arrays
Conflicts:
	src/gallium/auxiliary/tgsi/tgsi_dump.c
	src/gallium/include/pipe/p_shader_tokens.h
2010-01-05 11:04:50 +01:00
Michal Krol
1f9aa38f4e tgsi: Simplify implementation of few interpreter's instructions. 2010-01-05 11:00:07 +01:00
Michal Krol
55b5c8816e tgsi: Use FREE() to release MALLOC-ed() memories in sanity. 2010-01-05 09:28:41 +01:00
Michal Krol
767d1472df tgsi: Fix bogus loop condition in sanity. 2010-01-05 09:28:39 +01:00
Michal Krol
c301fa6fc8 tgsi: Treat MOV source operand as FLOAT so modifiers works as expected. 2010-01-05 09:28:36 +01:00
Michal Krol
7218322703 tgsi: Store ADDR file in interpreter as an int. 2010-01-05 09:28:34 +01:00
Michal Krol
7c8e67e4aa tgsi: Remove dead micro_umod(). 2010-01-05 09:28:32 +01:00
Michal Krol
97f9a147db tgsi: Make interpreter aware of float and integer data types.
Debug check for inf and nan only on float channels.

Apply absolute and negate source operand modifiers based on
opcode type.
2010-01-05 09:28:29 +01:00
Michal Krol
c34f6faf35 gallium: Add UMOD TGSI opcode.
Either that or have UDIV have two destination operands.
2010-01-05 09:28:27 +01:00
Michal Krol
062aab96e0 gallium: Add SWITCH, CASE, DEFAULT and ENDSWITCH opcodes to TGSI.
Provide reference implementation of them in tgsi_exec.

Note that BREAK opcode is overloaded and can be used to break out
of either a loop or a switch-case statement.
2010-01-05 09:28:25 +01:00
Michal Krol
08a3efee10 tgsi/ureg: Improve immediate match & expand logic.
Do not pollute immediates with unsuccessfull attempts to expand them.
2010-01-05 09:27:13 +01:00
Michal Krol
ff56a12051 tgsi: Support signed/unsigned integer immediate types. 2010-01-05 09:27:10 +01:00
Michal Krol
b1c55e80aa gallium: Add signed/unsigned int immediate data types. 2010-01-05 09:27:08 +01:00
Michal Krol
bf4b4c1b6f tgsi: Cleanup interpreter code for other existing integer opcodes. 2010-01-05 09:27:06 +01:00
Michal Krol
2c046034dc Remove TGSI_OPCODE_SHR, map existing usage to TGSI_OPCODE_ISHR.
This is to differentiate it from its unsigned version, TGSI_OPCODE_USHR.
2010-01-05 09:26:48 +01:00
Michal Krol
df0826fba3 tgsi: Implement new integer opcodes.
Update interpreter and ureg.
Also, get rid of SHR -- it's actually an alias for ISHR.
2010-01-05 09:26:46 +01:00
Michal Krol
c59eda0993 gallium: Add more integer TGSI opcodes. 2010-01-05 09:26:43 +01:00
Brian Paul
7836a96657 mesa: added _mesa_[Get]TexParameterI[u]iv() functions
New in GL 3.0.  Primarily meant for setting int/uint-valued texture
border color.  Not plugged into dispatch table yet.
2010-01-04 20:00:09 -07:00
Brian Paul
f6c2d1f94f mesa: make texture BorderColor a union of float/int/uint
When we have integer-valued texture formats, the texture border color
must also store integer and uint values.

With GL 3.0, the new glTexParameterIiv() and glTexParameterIuiv() functions
can set the border color to int or uint values.
2010-01-04 19:53:30 -07:00
Brian Paul
32b9983c0a mesa: use get_texobj() in _mesa_GetTexParameter() funcs 2010-01-04 19:20:33 -07:00
Brian Paul
5ac16495a2 Merge branch 'mesa_7_7_branch'
Conflicts:
	docs/relnotes.html
	src/gallium/drivers/llvmpipe/lp_tex_sample_c.c
	src/gallium/drivers/r300/r300_cs.h
	src/mesa/drivers/dri/i965/brw_wm_surface_state.c
	src/mesa/main/enums.c
2010-01-04 19:16:24 -07:00
Brian Paul
6d84580858 mesa: add missing _mesa_lock_texture() call 2010-01-04 19:05:31 -07:00
Eric Anholt
b434a816d7 i915: Use _MaxLevel on principle in texture setup.
It was OK before because we proceed to clamp the value to hardware
limits, but given that other use of MaxLevel has been a trap, let's
avoid it.
2010-01-04 14:15:12 -08:00
Eric Anholt
19a26dfc47 intel: Fix CopyTexImage from tiled mipmap levels > 0.
Fixes piglit fbo-copyteximage.
2010-01-04 14:15:12 -08:00
Eric Anholt
63610fae4f i965: Fix the surface offset calculation for tiled buffers.
If we ever had a non-tile-aligned tiled renderbuffer, the math was all
off.  Use the existing x,y coordinates instead of trying to
reconstruct them from an incorrectly-calculated offset value.
2010-01-04 14:15:12 -08:00
Andre Maasikas
a160d1c27d r600: support vertex_array_bgra
Use vertex program key mechanism and swizzle during vertex fetch - is there
a better way?
2010-01-04 16:16:43 -05:00
Chia-I Wu
8e6774937f progs/es1: Add compressed paletted texture tests to torus.
The tests can be toggled by `t'.  It will print current texture format
and the size of the image.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-04 14:15:16 -07:00
Chia-I Wu
a316b700ef mesa/es: Improve support for GL_OES_compressed_paletted_texture.
Add error checking and fix handling of level (it should be negative).
Besides, always use the palette entry format/type when calling
_mesa_TexImage2D.  It respects the base internal formats of the cpal
formats, and is simpler and faster, except for cases where the unpack
alignment needs to be changed.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-04 14:15:16 -07:00
Chia-I Wu
c4b9e1aa1a mesa/es: Fix GL_RGB565 support in FBO.
In GL_OES_framebuffer_object and OpenGL ES 2.0, GL_RGB565 is a valid
internal format.  Since it is not supported by the core, map it to
GL_RGB5 as a workaround.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-04 14:15:16 -07:00
Chia-I Wu
b80ec33f35 mesa/es: Fix GL_OES_texture_cube_map support.
Unlike in OpenGL, GL_OES_texture_cube_map says that all coordinates are
changed the same time by the token GL_TEXTURE_GEN_STR_OES, and the
initial mode is GL_REFLECTION_MAP_OES.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-04 14:15:15 -07:00
Chia-I Wu
3a4d0811b4 mesa/es: Clean up extension string.
Add some new extensions and remove those that do not belong to
OpenGL ES 2.0.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-04 14:15:15 -07:00
Chia-I Wu
f88297b369 mesa/es: Add more exnteions to APIspec.
This commit adds definitions of

  GL_EXT_texture_compression_dxt1
  GL_EXT_texture_lod_bias
  GL_EXT_blend_minmax
  GL_EXT_multi_draw_arrays

to APIspec.xml and get_gen.py.  Some of the enums are not avaiable in
the header files and the defining extensions are disabled.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-04 14:15:15 -07:00
Chia-I Wu
29bd20ad14 mesa/es: Add more extensions to glapi.
This commit adds definitions of

  GL_OES_texture_half_float_linear, GL_OES_texture_float_linear
  GL_OES_texture_half_float, GL_OES_texture_float
  GL_OES_vertex_half_float
  GL_OES_vertex_type_10_10_10_2
  GL_OES_get_program_binary
  GL_EXT_texture_compression_dxt1
  GL_EXT_texture_format_BGRA8888
  GL_EXT_texture_lod_bias
  GL_EXT_blend_minmax
  GL_EXT_read_format_bgra
  GL_EXT_multi_draw_arrays

to glapi.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-04 14:15:15 -07:00
Chia-I Wu
a2d21f67f9 mesa/es: Generate code for special functions.
es_generator.py did not generate code for special functions.  They were
supposed to be defined elsewhere.  But as a result, parameter checking
was also skipped.  This commit changes the way special functions are
called so that parameter checking is always performed.

When there is nothing to check, the check functions becomes macros
expanding to the real functions, as an optimization.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-04 14:15:15 -07:00
Chia-I Wu
f7d23dfef5 mesa/es: Remove unused code in es_generator.py.
Remove unused GetLoopSizeExpression.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-04 14:15:15 -07:00
Chia-I Wu
e0ab739c06 mesa/es: Generate _mesa_GetFixedv.
Have get_gen.py generate _mesa_GetFixedv.  The generated function does
all the checkings and thus simplifies APIspec.xml a bit.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-04 14:15:15 -07:00
Chia-I Wu
c3bd857917 mesa/es: Add a sanity check to APIspec.py.
Some attributes are constant in a switch.  Raise an exception if they
are not.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-04 14:15:15 -07:00
Chia-I Wu
8264a6a8a6 mesa/es: Switch to APIspec.xml.
Update Makefile and ES generator to use APIspec.xml.  Remove APIspec.txt
and related files.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-04 14:15:15 -07:00
Chia-I Wu
0c1a7bbe0d mesa/es: Add APIspec.xml and its parser.
APIspec.xml is based on APIspec.txt.  The new format has less code
duplications and should be easier to read.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2010-01-04 14:15:15 -07:00
Brian Paul
82421c549f mesa: added GL_DU8DV8_ATI in extract_float_rgba()
Fixes warning seen with Shadowgrounds.  See bug 24016.
2010-01-04 14:01:19 -07:00
Brian Paul
01bf004d8b docs: initial release notes for 7.7.1 2010-01-04 14:01:18 -07:00
Vinson Lee
6130bb1391 mesa: Prevent possible array out-of-bounds access by _mesa_light. 2010-01-04 12:06:04 -08:00
Vinson Lee
bfc34c8804 i965g: Fix assert. 2010-01-04 11:28:37 -08:00
Vinson Lee
ad80009c88 tgsi: Fix assert. 2010-01-04 11:25:38 -08:00
Brian Paul
0fb1eaddfb Merge branch 'gallium-conditional-rendering' 2010-01-04 11:47:39 -07:00
Brian Paul
e661bf5018 mesa: regenerated enums.c file 2010-01-04 11:30:03 -07:00
Brian Paul
707faf65c8 glapi: comment-out TIMEOUT_IGNORED
This is not really a GLenum value.
2010-01-04 11:30:03 -07:00
Brian Paul
f52dd2ab33 glsl: use varName variable in _slang_gen_assignment() 2010-01-04 11:30:03 -07:00
Brian Paul
195568e4cb mesa: more detailed error message in extract_float_rgba() 2010-01-04 11:27:17 -07:00
Alan Hourihane
1baaf111c8 fix overflow 2010-01-04 17:41:49 +00:00
Kristian Høgsberg
51362a75a7 intel: intelScreenContext() is no longer used 2010-01-04 11:48:03 -05:00
Kristian Høgsberg
5a0b60aa1b intel: Remove remaining dri2.enabled tests 2010-01-04 11:48:02 -05:00
Kristian Høgsberg
2861d9200b intel: Drop more cliprect bookkeeping 2010-01-04 11:48:02 -05:00
Kristian Høgsberg
d282128ff6 intel: Remove struct intel_framebuffer
With the vsync fields no longer relevant and by refactoring the code
to no longer use color_rb[0-1] we can just use struct gl_framebuffer
directly.
2010-01-04 11:48:02 -05:00
Kristian Høgsberg
a6e1d3edac intel: Remove client-side vblank code 2010-01-04 11:48:02 -05:00
Kristian Høgsberg
5bc4b886e4 intel: Drop intelWindowMoved()
Everything this functions does under DRI2 is also taken care of
by intel_draw_buffer(), which is always called where intelWindowMoved()
is called.
2010-01-04 11:48:02 -05:00
Kristian Høgsberg
5203b7227c intel: Drop batchbuffer cliprect_mode tracking 2010-01-04 11:48:02 -05:00
Kristian Høgsberg
f55d0920cd intel: Drop DRI1 static regions 2010-01-04 11:48:01 -05:00
Kristian Høgsberg
ee49ac8742 intel: Use depth buffer from ctx.DrawBuffer in copypix_src_region()
This function was using intel->depth_region, which is the static region
for the DRI1 depth buffer.  This code has always been broken with DRI2
but I suspect it doesn't get excersized much.
2010-01-04 11:48:01 -05:00
Kristian Høgsberg
01dc463e5d intel: Drop LOCK/UNLOCK_HARDWARE() 2010-01-04 11:48:01 -05:00
Kristian Høgsberg
3566bc7584 intel: Drop DRI1 SwapBuffer implementation 2010-01-04 11:48:01 -05:00
Kristian Høgsberg
4611f08c07 intel: Drop DRI1 CopySubBuffer implementation 2010-01-04 11:48:01 -05:00
Kristian Høgsberg
48c0ff1424 intel: Drop DRI1 support
The DDX driver stopped supporting DRI1 so we're dropping support for
that from the DRI driver too.
2010-01-04 11:48:00 -05:00
Kristian Høgsberg
39a0e4e7de Push __driDriverExtensions out of dri_util.c and into the drivers
This lets the individual drivers select which extensions to advertise.
Specifically, most drivers (tdfx, sis, savage etc) don't support DRI2
but the shared extension list in dri_util.c does list the DRI2 extension.

Pushing the list into the drivers, lets us avoid listing the DRI2
extension for drivers that don't support it.
2010-01-04 11:48:00 -05:00
Kristian Høgsberg
d61f07318c Remove leftover __DRI{screen,drawable,context}Private references
As part of the DRI driver interface rewrite I merged __DRIscreenPrivate
and __DRIscreen, and likewise for __DRIdrawablePrivate and
__DRIcontextPrivate.  I left typedefs in place though, to avoid renaming
all the *Private use internal to the driver.  That was probably a
mistake, and it turns out a one-line find+sed combo can do the mass
rename.  Better late than never.
2010-01-04 11:48:00 -05:00
Kristian Høgsberg
8616cec5c9 Check for libdrm_$chipset.pc when needed
This adds missing pkg-config lookup for intel and moves the radeon
lookup into a case...esac so it's only looked up when one or more of
the radeon drivers are enabled.
2010-01-04 11:47:59 -05:00
Michel Dänzer
1e414df894 st/mesa: Only call st_texture_image_unmap() if texImage->Data is non-NULL.
This was already done in st_TexImage() but was missed between incremental
changes to st_TexSubimage().
2010-01-04 16:54:29 +01:00
Alan Hourihane
a3abb9d1cc silence compiler warning 2010-01-04 12:42:51 +00:00
Alan Hourihane
4a531fb46a Fix test 2010-01-04 12:41:33 +00:00
Michal Krol
86b336f71b docs: Explain TGSI_SEMANTIC_NORMAL. 2010-01-04 13:38:58 +01:00
Michal Krol
8ab89d7681 docs: Fix indent. 2010-01-04 13:23:41 +01:00
Michal Krol
07f416cdc9 docs: Clarify what truncate means. 2010-01-04 13:21:32 +01:00
Michal Krol
cef218062a docs: Replace bogus \times' back with *'. 2010-01-04 13:15:28 +01:00
Michal Krol
c929664fdf docs: TGSI SIN and COS are scalar instructions. 2010-01-04 13:12:27 +01:00
Michel Dänzer
acd1451393 svga: Fix debug build crash when rendering to depth/stencil renderbuffer only. 2010-01-04 13:05:43 +01:00
Michel Dänzer
c114f000df st/xorg: Proper calculation of screen pitch. 2010-01-04 13:04:05 +01:00
Michel Dänzer
8282185752 vmware/xorg: Fix SCons build. 2010-01-04 13:02:40 +01:00
Michal Krol
b3567fc983 docs: Clarify math description of TGSI LRP instruction operation. 2010-01-04 12:59:17 +01:00
Michal Krol
b6659681f2 docs: Correct TGSI acronym expansion. 2010-01-04 12:52:43 +01:00
Andre Maasikas
e04a818606 r600: support vertex_array_bgra
Use vertex program key mechanism and swizzle during vertex fetch - is there
a better way?
2010-01-04 12:39:37 +02:00
Vinson Lee
d1e2fc19cc r300: Use C-style comments. 2010-01-03 23:33:32 -08:00
Vinson Lee
8a29e3f8e8 progs/egl: Silence uninitialized variable warnings. 2010-01-03 21:39:20 -08:00
Vinson Lee
3ea5a95078 progs/samples: Silence compiler warnings. 2010-01-03 21:29:33 -08:00
Vinson Lee
b14cbfaebc r300: Silence 'mixed declarations and code' warnings. 2010-01-03 20:51:23 -08:00
Kristian Høgsberg
2b218d94b5 Only enable verbose NoOp dispatch if DEBUG is defined
By default we generate a function per GL entry point to warn if it's
called without a context set.  This is to allow the function to print
it's name in the warning.  By using a generic function that doesn't print
the function name in the non-DEBUG case, we reduce libGL size from
320008 bytes to 283144 bytes (11%).
2010-01-03 23:24:13 -05:00
Vinson Lee
0214b7b3c1 r300: Silence 'mixed declarations and code' warning. 2010-01-03 20:16:59 -08:00
Kristian Høgsberg
c3047e73f7 Noop dispatch: move warning code out of the generated functions
This reduces libGL size by 11% here, going from 360968 bytes to
320008 bytes.
2010-01-03 23:01:23 -05:00
Vinson Lee
58531029e6 r300: Silence 'mixed declarations and code' warning. 2010-01-03 18:32:07 -08:00
Vinson Lee
3e196f433d r300g: Silence 'mixed declarations and code' warning. 2010-01-03 18:05:12 -08:00
Kristian Høgsberg
b8326b011d Fix glut to work with -fvisibility=hidden
The GLUTAPI #define used in the header file to mark the font structs
visible wasn't kicking in because of the #define glutBitmap9By15 XXX
prior to #include <GL/glut.h>.  High quality code... worked around by
copying the GLUTAPI specifier to the invidual C files.
2010-01-03 20:59:56 -05:00
Kristian Høgsberg
8d62eb4599 Export a few glapi functions used by gallium and r300
Fixes breakage from -fvisibility-hidden commit.
2010-01-03 19:53:01 -05:00
Vinson Lee
fe3ea299bf r300g: Remove comma at end of enumerator list. 2010-01-03 15:07:35 -08:00
Vinson Lee
0bfc579bd4 llvmpipe: Remove comma at end of enumerator list. 2010-01-03 14:42:36 -08:00
Kristian Høgsberg
e388d62b47 Compile with -fvisibility-hidden by default
We have all functions that need to be visible marked with PUBLIC and
this is trimming around 4% off the DRI driver .so size.
2010-01-03 15:40:59 -05:00
José Fonseca
eb5d9e6f70 mesa: Cope with the degenerate case of zero length ranges.
Fixes assertion failures on glean's bufferObject test.
2010-01-03 20:00:19 +00:00
José Fonseca
f3739bdb60 gdi: Don't generate import libraries for opengl32.dll.
Both MinGW and MSVC include opengl32 import libraries, and its safer to
always use those.
2010-01-03 20:00:19 +00:00
Francis Galiegue
a60084088b mesa: fix blend enable/disable calls in meta.c code
Fixes regression in some DRI drivers since the GL_EXT_draw_buffers2 changes.

Signed-off-by: Brian Paul <brianp@vmware.com>
2010-01-03 09:43:24 -07:00
Jeremy Huddleston
287cbba9b7 apple: Purge existing (not working) GLX_USE_APPLEGL from dated libGL on OSX
Signed-off-by: Jeremy Huddleston <jeremyhu@freedesktop.org>
2010-01-03 08:58:13 -05:00
Jeremy Huddleston
32305e3a9f glxcmds: Fix comment about __DRI_ALLOCATE
Signed-off-by: Jeremy Huddleston <jeremyhu@freedesktop.org>
2010-01-03 08:58:13 -05:00
Vinson Lee
1d95544446 trace: Remove comma at end of enumerator list. 2010-01-03 03:08:40 -08:00
José Fonseca
66c1de77ed rtasm: Play nicely with Windows's Data Execution Prevention. 2010-01-03 11:03:13 +00:00
Vinson Lee
1da47ac20e progs/vp: Ensure null-terminated byte string. 2010-01-03 02:38:22 -08:00
Vinson Lee
c9c6e9a39e progs/tests: Silence uninitialized variable warning. 2010-01-02 21:58:40 -08:00
Vinson Lee
32d18924df progs/tests: Silence warn_unused_result warning. 2010-01-02 21:52:51 -08:00
Vinson Lee
d27effbfd8 i810: Fix include recursion. 2010-01-02 21:05:06 -08:00
Vinson Lee
94c5faad26 sis: ifdef out unused variable.
Silences GCC warning.
2010-01-02 20:47:15 -08:00
Vinson Lee
d2758f3b74 st/xorg: Ensure null-terminated byte string. 2010-01-02 20:39:04 -08:00
Vinson Lee
be6fb5c083 r300g: Use C-style comments. 2010-01-02 20:17:43 -08:00
Vinson Lee
fe27b07b0f glu/sgi: Initialize members of struct O_curve. 2010-01-02 20:04:00 -08:00
José Fonseca
cdb445f3a9 svga: Use a shader id as low as possible. 2010-01-03 00:50:13 +00:00
José Fonseca
904917dcc6 util: Minor enhancements/corrections to the bitmask logic. 2010-01-03 00:50:13 +00:00
José Fonseca
da6a80301b svga: Rename error labels.
Make it easier to insert/remove error branches.
2010-01-03 00:50:12 +00:00
Vinson Lee
386f91eec3 glu/sgi: Initialize members of struct O_surface. 2010-01-02 15:46:11 -08:00
Vinson Lee
ba9dc26eec glu/sgi: Initialize member of struct O_trim. 2010-01-02 15:29:25 -08:00
José Fonseca
c978ab017d gallium: Hunt down all references to GALLIUM_AUXILIARY_DIRS. 2010-01-02 20:22:52 +00:00
Marc Dietrich
995c342018 autoconf: fix build breakage 2010-01-02 10:33:15 -07:00
Brian Paul
1fbc71937f mesa: added _mesa_GetBufferParameteri64v()
This is a new function in GL 3.2.  No dispatch for this function yet.
2010-01-02 10:32:37 -07:00
Vinson Lee
37e5626111 glu/sgi: Initialize member of struct Property. 2010-01-01 23:01:03 -08:00
Vinson Lee
646c8ce032 progs/samples: 'Silence no previous prototype' warnings. 2010-01-01 17:54:11 -08:00
Vinson Lee
2c64e4c50e glu/sgi: Initialize member of struct Dlnode. 2010-01-01 17:25:16 -08:00
Vinson Lee
64a1961011 glu/sgi: Initialize members of struct O_nurbscurve. 2010-01-01 17:19:27 -08:00
José Fonseca
52eb3e4235 scons: Build glew on all platforms.
It is required for progs.
2010-01-02 01:12:35 +00:00
Vinson Lee
fab161f287 x86: Silence printf format warnings. 2010-01-01 17:06:16 -08:00
José Fonseca
321aef7da3 scons: Update the MSVC SA to match latest scons code. 2010-01-02 00:56:01 +00:00
José Fonseca
58d376ac42 scons: Axe generic.py.
Progs are now built together with the rest so no longer needed.
2010-01-02 00:55:29 +00:00
Vinson Lee
ad9defdd9c progs/rbug: s/wait/rbug_wait/
wait conflicts with wait in /usr/include/sys/wait.h.
2010-01-01 16:25:37 -08:00
Vinson Lee
3ae37da611 llvmpipe: Silence uninitialized variable warning. 2010-01-01 16:03:53 -08:00
José Fonseca
8a318edd08 scons: Put glut and glew shared libraries into build/xxx/bin or lib.
Use bin subdir for windows dlls, lib for unices.
2010-01-02 00:01:43 +00:00
José Fonseca
ee39dc20e6 python: Don't generate a import library for python module either. 2010-01-02 00:01:43 +00:00
José Fonseca
6f19ec64fc i965: Add missing include. 2010-01-02 00:01:43 +00:00
José Fonseca
2104cbb694 scons: Remove duplicated code. 2010-01-02 00:01:42 +00:00
José Fonseca
b2e40643a3 scons: Disable version symlinking for DLLs.
Fixes windows build.
2010-01-02 00:01:42 +00:00
José Fonseca
187066caa0 gdi: Don't generate import libraries for opengl32.dll.
Both MinGW and MSVC include opengl32 import libraries, and its safer to
always use those.
2010-01-02 00:01:42 +00:00
José Fonseca
14a8c9dac7 scons: Fix glew build on MSVC.
The environment for building the DLL needs to be quite different from
the environment for building the programs, in order to get
the dllexport/dllimport attribute done currectly. I don't know how MinGW
managed to build the programs, but MS linker refuses to link symbols with
mismatching attributes.
2010-01-02 00:01:42 +00:00
José Fonseca
c852e960cc util: Silent potential loss of precision warnings.
Also ensure multiplication doesn't happen for negative numbers.
2010-01-02 00:01:42 +00:00
Vinson Lee
fd237a879f llvmpipe: Use C-style comment. 2010-01-01 15:38:19 -08:00
Vinson Lee
dac82c378a gallium/util: Silence format warnings. 2010-01-01 15:32:52 -08:00
Vinson Lee
88bd32383a ARB prog parser: Silence unused variable warnings. 2010-01-01 15:12:58 -08:00
Vinson Lee
7df06e7e9d gallium/util: Replace h_addr with h_addr_list[0].
Fixes compilation error on Mac OS.
2010-01-01 15:01:22 -08:00
Vinson Lee
a349687d49 glu/sgi: Initialize members of class Knotvector. 2010-01-01 14:46:30 -08:00
Vinson Lee
5d3d202ac9 glu/sgi: Initialize member of struct Property. 2010-01-01 14:39:16 -08:00
Igor Oliveira
9595b59247 tgsi: Add missing semantic name in text parser. 2010-01-01 19:03:27 +01:00
José Fonseca
486ccb55a8 r300: Fix scons build. 2010-01-01 12:16:20 +00:00
José Fonseca
89d778ff02 scons: Don't list cell as a driver.
Cell driver's SConscript never got written, and it is not trivial one to
write, so don't accept cell in the driver option to avoid confusion.
2010-01-01 12:16:20 +00:00
José Fonseca
cf9be46c01 llvmpipe: Add missing include path.
The abscense was being masked previously.
2010-01-01 12:16:20 +00:00
José Fonseca
c847a13d38 gallium: Generate a single library for auxiliaries with Make too. 2010-01-01 12:16:19 +00:00
José Fonseca
f8f4757d46 scons: Aggregate all tiny libraries in a single library.
Makes integration of gallium into out of tree components much easier. No
pratical change for components in this tree,
2010-01-01 12:16:19 +00:00
José Fonseca
fc8e0b97e5 gallium: Remove the sct module.
Not used, and its functionality is now addressed by
pipe_context::is_texture/buffer_referenced callbacks.
2010-01-01 12:16:19 +00:00
José Fonseca
7bbf7f94ea scons: Build progs together with everything else.
This is a substantial reorganization, This particular commit enables:
- building the progs for unices platforms
- glew is now built as a shared library (it is the default, and it is
inconvenient and pointless to shift away from that default)
- all progs get built by default
2010-01-01 12:16:19 +00:00
José Fonseca
58b401315b progs: Ignore derived files. 2010-01-01 12:16:19 +00:00
José Fonseca
cbb23523a8 glsl: Ignore programs. 2010-01-01 12:16:19 +00:00
José Fonseca
3d747eded4 scons: Don't globally define WIN32_LEAN_AND_MEAN.
Some of the demo progams legitimately need the functionality
that's disabled by WIN32_LEAN_AND_MEAN.

Instead the solution should be to define WIN32_LEAN_AND_MEAN just before
including windows.h on a case by case basis.
2010-01-01 12:16:19 +00:00
José Fonseca
33f44b93d2 mesa: Avoid WIN32_LEAN_AND_MEAN re-definition. 2010-01-01 12:16:18 +00:00
José Fonseca
04c7f483b4 mesa: Make condrender.[ch] prototypes match.
GLAPI on windows is more than "extern" -- it includes the --, so the
mismatch between condrender.[ch] prototypes causes "different linkage"
errors on windows.
2010-01-01 11:20:38 +00:00
José Fonseca
97e2c5ac0b scons: Expose convienience libraries to the host environment.
This fixes MinGW cross compilation build, recently broken due to the use
of convenience libraries in the GLSL preprocessor.
2010-01-01 11:00:58 +00:00
José Fonseca
700a2ebbf1 glut: Silent the glut*_ATEXIT_HACK defined but not used warnings.
There are two ways to silent this: put inline keyword, or reimplement the
hack as a #define. inline keyword actually varies slightly with compiler
so I've opted by the latter.
2010-01-01 11:00:58 +00:00
Brian Paul
c9b5583518 st/mesa: implement conditional rendering 2009-12-31 14:47:21 -07:00
Brian Paul
f1b382d2e6 st/mesa: move st_query_object type to header to make it public 2009-12-31 14:46:57 -07:00
Brian Paul
41450b03a8 softpipe: implement conditional rendering 2009-12-31 14:46:15 -07:00
Brian Paul
c0b4fb06b8 gallium: pipe_context::render_condition() and mode flags
For conditional rendering predicated on results of an occlusion query.

If this driver function is NULL, conditional rendering is not supported by
the driver.
2009-12-31 14:45:15 -07:00
Christoph Bumiller
45a01bc5bd nv50: small fix for handling "dangerous" swizzles 2009-12-31 22:29:39 +01:00
Brian Paul
25024d9482 Merge branch 'mesa_7_7_branch'
Conflicts:
	configs/darwin
	src/gallium/auxiliary/util/u_clear.h
	src/gallium/state_trackers/xorg/xorg_exa_tgsi.c
	src/mesa/drivers/dri/i965/brw_draw_upload.c
2009-12-31 09:02:27 -07:00
Brian Paul
d14beea534 mesa: remove a line of dead code 2009-12-31 08:50:26 -07:00
Brian Paul
06f10903cb docs: 7.8 relnotes: GL_NV_conditional_render and GL_EXT_draw_buffers2 2009-12-31 08:49:28 -07:00
Brian Paul
f10470e3fe mesa: enable ColorMaskIndexed in display lists 2009-12-31 08:49:28 -07:00
Brian Paul
34075d0219 progs/tests: added test for GL_EXT_draw_buffers2
Render into two color buffers (render targets).  Display half of each
buffer in the window.  Use different color masks for each render target.
Only enable blending for the second render target.
2009-12-31 08:49:27 -07:00
Brian Paul
fcc2e1a729 mesa: enable GL_EXT_draw_buffers2 for sw drivers 2009-12-31 08:49:27 -07:00
Brian Paul
c28b451e40 docs: update status for conditional rendering 2009-12-31 08:49:27 -07:00
Brian Paul
08d145e1d7 progs/tests: added conditional rendering test program 2009-12-31 08:49:27 -07:00
Brian Paul
aa491c19b9 mesa: turn on NV_conditional_render for software drivers 2009-12-31 08:49:27 -07:00
Brian Paul
ab26682eb4 swrast: add check for conditional rendering 2009-12-31 08:49:27 -07:00
Brian Paul
699cfaeb3c tnl: add check for conditional rendering 2009-12-31 08:49:26 -07:00
Brian Paul
ff3a52643d mesa: plug in API functions for conditional rendering 2009-12-31 08:49:26 -07:00
Brian Paul
007b1f42c4 mesa: added dispatch for GL_NV_conditional_render extension 2009-12-31 08:49:26 -07:00
Brian Paul
5a0eb89da5 mesa: added FLUSH_VERTICES(), more comments 2009-12-31 08:49:26 -07:00
Brian Paul
2be0d77a97 mesa: add flag for GL_NV_conditional_render extension 2009-12-31 08:49:26 -07:00
Brian Paul
0fbe828c1d mesa: _mesa_Begin/EndConditionalRender() functions
For GL_NV_conditional_render and GL3.

The drawing functions don't check the query object yet.
No API dispatch yet.
2009-12-31 08:49:26 -07:00
Brian Paul
534e005185 mesa: make _mesa_lookup_query_object() an non-private inline function 2009-12-31 08:49:25 -07:00
Brian Paul
195e7657e2 swrast: use different temp array in _swrast_get_dest_rgba()
When using multiple color drawbuffers with blending/logicop/masking we
were overwriting color values which we still needed.
2009-12-31 08:44:27 -07:00
Christoph Bumiller
4e4244b910 nv50: fix TEXLOD sequence and use it only in FPs 2009-12-31 14:34:46 +01:00
Christoph Bumiller
616ddc8dfa nv50: cannot kill branch if immediate is used
The immediate's bits eat the condition bits.
2009-12-31 14:34:42 +01:00
Christoph Bumiller
b3425bc360 nv50: make assimilate_temp safe
Cannot change hw reg assigned to a TGSI TEMP on the fly if
we are in a loop, conditional, or can jump around wildly.
2009-12-31 14:34:38 +01:00
Christoph Bumiller
d9ae8f31d5 nv50: handle TGSI_OPCODE_EXP,LOG
Not that they make much sense on nv50, but we also do LIT ...
2009-12-31 14:34:34 +01:00
Christoph Bumiller
f2cca04bd8 nv50: add support for subroutines 2009-12-31 14:34:30 +01:00
Christoph Bumiller
170cdb4507 nv50: alloc_reg on reg_instance
If we create multiple instances of an nv50_reg referencing
them same resource, register allocation from alloc_reg has
to be done with the original nv50_reg.
2009-12-31 14:34:26 +01:00
Christoph Bumiller
0ba518e327 nv50: multiply polygon offset units by 2 2009-12-31 14:34:22 +01:00
Christoph Bumiller
4d2551beb7 nv50: neg and abs modifiers for flops
Also fixes RSQ of negative sources.
2009-12-31 14:34:17 +01:00
Christoph Bumiller
3019afdbd8 nv50: don't negate immediates in set_immd
This negation would only be triggered in situations
where it's incorrect.
The caller of set_immd should negate the immediate value
in the instruction itself if desired, and will also know
if it's a float or an int.

ADD TEMP[0], CONST[0], -IMMD[0] would load the immediate
into extra TEMP, negated, and set the negate flag in add
as well - double negation.
2009-12-31 14:34:10 +01:00
Vinson Lee
6e0584932b mesa: Silence unused variable warning. 2009-12-31 00:07:47 -08:00
Michal Krol
543b9566bd Add lame support for instanceID to draw module.
It's all screaming for integer support -- fake it with float for now.
2009-12-30 22:18:53 +01:00
Michal Krol
5754185d39 tgsi: Support system values in ureg. 2009-12-30 21:52:01 +01:00
Vinson Lee
5b2713c92a progs/glsl: Provide a better fix for fgets warning. 2009-12-30 12:38:21 -08:00
Michal Krol
6481f40eec draw: Implement draw_arrays() in terms of draw_arrays_instanced(). 2009-12-30 18:54:04 +01:00
Michal Krol
230355648b sp: Generalise drawing code to remove dupes.
Also, avoid nested draw calls from simpler versions.
2009-12-30 18:41:05 +01:00
Brian Paul
9b0bbe15a5 docs: added GL 3.x feature checklist to track what's done in Mesa 2009-12-30 10:39:20 -07:00
Brian Paul
16e91d4c0e mesa: implement _mesa_GetStringi() for GL3
Note: not plugged into the dispatch table yet.
2009-12-30 10:30:23 -07:00
Brian Paul
56bdaca03e mesa: _mesa_get_enabled_extension() function 2009-12-30 10:29:53 -07:00
Michal Krol
bccdb239c7 sp: Implement draw_elements_instanced(). 2009-12-30 18:27:58 +01:00
Michal Krol
5007e39f76 Implement instanced indexed draw. 2009-12-30 18:26:40 +01:00
Brian Paul
802b808939 mesa: implement GL3 GL_NUM_EXTENSIONS query 2009-12-30 10:16:01 -07:00
Brian Paul
1ec6de9f94 mesa: simplify some extension testing code 2009-12-30 10:13:31 -07:00
Brian Paul
05fb922e61 mesa: display list support for glClearBuffer functions
Note: some code disabled until dispatch table supports GL3 entrypoints.
2009-12-30 09:45:58 -07:00
Brian Paul
2b5ece5746 mesa: implement GL3 glClearBuffer() functions
These functions clear color/depth/stencil buffers with a value that's
passed to the function, rather than the context clear values.

For now these functions are implemented in terms of the existing
ctx->Driver.Clear() hook.  In the future when we have non-normalized
integer and unsigned integer color buffer formats we'll need new
driver hook(s) to pass int and uint clear values to the driver.

Note: these functions are not hooked into the dispatch table at this time.
2009-12-30 09:30:24 -07:00
Brian Paul
12039aa7a9 mklib: use a wrapper for ar 2009-12-30 09:30:24 -07:00
Michal Krol
76e53923ba translate: Fix a call to indexed SSE run. 2009-12-30 16:28:01 +01:00
Luca Barbieri
9656177bc0 nouveau: Fix glTexSubImage on swizzled surfaces on <=NV40
Currently in nvXX_transfer_new a temporary as large as the surface is created.
If the subrectangle is not the whole texture we would need to read
back the whole texture, but we aren't.
Thus, everything but the subrectangle specified is loaded as garbage.
This can be seen in progs/demos/ray.

This patch fixes the problem by creating a temporary that covers only
the desired subrectangle.

That makes us hit an alignment assert in nv04_surface_2d.c. Fix it
using the point registers instead of manipulating the swizzled surface
offset to account for the destination coordinates (which do not seem
to have a 1024 limit).

Signed-off-by: Francisco Jerez <currojerez@riseup.net>
2009-12-30 14:37:19 +01:00
Michal Krol
09c0287b84 translate: Implement instancing for linear SSE run. 2009-12-30 14:23:12 +01:00
Michal Krol
0f185cb027 rtasm: Add x86_div(). 2009-12-30 14:20:29 +01:00
Brian Paul
f00bf0598c st/mesa: add PIPE_FORMAT_Z24S8_UNORM in st_get_format_info()
Fixes progs/demos/fbotexture on Nouveau.
Patch submitted by Luca Barbieri <luca@luca-barbieri.com>.
2009-12-29 23:31:43 -07:00
Vinson Lee
de95e5768b glu/sgi: Initialize members of struct O_nurbssurface. 2009-12-29 22:29:53 -08:00
Brian Paul
1677d5c0ae mesa: fix-up blend enable/disable code in _mesa_PopAttrib() 2009-12-29 23:04:27 -07:00
Brian Paul
36092fa2d8 mesa: finish-up indexed color mask code in _mesa_PopAttrib() 2009-12-29 22:58:44 -07:00
Brian Paul
81c72a1dab mesa: plug in GL_EXT_draw_buffers2 functions 2009-12-29 22:56:32 -07:00
Brian Paul
285d3f9ed8 mesa: regenerate API files related to GL_EXT_draw_buffers2 2009-12-29 22:55:57 -07:00
Brian Paul
ca3a8538b6 glapi: extension info for GL_EXT_draw_buffers2 2009-12-29 22:54:30 -07:00
Vinson Lee
ac21edff1c tdfx: Silence uninitialized variable warning. 2009-12-29 21:34:06 -08:00
Vinson Lee
0ab29d2b35 progs/glsl: Silence compiler warnings. 2009-12-29 21:11:37 -08:00
Vinson Lee
70bbe22366 glu/sgi: Silence warn_unused_result warnings. 2009-12-29 21:03:23 -08:00
Vinson Lee
31263f41a0 st/xorg: Use C-style comments. 2009-12-29 20:56:47 -08:00
Vinson Lee
97b899374c glu/sgi: Initialize member of struct GridVertex. 2009-12-29 20:45:24 -08:00
Jakob Bornecrantz
5169775345 st/xorg: Fix warning and add a TODO comment 2009-12-30 05:08:41 +01:00
Jakob Bornecrantz
d34fdf149d st/xorg: On close wait on fences and then destroy the screen 2009-12-30 05:01:09 +01:00
Jakob Bornecrantz
5fdc4f732f st/xorg: Be proper with pipe pointers on close in exa 2009-12-30 05:00:30 +01:00
Brian Paul
8f6f112463 mesa: added infrastructure for GL_EXT_draw_buffers2 2009-12-29 20:51:20 -07:00
Jakob Bornecrantz
53e314cb80 st/xorg: Make sure we don't overrun the fence array in block handler 2009-12-30 04:22:12 +01:00
Vinson Lee
3bcf7d7d7b glu/sgi: Initialize member variables in class Varray. 2009-12-29 17:46:42 -08:00
Vinson Lee
a7db305c2f glu/sgi: Initialize member of class monoChain. 2009-12-29 17:35:22 -08:00
Vinson Lee
5060fb428d glu/sgi: Initialize members of class sampledLine. 2009-12-29 17:22:11 -08:00
Brian Paul
a856d635d3 mesa: add dlist support for indexed colormask and indexed enables/disables
Not plugged into dispatch table yet...
2009-12-29 16:30:04 -07:00
Brian Paul
fd5511d27f mesa: implement per-buffer color masking
This is part of the GL_EXT_draw_buffers2 extension and part of GL 3.0.

The ctx->Color.ColorMask field is now a 2-D array.  Until drivers are
modified to support per-buffer color masking, they can just look at
the 0th color mask.

The new _mesa_ColorMaskIndexed() function will be called by
glColorMaskIndexedEXT() or glColorMaski().
2009-12-29 16:17:14 -07:00
Vinson Lee
495b8f8f7a glu/sgi: Initialize members of class directedLine. 2009-12-29 14:28:33 -08:00
Michal Krol
7ca0ce3834 Implement draw_arrays_instanced() in softpipe.
Modify the translate module to respect instance divisors and accept
instance id as a parameter to calculate input vertex offset.
2009-12-29 23:21:01 +01:00
Brian Paul
126b35bd3a mesa: implement indexed glGet functions
The functions are _mesa_GetBooleanIndexedv(), _mesa_GetIntegerIndexedv(), and
_mesa_GetInteger64Indexedv().  These will be called from API functions such as
glGetBooleanIndexedvEXT() and glGetBooleani_v().

Only the GL_BLEND query is supported at this time.
2009-12-29 15:09:16 -07:00
Brian Paul
3728673bd1 mesa: per-buffer blend enabled flags
ctx->Color.BlendEnabled is now a GLbitfield instead of a GLboolean to
indicate blend on/off status for each color/draw buffer.

This is infrastructure for GL_EXT_draw_buffers2 and OpenGL 3.x

New functions include _mesa_EnableIndexed(), _mesa_DisableIndexed(), and
_mesa_IsEnabledIndexed().  The enable function corresponds to
glEnableIndexedEXT() for GL_EXT_draw_buffers2 or glEnablei() for GL3.

Note that there's quite a few tests for ctx->Color.BlendEnabled != 0 in
drivers, etc.  Those tests can remain as-is since the mask will be 0 or ~0
unless GL_EXT_draw_buffers2 is enabled.
2009-12-29 15:04:03 -07:00
Michal Krol
7124fa16ef translate: Fix translate_key_compare().
Sizes of translate keys must also match.
2009-12-29 22:49:31 +01:00
Vinson Lee
62a0d4ef7f mesa: Initialize variable in get_tex_color_index. 2009-12-29 13:38:02 -08:00
Michal Krol
f7d1689cfa gallium: Move instance_divisor field from vertex_buffer to vertex_element. 2009-12-29 19:18:54 +01:00
Brian Paul
4f481cb87a glsl: added uniform initializer check
GLSL 1.10 disallows initializers for uniforms but GLSL 1.20 and later
allows them.  This patch uses the #version directive to allow/disallow
uniform initializers.

This addresses bug 25807, but piglit also needs to be fixed to specify
the GLSL version in the shader.
2009-12-29 10:11:29 -07:00
Brian Paul
639e7a140e ARB prog parser: use _mesa_add_unnamed_constant() to use fewer constant slots
This function will search the constant parameters in an effort to re-use
constant slots.  For example, {1,2,3,4} and {4,1,1,2} can be stored in
one constant slot and accessed with different swizzles.  The swizzle info
must be propogated though the parsing code in a few places.

Fixes Piglit "vpfp-generic tests/shaders/generic/big-param.vpfp" failure.
2009-12-29 09:08:02 -07:00
Brian Paul
561a107df7 glsl: added default case in _fetch_token() to silence warnings 2009-12-29 08:47:40 -07:00
Julien Cristau
53d395336d Prepare changelog for upload 2009-12-29 10:42:29 +00:00
Julien Cristau
bc94d48259 Update patch stack
Drop hunk from 05_hurd-ftbfs.diff that was applied upstream.
Refresh other patches.
2009-12-29 10:40:05 +00:00
Julien Cristau
fabfd3eaca Bump linux-libc-dev build-dep to 2.6.31 for the r600 dri driver
fixes ftbfs on mips
2009-12-29 10:19:48 +00:00
Julien Cristau
089e2e656c Bump changelogs 2009-12-29 10:17:41 +00:00
Julien Cristau
7030b61d99 Merge branch 'mesa_7_6_branch' of git://anongit.freedesktop.org/mesa/mesa into debian-unstable
Conflicts:
	progs/tests/bug_texstore_i8.c
	progs/tests/crossbar.c
	progs/tests/cva.c
	progs/tests/fptest1.c
	progs/tests/invert.c
	progs/tests/packedpixels.c
	progs/tests/quads.c
	progs/tests/scissor-viewport.c
	progs/tests/scissor.c
	progs/tests/stencilwrap.c
	progs/tests/tex1d.c
	progs/tests/texcomp_image.h
	progs/tests/unfilledclip.c
	progs/tests/vpeval.c
	progs/trivial/clear-fbo-tex.c
	progs/trivial/createwin.c
	progs/trivial/dlist-begin-call-end.c
	progs/trivial/draw2arrays.c
	progs/trivial/drawarrays.c
	progs/trivial/tri-blend-max.c
	progs/trivial/tri-blend-min.c
	progs/trivial/tri-blend-revsub.c
	progs/trivial/tri-blend-sub.c
	progs/trivial/tri-blend.c
	progs/trivial/tri-fbo-tex.c
	progs/trivial/tri-fp.c
	progs/trivial/tri-logicop-none.c
	progs/trivial/tri-logicop-xor.c
	progs/trivial/tri-z.c
	progs/trivial/vbo-drawarrays.c
	progs/trivial/vbo-noninterleaved.c
	scons/gallium.py
	scons/generic.py
2009-12-29 10:16:21 +00:00
Eric Anholt
a099644755 intel: Fix false positives in checking for non-packed depth/stencil RB.
The wine d3d9 visual.c testcase was tripping over this and failing.
Presumably it's binding a packed depth/stencil texture to both
stencil and depth attachment points, and we make a new renderbuffer
wrapper for each in that case.
2009-12-28 19:21:27 -08:00
Vinson Lee
b4658dbf04 st/egl: Move declaration before code. 2009-12-28 19:09:33 -08:00
Eric Anholt
089144e4e5 intel: Allow binding a stencil but not a depth buffer.
Wine's d3d9 visual.c testcase tries this a lot, so I've added some
piglit tests (fbo-nodepth-test, fbo-nostencil-test, fbo-stencil-only)
and enabled it.
2009-12-28 18:52:47 -08:00
Eric Anholt
e4df8d32b5 intel: Improve INTEL_DEBUG=fbo output. 2009-12-28 18:51:18 -08:00
Eric Anholt
1e4677a61f intel: Remove dead fthrottle_mode option. We only do IRQ waits.
Noticed by clang.
2009-12-28 18:51:18 -08:00
Eric Anholt
2515ccaf24 mesa: remove gratuitous stores I added in remove_instructions. 2009-12-28 18:51:18 -08:00
Vinson Lee
c67bb15d4e intel: Silence compiler warnings. 2009-12-28 18:46:15 -08:00
Vinson Lee
46c2196de3 llvmpipe: Fix assert. 2009-12-28 18:07:09 -08:00
Vinson Lee
e049ddb754 llvmpipe: Silence compiler warnings. 2009-12-28 18:05:30 -08:00
Younes Manton
85dcc07071 nouveau: Unreference state/buffer objects on context/screen destruction.
- unreference state objects so that buffer objects are unreferenced and
eventually destroyed
- free channel at screen's destruction

Based on Krzysztof Smiechowicz's patch.
2009-12-28 17:59:01 -05:00
Luca Barbieri
cb9214f330 nouveau: Fix swizzling for copies to rectangular textures
nVidia hardware seems to swizzle rectangular texture (with width !=
height) coordinates by swizzling the lower bits and then adding the
higher bits from the larger dimension.
However, nv04_swizzle_bits ignores width and height and just
interleaves everything.
This causes problems with rectangular POT textures with height or
width 2048 or 4096 (but not 2048x1024 where it works by chance) since
the driver swizzles them in 1024x1024 chunks and gets the start
position for the non-first chunks wrong.
The following patch seems to fix those problems.
2009-12-28 17:59:01 -05:00
Luca Barbieri
3a0c527bd0 nouveau: Fix nv20-40 swizzled miptree RTs
I just coded a patch that does this and seems to work fine. It must be
fixed since it breaks OpenGL (or the state tracker can be changed, but
it seems better to do it in the driver).

The patch also fixes NV20 and NV30 in the same way. They compile but
are untested.

I would guess that using the 3D engine is faster for the larger
levels, but the 2D engine is faster for the smaller ones (and lacks
this issue).
2009-12-28 17:59:01 -05:00
Luca Barbieri
a55e50b082 NV30/NV40 CMP and SCS src == dst handling
CMP and SCS can produce incorrect results if the source and
destination are the same.
This patch should fix the issues.
CMP is fixed by predicating both moves.
SCS by changing the order if the source component is X.
2009-12-28 17:59:00 -05:00
José Fonseca
926562fe27 llvmpipe: Unmapping vertex/index buffers does NOT flush draw module anymore.
Not since 6094e79f4e.

Drivers now need to flush draw module explicitely (which explains why
all those previous commits adding draw_flushes calls were necessary).

This is a good thing, but it's tricky to get this right in face of user buffers
(it's not even clear who has the responsibility to flush when a user buffer
is seen -- statetracker or pipe driver), so just force flush (temporarily)
since it's not a bottleneck now.
2009-12-28 22:53:41 +00:00
José Fonseca
64893eb501 python/retrace: Dump only the specified image rectangles. 2009-12-28 22:53:40 +00:00
José Fonseca
67171ed85f xlib: Integrate the trace driver with all pipe drivers.
And not just softpipe.

It is particularly convenient to use llvmpipe instead, since it is much
faster. It also allows to use rbug with all xlib drivers.
2009-12-28 22:53:40 +00:00
José Fonseca
7abdaf574a scons: Fix xlib build.
After glsl rework merge.
2009-12-28 22:53:40 +00:00
Francisco Jerez
49a0f291ae nv04: Fix build after the latest nouveau_class.h changes. 2009-12-28 18:11:06 +01:00
Marcin Kościelnicki
c84cc09d41 nv50: Dehexify and bring up to date with new method defines.
Signed-off-by: Francisco Jerez <currojerez@riseup.net>
2009-12-28 18:09:26 +01:00
Keith Whitwell
f0ba7d897d util: better fix for unused variable warnings with asserts
Modify the non-debug (ie disabled) version of assert to expose the
value in the expression to the compiler (avoiding the unused variable
messages) while still expanding to a noop.
2009-12-28 11:06:11 +00:00
Vinson Lee
31d1822473 llvmpipe: Silence compiler warnings. 2009-12-28 00:44:30 -08:00
Vinson Lee
c441386b0c st/xorg: Silence unused variable warnings. 2009-12-27 23:02:55 -08:00
Vinson Lee
aa0437532e g3dvl: Silence compiler warnings. 2009-12-27 22:49:49 -08:00
Vinson Lee
bf63b9d7a9 st/vega: Silence compiler warnings. 2009-12-27 22:39:31 -08:00
Vinson Lee
9d3092d134 gallium/xlib: Silence unused variable warning. 2009-12-27 22:18:18 -08:00
Vinson Lee
d1f64fa72f trace: Silence unused variable warnings. 2009-12-27 18:12:58 -08:00
Vinson Lee
f31f9cf485 i915g: Silence unused variable warning. 2009-12-27 18:09:58 -08:00
Vinson Lee
3a2f96f18a softpipe: Silence unintialized variable warnings. 2009-12-27 18:06:02 -08:00
Vinson Lee
180ccffe55 softpipe: Silence unused variable warning. 2009-12-27 17:52:47 -08:00
Vinson Lee
0463ee64e3 tgsi/ureg: Silence uninitialized variable warnings. 2009-12-27 17:40:48 -08:00
Brian Paul
b0d5e44f24 docs: insert 7.7 release date 2009-12-27 15:33:25 -07:00
Brian Paul
d0b7ff551a Merge branch 'mesa_7_6_branch' into mesa_7_7_branch
Conflicts:
	src/gallium/auxiliary/util/u_network.c
	src/gallium/auxiliary/util/u_network.h
	src/gallium/drivers/i915/i915_state.c
	src/gallium/drivers/trace/tr_rbug.c
	src/gallium/state_trackers/vega/bezier.c
	src/gallium/state_trackers/vega/vg_context.c
	src/gallium/state_trackers/xorg/xorg_crtc.c
	src/gallium/state_trackers/xorg/xorg_driver.c
	src/gallium/winsys/xlib/xlib_brw_context.c
	src/mesa/main/mtypes.h
2009-12-27 15:31:08 -07:00
Brian Paul
da876fa3a5 docs: insert 7.6.1 release date 2009-12-27 15:14:25 -07:00
Brian Paul
b46bcd8e7b Merge branch 'mesa_7_7_branch' 2009-12-27 10:24:21 -07:00
Brian Paul
cb504a026c cell: add glsl to SRC_DIRS 2009-12-27 10:24:12 -07:00
Brian Paul
7831515e69 st/mesa: add missing case for PIPE_FORMAT_B8G8R8A8_UNORM 2009-12-27 10:09:24 -07:00
Dave Airlie
bdbabcd1e4 r300g: fix use of uninitialised variables.
These buffers were getting dereferenced later.
2009-12-27 16:13:41 +10:00
Dave Airlie
9ee5b78e7f r300g: rename modesetting_drv.so to radeong_drv.so 2009-12-27 16:13:16 +10:00
Vinson Lee
331e910b5c gallium/util: Remove comma at end of enumerator list. 2009-12-26 16:22:25 -08:00
Vinson Lee
3c2fd1bae0 rbug: Remove comma at end of enumerator list. 2009-12-26 16:18:47 -08:00
Vinson Lee
f8ca25e02f rbug: Remove comma at end of enumerator list. 2009-12-26 16:14:39 -08:00
Vinson Lee
fc11424bcd mesa: Remove comma at end of enumerator list. 2009-12-26 16:09:41 -08:00
Vinson Lee
309c156bae i915: Fix assert. 2009-12-26 15:55:38 -08:00
José Fonseca
4ccf0bb74e softpipe: Flush draw module when fragment pipeline state changes. 2009-12-26 21:06:46 +00:00
José Fonseca
080703e398 llvmpipe: Treat state changes systematically.
That is:
- check for no op
- update/flush draw module
- update bound state and mark it as dirty

In particular flushing the draw module is important since it may contain
unflushed primitives which would otherwise be draw with wrong state.
2009-12-26 21:06:46 +00:00
Eric Anholt
c4ac1f8299 i965: Extra asserts on flow control instructions to clarify for clang. 2009-12-26 11:18:02 -08:00
Eric Anholt
c196a3592a i965: Clean up double initialization of dst_flags from a rebase resolve.
Caught by clang.
2009-12-26 11:18:02 -08:00
Eric Anholt
070bbd4fcd i965: Fix setup of immediate types for gen4 disasm.
Caught by clang.
2009-12-26 11:18:02 -08:00
José Fonseca
d01c7bef29 llvmpipe: Use comments and more code from softpipe's is_texture_referenced implementation. 2009-12-26 11:02:02 +00:00
José Fonseca
7a15642f41 softpipe: Flush draw module before switching framebuffer.
Otherwise geometry might end up in the wrong rendertarget.
2009-12-26 11:01:05 +00:00
José Fonseca
491a184943 llvmpipe: Flush draw module before switching framebuffer.
Otherwise geometry will end up in the wrong rendertarget.
2009-12-26 11:00:42 +00:00
José Fonseca
399190d136 tgsi: Don't dump parenthesis for negation.
It doesn't seem necessary, and more importantly, tgsi_parse doesn't know
how to read them.
2009-12-26 10:59:46 +00:00
Vinson Lee
e81fe088f4 progs/demos: Silence warn_unused_result warnings. 2009-12-26 01:08:26 -08:00
Vinson Lee
cdc69e3469 progs/util: Silence warn_unused_result warnings. 2009-12-25 23:13:50 -08:00
Vinson Lee
cd59e6f553 intel: Silence implicit function declaration warning. 2009-12-25 22:34:35 -08:00
José Fonseca
230a5b5f1c python: Update python state tracker and samples for recent interface changes. 2009-12-26 01:14:59 +00:00
José Fonseca
3f176bf08c trace: Fix transfer size computation. 2009-12-26 01:14:08 +00:00
José Fonseca
8b7552673f scons: Put the configuration info in the build directory too.
It fixes cached configuration results from one platform being erroneously
used in other platforms.
2009-12-26 01:14:08 +00:00
José Fonseca
8353c87cce svga: Allow to dump an individual command. 2009-12-26 01:14:08 +00:00
Vinson Lee
67a4abcc3b glu/sgi: Fix include recursion.
arcsorter.h should not include itself.
2009-12-25 14:23:10 -08:00
Dave Airlie
5676082d28 r300g: fixup for GS additions
draw_set_mapped_constant_buffer changed API
2009-12-26 07:28:21 +10:00
Julien Cristau
36461f0d66 Delete some files not present in tarballs 2009-12-25 19:48:46 +01:00
Julien Cristau
5e20a66515 Bump changelogs 2009-12-25 17:06:27 +01:00
Julien Cristau
12251b4915 Merge remote branch 'upstream/mesa_7_7_branch' into debian-experimental
Conflicts:
	progs/tests/bug_texstore_i8.c
	progs/tests/crossbar.c
	progs/tests/cva.c
	progs/tests/fptest1.c
	progs/tests/invert.c
	progs/tests/packedpixels.c
	progs/tests/quads.c
	progs/tests/scissor-viewport.c
	progs/tests/scissor.c
	progs/tests/stencilwrap.c
	progs/tests/tex1d.c
	progs/tests/unfilledclip.c
	progs/tests/vpeval.c
	progs/trivial/clear-fbo-tex.c
	progs/trivial/createwin.c
	progs/trivial/dlist-begin-call-end.c
	progs/trivial/draw2arrays.c
	progs/trivial/drawarrays.c
	progs/trivial/tri-blend-max.c
	progs/trivial/tri-blend-min.c
	progs/trivial/tri-blend-revsub.c
	progs/trivial/tri-blend-sub.c
	progs/trivial/tri-blend.c
	progs/trivial/tri-fbo-tex.c
	progs/trivial/tri-fp.c
	progs/trivial/tri-logicop-none.c
	progs/trivial/tri-logicop-xor.c
	progs/trivial/tri-z.c
	progs/trivial/vbo-drawarrays.c
	progs/trivial/vbo-noninterleaved.c
	src/glut/glx/glut_menu.c
2009-12-25 16:25:56 +01:00
Julien Cristau
addd04c255 Don't include GLUT sources since we don't use them. 2009-12-25 16:19:26 +01:00
Julien Cristau
2596bd88d7 Add freedesktop.org ftp to watch file since that's where newer upstream tarballs are. 2009-12-25 16:13:38 +01:00
Zack Rusin
fb0a9aa5e0 gallium: remove TGSI_SEMANTIC_VERTICES
it's a leftover from an early version of geometry shading support.
geometry shaders now encode the primitive size in the PROPERTY token
and don't need special input with their size.
2009-12-25 05:52:20 -05:00
Zack Rusin
b0bc582db7 draw: disable some debugging output coming from the geometry shaders 2009-12-25 05:52:20 -05:00
Zack Rusin
519a6d308d gallium: geometry shader can be always enabled and we don't need a cap for that
using the draw module allows us to enable geometry shading even on hardware
that doesn't support it.
2009-12-25 05:52:20 -05:00
Zack Rusin
a00da63e66 util: put vertices_per_primitive function in its proper location 2009-12-25 05:52:19 -05:00
Zack Rusin
49155c3264 draw/tgsi: fix geometry shader input/output swizzling 2009-12-25 05:52:19 -05:00
Zack Rusin
afd01366b0 tgsi: dump the indices correctly when dealing with 2d arrays 2009-12-25 05:52:19 -05:00
Zack Rusin
960be012a9 tgsi: fix property parsing/building 2009-12-25 05:52:19 -05:00
Zack Rusin
e9c6f01a52 python: fix python state tracker after some latest changes 2009-12-25 05:52:18 -05:00
Zack Rusin
ac96ee1c16 softpipe: make it possible to dump geometry shader from the softpipe 2009-12-25 05:52:18 -05:00
Zack Rusin
22370990f2 tgsi: add missing support for two dimensional arrays in various places
in particular asm text parsing and sanity checking were missing code
to handle multi-dimensional arrays/geometry shaders
2009-12-25 05:52:18 -05:00
Zack Rusin
8a39f5dfdd python/gs: fix the example 2009-12-25 05:52:18 -05:00
Zack Rusin
f658fa5e8f gallium: add an inline that returns number of vertices per primitive 2009-12-25 05:52:18 -05:00
Zack Rusin
42eefb8235 softpipe/gs: don't crash with null shader 2009-12-25 05:52:17 -05:00
Zack Rusin
b0575151b6 gs: fix drivers so they work with geometry shaders 2009-12-25 05:52:17 -05:00
Zack Rusin
5aac920e49 tgsi: make the tgsi assembly parser report line/column on error 2009-12-25 05:52:17 -05:00
Zack Rusin
89d8577fb3 gallium: add geometry shader support to gallium 2009-12-25 05:52:16 -05:00
Vinson Lee
2447786ed0 i965: Fix assert. 2009-12-24 22:58:05 -08:00
Vinson Lee
f5ad1d0d02 i965: Add missing va_end. 2009-12-24 16:26:09 -08:00
Brian Paul
57cce7a409 mklib: put usage info into usage() function 2009-12-24 07:24:33 -07:00
Brian Paul
191d9651cd mklib: expand .a into .o files on FreeBSD, put common code into subroutines 2009-12-24 07:24:33 -07:00
Keith Whitwell
5f6dcf65e7 i965g: get trivial/tri working again after edgeflag changes 2009-12-24 12:53:07 +00:00
Keith Whitwell
6c30e17f9e i965g: strict aliasing changes 2009-12-24 12:53:06 +00:00
Keith Whitwell
e4069d07dd gallium/util: quieten compiler 2009-12-24 12:53:06 +00:00
Keith Whitwell
9546c3dbd2 i965g: calculate depth min/max
Previously hard-wired to 0..1
2009-12-24 12:53:06 +00:00
Christoph Bumiller
b7b2226a75 nv50: support TGSI_OPCODE_CONT 2009-12-24 13:36:54 +01:00
Christoph Bumiller
d29f55546d nv50: make edgeflags work
It doesn't seem to be possible to set the egdeflag in the
vertex shader, so we need to fallback to pushing vertices
through the FIFO and use method 0x15e4 if they are used.

This only works if VP does MOV OUT[X] IN[Y] where X is the
edgeflag output, and Y is saved so we can tell the correct
input later.

The VP still writes the useless values to wasted outputs
as punishment.
2009-12-24 12:48:00 +01:00
Corbin Simpson
54ddf642df docs: Add all semantics to TGSI doc, regen. 2009-12-23 23:36:06 -08:00
Vinson Lee
098f10c270 glsl: Initialize member a_obj of struct slang_operation. 2009-12-23 18:00:06 -08:00
Vinson Lee
261c3cd530 glu/sgi: Initialize variable in directedLine. 2009-12-23 17:50:02 -08:00
Vinson Lee
520955a0cd gallium/util: Initialize variable in util_clear. 2009-12-23 16:22:03 -08:00
Vinson Lee
6138145b35 glu/sgi: Silence compiler warnings. 2009-12-23 16:11:10 -08:00
Roland Scheidegger
1278507e3b gallium: adapt drivers to pipe_constant_buffer removal 2009-12-24 00:55:49 +01:00
Vinson Lee
51dcea2aac util: Ensure debug_dump_flags generates a null-terminated string. 2009-12-23 15:19:45 -08:00
Vinson Lee
2ea061509d st/xorg: Use C-style comments. 2009-12-23 14:52:06 -08:00
Vinson Lee
15ecd0337e st/vega: Move declaration outside for loop. 2009-12-23 14:43:53 -08:00
Vinson Lee
1b0ab3e3c9 st/egl: Use C-style comments. 2009-12-23 14:18:11 -08:00
Vinson Lee
6c8c1ce78b glx: Add XF86DRI[Open|Close]FullScreen prototypes to xf86dri.h. 2009-12-23 14:09:36 -08:00
Roland Scheidegger
e3be32ccf9 gallium: propagate draw retval changes into cell driver 2009-12-23 21:48:36 +01:00
Vinson Lee
cf3bb0cf31 glx: Move declaration outside for loop. 2009-12-23 12:42:38 -08:00
Roland Scheidegger
f44b0ff843 gallium: adapt state trackers etc. to pipe_constant_buffer removal 2009-12-23 20:44:06 +01:00
Roland Scheidegger
beb712ee9a gallium: API cleanup, remove pointless pipe_constant_buffer 2009-12-23 20:42:55 +01:00
Tom Fogal
f42c861f02 Regenerate gl_mangle.h.
Signed-off-by: Brian Paul <brianp@vmware.com>
2009-12-23 11:38:14 -07:00
Michal Krol
d0b55120be gallium: Add interfaces needed for instanced drawing. 2009-12-23 19:37:18 +01:00
José Fonseca
b5a408bae5 llvmpipe: Install unit tests on build/xxx/bin 2009-12-23 16:38:50 +00:00
José Fonseca
88b2d8f796 util: Define common dynamic library extensions. 2009-12-23 16:38:50 +00:00
Maarten Maathuis
8e8502bc63 gallium: only create pipe buffer when size is nonzero
- This fixes a crash upon starting spring (a rts engine/game).

Signed-off-by: Maarten Maathuis <madman2003@gmail.com>
2009-12-23 16:33:54 +00:00
Keith Whitwell
b2a615e3cd glsl/pp: move static functions out of header file 2009-12-23 16:10:37 +00:00
Keith Whitwell
cdd25ab8cf glsl/pp: quieten compiler about missing case statements 2009-12-23 16:10:37 +00:00
Tomas Carnecky
cc7a2d8e64 i965g: Rename {pf->util_format}_is_depth_or_stencil() 2009-12-23 16:58:53 +01:00
Roland Scheidegger
faae0e5da3 rbug: rename pf_is_compressed to util_format_is_compressed 2009-12-23 16:57:46 +01:00
Tomas Carnecky
315ca95666 [i965] Rename {pf -> util}_format_is_depth_or_stencil()
The function was moved and renamed in 0bed834b.

Signed-off-by: Tomas Carnecky <tom@dbservice.com>
2009-12-23 15:40:20 +00:00
Vinson Lee
0f6cbc55b7 progs/tests: Fix build.
(cherry picked from commit 1bf2d78b11)
2009-12-22 23:30:23 -08:00
Vinson Lee
57b5ca5d11 glu/sgi: Silence uninitialized variable warnings. 2009-12-22 23:07:00 -08:00
Vinson Lee
19a40524d3 Add gallium to darwin config. 2009-12-22 18:21:41 -08:00
Vinson Lee
aae32df718 xlib: Use C-style comments. 2009-12-22 17:51:58 -08:00
Vinson Lee
b20382d477 trace: Silence uninitialized variable warnings. 2009-12-22 17:34:39 -08:00
Vinson Lee
f6ca26e5a7 trace: Add PIPE_OS_APPLE. 2009-12-22 17:17:28 -08:00
Vinson Lee
6ce28a755c gallium/util: Add PIPE_OS_APPLE to u_stream_stdc.c. 2009-12-22 16:23:00 -08:00
Vinson Lee
5e73bcb396 gallium/util: Add PIPE_OS_APPLE to u_network. 2009-12-22 15:59:50 -08:00
Vinson Lee
fb8bff341e i915g: Use C-style comment. 2009-12-22 15:19:48 -08:00
Vinson Lee
cf02484fb6 glx: Compile dri2.c only if GLX_DIRECT_RENDERING is defined. 2009-12-22 14:51:12 -08:00
Vinson Lee
c1033299e8 ffb: Silence compiler warnings. 2009-12-22 14:28:40 -08:00
Eric Anholt
f677480389 intel: Replace some gen3 IS_* checks with context structure usage.
Shaves 400 bytes or so from i915_dri.so.
2009-12-22 14:20:27 -08:00
Eric Anholt
cb3810dd19 intel: Replace IS_965 checks with context structure usage.
Saves another 600 bytes or so of code.
2009-12-22 14:20:27 -08:00
Eric Anholt
0b87f143c4 intel: Replace IS_G4X() across the driver with context structure usage.
Saves ~2KB of code.
2009-12-22 14:20:26 -08:00
Eric Anholt
1c96e85c9d intel: Replace IS_IGDNG checks with intel->is_ironlake or needs_ff_sync.
Saves ~480 bytes of code.
2009-12-22 14:20:26 -08:00
Eric Anholt
b08ed4f595 mesa: Fix a NULL deref in glDeleteFragmentShaderATI(badname);
Fixes piglit ati-fs-bad-delete.  Caught by clang.
2009-12-22 14:20:26 -08:00
Eric Anholt
fbeceec97b mesa: remove unnecessary store. 2009-12-22 14:20:26 -08:00
Eric Anholt
6260d4a14c mesa: Remove an unnecessary store reported by clang.
This was a workaround for a compiler warning that was showing a real
error.  The real error was later fixed.
2009-12-22 14:20:26 -08:00
Eric Anholt
d85a6f70eb intel: Fix leakage of active texture state in glBitmap fp metaops.
Noticed by clang.
2009-12-22 14:20:26 -08:00
Eric Anholt
e3202a8cc7 i915: Fix use of uninitialized variable in OPCODE_NOISE stub.
We don't actually care which register is used since we're just
swizzling (0,0,0,0), but it should be a valid variable number.
Detected by clang.
2009-12-22 14:20:26 -08:00
Eric Anholt
d203dbc73d mesa: Replace CLAMP_SELF() macro with more obvious CLAMP() usage.
The same code is generated, and readers and static analyzers are
happier.
2009-12-22 14:20:26 -08:00
Eric Anholt
5727147f89 intel: Remove unused stored values reported by clang. 2009-12-22 14:20:26 -08:00
Eric Anholt
1a80fe461e mesa: Remove _mesa_exit wrapper for exit().
It does nothing else while being less useful than exit() because it lacks
attributes that real exit() has.
2009-12-22 14:20:26 -08:00
Brian Paul
ddd9729bc3 mesa: adjust OPCODE_IF/ELSE BranchTarget fields to point to ELSE/ENDIF instr.
This is a little more logical.  Suggested in bug report 25654.
2009-12-22 14:26:06 -07:00
Brian Paul
db721151b7 mesa: adjust BRK/CONT BranchTarget to always point to ENDLOOP instruction
To be more consistant.
2009-12-22 14:26:06 -07:00
Brian Paul
e8ea2d26cd mesa: added some assertions in BNGLOOP/ENDLOOP cases 2009-12-22 14:26:06 -07:00
Brian Paul
b5ddc7821a mesa: fix binary() function, printf format string
Need to use the constant 1ULL and 0xllx format string.  This fixes incorrect
results and a NULL pointer/parameter bug.
2009-12-22 13:33:40 -07:00
Roland Scheidegger
d186079520 i965g: fix for edgeflag changes (untested) 2009-12-22 21:26:51 +01:00
Roland Scheidegger
35e8283c69 Merge branch 'gallium-edgeflags'
Conflicts:
	src/mesa/state_tracker/st_draw.c
2009-12-22 20:54:26 +01:00
José Fonseca
00b463fc30 scons: Set the default windows platform to be windows userspace.
I thought I had done this ages ago.
2009-12-22 19:03:56 +00:00
Michal Krol
79bb3da4d3 tgsi: Implement BREAKC in interpreter. 2009-12-22 16:11:40 +01:00
Keith Whitwell
f069e45750 i965g: fix bo_reference 2009-12-22 09:57:16 +00:00
Keith Whitwell
96d63ebbf5 i965g: update for u_format changes 2009-12-22 09:52:26 +00:00
Keith Whitwell
aa02683e45 Merge branch 'i965g-restart'
Conflicts:
	configure.ac
2009-12-22 09:40:39 +00:00
Christoph Bumiller
ebbc73d1ae nv50: correct the negation of DDY sources
The state tracker now does the correct thing, so
interpret negation normally.
2009-12-22 10:14:45 +01:00
Vinson Lee
1bf2d78b11 progs/tests: Fix build. 2009-12-22 00:54:34 -08:00
Corbin Simpson
5bcd26c172 docs: Re-adjust headers for TGSI, regenerate. 2009-12-21 21:04:10 -08:00
Corbin Simpson
1a7b2f7e95 docs: Regenerate. 2009-12-21 20:33:18 -08:00
Corbin Simpson
da65ac6bba docs: Moar cleanup.
Good enough for now!
2009-12-21 20:32:46 -08:00
Corbin Simpson
ecb2f2a230 docs: \times.
Yay for sed.
2009-12-21 20:07:10 -08:00
Corbin Simpson
14743ac0e3 docs: abs, lg2, ceil. 2009-12-21 20:01:42 -08:00
Corbin Simpson
dd801e5c02 docs: Pow, sqrt. 2009-12-21 19:41:09 -08:00
Corbin Simpson
d92a685bc3 docs: Clean floor, sine, cosine. 2009-12-21 19:30:29 -08:00
Corbin Simpson
e8ed3b9607 docs: Start mathifying TGSI insts. 2009-12-21 19:12:55 -08:00
Ian Romanick
71678a7ede intel: Replace release info in DRIVER_DATE with "DEVELOPMENT" 2009-12-21 18:46:17 -08:00
Ian Romanick
a4b6b42885 Merge branch 'mesa_7_7_branch'
Conflicts:
	src/mesa/main/version.h
2009-12-21 18:45:31 -08:00
Ian Romanick
82184970d3 Add MD5 checksums for 7.6.1 release 2009-12-21 18:43:09 -08:00
Ian Romanick
e9b5ed1c13 Add MD5 checksums for 7.6.1 release 2009-12-21 18:32:32 -08:00
Ian Romanick
6ffed19993 Add MD5 checksums for 7.7 release 2009-12-21 18:30:35 -08:00
Ian Romanick
7e210b9337 mesa: set version string to 7.7 2009-12-21 18:28:32 -08:00
Ian Romanick
164b583852 intel: Bump driver date to reflect status as final Q4 driver RC 2009-12-21 18:27:50 -08:00
Ian Romanick
48302e9b30 Merge branch 'mesa_7_6_branch' into mesa_7_7_branch
Conflicts:
	scons/gallium.py
	scons/generic.py
	src/mesa/main/version.h
2009-12-21 18:27:24 -08:00
Ian Romanick
75ad099d3c mesa: set version string to 7.6.1 2009-12-21 18:25:30 -08:00
Brian Paul
ef17105134 glsl: assorted clean-ups in slang_compile.c 2009-12-21 19:14:41 -07:00
Vinson Lee
982acbddab progs/perf: Fix MSVC build.
(cherry picked from commit cbf46ed670)
2009-12-21 18:10:44 -08:00
Corbin Simpson
9ddeab48c8 More docs. Glossary. 2009-12-21 18:01:24 -08:00
Jeremy Huddleston
3839f6768d darwin: Build glsl
Signed-off-by: Jeremy Huddleston <jeremyhu@freedesktop.org>
2009-12-21 17:49:44 -08:00
Jeremy Huddleston
5bbdc7f420 osmesa: Fix a copy/paste error in building libOSMesa
Signed-off-by: Jeremy Huddleston <jeremyhu@freedesktop.org>
2009-12-21 17:49:43 -08:00
Brian Paul
9eb7fc6661 Merge branch 'mesa_7_7_branch'
Conflicts:
	src/mesa/main/version.h
	src/mesa/state_tracker/st_atom_shader.c
2009-12-21 18:35:54 -07:00
Brian Paul
b57abd3bea Merge branch 'mesa_7_6_branch' into mesa_7_7_branch
Conflicts:
	configure.ac
	progs/demos/morph3d.c
	progs/demos/textures.c
	progs/glsl/shtest.c
	progs/glsl/texaaline.c
	progs/tests/packedpixels.c
	progs/xdemos/corender.c
	src/mesa/main/version.h
2009-12-21 18:23:53 -07:00
Fabio Pedretti
bf064ce0c3 configure.ac: fix for libdrm_radeon API changes. 2009-12-22 10:44:53 +10:00
Fabio Pedretti
ae1c0a06e8 configure.ac: fix for libdrm_radeon API changes. 2009-12-22 10:43:35 +10:00
Dave Airlie
bd9e0ebaff radeon/r600: use new libdrm_radeon api 2009-12-22 10:25:47 +10:00
Dave Airlie
bce03f7174 radeon: drop assert accessing cref which is meant to be hidden 2009-12-22 10:25:05 +10:00
Dave Airlie
34671efa29 radeon: drop unused members of radeon_state. 2009-12-22 10:24:57 +10:00
Dave Airlie
e77bfc436d r600: move structs for legacy cmdbuf into cmdbuf C file.
these really shouldn't be exposed here
2009-12-22 10:24:47 +10:00
Keith Whitwell
f3347fe397 gallium/docs: extend the context docs a little 2009-12-21 23:44:32 +00:00
Keith Whitwell
14eacb041b docs: remove some old opcodes and other cruft from tgsi doc 2009-12-21 23:38:29 +00:00
Keith Whitwell
a62aaa7399 docs: pull in tgsi-instruction-set.txt verbatim 2009-12-21 23:25:15 +00:00
Keith Whitwell
03f212b0d8 gallium: propogate draw retval changes into more drivers 2009-12-21 22:55:40 +00:00
Keith Whitwell
09e785ee04 gallium: remove return value from draw calls 2009-12-21 22:14:35 +00:00
Brian Paul
fdae39c289 progs/perf: added check for GL_ARB_framebuffer_object 2009-12-21 13:49:25 -07:00
Brian Paul
79e74cda73 progs/demos: report pixel rate in million pixels / sec 2009-12-21 13:49:25 -07:00
Brian Paul
bd5fbcf92b osmesa: added new GLSL libs 2009-12-21 13:37:49 -07:00
Brian Paul
d26cdaaa23 progs/osmes: add missing libGL dependency, remove unneeded lines 2009-12-21 13:37:11 -07:00
Keith Whitwell
0fc4dd3819 i965g: fixes to build after merge of master 2009-12-21 19:50:05 +00:00
Keith Whitwell
f72de22439 i965g: remove half-finished change to tgsi_parse 2009-12-21 19:22:45 +00:00
Keith Whitwell
57531baa92 i965g: back out unintentional changes to linux-dri 2009-12-21 19:21:09 +00:00
Keith Whitwell
66e779c22b i965g: back out unintentional changes to gears 2009-12-21 19:19:01 +00:00
Keith Whitwell
a5585cb533 Merge commit 'origin/master' into i965g-restart
Conflicts:
	SConstruct
	configs/default
	configs/linux-dri
2009-12-21 19:18:41 +00:00
Christoph Bumiller
c020a83fae util: draw cube mipmaps with TEX CUBE 2009-12-21 19:04:06 +00:00
Roland Scheidegger
8f1d2ab590 python: fix some pipe_format_simplify merge damage 2009-12-21 18:20:31 +01:00
Roland Scheidegger
ba25137655 svga: fix typo 2009-12-21 18:20:01 +01:00
Keith Whitwell
d288a30610 ws/i965: respect DEBUG_WINSYS flag 2009-12-21 16:58:14 +00:00
Keith Whitwell
061411b261 i965g: hook vertex state emit up to PIPE_NEW_VERTEX_BUFFER 2009-12-21 16:57:37 +00:00
Keith Whitwell
1ec7e058f5 i965g: keep refcounts to bound vertex buffers 2009-12-21 16:56:46 +00:00
Keith Whitwell
6c719d4c22 i965g: add DEBUG_WINSYS flag 2009-12-21 16:55:40 +00:00
Keith Whitwell
f217927a57 i965g: remove duplicate set_viewport_state, fixes samples/depth 2009-12-21 15:38:08 +00:00
Andre Maasikas
764899d7ab r600: support more of arb_point_sprite and also sprite_coord_origin 2009-12-21 15:23:37 +02:00
Andre Maasikas
69728a2ae2 r600: disallow negative offsets for relative addressing for now
otherwise for example const[ADDR-3] gets us 253 - ALU_SRC_LITERAL which
expects immediate floats to follow and hangs
2009-12-21 15:23:27 +02:00
Michal Krol
3d3480abbc vega: Add missing actual argument. 2009-12-21 11:58:17 +01:00
Jeremy Huddleston
ad7f9d71e2 darwin: mklib: Use lipo rather than file to figure out architectures of object files 2009-12-20 21:34:27 -08:00
Jeremy Huddleston
4a1e103858 darwin: Cleanup CPPFLAGS a bit 2009-12-20 21:32:35 -08:00
Corbin Simpson
c083fa9bba Regen docs. 2009-12-20 19:42:03 -08:00
Corbin Simpson
a524aab8ae Moar docs, mostly context. 2009-12-20 19:41:50 -08:00
Corbin Simpson
9f936f2001 Regenerate docs. 2009-12-20 17:25:44 -08:00
Corbin Simpson
fa33812d47 Document rasterizer. 2009-12-20 17:25:36 -08:00
Corbin Simpson
c80f2b04e0 Fill out some of the CSO info.
...And looks like there's already things I don't know. Go figure.
2009-12-20 16:40:39 -08:00
Dave Airlie
393857a2f5 r600: fix glFrontFace(GL_CW)
fd.o bug #25290

Suggested fix from Rafael Monica
2009-12-21 10:21:28 +10:00
Corbin Simpson
32d737397c r300g: Add a few more params. 2009-12-20 15:47:48 -08:00
Corbin Simpson
8283e200af Add screen and context to docs. 2009-12-20 15:28:00 -08:00
Dave Airlie
55c43ee315 glsl: make stack compile.
it would be nice if this stuff would be test built on mesa's primary
platform with mesa's primary build system.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-12-21 09:10:21 +10:00
Corbin Simpson
a8df5cad9d Add a compiled HTML doctree. 2009-12-20 15:02:33 -08:00
Corbin Simpson
c686e17e52 Add Gallium docs.
In Sphinx/ReST format.
2009-12-20 15:00:40 -08:00
Dave Airlie
b065aec840 radeon/r600: use new libdrm_radeon api 2009-12-21 08:09:11 +10:00
Corbin Simpson
65ecbdd49c r300g: Add a few more params. 2009-12-20 14:00:34 -08:00
Michal Krol
1071ad70f5 glsl/apps: Update after glsl cl interface changes. 2009-12-20 21:19:10 +01:00
Michal Krol
1cc9610f88 slang: Update after glsl cl interface changes. 2009-12-20 21:19:09 +01:00
Michal Krol
d801c296c6 glsl: Do syntax parsing inline with processing. 2009-12-20 21:19:07 +01:00
Michal Krol
5fb345c422 slang: Add gitignore for autogenerated files. 2009-12-20 21:19:06 +01:00
Michal Krol
ec73cd011d slang: Update after glsl pp changes. 2009-12-20 21:19:05 +01:00
Michal Krol
9c15948125 glsl/apps: Update after glsl pp interface changes. 2009-12-20 21:19:03 +01:00
Michal Krol
e0f57a37b2 glsl/apps: Do not print number of eaten tokens in version.
This is due to the glsl pp interface changes.
2009-12-20 21:19:02 +01:00
Michal Krol
0874ce48a6 glsl/apps: Print error line number in compile. 2009-12-20 21:19:01 +01:00
Michal Krol
d696cb279d glsl/pp: Do processing inline with tokenisation. 2009-12-20 21:18:59 +01:00
Michal Krol
7631dca25b glsl/pp: Remove outdated TODO.
Already implemented in mesa compiler using predefined symbols.
2009-12-20 21:18:58 +01:00
Michal Krol
e9aa65d2b7 glsl/pp: Report correct error line for purify and tokeniser errors. 2009-12-20 21:18:57 +01:00
Christoph Bumiller
a6e663def4 util: util_format_get_blocksizebits() returns bits per block. 2009-12-20 19:09:35 +01:00
Christoph Bumiller
b3ac75f7eb nv50: make address reg allocation a little less hacky
Before I tried to distinguish int +0 and -0, and regs
relative to $a1 would have been considered reserved
for TGSI.
This would probably never occur, let it be fixed even so.
2009-12-20 14:15:51 +01:00
Christoph Bumiller
2ed083dda9 nv50: use BREAKADDR and BREAK for loops
This is easier, we don't have to record all the BRK branches
to fill in the address at ENDLOOP - which wasn't done before
and thus made all but the last BRK branch jump to the start.

Also, we don't risk reactivting threads that already left
the loop if we join threads after a conditional with a BRK
(although it might be wiser to remove the join altogether
in such cases).
2009-12-20 14:15:51 +01:00
Christoph Bumiller
3c7f109d67 nv50: handle TGSI_OPCODE_RET,KILP 2009-12-20 14:15:51 +01:00
Marek Olšák
6ba83cd63f r300g: add texture compare modes 2009-12-19 23:54:53 -08:00
Roland Scheidegger
420ff89067 gallium: don't use edgeflags if the app didn't supply them 2009-12-19 20:25:43 +01:00
Roland Scheidegger
1aba413a70 gallium: fix not generating new vp varient when polygon mode changes 2009-12-19 17:12:14 +01:00
Maciej Cencora
4b6dee0865 r300: minor blit rework
Use vert/tex coords instead of byte offsets for specyfing src/dst image offsets.
This will allow for blitting between tiled/untiled buffers.
2009-12-19 14:43:08 +01:00
Maciej Cencora
a1428868a6 r300: better fix for glCopyTexSubImage 2009-12-19 14:43:08 +01:00
Corbin Simpson
759fd1f25f r300g: Fix provoking vertex for non-quads.
Read the comments. In short, we can't possibly pass piglit's
glean/clipFlat without some help from Gallium and an API/spec change.
2009-12-18 21:50:45 -08:00
Corbin Simpson
f13a904c34 r300g: Respect provoking vertex for trifans.
Fixes part of piglit's clipFlat test; next up is to get quads right.
2009-12-18 19:49:14 -08:00
Roland Scheidegger
429f0e3b37 gallium: fix up drivers for edgeflag changes
several drivers which chose to ignore edgeflags might require some more work,
while edgeflags never worked there they might now crash.
2009-12-19 00:18:43 +01:00
Roland Scheidegger
ff5b0c72db gallium: store edgflag info in tgsi_shader_info
provides easier access for drivers which may base fallback decision on this
2009-12-18 23:53:25 +01:00
Corbin Simpson
bf611cef29 r300g: Eliminate a couple more asserts. 2009-12-18 14:07:12 -08:00
Corbin Simpson
62afcbb233 r300g: Nuke r300_vbo. 2009-12-18 14:07:12 -08:00
Brian Paul
263f4322e7 progs/demos: fix glut initialization calls
Remove glutInitWindowPosition() calls to play nicer with window managers.

Move glutInitWindowSize() calls before glutInit() so the the default window
size can be overridden by the -geometry cmd line option.
2009-12-18 13:58:14 -07:00
Brian Paul
6a7b6a530d llvmpipe: added linux-llvm-debug configuration 2009-12-18 11:17:06 -07:00
Brian Paul
04794080d2 llvmpipe: change configs/linux-llvm from debug build to optimized build
Basically equivalent to the SCons non-debug build now.
2009-12-18 11:13:06 -07:00
Alex Deucher
c8de081dc1 radeon: protect fbo allocation message with debug
fixes fdo bug 25708

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
2009-12-18 10:57:37 -05:00
Roland Scheidegger
9d938e29f2 fix debug output mising from edgeflag changes 2009-12-18 16:09:32 +01:00
Roland Scheidegger
890809d71b gallium: fix mesa to tgsi translation for edgeflags
test apps (progs/trivial/tri-edgeflags and similar) seem to work now
2009-12-18 15:54:28 +01:00
Michal Krol
c35e5c19e7 util: Add util_format_has_alpha(), enclose in extern C. 2009-12-18 14:15:21 +01:00
Michal Krol
b1580a1623 util/pack: Handle the remaining formats with generic u_format access functions. 2009-12-18 13:06:10 +01:00
Corbin Simpson
f874da422b util: Update blitter for u_format changes.
:T
2009-12-18 03:20:19 -08:00
Corbin Simpson
a70eba5648 Revert "r300g: flush CS if a buffer being deleted is referenced by it"
As requested by just about everybody. I'm going back to actually reading
patches before ACKing and pushing them.

This reverts commit 417ce06306.

Conflicts:

	src/gallium/winsys/drm/radeon/core/radeon_buffer.c
2009-12-18 02:55:28 -08:00
Michal Krol
7855fcb63b Merge branch 'pipe-format-simplify' 2009-12-18 09:08:26 +01:00
Richard Li
465333ab70 r600 : enable gl2, set R600_ENABLE_GLSL_TEST by default. 2009-12-18 00:23:04 -05:00
Dave Airlie
112908c279 radeon: fix frontbuffer read/drawpixels
Bug 25699

The main problem was the optimising flush wasn't doing the front
rendering checks properly.
2009-12-18 14:35:03 +10:00
Dave Airlie
5f59e79f3a r300g: store own copy of flush_cb and flush data.
don't go sneaking around inside the libdrm copy.
2009-12-18 10:24:50 +10:00
Michal Krol
b1ed72ebe2 Move the remaining format pf_get_* functions to u_format.h.
Previously they depended on format blocks, but after removing those
they started depending on format encoding.
2009-12-17 23:41:57 +01:00
Michal Krol
ec5577a83d util: Remove util_format_get_block(). 2009-12-17 22:39:03 +01:00
Michal Krol
16c6dce013 Merge branch 'master' into pipe-format-simplify
Conflicts:
	src/gallium/auxiliary/draw/draw_pipe_aaline.c
	src/gallium/auxiliary/draw/draw_pipe_pstipple.c
	src/gallium/auxiliary/util/u_blit.c
	src/gallium/auxiliary/util/u_gen_mipmap.c
	src/gallium/auxiliary/util/u_surface.c
	src/gallium/auxiliary/vl/vl_mpeg12_mc_renderer.c
	src/gallium/drivers/cell/ppu/cell_texture.c
	src/gallium/drivers/llvmpipe/lp_texture.c
	src/gallium/drivers/r300/r300_emit.c
	src/gallium/drivers/r300/r300_texture.c
	src/gallium/drivers/softpipe/sp_texture.c
	src/gallium/drivers/softpipe/sp_tile_cache.c
	src/gallium/drivers/svga/svga_state_vs.c
	src/gallium/include/pipe/p_format.h
	src/gallium/state_trackers/dri/dri_drawable.c
	src/gallium/state_trackers/egl/egl_surface.c
	src/gallium/state_trackers/python/p_device.i
	src/gallium/state_trackers/python/st_softpipe_winsys.c
	src/gallium/state_trackers/vega/api_filters.c
	src/gallium/state_trackers/vega/image.c
	src/gallium/state_trackers/vega/mask.c
	src/gallium/state_trackers/vega/paint.c
	src/gallium/state_trackers/vega/renderer.c
	src/gallium/state_trackers/vega/vg_tracker.c
	src/gallium/state_trackers/xorg/xorg_crtc.c
	src/gallium/state_trackers/xorg/xorg_dri2.c
	src/gallium/state_trackers/xorg/xorg_exa.c
	src/gallium/state_trackers/xorg/xorg_renderer.c
	src/gallium/state_trackers/xorg/xorg_xv.c
	src/gallium/state_trackers/xorg/xvmc/surface.c
	src/gallium/winsys/drm/nouveau/drm/nouveau_drm_api.c
	src/gallium/winsys/drm/radeon/core/radeon_buffer.c
	src/gallium/winsys/egl_xlib/sw_winsys.c
	src/gallium/winsys/g3dvl/xlib/xsp_winsys.c
	src/gallium/winsys/gdi/gdi_llvmpipe_winsys.c
	src/gallium/winsys/gdi/gdi_softpipe_winsys.c
	src/gallium/winsys/xlib/xlib_cell.c
	src/gallium/winsys/xlib/xlib_llvmpipe.c
	src/gallium/winsys/xlib/xlib_softpipe.c
	src/mesa/state_tracker/st_cb_fbo.c
	src/mesa/state_tracker/st_cb_texture.c
	src/mesa/state_tracker/st_texture.c
2009-12-17 22:37:15 +01:00
Brian Paul
aeb6351a09 llvmpipe: fix upper/lower-case typo 2009-12-17 14:26:48 -07:00
Brian Paul
7d9b97703a llvmpipe: added function comments 2009-12-17 14:22:43 -07:00
Michal Krol
440fc5bf78 util/format: Fix bogus assertion. 2009-12-17 21:57:24 +01:00
Michal Krol
3af2ddbe94 s/desc->type/desc->channel[0].type/ 2009-12-17 21:25:47 +01:00
Sedat Dilek
294bd53d4b glsl/apps: Add dummy install target to fix 'make install'
Signed-off-by: Brian Paul <brianp@vmware.com>
2009-12-17 12:46:55 -07:00
Sedat Dilek
2f127e5236 configure.ac: Add glsl to SRC_DIRS
Signed-off-by: Brian Paul <brianp@vmware.com>
2009-12-17 12:46:55 -07:00
Brian Paul
5771f3d483 llvmpipe: remove unused code, added comments, etc 2009-12-17 10:52:50 -07:00
Brian Paul
808170a0ff llvmpipe: replace INT_MIN/2 with INT_MIN
Since changing the in/out test we can just use INT_MIN to be sure the
comparison against the step values always passes.
2009-12-17 09:01:01 -07:00
Michal Krol
e195eab909 Merge branch 'glsl-pp-rework-2' 2009-12-17 17:00:46 +01:00
Brian Paul
b9d33db0a4 llvmpipe: improve the in/out test a little
Instead of:
  s = c + step
  m = s > 0
Do:
  m = step > c  (with negated c)
2009-12-17 08:17:04 -07:00
Keith Whitwell
7f2ba80025 llvmpipe: keep copy of framebuffer state in setup context
Avoids crashes when first frame is rendered before window is mapped.
Avoids potential issue where fb state is changed before setup context is
flushed.
2009-12-17 11:29:37 +00:00
Dave Airlie
1c28073fdf radeon: drop assert accessing cref which is meant to be hidden 2009-12-17 14:23:53 +10:00
Dave Airlie
5484f9dfc6 radeon: drop unused members of radeon_state. 2009-12-17 14:23:47 +10:00
Dave Airlie
f24c29cc39 r600: move structs for legacy cmdbuf into cmdbuf C file.
these really shouldn't be exposed here
2009-12-17 14:23:08 +10:00
Brian Paul
ab94381930 llvmpipe: do final the pixel in/out triangle test in the fragment shader
The test to determine which of the pixels in a 2x2 quad is now done in
the fragment shader rather than in the calling C code.  This is a little
faster but there's a few more things to do.

Note that the step[] array elements are in a different order now.  Rather
than being in row-major order for the 4x4 grid, they're in "quad-major"
order.  The setup of the step arrays is a little more complicated now.
So is the course/intermediate tile test code, but some lookup tables
help with that.

Next steps:
 - early-cull 2x2 quads which are totally outside the triangle.
 - skip the in/out test for fully contained quads
 - make the in/out comparison code tighter/faster.
2009-12-16 16:10:05 -07:00
Roland Scheidegger
50caff5675 gallium: edgeflags change fixes
use correct number of vertex inputs
fix not running pipeline in case of edgeflags
changes to mesa to tgsi translation still very broken
2009-12-16 22:12:16 +01:00
Brian Paul
e288796c92 llvmpipe: added lp_build_int32_vec4_type() 2009-12-16 12:33:11 -07:00
Brian Paul
2297bc9233 llvmpipe: refactor lp_build_cmp() to use lp_build_compare() 2009-12-16 12:32:45 -07:00
Richard Li
09cef45393 r600 : clean a bit to prepare to enable gl2. 2009-12-16 11:41:37 -05:00
José Fonseca
2584c5bd25 llvmpipe: add LP_DEBUG env var
Cherry-picked from dec35d04ae.
2009-12-16 15:06:17 +00:00
Brian Paul
f1f49bd465 llvmpipe: fix broken TGSI_OPCODE_FRC codegen 2009-12-16 15:06:17 +00:00
Brian Paul
43d6c81ae2 llvmpipe: fix broken lp_build_abs() 2009-12-16 15:06:16 +00:00
Marek Olšák
2ddee2cfbc r300g: fix emission of which textures are enabled
It fixes most of the "Bad CS" issues in piglit/texCombine and piglit/fbo.
Some other issues of this kind will get fixed in the kernel soon (depth-only
rendering, S3TC, and RGTC).
2009-12-15 19:04:46 -08:00
Marek Olšák
ded4ecde60 r300g: clean up the invariant state 2009-12-15 19:04:46 -08:00
Marek Olšák
acce4824ec r300g: clamp vertex indices to [min,max] everywhere 2009-12-15 19:04:46 -08:00
Marek Olšák
a6d701d1c6 r300g: if no colorbuffers are set, disable blending and set the color mask to 0
This seems to be the only way to disable the first colorbuffer.
2009-12-15 19:04:46 -08:00
Marek Olšák
cf85bf9cd0 r300g: set the number of colorbuffers in RB3D_CCTL 2009-12-15 19:04:46 -08:00
Marek Olšák
de0befc4b2 r300g: remove unnecessary flush in set_sampler_textures 2009-12-15 19:04:45 -08:00
Marek Olšák
c5e0b0bc37 r300g: add Z24X8 to the list of unsupported sampler formats on R3xx-R4xx 2009-12-15 19:04:45 -08:00
Marek Olšák
38a97148bf r300g: add acceleration of the clear, surface_copy, and surface_fill functions 2009-12-15 19:04:45 -08:00
Marek Olšák
417ce06306 r300g: flush CS if a buffer being deleted is referenced by it 2009-12-15 19:04:45 -08:00
Michel Dänzer
bc443d841c r300: Fix typo on < R5xx RS setup for blits. 2009-12-16 00:51:55 +01:00
Brian Paul
cdbcd96fdf llvmpipe: tighten up an assertion 2009-12-15 15:39:48 -07:00
Marek Olšák
80e8156394 util/blitter: kill the draw_quad callback 2009-12-15 18:00:48 +00:00
Marek Olšák
85bf420a78 util/blitter: allocate most of the state objects on-demand 2009-12-15 18:00:48 +00:00
Marek Olšák
ab85ba30e2 util/blitter: use PIPE_MAX_* limits, and fix a memory leak 2009-12-15 18:00:48 +00:00
Marek Olšák
e1d0f47808 pipe: add PIPE_MAX_TEXTURE_TYPES 2009-12-15 18:00:39 +00:00
Marek Olšák
55753f59ae util: add blitter 2009-12-15 18:00:30 +00:00
Marek Olšák
4c61022b4a util: add a function which converts 2D coordinates to cubemap coordinates
The code was taken over from u_gen_mipmap.
2009-12-15 17:59:54 +00:00
Marek Olšák
dff4c9ed55 util: add new fragment shaders to simple_shaders
New shaders:
* Fragment shader which writes depth sampled from a texture
* Fragment shader which copies COLOR[0] to multiple render targets

Additional improvements:
* The fragment 'tex' shaders now take a sampler type (TGSI_TEXTURE_*)
  so that they can sample from any type of texture, not only from a 2D one.
2009-12-15 17:59:50 +00:00
Brian Paul
276b8523e8 llvmpipe: use 1ULL to be ready for 64-bit arithmetic someday 2009-12-15 07:58:37 -07:00
José Fonseca
3a15c48ece llvmpipe: Fix yet another copynpaste typo in lp_build_log2_approx.
Now fslight looks perfect.
2009-12-15 14:46:43 +00:00
José Fonseca
85c27c3ef7 llvmpipe: Fix lp_build_polynomial comment. 2009-12-15 14:15:52 +00:00
José Fonseca
72c9878069 llvmpipe: Fix typo in lp_build_log constant. 2009-12-15 13:58:53 +00:00
José Fonseca
079b1cf4cf util: Fix unity value for swizzle 1.
It should be 255 for ubytes, and not 1.

Thanks Michal for spotting this.
2009-12-15 13:40:13 +00:00
José Fonseca
846e38f1c3 llvmpipe: Fix bad SI -> FP conversion into lp_build_log2_approx.
It should be a bitcast  as the integer value is actually an encoded FP
already.
2009-12-15 13:15:16 +00:00
José Fonseca
d508bf862b util: Add dl wrappers.
Borrowed from Mesa, slightly changed for more type safety.
2009-12-15 13:15:16 +00:00
Michal Krol
c1efa45e04 tgsi/text: Don't use strncasecmp(), it breaks windows build.
Also, break out of the for-loop when a matching property is found.
2009-12-15 13:54:05 +01:00
Andre Maasikas
f8135d545b r600: use _mesa_insert_instructions to fixup wpos instead of manual ins insert
this keeps branch targets correct.
glsl/trirast works correctly now afaics
2009-12-15 12:08:55 +02:00
Andre Maasikas
dbc374cd30 r600: fix typos for vert-tex
at least i think this is how it was meant to work
2009-12-15 10:26:37 +02:00
Andre Maasikas
bae5e7f213 r600: fix fragment.position
wpos.y seems inferted to what opengl expexts, so calculate correct
value from window dimension and replace references in fragmentprog
with calculated value
2009-12-15 09:46:57 +02:00
Andre Maasikas
10f5cff6ac r600: add support for FRAG_ATTRIB_PNTC 2009-12-15 09:46:49 +02:00
Andre Maasikas
0c046bec8f r600: add DDX DDY opcodes 2009-12-15 09:46:34 +02:00
Richard Li
18ebcfe393 r600 : add texture support for vertex shader. 2009-12-14 18:08:40 -05:00
Brian Paul
55879440d7 llvmpipe: fix broken TGSI_OPCODE_FRC codegen 2009-12-14 15:27:35 -07:00
Brian Paul
6e2a93739e llvmpipe: fix broken lp_build_abs() 2009-12-14 15:24:31 -07:00
Zack Rusin
3ff688ea29 tgsi: add properties and system value register
adds support for properties to all parts of the tgsi framework, plus
introduces a new register which will be used for system generated
values.
2009-12-14 16:35:09 -05:00
Brian Paul
b06b3a4925 llvmpipe: update file list in Makefile 2009-12-14 11:49:23 -07:00
Maarten Maathuis
41b52aa336 nouveau: avoid running out of relocs
- Added flush notify functions for NV30 and NV40.
- Flushing mid frame will call flush notify, which will resubmit all
relocs.
- We don't try to recover from reloc failure yet.
2009-12-14 19:31:54 +01:00
Christoph Bumiller
2677f199a5 nv50: be more cautious about using reg_instance
Trying to free part of nv50_pc->reg_instances[] for an
nv50_reg representing an indirect constant resulted in
a segmentation fault.
2009-12-14 18:39:13 +01:00
Roland Scheidegger
a0127b6ced gallium: more work for edgeflags changes
fixes, cleanups, etc.
not working yet
2009-12-14 18:36:33 +01:00
Michal Krol
c14be63c56 tgsi/ureg: Add ureg_DECL_gs_input().
Allows one to declare GS input registers.
2009-12-14 17:29:58 +01:00
Christoph Bumiller
1778ddaf74 nv50: store immediates as uint32
Sometimes we want non-float immediates, hacking them into
floats isn't nice.

Sorry, this should have already been committed before.
2009-12-14 11:12:59 +01:00
Brice Goglin
35994294ea Bump libdrm build dependency to 2.4.15 2009-12-14 09:20:38 +01:00
Patrice Mandin
d4d880199e nouveau: nv50: Add missing ctor_immd_4u32 function 2009-12-13 20:09:33 +01:00
Keith Whitwell
663750d556 llvmpipe: rename bins to scene
It was pretty confusing having an entity named "bin" and another named
"bins", not least because sometimes there was a need to talk about >1
of the "bins" objects, which couldn't be pluralized any further...

Scene is a term used in a bunch of places to talk about what a binner
operates on, so it's a decent choice here.
2009-12-13 18:17:25 +00:00
Maciej Cencora
e76bb2f337 r300: enable accelerated support for glCopyTexImage only under KMS 2009-12-13 17:22:33 +01:00
Maciej Cencora
8403df33e0 r300: fix regression introduced by da73c1ed
The 0 value is correct for I8 format.
2009-12-13 17:20:11 +01:00
Maciej Cencora
9d8501bf27 r300: fix glCopyTexSubImage
Need to properly setup colorbuffer when dst pitch != dst width.
2009-12-13 17:20:11 +01:00
Christoph Bumiller
079b670111 nv50: add proper zslice offset in miptree_surface 2009-12-13 14:39:19 +01:00
Christoph Bumiller
7b5a6fa0c8 nv50: use m2mf z pos instead of calculating offset manually 2009-12-13 14:39:19 +01:00
Christoph Bumiller
44d8c9add2 nv50: add craziness for non-constant TXB and TXL
If lod or bias can be non-constant across a quad of fragments,
we need to execute TEX separately for each value.
Don't ask why.
2009-12-13 14:39:19 +01:00
Patrice Mandin
b91503f457 Revert "nouveau: nv30: Disable swizzled surface usage if any dimension is 1 (Warsow creates a 1x1 front buffer)"
This reverts commit ec7844537e.
2009-12-12 23:15:08 +01:00
Patrice Mandin
ec7844537e nouveau: nv30: Disable swizzled surface usage if any dimension is 1 (Warsow creates a 1x1 front buffer) 2009-12-12 22:31:53 +01:00
Keith Whitwell
39dd7108bf llvmpipe: rename queue size to count 2009-12-12 20:29:39 +00:00
Keith Whitwell
314d3cd751 llvmpipe: rename one of the two rasterize_bins functions 2009-12-12 20:19:46 +00:00
Michal Krol
75f371e973 Remove grammar module -- no dependencies left. 2009-12-12 16:58:43 +01:00
Michal Krol
a3b32934c8 slang: Delete a file that is now autogenerated.
This file has been modified in master and removed in feature branch.
This gave a merge conflict I couldn't resolve by removing and git adding
it to index.
2009-12-12 16:49:26 +01:00
Michal Krol
a3eb0f718e Merge branch 'master' into glsl-pp-rework-2
Conflicts:
	progs/perf/drawoverhead.c
	progs/perf/teximage.c
	progs/perf/vbo.c
	progs/perf/vertexrate.c
	src/mesa/shader/slang/library/slang_common_builtin_gc.h
2009-12-12 16:48:32 +01:00
Christoph Bumiller
d80778218d nv50: support TXB and TXL
... and don't set the 'live' flag for TEX anymore, we'd
have to know if results affect the inputs for another TEX,
and I'm not going to do that kind of analysis now.
2009-12-12 16:39:00 +01:00
Christoph Bumiller
b0036f391a nv50: add S8Z24 depth texture format too 2009-12-12 16:38:59 +01:00
Christoph Bumiller
cc0ffaba7d nv50: fix depth comparison func TSC bits
Unfortunately it seems that if depth comparison is
active and we read a 2D texture, i.e. provide only
2 inputs, the second is used for comparison ...
2009-12-12 16:38:59 +01:00
Christoph Bumiller
6a689783b9 nv50: add src_mask case for IF opcode 2009-12-12 16:38:59 +01:00
Christoph Bumiller
9f3644c423 nv50: plug memory leak in miptree creation/destruction
Keeping this dynamically allocated for texture arrays.
Since we don't use it to store zslice offsets anymore
it's either 1 or 6 integers (cube) ...
2009-12-12 16:38:59 +01:00
Christoph Bumiller
f7a9734492 nv50: use copies of tgsi src nv50_regs
So we can use the 'mod' member without concern
if a source is used multiple times in 1 insn.
2009-12-12 16:38:59 +01:00
Christoph Bumiller
6a15ec9141 nv50: support vertex program textures 2009-12-12 16:38:59 +01:00
Brice Goglin
bb1193ca83 Prepare Changelog for upload 2009-12-12 13:03:07 +01:00
Brice Goglin
14cc33508c Do not build s3v and trident anymore 2009-12-12 13:02:44 +01:00
Brice Goglin
890a0f155f New upstream release candidate 2009-12-12 12:35:13 +01:00
Brice Goglin
6640b46db9 Merge branch 'upstream-experimental' into debian-experimental
Conflicts:
	doxygen/gallium.doc
	progs/egl/demo1.c
	progs/egl/demo2.c
	progs/egl/demo3.c
	progs/egl/eglgears.c
	progs/egl/eglinfo.c
	progs/slang/cltest.c
	progs/slang/vstest.c
	progs/tests/arbgpuprog.c
	progs/tests/getprocaddress.c
	progs/tests/getteximage.c
	progs/tests/mipmap_limits.c
	progs/tests/packedpixels.c
	progs/tests/sharedtex.c
	progs/tests/texcmp.c
	progs/tests/texcomp_image.h
	progs/tests/texcompsub.c
	progs/tests/zreaddraw.c
	scons/crossmingw.py
	scons/dxsdk.py
	scons/gallium.py
	scons/generic.py
	scons/llvm.py
	scons/winddk.py
	src/gallium/state_trackers/xorg/xvmc/tests/.gitignore
	src/gallium/state_trackers/xorg/xvmc/tests/test_context.c
	src/gallium/state_trackers/xorg/xvmc/tests/test_rendering.c
	src/gallium/state_trackers/xorg/xvmc/tests/testlib.c
	src/gallium/state_trackers/xorg/xvmc/tests/xvmc_bench.c
	src/mesa/drivers/windows/gldirect/mesasw/gld_wgl_mesasw.c
	windows/VC7/mesa/mesa/mesa.vcproj
2009-12-12 12:31:27 +01:00
Brian Paul
6cbb1219a3 llvmpipe: checkpoint: plug in the new fencing code
This has only been very lightly tested.  More work to come.
2009-12-11 17:59:32 -07:00
Brian Paul
4b70af918d llvmpipe: added lp_rast_fence() bin function 2009-12-11 17:57:45 -07:00
Brian Paul
9323740738 llvmpipe: added lp_rast_get_num_threads() 2009-12-11 17:45:52 -07:00
Brian Paul
8736ee1e7d llvmpipe: added lp_bin_get_num_bins() 2009-12-11 17:33:30 -07:00
Brian Paul
2876b684de llvmpipe: remove old fence code, compile new lp_fence.c file 2009-12-11 17:32:45 -07:00
Brian Paul
edbaca6fd1 llvmpipe: initial fence implementation 2009-12-11 17:32:08 -07:00
Maciej Cencora
784cca9fa5 r300: disable blit debugging info 2009-12-12 00:52:52 +01:00
Maciej Cencora
6b8315494a r300: emit number of used colorbuffers to pass radeon cs checker 2009-12-12 00:52:52 +01:00
Maciej Cencora
dbd53f8f55 r300: setup render target format for r300/r400 cards too 2009-12-12 00:52:51 +01:00
Maciej Cencora
353966b2da r300: finish blit support for r300 2009-12-12 00:52:51 +01:00
Maciej Cencora
c1a7cc1e44 more blit fixes 2009-12-12 00:52:51 +01:00
Maciej Cencora
cd5f167353 blit WIP 2009-12-12 00:52:51 +01:00
Maciej Cencora
7255a5486d r300: use accelerated emit for CopyTex[Sub]Image functions 2009-12-12 00:52:51 +01:00
Maciej Cencora
a4df3f9227 r300: accelerated blit support 2009-12-12 00:52:51 +01:00
Maciej Cencora
0a0d410bdb r300: fix wrong assertion 2009-12-12 00:52:51 +01:00
Maciej Cencora
bd58253f67 r300: export translateTexFormat function 2009-12-12 00:52:51 +01:00
Maciej Cencora
9975c484ad r300: refactor PVS code and constants emission 2009-12-12 00:52:50 +01:00
Maciej Cencora
545a2f4f2d r300: refactor R500 fragment program emission 2009-12-12 00:52:50 +01:00
Maciej Cencora
05fae9fbf6 r300: refactor color buffer setup 2009-12-12 00:52:50 +01:00
Maciej Cencora
5ee270820b r300: use _mesa_meta_Clear for buffer clears 2009-12-12 00:52:50 +01:00
Maciej Cencora
da73c1ed41 r300: minor texture code refactoring 2009-12-12 00:52:50 +01:00
Brian Paul
4430a05a3a gallium: added comment for pipe_reference() return value 2009-12-11 16:50:25 -07:00
Brian Paul
9c01cf425f mesa: minor reformatting/rewrapping in dd.h 2009-12-11 16:42:31 -07:00
Brian Paul
56dce15dcc mesa: remove unused ctx->Driver.ActiveTexture() hook 2009-12-11 16:42:31 -07:00
Brian Paul
e24a8de8ba mesa: updated comment 2009-12-11 16:42:30 -07:00
Brian Paul
92dc0f92b0 llvmpipe: implement lp_rast_load_color() 2009-12-11 15:00:28 -07:00
Brian Paul
2bce5c195f llvmpipe: checkpoint: more thread/queuing changes
Now mapping/unmapping the framebuffer is done by a rasteizer thread
rather than the main calling thread.
2009-12-11 14:52:46 -07:00
Brian Paul
24d894e557 gallium: comments and minor re-org in p_thread.h
There's more work to do in this file:
1. Implement condvars for Windows via Win32 CONDITION_VARIABLE type.
2. Implement barriers for Windows
3. Try to get rid of PIPE_THREAD_HAVE_CONDVAR (only used in trace driver)
4. Why the 2 in _P_THREAD2_H_?
2009-12-11 14:07:27 -07:00
Brian Paul
0fc90dfa28 gallium: added pipe_barrier type and functions 2009-12-11 14:00:25 -07:00
Brian Paul
de31b0e60c llvmpipe: remove unused lp_rasterizer::fb field 2009-12-11 11:56:22 -07:00
Brian Paul
156eabbaf9 llvmpipe: improve framebuffer/surface code 2009-12-11 11:46:23 -07:00
Brian Paul
9d0faea58c llvmpipe: fix-up #includes 2009-12-11 11:42:18 -07:00
Brian Paul
544882eb58 llvmpipe: fix inverted util_framebuffer_state_equal() result 2009-12-11 11:41:11 -07:00
Brian Paul
d1fa748cdb gallium/util: added util_unreference_framebuffer_state() 2009-12-11 11:40:52 -07:00
Brian Paul
8f2a173663 gallium/util: simplify util_framebuffer_state_equal()
And copy width, height in util_copy_framebuffer_state().
2009-12-11 11:39:55 -07:00
Brian Paul
205da96fc6 llvmpipe: remove unused fb parameter 2009-12-11 11:25:22 -07:00
Brian Paul
4e67f10331 llvmpipe: minor comment fix 2009-12-11 11:16:48 -07:00
Brice Goglin
7f8952d242 Prepare Changelog for upload 2009-12-11 18:36:40 +01:00
Brice Goglin
adae195cc1 Drop 07_sparc64_xform_asm.patch, applied upstream 2009-12-11 18:36:25 +01:00
Brice Goglin
3fa885911b New upstream release candidate 2009-12-11 18:33:34 +01:00
Brice Goglin
ebf57c6202 Merge branch 'mesa_7_6_branch' of git://anongit.freedesktop.org/mesa/mesa into debian-unstable
Conflicts:
	progs/tests/Makefile
	progs/tests/prog_parameter.c
2009-12-11 18:31:38 +01:00
Brian Paul
09aa984494 Revert "scons: Pass -fno-strict-aliasing to gcc."
This reverts commit a2937a2f4e.

Per Jose's comment, We don't want this on master.
2009-12-11 10:11:45 -07:00
Brian Paul
a087eb590d Merge branch 'mesa_7_7_branch'
Conflicts:
	src/gallium/state_trackers/xorg/xorg_xv.c
	src/mesa/drivers/dri/intel/intel_span.c
2009-12-11 10:04:07 -07:00
Brian Paul
e128cc205e Merge branch 'mesa_7_6_branch' into mesa_7_7_branch 2009-12-11 09:51:27 -07:00
Brian Paul
b605f4ff11 Merge branch 'mesa_7_6_branch' into mesa_7_7_branch 2009-12-11 09:22:00 -07:00
José Fonseca
da3bc492d2 scons: Tweak MSVC release options.
Enable whole program optimizations and fast math.
2009-12-11 15:16:22 +00:00
Brice Goglin
1f47135544 Build r600_dri.so 2009-12-11 15:54:32 +01:00
José Fonseca
ffae1f938d svga: Add a missing dependency from the prescale state.
Thanks for Keith to finding this.

Fixes Jedi Knight 2 menus.
2009-12-11 14:14:03 +00:00
José Fonseca
8469baf41b svga: Always pass SVGA3D_SURFACE_HINT_DYNAMIC.
Since we're reusing buffers we're effectively transforming all
of them into dynamic buffers.

It would be nice to not cache long lived static buffers. But there
is no way to detect the long lived from short lived ones yet. A
good heuristic would be buffer size.
2009-12-11 13:15:12 +00:00
José Fonseca
16876b8328 svga: Keep tight control of texture handle ownership.
The texture owns the surface handle. All derivatives need to keep
a reference to texture.

This fixes several assertions failures starting up Jedi Knight 2.

Should cause no change for DRM surface sharing -- reference count still
done as before there.
2009-12-11 12:29:02 +00:00
José Fonseca
770323e33e svga: Fix mixed signed comparisons. 2009-12-11 12:28:53 +00:00
José Fonseca
a2937a2f4e scons: Pass -fno-strict-aliasing to gcc.
Strict aliasing tule violations were fixed on master, but
they're still causing problem in this branch, so disable this assumptions.

Do not apply this fix to master (revert when you merge).
2009-12-11 12:28:53 +00:00
José Fonseca
8c981b94dc scons: Make it work with MinGW build of LLVM 2.6.
LLVM 2.5 is no longer supported on windows.
2009-12-11 12:28:53 +00:00
Brice Goglin
ac180fa6a7 fix sparc64 FTBFS 2009-12-11 07:52:39 +01:00
Ian Romanick
e624b77eb2 intel: Remove ARGB internal_format == GL_RGB hacks
Now that XRGB is supported, we don't need to hack around cases of an RGBA
format buffer with an internal format of GL_RGB.
2009-12-10 15:12:31 -08:00
Ian Romanick
b4a6169412 intel: Make RGB textures use XRGB8888 2009-12-10 15:12:30 -08:00
Ian Romanick
cbdeb33209 intel: Make RGB renderbuffers use XRGB8888 like we do for RGB system buffers. 2009-12-10 15:12:30 -08:00
Ian Romanick
eadd9b8e16 i965: Fix handling of drawing to MESA_FORMAT_XRGB8888
It turns out that 965 and friends cannot actually render to an xRGB
surfaces.  Instead, the surface has to be RGBA with writes to alpha
disabled and the blend function modified to always use 1.0 for
destination alpha.
2009-12-10 15:12:30 -08:00
Ian Romanick
4f2b2032f4 intel: Use spantmp2 GL_BGR / GL_UNSIGNED_INT_8_8_8_8_REV for XRGB8888 2009-12-10 15:12:30 -08:00
Ian Romanick
ffc1f299e9 spantmp2: Add support for GL_BGR / GL_UNSIGNED_INT_8_8_8_8_REV
This is really for MESA_FORMAT_XRGB8888.  Clearly spantmp2.h needs some
re-work.  Any volunteers?
2009-12-10 15:12:30 -08:00
Ian Romanick
430876cd3a intel: name in intel_create_renderbuffer was always 0, remove 2009-12-10 15:12:30 -08:00
Ian Romanick
0f01674a58 intel: Use texformat accessor to get bytes-per-pixel 2009-12-10 15:12:30 -08:00
Ian Romanick
4eee46efcb intel: softwareBuffer in intel_alloc_renderbuffer_storage was always false, remove 2009-12-10 15:12:30 -08:00
Ian Romanick
3078bd136d intel: Axe intel_renderbuffer::texformat
Since the texformat branch merge, the value of intel_renderbuffer::texformat
is just a copy of gl_renderbuffer::Format.
2009-12-10 15:12:30 -08:00
Eric Anholt
539a14a1dd intel: Flush the render/texture cache when finishing render to texture.
Back when we were flushing the entire batch at BindFramebuffer, the kernel
would notice the domain transition when someone went to texture from it and
flush for us.  We no longer do the batch flushing every time, so we get to
do aggressive flushing until we move batchbuffer handling to libdrm.

Fixes piglit fbo-flushing.  Bug #25377.  No noticeable performance loss
on cairo-gl (so this is better than batch flushing).
2009-12-10 14:47:09 -08:00
Brian Paul
9509f73c21 llvmpipe: checkpoint: use empty/full bin queues 2009-12-10 14:56:30 -07:00
Brian Paul
9a6567f1ed llvmpipe: updated comment 2009-12-10 14:56:11 -07:00
Brian Paul
6d810e5a7b llvmpipe: simplify llvmpipe_set_framebuffer_state() 2009-12-10 14:55:28 -07:00
Brian Paul
a67f39810b gallium/util: added framebuffer compare, copy util funcs 2009-12-10 14:54:57 -07:00
Brian Paul
721b5167dc llvmpipe: added some bin queue debug code 2009-12-10 14:54:32 -07:00
Eric Anholt
cb640c8d40 mesa: Fix default (swrast) GL_MAX_COMBINED_TEXTURE_IMAGE_UNITS.
The swrast pipeline shouldn't have any problem with all the frag and vert
textures being bound at the same time.  Note that this may result in
DRI drivers that don't set this limit having an improbable return
(fragment + vertex < combined), but it seems like it shouldn't cause
problems for apps.
2009-12-10 10:05:31 -08:00
Zack Rusin
967e6e2009 st/xorg: fix yv12 plus some cleanups in the upload code 2009-12-10 13:04:26 -05:00
Zack Rusin
690d888416 st/xorg: enable yv12 for xv 2009-12-10 13:04:05 -05:00
Brian Paul
21008441e4 llvmpipe: updated comments 2009-12-10 10:59:46 -07:00
Eric Anholt
51e945ec9c intel: Attempt to fix up after "Update vertex texture code."
The MaxCombinedTextureImageUnits is the total number of samplers that can
be bound between vertex, geometry, and fragment, not 0.  This should report
the correct value on 965 now.  Other DRI drivers may also need updating if
their MaxVertexTextureImageUnits != 0 (for example, if using the sw vertex
pipeline).

It's not clear to me if there's going to be a valid value for this
limit other than MaxTextureImageUnits + MaxVertexTextureImageUnits (+
MaxGeometryTextureImageUnits eventually).  If not, then we should probably
just move this into the core at Get time.

Bug #25518 (wine regression).  Fixes piglit vp-combined-image-units.
2009-12-10 09:56:52 -08:00
José Fonseca
491f384c39 scons: Get GLSL code building correctly when cross compiling.
This is quite messy. GLSL code has to be built twice: one for the
host OS, another for the target OS.
2009-12-10 16:30:08 +00:00
Brian Paul
289eab5389 glsl/sl: fix _parse_boolconstant()
Need to emit the radix before the digits.
This fixes several glean/glgl1 regressions.
2009-12-10 09:16:39 -07:00
Brian Paul
cc020425e9 mesa: added new libglslpp.a and libglslcl.a to libGL build 2009-12-10 08:33:01 -07:00
Brian Paul
05eccfe79e glsl/apps: remove unused vars 2009-12-10 08:25:47 -07:00
Brian Paul
0d654a7f2c glsl/pp: make some functions static 2009-12-10 08:25:35 -07:00
Brian Paul
52271c5345 glsl/pp: declare sl_pp_purify_options to silence warning 2009-12-10 08:25:16 -07:00
Brian Paul
7502b6affa glsl/cl: silence unused var warning 2009-12-10 08:24:45 -07:00
Michal Krol
f00805a117 slang: Predefine ES symbols for FEATURE_es2_glsl. 2009-12-10 12:59:23 +01:00
Michal Krol
417f36ccb0 glsl/apps: Predefine __GLSL_PP_PREDEFINED_MACRO_TEST for testing. 2009-12-10 12:58:44 +01:00
Michal Krol
22200bcafc glsl/pp: Add support for user-defined macros. 2009-12-10 12:58:21 +01:00
Michal Krol
d1a09a9ba4 glsl/apps: Explicitly add ARB_draw_buffers and ARB_texture_rectangle. 2009-12-10 12:39:37 +01:00
Michal Krol
48c60b0ecb slang: Explicitly enable ARB_draw_buffers and ARB_texture_rectangle.
They are no longer built into the glsl preprocessor.
2009-12-10 12:39:10 +01:00
Michal Krol
91e164b3d0 glsl/pp: Add sl_pp_context_add_extension().
This way third parties are able to add supported extension strings.
2009-12-10 12:38:22 +01:00
Vinson Lee
05b6296092 mesa: Fix SCons build.
Commit cd6b8dd9e8 deleted
src/mesa/state_tracker/st_cb_get.c.
2009-12-09 22:35:32 -08:00
Roland Scheidegger
71f4267ac2 winsys/intel: fix dereferencing of opaque type due to pipe_reference changes 2009-12-10 03:51:35 +01:00
michal
068596c9a7 Build mesa glsl with make.
Still don't know how to add glsl to mesa dependencies.
2009-12-10 01:03:15 +01:00
Brian Paul
96689d451a llvmpipe: added some debug/info code 2009-12-09 16:32:32 -07:00
Brian Paul
ad3c16c127 llvmpipe: simplify the tiles_x, tiles_y code a bit 2009-12-09 16:30:05 -07:00
Brian Paul
edf11da7f8 progs/demos/gloss: press 'n' to advance by one frame 2009-12-09 16:23:30 -07:00
Brian Paul
3bee8c2e7c llvmpipe: use the empty_bins queue now 2009-12-09 16:06:04 -07:00
Brian Paul
288ea9770a progs/demos: call glutDestroyWindow() in gloss.c 2009-12-09 14:53:53 -07:00
Brian Paul
d7dbc66636 llvmpipe: checkpoint: begin plugging in bin queue code 2009-12-09 14:53:33 -07:00
Marek Olšák
c6b450033d r300g: fix routing of vertex streams if TCL is bypassed
Generating mipmaps finally works, among other things. Yay!
2009-12-09 13:38:11 -08:00
Marek Olšák
6de7ac73bf r300g: always disable unused colorbuffers 2009-12-09 13:38:11 -08:00
Marek Olšák
87b822e024 r300g: make pow(0,0) return 1 instead of NaN in the R500 fragment shader
Unfortunately we can't fix this easily in the R300 fragment shader,
and it's probably not worth the effort.
2009-12-09 13:38:11 -08:00
Marek Olšák
8cc570a48c r300g: clean up r300_emit_aos 2009-12-09 13:38:11 -08:00
Brian Paul
ea35993e74 llvmpipe: added new lp_bin_queue.[ch] files
The queues will be used for keeping track of full and empty bins so
we can overlap setup with the rasterization threads.
2009-12-09 14:36:54 -07:00
Richard Li
8927b72118 r600 : add pre-compile mesa shader calling interface, in order to handle
complex built-in shader instructions.
2009-12-09 15:39:16 -05:00
Brian Paul
22b07b8be4 llvmpipe: use new lp_setup_get_current_bins() function
This stub function will interface to the queue system...
2009-12-09 12:28:59 -07:00
Brian Paul
88e62b33dc llvmpipe: more bin functions for create/destroy/queries 2009-12-09 12:22:12 -07:00
Keith Whitwell
a08e348a84 gallium: first steps to treat edgeflags as regular vertex element
The idea here is to eliminate the set_edgeflags() call in pipe_context
by treating edgeflags as a regular vertex element.

Edgeflags provoke special treatment in hardware, which means we need to
label them in some way, in this case we'll be passing them through the
vertex shader and labelling the vertex shader output with a new TGSI
semantic (TGSI_SEMANTIC_EDGEFLAG).
2009-12-09 19:03:10 +01:00
Michal Krol
dfdf83d714 Revert "Simplify the redundant meaning of format layout."
This reverts commit eb926ddf9e.
2009-12-09 14:22:30 +01:00
José Fonseca
59f6af51b8 util: Document the meaning of util_format_layout.
The util_format_layout name was unfortunate and there
are  as been a lot of confusion due to this. Hopefully
this will shed some light on what it was meant for.

Bottom line is: do not rely on these values unless
you're automatically code generating pixel
packing/unpacking routines.

Suggestions for better names than util_format_layout
are welcome!
2009-12-09 11:00:26 +00:00
Jakob Bornecrantz
5e2a86cb1b vmware/xorg: Properly detect overlay support 2009-12-09 09:51:05 +01:00
Jakob Bornecrantz
b7cf8a1f93 vmware/core: Update vmwgfx_drm.h 2009-12-09 09:51:04 +01:00
Ian Romanick
e3fa700c17 meta: Bind texture to unit 0 for mipmap generation
If the active texture unit on entry to mipmap generation is not zero, bind the
texture to unit zero.

Fixes bug #24219.
2009-12-09 11:05:15 -08:00
Eric Anholt
cd6b8dd9e8 mesa: Move OES_read_format support from drivers into the core.
The assertion is that the correct read type to be using is the native
type of the underlying read renderbuffer.  For some fallback paths, this
may be worse than GL_RGBA/GL_UNSIGNED_BYTE for reads today, but it gets
all drivers the expected GL_BGRA/GL_UNSIGNED_BYTE for ARGB8888 or
GL_BGR//GL_UNSIGNED_SHORT_5_6_5_REV for rgb565 with no work.

This fixes the intel (and other) DRI drivers to report read formats that
should hit blit PBO readpixels paths.
2009-12-09 10:37:36 -08:00
Eric Anholt
dd9eb8774a i965: Enable the accelerated ReadPixels path on gen4 along with pre-gen4.
Passes piglit pbo-read-argb8888, and doesn't otherwise regress quick.tests.
2009-12-08 16:35:05 -08:00
Michal Krol
eb926ddf9e Simplify the redundant meaning of format layout.
We really just need to know whether the format is compressed or not.
For more detailed information format colorspace should suffice.
2009-12-08 20:48:47 +01:00
Roland Scheidegger
47c780180b nouveau: use boolean instead of bool 2009-12-08 19:58:46 +01:00
Roland Scheidegger
849a0644ad cell: use boolean instead of bool 2009-12-08 19:58:36 +01:00
Roland Scheidegger
fd7a9ec7f9 gallium: use boolean instead of bool in p_refcnt.h
all code in gallium should use boolean not bool
2009-12-08 19:58:28 +01:00
Michal Krol
876a785a18 Format layout cannot be used to distinguish scaled/normalised formats. 2009-12-08 19:58:13 +01:00
Roland Scheidegger
4ebc54795d Merge branch 'gallium-strict-aliasing' 2009-12-08 19:26:20 +01:00
Roland Scheidegger
ee1720b99d gallium: fix more potential strict aliasing issues
In particular, gcc man page warns that
union a_union {
   int i;
   double d;
};

int f() {
   double d = 3.0;
   return ((union a_union *) &d)->i;
}

"might" not be ok (why not?), even though it doesn't seem to generate
any warnings. Hence don't use this and do the extra step to actually use
assignment to get the values in/out of the union.
This changes parts of 3456f9149b.
2009-12-08 19:17:08 +01:00
Brian Paul
bc7567d966 tgsi: fix some off-by-one errors in shader length, instruction length
The ureg and/or tgsi-simplification work introduced some inconsistencies
between the ureg and traditional TGSI construction code.

Now the tgsi_instruction::NrTokens field is consistant and the
tgsi_header::BodySize field isn't off by one.

Fixes bug 25455.
2009-12-08 08:14:14 -07:00
Michal Krol
ddbd2d08b7 util/format: Take advantage of sequential nature of pipe_format enum.
Make sure the format descriptor table can be indexed directly.
2009-12-08 15:46:15 +01:00
Michal Krol
714e1880d9 gallium: Make pipe_format a sequential enum. 2009-12-08 15:35:54 +01:00
Michal Krol
ceb3cf5519 util/format: Remove unreferenced local. 2009-12-08 15:31:07 +01:00
Michal Krol
6fd8b9b550 Remove remaining pipe format utility functions.
Depricate pf_type(), pf_size_*(), pf_layout() and pf_exp2().

Map depricated PIPE_FORMAT_TYPE to new UTIL_FORMAT_ values:

UNKNOWN = TYPE_VOID
UNORM   = TYPE_UNSIGNED + LAYOUT_ARITH
SNORM   = TYPE_SIGNED + LAYOUT_ARITH
FIXED   = TYPE_FIXED
FLOAT   = TYPE_FLOAT
USCALED = TYPE_UNSIGNED + LAYOUT_ARRAY
SSCALED = TYPE_SIGNED + LAYOUT_ARRAY
SRGB    = TYPE_COLORSPACE_SRGB
2009-12-08 15:30:10 +01:00
Andre Maasikas
629a648b05 r600: and finally fix SCS 2009-12-08 15:45:26 +02:00
Andre Maasikas
0f854105f5 r600: remove (now) dead code 2009-12-08 15:44:42 +02:00
Andre Maasikas
fbe06a9c29 r600: fix SIN also 2009-12-08 15:44:34 +02:00
Andre Maasikas
2b8b16f6a6 r600: use the new inline constants feature to fix COS 2009-12-08 15:44:23 +02:00
Andre Maasikas
4e86cedf5b r600: add assembler support for literal(inline) constants
and use it in cubemap instruction sequence for testing
2009-12-08 15:43:12 +02:00
Andre Maasikas
602ba357ed r600: merge alu_instruction/alu_instruction2 2009-12-08 15:39:57 +02:00
Andre Maasikas
17e212e263 r600: add ABS support for source regs to assembler
use it in tex cube instruction sequence
2009-12-08 15:39:45 +02:00
Andre Maasikas
50ab51101e r600: glsl - allow specifying texture sampler via uniforms
looks kinda hackish, should rethink later
2009-12-08 15:39:39 +02:00
Andre Maasikas
94723b60cf r600: implement FRAG_ATTRIB_FACE, glsl/twoside works 2009-12-08 15:39:29 +02:00
Andre Maasikas
323d1fb391 r600: quick hack to get KIL_NV working - does condition TR only for now 2009-12-08 15:39:20 +02:00
Andre Maasikas
c1d79a4235 r600: wip glsl - refactor conditional instructions a bit
remember the dst register which is used for cond updates
when it's time to use the cond codes issue a separate PRED instruction
2009-12-08 15:39:08 +02:00
Andre Maasikas
94c6ec5809 r600: execute SET funtions on all channels
seems assemble_LOGIC was meant for non-condition-code instructions
so execute in for all components as previously
2009-12-08 15:38:59 +02:00
Alan Hourihane
2aebc5e01f move assert to avoid crash in debug build. 2009-12-08 13:12:02 +00:00
Thomas Hellstrom
f44f6473e6 st/xorg Fail early if we don't intend to accelerate.
Saves a number of unneeded computations and log noise.

Signed-off-by: Thomas Hellstrom <thellstrom@vmware.com>
2009-12-08 12:50:27 +01:00
Jeremy Huddleston
189ee75abb darwin: mklib: Use lipo rather than file to figure out architectures of object files
(cherry picked from commit ad7f9d71e2)
2009-12-20 21:36:58 -08:00
Jeremy Huddleston
da5741cf53 darwin: Cleanup CPPFLAGS a bit
(cherry picked from commit 4a1e103858)
2009-12-20 21:36:56 -08:00
Eric Anholt
6785d6741d i915: Fix GL_TEXTURE_MAX_LEVEL support (piglit levelclamp test). 2009-12-18 20:35:57 -08:00
Eric Anholt
b51e0fafdf i915: Clean up some unnecessary x/y miptree code.
The base of the texture is always the base of the miptree.  If it wasn't,
we'd have issues with this code due to miptrees not walking the same
direction for all LODs.
2009-12-18 20:35:57 -08:00
Eric Anholt
f06c8bd8dd i965: Add support for OPCODE_CMP in the VS to fix GLSL sqrt()
Bug #25628.  Fixes piglit case glsl-vs-sqrt-zero.
2009-12-18 20:35:57 -08:00
Keith Whitwell
325f045c04 st/mesa: move assert on nr vs insns until after pos_invarient expansion
It is possible to have a 1-instruction vertex shader before expanding
pos_invarient.  Not sure what this assert achieved, but at least move
it where it is correct.
2009-12-18 18:39:44 +00:00
Michel Dänzer
eaa3a025da Merge branch 'mesa_7_7_branch' 2009-12-08 12:25:34 +01:00
Michel Dänzer
32ccc9b0bb vmware/xorg: Fix SCons build.
Not sure how vmw_screen.c could build at all though...
2009-12-08 11:45:19 +01:00
Michel Dänzer
9e42683fb3 vmware/xorg: Avoid warning about HAVE_STDINT_H being redefined. 2009-12-08 11:43:22 +01:00
Andre Maasikas
b5e256c76d Merge branch 'mesa_7_7_branch'
Conflicts:
	src/mesa/drivers/dri/r600/r700_assembler.c
	src/mesa/main/version.h
2009-12-08 11:57:24 +02:00
Andre Maasikas
0d4a05445c Merge branch 'mesa_7_6_branch' into mesa_7_7_branch 2009-12-08 10:16:14 +02:00
José Fonseca
7f457acabc llvmpipe: Use number of CPUs as default number of threads.
Also bump MAX_THREADS to 8.
2009-12-08 08:02:49 +00:00
Ian Romanick
ba167f812c mesa: set version string to 7.7-rc1
Also modify the Makefile to use the correct version for the tarballs.
2009-12-07 17:18:56 -08:00
Brian Paul
73e13c33fd llvmpipe: remove some left-over debug code 2009-12-07 18:18:37 -07:00
Ian Romanick
8fc433fa0f Merge branch 'mesa_7_6_branch' into mesa_7_7_branch
Conflicts:
	progs/demos/projtex.c
	progs/xdemos/glxinfo.c
	src/mesa/main/version.h

To fix the confilicts in projtex.c and glxinfo.c I just took the code from
mesa_7_6_branch.  The conflicts seem to have occured from cherry-picks from
mesa_7_7_branch to mesa_7_6_branch followed by commmits just to
mesa_7_6_branch.
2009-12-07 17:16:10 -08:00
Ian Romanick
bb64c9bcdf Revert "intel: Make RGB renderbuffers use XRGB8888 like we do for RGB system buffers."
This reverts commit 4598942b1b.

XRGB8888 doesn't work as intended.  Revert this for now, and we'll revisit it
for 7.8 or something.
2009-12-07 17:06:07 -08:00
Brian Paul
aab1ceceec llvmpipe: implement threaded rasterization
The LP_NUM_THREADS env var controls how many threads are created.
The default (and max) is 4, for now.
If LP_NUM_THREADS = 0, threading is not used.
2009-12-07 18:04:54 -07:00
Brian Paul
87c9ceaea2 gallium: added pipe_semaphore and related code 2009-12-07 18:04:54 -07:00
Brian Paul
3a06c113c7 llvmpipe: repartition lp_rasterizer state for threading
Some of the state is per-thread.  Put that state in new lp_rasterizer_task
struct.
2009-12-07 18:04:54 -07:00
Brian Paul
cdaea049c9 llvmpipe: use bin iteration functions when rasterizing bins 2009-12-07 18:04:54 -07:00
Brian Paul
270f154860 llvmpipe: introduce mutex and bin iteration functions 2009-12-07 18:04:31 -07:00
Maciej Cencora
9921b3048e radeon: fix cases when only first image where put directly into miptree.
Make sure that minimal width, height and depth of texture image is 1.
2009-12-07 22:33:11 +01:00
Maciej Cencora
013cf1d63d radeon: fix image migration for small compressed textures
memcpy would give incorrect results if src rowstride != dst rowstride
2009-12-07 22:29:11 +01:00
Roland Scheidegger
72362a5cd4 mesa: fix shader prog_execute strict aliasing violations
use unions instead of pointer casts.
2009-12-07 21:47:49 +01:00
Roland Scheidegger
3456f9149b gallium/util: fix util_color_[un]pack[-ub] to be strict aliasing safe
use pointer to union instead of void pointer.
gcc complained a lot, depending what the pointer originally actually was.
Looks like it's in fact maybe legal to cast for instance uint pointers to
union pointers as long as union contains a uint type, hence use this with some
callers, other just use union util_color in the first place.
2009-12-07 20:35:42 +01:00
Roland Scheidegger
c36d1aacf4 mesa: fix strict aliasing issues in half-to-float/float-to-half conversions
use union instead of casts
2009-12-07 20:11:46 +01:00
Michal Krol
ac66598ed8 util/tile: Support R8G8B8A8_UNORM format. 2009-12-07 18:21:37 +01:00
Brian Paul
c90baf444c st/mesa: remove debug code 2009-12-07 09:05:40 -07:00
Brian Paul
0311d9ccf4 progs/glsl: updates to deriv.c test
Pass window size into the shader so scaling the window doesn't effect
the colors.
2009-12-07 09:03:41 -07:00
Brian Paul
8ce1713443 st/mesa: negate DDY to match GL semantics
This fixes the regression from commit 884007546c
Fixes bug 25456 (piglit derivs regression).
2009-12-07 09:00:59 -07:00
Brian Paul
8468234bfa st/mesa: fix up comment 2009-12-07 08:59:38 -07:00
Brian Paul
8796dbf519 progs/glsl: added texture mapping to bump demo
Press 't' to toggle texture map.
2009-12-07 07:46:02 -07:00
Corbin Simpson
12981589b7 radeong: Automatically softpipe for non-r3xx.
Well, technically non-r[345]xx. At any rate...

$ glxgears
libGL: OpenDriver: trying /home/simpson/mesa/lib/gallium/r600_dri.so
131 frames in 5.0 seconds = 26.107 FPS

I'm sure you can see where this is going. :3
2009-12-06 23:55:58 -08:00
Corbin Simpson
e3a3ca097c radeong: Call softpipe_create directly.
Allows us to finally remove radeon_winsys_softpipe.
2009-12-06 23:50:31 -08:00
Corbin Simpson
d8d8b0d244 softpipe: sp_winsys.h should define/include what it needs. 2009-12-06 23:49:02 -08:00
Corbin Simpson
c99fb991a3 r300g: Clean up previous commit.
If *I* can't read it, there's a strong possibility others can't,
either.
2009-12-06 23:34:53 -08:00
Marek Olšák
7091afed78 r300g: enhance ZTOP conditions 2009-12-06 23:34:53 -08:00
Younes Manton
c574f515f0 nouveau: Work around nv04-nv40 miptrees not matching nouveau_miptree.
Thanks to Bob Gleitsmann for the patch.

I'll clean this up in a better way later if noone else beats me to it.
2009-12-06 12:34:27 -05:00
Marek Olšák
0748764351 r300g: don't render if everything is culled by scissoring
Otherwise a CS is refused by kernel 2.6.31 (and maybe all later
versions, not sure).
2009-12-06 01:13:37 -08:00
Marek Olšák
e1380cae88 r300g: remove redundant code and clean up 2009-12-06 01:13:36 -08:00
Alex Deucher
df02bc42b3 radeon/r200/r600: fix drivers for changes in 433f0a82f5 2009-12-05 18:24:41 -05:00
Brice Goglin
a7109f3ae5 Prepare Changelog for upload 2009-12-06 00:15:21 +01:00
Brice Goglin
e5e54a9a6e Refresh patches 2009-12-06 00:15:21 +01:00
Brice Goglin
c2ad82a90b New upstream release candidate 2009-12-06 00:15:07 +01:00
Brice Goglin
9347983556 Merge branch 'mesa_7_6_branch' of git://anongit.freedesktop.org/mesa/mesa into debian-unstable
Conflicts:
	progs/fp/Makefile
	progs/fp/fp-tri.c
	progs/fp/point-position.c
	progs/fp/tri-depth.c
	progs/fp/tri-depth2.c
	progs/fp/tri-depthwrite.c
	progs/fp/tri-depthwrite2.c
	progs/fp/tri-inv.c
	progs/fp/tri-param.c
	progs/fp/tri-tex.c
	progs/tests/Makefile
	progs/tests/SConscript
	progs/tests/arraytexture.c
	progs/tests/copypixrate.c
	progs/tests/crossbar.c
	progs/tests/drawbuffers.c
	progs/tests/invert.c
	progs/tests/minmag.c
	progs/tests/mipmap_comp.c
	progs/tests/prog_parameter.c
	progs/tests/random.c
	progs/tests/shader_api.c
	progs/tests/stencil_twoside.c
	progs/tests/texcmp.c
	progs/tests/texdown.c
	progs/tests/vao-01.c
	progs/tests/vao-02.c
	progs/trivial/clear-fbo-tex.c
	progs/trivial/clear-fbo.c
	progs/trivial/clear-random.c
	progs/trivial/clear-scissor.c
	progs/trivial/clear.c
	progs/trivial/createwin.c
	progs/trivial/dlist-begin-call-end.c
	progs/trivial/dlist-dangling.c
	progs/trivial/dlist-edgeflag-dangling.c
	progs/trivial/dlist-edgeflag.c
	progs/trivial/dlist-flat-tri.c
	progs/trivial/dlist-mat-tri.c
	progs/trivial/dlist-recursive-call.c
	progs/trivial/dlist-tri-flat-tri.c
	progs/trivial/dlist-tri-mat-tri.c
	progs/trivial/line-clip.c
	progs/trivial/line-cull.c
	progs/trivial/line-flat.c
	progs/trivial/line-stipple-wide.c
	progs/trivial/line-userclip-clip.c
	progs/trivial/line-userclip-nop-clip.c
	progs/trivial/line-userclip-nop.c
	progs/trivial/line-userclip.c
	progs/trivial/line-wide.c
	progs/trivial/line.c
	progs/trivial/lineloop-clip.c
	progs/trivial/lineloop.c
	progs/trivial/linestrip-clip.c
	progs/trivial/linestrip-flat-stipple.c
	progs/trivial/linestrip-stipple-wide.c
	progs/trivial/linestrip-stipple.c
	progs/trivial/linestrip.c
	progs/trivial/point-clip.c
	progs/trivial/point-param.c
	progs/trivial/point-sprite.c
	progs/trivial/point-wide-smooth.c
	progs/trivial/point-wide.c
	progs/trivial/point.c
	progs/trivial/poly-flat-clip.c
	progs/trivial/poly-flat-unfilled-clip.c
	progs/trivial/poly-flat.c
	progs/trivial/poly-unfilled.c
	progs/trivial/poly.c
	progs/trivial/quad-clip-all-vertices.c
	progs/trivial/quad-clip.c
	progs/trivial/quad-degenerate.c
	progs/trivial/quad-flat.c
	progs/trivial/quad-offset-factor.c
	progs/trivial/quad-offset-unfilled.c
	progs/trivial/quad-offset-units.c
	progs/trivial/quad-tex-alpha.c
	progs/trivial/quad-tex-pbo.c
	progs/trivial/quad-unfilled-clip.c
	progs/trivial/quad-unfilled-stipple.c
	progs/trivial/quad-unfilled.c
	progs/trivial/quad.c
	progs/trivial/quads.c
	progs/trivial/quadstrip-cont.c
	progs/trivial/quadstrip-flat.c
	progs/trivial/quadstrip.c
	progs/trivial/readpixels.c
	progs/trivial/tri-alpha-tex.c
	progs/trivial/tri-alpha.c
	progs/trivial/tri-blend-color.c
	progs/trivial/tri-clear.c
	progs/trivial/tri-clip.c
	progs/trivial/tri-cull-both.c
	progs/trivial/tri-dlist.c
	progs/trivial/tri-fbo.c
	progs/trivial/tri-flat-clip.c
	progs/trivial/tri-flat.c
	progs/trivial/tri-fog.c
	progs/trivial/tri-fp-const-imm.c
	progs/trivial/tri-fp.c
	progs/trivial/tri-lit-material.c
	progs/trivial/tri-lit.c
	progs/trivial/tri-multitex-vbo.c
	progs/trivial/tri-orig.c
	progs/trivial/tri-query.c
	progs/trivial/tri-scissor-tri.c
	progs/trivial/tri-square.c
	progs/trivial/tri-stipple.c
	progs/trivial/tri-tex-3d.c
	progs/trivial/tri-tex.c
	progs/trivial/tri-tri.c
	progs/trivial/tri-unfilled-clip.c
	progs/trivial/tri-unfilled-edgeflag.c
	progs/trivial/tri-unfilled-point.c
	progs/trivial/tri-unfilled-smooth.c
	progs/trivial/tri-unfilled-tri-lit.c
	progs/trivial/tri-unfilled-tri.c
	progs/trivial/tri-unfilled-userclip-stip.c
	progs/trivial/tri-unfilled-userclip.c
	progs/trivial/tri-unfilled.c
	progs/trivial/tri-userclip.c
	progs/trivial/tri-z-9.c
	progs/trivial/tri-z-eq.c
	progs/trivial/trifan-flat-clip.c
	progs/trivial/trifan-flat-unfilled-clip.c
	progs/trivial/trifan-flat.c
	progs/trivial/trifan-unfilled.c
	progs/trivial/trifan.c
	progs/trivial/tristrip-clip.c
	progs/trivial/tristrip-flat.c
	progs/trivial/tristrip.c
	progs/trivial/vp-tri-cb-pos.c
	progs/trivial/vp-tri-cb-tex.c
	progs/trivial/vp-tri-invariant.c
	progs/vp/vp-tris.c
	progs/vpglsl/psiz-mul.glsl
	progs/vpglsl/vp-tris.c
2009-12-05 23:36:06 +01:00
Younes Manton
cbb7226a4b st/xvmc: No more pf_get_block(). 2009-12-05 13:19:54 -05:00
Michel Dänzer
56a4342a04 r300g: Need to emit a hardware scissor rectangle even if scissor is disabled.
Just make it cover the whole framebuffer in that case. Otherwise the kernel CS
checker may complain, e.g. running progs/demos/gearbox. That runs fast now
here, but doesn't look right yet.
2009-12-05 17:59:49 +01:00
Michel Dänzer
01537a84df st/mesa: Prefer alpha-less formats for RGB textures.
This can e.g. increase the chance of being able to accelerate
glCopyTex(Sub)Image from an alpha-less renderbuffer.
2009-12-05 17:59:49 +01:00
Michel Dänzer
d13c603e37 Add 'texture leak' test. 2009-12-05 17:59:49 +01:00
Michel Dänzer
433f0a82f5 radeon: Only get DRI2 front buffer information for glXBindTexImageEXT. 2009-12-05 17:54:23 +01:00
José Fonseca
5b1a7843f8 svga: Dump SVGA_3D_CMD_BLIT_SURFACE_TO_SCREEN commands. 2009-12-05 06:34:59 +00:00
José Fonseca
781d8fccba svga: Use _debug_printf, so that output may be dumped in release builds too.
The dump calls should be wrapped in #ifdef DEBUG .. #endif.
2009-12-05 06:05:56 +00:00
José Fonseca
501989bbcd llvmpipe: Tweak disassembly to match gdb.
Helps verifying udis86 output.
2009-12-05 05:43:53 +00:00
José Fonseca
dd51b4f909 llvmpipe: Stop disassembling when an unsupported opcode is found.
Otherwise the terminal gets full of garbage.
2009-12-05 05:43:10 +00:00
Brian Paul
8a23105fa0 llvmpipe: still more bin code reorganization
Move tiles_x,y fields from setup state into bin state.
Move more bin-adding commands into lp_bin.[ch].
2009-12-04 15:59:25 -07:00
Brian Paul
2c8d5c66ce llvmpipe: remove dead code left over from a previous commit 2009-12-04 15:46:37 -07:00
Brian Paul
01b1900084 llvmpipe: reorganization of binning data structions and funtions
New lp_bins struct contains all bin information.
More move bin-related code into lp_bin.[ch]
Use new/updated bin-access functions to hide implementation details.
The result is more/cleaner separation between the setup and rast components.
This will make double-buffering of the bins easier, etc.
2009-12-04 15:31:09 -07:00
Brian Paul
b533b56750 llvmpipe: move lp_rasterize_bin() into lp_rast.c
First step of moving bin rasterization/execution code out of lp_setup.c
2009-12-04 14:47:46 -07:00
José Fonseca
c0a13bbae1 llvmpipe: Port vertex sampler support from softpipe.
Just enough boilerplate code to avoid segfaulting.
2009-12-04 21:27:03 +00:00
José Fonseca
a312e76468 llvmpipe: Ensure transfers are mapped.
This shouldn't happen but it does by some misterious reason. Fail the
assertion but at least do not segfault on release builds.
2009-12-04 21:27:03 +00:00
José Fonseca
b00b06b6e4 llvmpipe: Remove debug printf. 2009-12-04 21:27:03 +00:00
José Fonseca
818fd6b101 gallium: Disable force_align_arg_pointer attribute on x86_64.
Apparently not only unnecessary but also causes gcc to complain.
2009-12-04 21:27:03 +00:00
Brian Paul
9fca3e065b llvmpipe: simplify framebuffer state code 2009-12-04 14:22:08 -07:00
Brian Paul
a08d630216 llvmpipe: use LP_DBG() macro everywhere 2009-12-04 14:11:25 -07:00
Brian Paul
15a2a588d8 llvmpipe: fix-up polygon culling/winding 2009-12-04 13:53:28 -07:00
Brian Paul
24a3b0d23a llvmpipe: add missing sources to Makefile 2009-12-04 13:01:03 -07:00
Brian Paul
49a720c5cd llvmpipe: comments and minor clean-ups 2009-12-04 12:59:34 -07:00
Brian Paul
d9dc3d5976 llvmpipe: move bin-related structures and functions into new lp_bin.[ch]
And put lp_ prefixes on some functions.
2009-12-04 12:54:37 -07:00
Brian Paul
5c7d1b592a llvmpipe: remove lp_rast_triangle::oneoverarea field
Makes lp_rast_triangle a little smaller (now 280 bytes on a 32-bit system).
2009-12-04 11:58:26 -07:00
Brian Paul
b1659b9213 llvmpipe: bin state-change commands
Previously, each triangle had a pointer to the state to use for shading.
Now we insert state-change commands into the bins.  When we execute one
of those commands we just update a 'current state' pointer and use that
pointer when calling the jit shader.

When inserting state-change commands into a bin we check if the previous
command was also a state-change command and simply replace it.  This
avoids accumulating useless/redundant state-change commands.
2009-12-04 11:50:43 -07:00
Brian Paul
9dca010048 llvmpipe: struct cmd_bin
Just introducing a new structure to represent a per-tile bin.
2009-12-04 10:41:42 -07:00
Roland Scheidegger
7d9b2edb97 identity: fix copy&paste error 2009-12-04 18:34:52 +01:00
Marek Olšák
042b524d48 radeong: flush CS if a buffer being mapped is referenced by it
Also, overlapping occlusion queries seems to work now.
2009-12-04 09:23:59 -08:00
Marek Olšák
7679447b58 r300g, radeong: fix the CS overflow 2009-12-04 09:23:59 -08:00
Marek Olšák
3da8265cd3 r300g: fix warnings 2009-12-04 09:23:59 -08:00
Roland Scheidegger
c977dd9c77 svga: fix another pipe_reference strict aliasing violation 2009-12-04 18:23:35 +01:00
Brian Paul
1796ffd3bc llvmpipe: fix typo, whitespace 2009-12-04 09:19:09 -07:00
Brian Paul
04e12e31b2 llvmpipe: dynamic allocation of triangle a0/dadx/dady arrays
Much less memory per triangle now.
2009-12-04 09:14:42 -07:00
Jakob Bornecrantz
6f1db18f14 vmware/xorg: Also stop ports on close 2009-12-04 16:50:26 +01:00
Jakob Bornecrantz
124f4bc977 vmware/xorg: Stop video ports on leave vt 2009-12-04 16:50:20 +01:00
Jakob Bornecrantz
f2e3fc1814 st/xorg: Add enter/leave vt hooks for winsys 2009-12-04 16:50:16 +01:00
Jakob Bornecrantz
c33520b360 st/xorg: Fix leave enter vt cycle in crtc code 2009-12-04 16:50:12 +01:00
Jakob Bornecrantz
d5b94b49f6 st/xorg: New libkms destroy api 2009-12-04 16:50:08 +01:00
Keith Whitwell
6bb415f862 softpipe: dont claim to support PIPE_FORMAT_NONE 2009-12-04 14:15:21 +00:00
Keith Whitwell
a4b3bb12d7 softpipe: fix double-minify in texture layout 2009-12-04 11:49:42 +00:00
Jakob Bornecrantz
1ef8c493b2 vmware/xorg: Use Write instead of WriteRead for cursor bypass 2009-12-04 10:33:34 +01:00
Jakob Bornecrantz
cd4d806a47 vmware/xorg: Give kernel infromation about cursor bypass 2009-12-04 09:54:51 +01:00
Jakob Bornecrantz
12fdef20b0 vmware/xorg: Handle no init of video in vmw_video_close 2009-12-04 09:54:50 +01:00
Jakob Bornecrantz
47e128331a vmware/core: Update vmwgfx_drm.h to include cursor bypass 2009-12-04 09:54:50 +01:00
Jakob Bornecrantz
bc0532b0ed gallium: DRI drivers enabled by default, Xorg drivers auto by default.
This change enabled gallium dri drivers by default under the
configure build system. Xorg drivers are built automaticaly
if a Xorg dev enviroment is installed and the Xorg version
is higher then 1.6.0.
2009-12-04 19:02:41 +00:00
Jakob Bornecrantz
8ac2503397 i915g: Do not build winsys and binaries by default
Using a hack in the configure script the gallium intel
drivers have 3 options. Off, nothing is built. On, the
driver and binaries are built. Auto, only the driver but
not the binaries and winsys is built.

Since the i915g driver builds everywhere its can enable
the driver per default, so we can get build coverage.
But building the binaries per default is a pain for
distributions and testers since they conflict on the
install target with the old mesa drivers. Which are more
stable/faster/better.

So this change gives us the best of both worlds.
2009-12-04 16:01:41 +00:00
Brian Paul
c6057ab8ff llvmpipe: comments regarding lp_rast_triangle 2009-12-03 17:28:48 -07:00
Brian Paul
9c1debe208 llvmpipe: comment about blend color 2009-12-03 17:28:02 -07:00
Brian Paul
f492edee98 llvmpipe: comments 2009-12-03 17:27:37 -07:00
Brian Paul
30c122a4c9 llvmpipe: new comment in do_triangle_ccw() 2009-12-03 17:27:10 -07:00
Brian Paul
4e058f6c48 llvmpipe: fix incorrect array indexing when saving blend color 2009-12-03 17:00:22 -07:00
Roland Scheidegger
9dfbd1be44 vega: fix missing include 2009-12-04 00:42:53 +01:00
Roland Scheidegger
9c6a9363ef Merge branch 'gallium-noblocks'
Conflicts:
	src/gallium/state_trackers/xorg/xorg_exa.c
2009-12-04 00:35:14 +01:00
Brian Paul
a9be9cd8be llvmpipe: comments, clean-ups in lp_rast_priv.h 2009-12-03 16:23:52 -07:00
Brian Paul
e2f4634456 llvmpipe: checkpoint some initial state binning code 2009-12-03 16:05:12 -07:00
Roland Scheidegger
4153ec547c gallium: fix remaining users of pipe_reference function 2009-12-03 23:58:30 +01:00
Roland Scheidegger
86c8f70db1 mesa: use _mesa_memcpy for COPY_4FV macro
Gets rid of one of the worst strict-aliasing offenders, and actually
produces faster code (at least in some cases, when compiler can use
for instance 64bit moves for memcpy).
(note _mesa_memcpy should get inlined)
2009-12-03 23:26:13 +01:00
José Fonseca
13c647fa0d gallium: fix ref counting bug in pb_bufmgr
This was discovered by the pipe_reference api change.
2009-12-03 23:20:56 +01:00
Roland Scheidegger
35a15f0263 gallium: fix reference counting functions to be strict-aliasing compliant
Historically, parts of mesa code are not strict-aliasing safe, hence
-fno-strict-aliasing is needed to compile (this got forgotten for scons
builds for gallium, which indeed not only caused compiler warnings but also
unexplicable crashes in non-debug builds). However, we should try to eliminate
code not complying with strict-aliasing code at least for gallium.
Hence change pipe_reference functions to make them strict-aliasing compliant.
This adds a bit more complexity (especially for derived classes) but is the
right thing to do, and it does in fact fix a segfault.
2009-12-03 23:15:38 +01:00
Brian Paul
ffd0759973 llvmpipe: comments and a stub for lp_rast_set_state() 2009-12-03 14:57:44 -07:00
Brian Paul
29207a2ae6 llvmpipe: comments 2009-12-03 14:57:13 -07:00
Brian Paul
0e042bed49 llvmpipe: set LP_SETUP_NEW_FS in lp_setup_set_fs()
Fixes progs/trivial/tri-blend.c, but I think we're just getting
lucky in this case.
2009-12-03 14:56:38 -07:00
Brian Paul
3094fc2009 llvmpipe: more debug info 2009-12-03 14:25:08 -07:00
Brian Paul
51410a254c llvmpipe: fix blend debug strings 2009-12-03 14:13:22 -07:00
Maciej Cencora
6c41bb25a2 radeon: workaround an FBO issue
Fixes #21501
2009-12-03 20:23:22 +01:00
Maciej Cencora
8cde43eb19 radeon: properly check if image should be placed in the miptree
Fixes #25355
2009-12-03 20:23:22 +01:00
Brian Paul
52081f0a2c progs/trivial: readback and print Z value in tri-z-eq.c 2009-12-03 11:43:19 -07:00
Brian Paul
51663f0506 llvmpipe: quick & dirty implementation of lp_rast_store_zstencil()
This allows us to do a glReadPixels(GL_DEPTH_COMPONENT) to see what's
in the depth buffer to help debugging.
2009-12-03 11:41:48 -07:00
Brian Paul
69fe4281ea llvmpipe: additional comment about float->uint conversion 2009-12-03 11:40:49 -07:00
Brian Paul
e01fa1eaec llvmpipe: comments 2009-12-03 11:39:40 -07:00
Michal Krol
72befaaae5 Remove pf_swizzle_* internal macros. 2009-12-03 12:25:49 +01:00
Michal Krol
018f33a328 gallium: Remove pf_mixed_*(). 2009-12-03 12:05:21 +01:00
Michal Krol
9861ad46ab gallium: Remove pf_rev(). 2009-12-03 12:03:57 +01:00
Michal Krol
f5bd93fae2 Move pf_get_component_bits() to u_format auxiliary module. 2009-12-03 11:58:36 +01:00
Michal Krol
cceeab39ea Move pf_get_bits/size() to u_format auxiliary module. 2009-12-03 11:17:37 +01:00
Michal Krol
6df42d8023 Move pf_get_block() to u_format auxiliary module. 2009-12-03 10:52:47 +01:00
Michal Krol
0bed834be4 Move pf_is_depth_and_stencil() to u_format auxiliary module. 2009-12-03 10:20:49 +01:00
Michal Krol
d28740c298 Move pf_is_depth_stencil() to u_format auxiliary module. 2009-12-03 10:12:47 +01:00
Michal Krol
3400b668e3 Move pf_is_compressed() to u_format auxiliary module. 2009-12-03 09:56:03 +01:00
Michal Krol
3ffe25c917 gallium: Remove unused format functions. 2009-12-03 09:48:18 +01:00
Michal Krol
cdb6849fc1 tgsi/ureg: Fix ureg_emit_src(). 2009-12-03 09:13:52 +01:00
Brian Paul
866e6856d3 llvmpipe: execute shaders on 4x4 blocks instead of 8x2
This matches the convention used by the recursive rasterizer.
Also fixed assorted typos, comments, etc.
Now tri-z.c, gears.c, etc look basically right but there's still some
cracks in triangle rasterization.
2009-12-02 15:13:47 -07:00
Brian Paul
5750a6426b llvmpipe: whitespace for readability 2009-12-02 14:55:48 -07:00
Corbin Simpson
ab7e70fabd radeong: Clean up some bad code. 2009-12-02 12:58:15 -08:00
Corbin Simpson
f79028bbd4 radeong: Add helper to determine pipe driver. 2009-12-02 12:58:15 -08:00
Corbin Simpson
4395d35c8a radeong: Do ioctls before selecting pipe driver. 2009-12-02 12:58:15 -08:00
Corbin Simpson
4f77b0103d r300g, radeong: De-specialize r300_winsys into radeon_winsys.
There's like five good reasons for this, I swear.
2009-12-02 12:58:15 -08:00
Corbin Simpson
dad193d516 radeong: Change ioctl order, document it. 2009-12-02 12:58:14 -08:00
Corbin Simpson
08383af4c7 r300g: No vertex textures here. 2009-12-02 12:58:14 -08:00
Brian Paul
debc0b6fa8 cso: check if pipe_context::bind_vertex_sampler_states is non-null
Fixes segfaults upon exit when the CSO module is releasing its objects.
2009-12-02 12:24:27 -07:00
Brian Paul
d5e5909f17 Revert "llvmpipe: plug in dummy pipe_context::set_vertex_sampler_textures function"
This reverts commit 792888121b.

We're instead returning 0 for the PIPE_CAP_MAX_VERTEX_TEXTURE_UNITS query.
2009-12-02 12:20:15 -07:00
Brian Paul
f42192e783 llvmpipe: return 0 for PIPE_CAP_MAX_VERTEX_TEXTURE_UNITS query
The driver (and draw module) don't support vertex shader textures yet.
2009-12-02 12:19:33 -07:00
Brian Paul
792888121b llvmpipe: plug in dummy pipe_context::set_vertex_sampler_textures function
Fixes immediate segfault.
2009-12-02 10:11:05 -07:00
Brian Paul
429bf75417 cell: fix TGSI breakage 2009-12-02 09:23:37 -07:00
Brian Paul
144afacc6f gallium/util: __builtin_bswap32() is in only gcc 4.3 or later 2009-12-02 09:23:15 -07:00
Brian Paul
f6d5e58427 gallium/util: added PIPE_CC_GCC_VERSION symbol 2009-12-02 09:22:42 -07:00
Roland Scheidegger
94b5c28a98 gallium: adapt nv drivers to interface cleanups 2009-12-02 16:55:33 +01:00
Jakob Bornecrantz
cc8a537c57 Merge branch 'mesa_7_7_branch' 2009-12-02 14:56:56 +01:00
José Fonseca
7fc75ef7d4 util: Fix generated swizzle comments. 2009-12-03 18:19:43 +00:00
Jakob Bornecrantz
0c75854cc1 Merge commit 'mesa_7_6_branch' into mesa_7_7_branch
Conflicts:
	src/mesa/main/version.h
2009-12-02 14:52:51 +01:00
Eric Anholt
4598942b1b intel: Make RGB renderbuffers use XRGB8888 like we do for RGB system buffers. 2009-12-02 16:19:37 -08:00
Eric Anholt
db352f58fa mesa: Fix bad conversion in AL1616_REV texstore. 2009-12-02 16:19:36 -08:00
Eric Anholt
b47f7316da mesa: Fix copy'n'paste problem in al1616 texel fetch. 2009-12-02 16:19:36 -08:00
Roland Scheidegger
c78748a527 gallium: adapt drivers to interface cleanups 2009-12-02 02:08:26 +01:00
Brian Paul
63fe997e28 llvmpipe: added assertions
And remove unused BLOCKSIZE.
2009-12-01 16:25:00 -07:00
Brian Paul
9c48677491 llvmpipe: simplify mask computation
Make this a little easier to understand.
2009-12-01 16:24:19 -07:00
Brian Paul
6bde3e0fdf llvmpipe: replace shifts with multiplies to be clearer
The compiler will still do the multiplies with shifts.
It's just a bit easier to follow the logic with multiplies.
2009-12-01 16:00:30 -07:00
Brian Paul
938acf0367 llvmpipe: make nr_blocks unsigned 2009-12-01 16:00:08 -07:00
Brian Paul
63b1f23b3e llvmpipe: comments, reformatting and assertions in tri rast code 2009-12-01 15:43:01 -07:00
Brian Paul
09325b9ff4 mesa: added comment for target_enum_to_index() 2009-12-01 12:28:25 -07:00
Brian Paul
e0399fddf2 softpipe: setup machine->Face without a conditional 2009-12-01 12:25:13 -07:00
Keith Whitwell
ba4cb8b2ca i965g: nasty hack for clearing y-tiled surfaces 2009-12-01 17:04:46 +00:00
Keith Whitwell
63a8637c74 i965g: add missing header 2009-12-01 16:39:02 +00:00
Keith Whitwell
eb68acaf6d i965g: don't reference unused vars in RSQ
Probably overly pedantic
2009-12-01 16:33:59 +00:00
Keith Whitwell
759c094bf8 mesa/st: avoid quadstrips if its easy to do so
Tristrips are easier for many drivers to handle.
2009-12-01 16:33:59 +00:00
Jakob Bornecrantz
77ff3a5619 vmware/xorg: Add video support
By using the hooks st/xorg provides us we can create a driver
specific implementation that uses the svga overlay engines.
2009-12-01 17:29:42 +01:00
Jakob Bornecrantz
64102a5625 vmware/xorg: Create a small driver that sits ontop of st/xorg 2009-12-01 17:29:42 +01:00
Jakob Bornecrantz
bb80a93c9e st/xorg: Create winsys hooks that we call into 2009-12-01 17:29:41 +01:00
Jakob Bornecrantz
232e59ca6f vmware/core: Update vmwgfx_drm.h to latest version 2009-12-01 17:29:41 +01:00
Jakob Bornecrantz
9077ddaa25 svga: Add header files for overlay support 2009-12-01 17:29:40 +01:00
Eric Anholt
a7e4a311e9 intel: Fix more front-buffer rendering after Brian's less flushing patch.
bcbfda71b0 left out many blit paths.
This fixes up more of them to get Blender to work again.

Bug #25030.
2009-12-02 11:58:57 -08:00
José Fonseca
b2581dcab4 wgl: Call st_swapbuffers instead of st_notify_swapbuffers.
This will get single buffer, double buffer, and
joint single/double buffer (typical in CAD applications) done right,
at least as far as the frambuffer is concerned.

There are still problems with multiple contexts using the same
framebuffer because st_framebuffer_* calls assume the framebuffer
is bound to a single context.
2009-12-02 17:05:20 +00:00
Dave Airlie
e84dddde9b Revert "radeon/r300: no need to flush the cmdbuf when changing scissors state in KMM mode"
This reverts commit 286bf89e5a.

This doesn't appear to be correct, regression so revert it.
http://bugs.freedesktop.org/show_bug.cgi?id=25193
2009-12-02 11:03:22 +10:00
Brian Paul
c8cdce6657 vbo: make flush recursion check code per-context
This fixes invalid failed assertions when running multi-threaded apps.
2009-12-01 13:27:32 -07:00
Brian Paul
8c26cefec7 st/mesa: updated emit_swz() comment 2009-12-01 12:23:28 -07:00
Keith Whitwell
574715d836 tgsi: fix ureg emit after version token change 2009-12-01 15:01:00 +00:00
Keith Whitwell
b7f94c9002 st/xorg: fix merge droppings
These were stranded in emacs and not saved before committing.
2009-12-01 14:54:32 +00:00
Keith Whitwell
87eec80c11 Merge commit 'origin/tgsi-simplify-ext'
Conflicts:
	src/gallium/drivers/r300/r300_vs.c
2009-12-01 14:31:14 +00:00
Keith Whitwell
06d3732a90 Merge commit 'origin/mesa_7_7_branch'
Conflicts:
	src/gallium/drivers/svga/svga_screen_texture.c
	src/gallium/state_trackers/xorg/xorg_composite.c
	src/gallium/state_trackers/xorg/xorg_exa.c
	src/gallium/state_trackers/xorg/xorg_renderer.c
	src/gallium/state_trackers/xorg/xorg_xv.c
	src/mesa/main/texgetimage.c
	src/mesa/main/version.h
2009-12-01 10:57:37 +00:00
Michal Krol
853d4807fe mesa: Update vertex texture code after gallium changes. 2009-12-01 11:21:21 +01:00
Marek Olšák
af3dea3660 r300g: simplify allocations of VS output registers
No need to parse TGSI tokens since it's easier to walk through shader
semantics.

Also fog coordinates now work reliably.
2009-12-01 01:20:26 -08:00
Marek Olšák
f55c088f89 r300g: simplify allocations of FS input registers 2009-12-01 01:20:26 -08:00
Marek Olšák
cb90235135 r300g: clean up derived states
The state setups which aren't derived anymore have been moved to the VS
and FS objects.
2009-12-01 01:20:26 -08:00
Marek Olšák
6f05eba020 r300g: VS->FS attribute routing rework
Now it always correctly pairs up VS and FS even if the semantics and indices
of VS outputs and FS inputs don't match.
2009-12-01 01:20:26 -08:00
Marek Olšák
759604e32b r300g: add R300 prefix in reg definitions 2009-12-01 01:20:26 -08:00
Michal Krol
7a43c39d20 cso: Fix function prototype. 2009-12-01 10:07:15 +01:00
Michal Krol
57ed791305 trace: Implement separate vertex sampler state. 2009-12-01 09:52:44 +01:00
Michal Krol
f8969db2f8 fo: Implement separate vertex sampler state. 2009-12-01 09:52:42 +01:00
Michal Krol
f2f7bd855a id: Implement separate vertex sampler state. 2009-12-01 09:52:39 +01:00
Michal Krol
3f900c33ae trace: Reduce double semicolons to single ones. 2009-12-01 09:52:37 +01:00
Michal Krol
0f884ed993 sp: Do not falsely advertise support for some SNORM formats. 2009-12-01 09:52:35 +01:00
Michal Krol
8a619e62bf sp: Implement separate vertex sampler state. 2009-12-01 09:52:32 +01:00
Michal Krol
ee86b1b58d python: Update for renamed sampler/texture state setters. 2009-12-01 09:52:30 +01:00
Michal Krol
e197652ce0 st: Update for renamed sampler/texture state setters. 2009-12-01 09:52:27 +01:00
Michal Krol
eeb8dd12b4 trace: Update for renamed sampler/texture state setters. 2009-12-01 09:52:25 +01:00
Michal Krol
8eecd3bafb svga: Update for renamed sampler/texture state setters. 2009-12-01 09:52:23 +01:00
Michal Krol
c1bcedc4ce r300: Update for renamed sampler/texture state setters. 2009-12-01 09:52:20 +01:00
Michal Krol
d15bb1cba3 nv: Update for renamed sampler/texture state setters. 2009-12-01 09:52:18 +01:00
Michal Krol
551b2db82b lp: Update for renamed sampler/texture state setters. 2009-12-01 09:52:15 +01:00
Michal Krol
f0d3abf383 id: Update for renamed sampler/texture state setters. 2009-12-01 09:52:13 +01:00
Michal Krol
25bb04a1ee i915: Update for renamed sampler/texture state setters. 2009-12-01 09:52:11 +01:00
Michal Krol
e04324b8f9 fo: Update for renamed sampler/texture state setters. 2009-12-01 09:52:08 +01:00
Michal Krol
cd3409ce05 cell: Update for renamed sampler/texture state setters. 2009-12-01 09:52:06 +01:00
Michal Krol
204e586c56 vl: Update for renamed sampler/texture state setters. 2009-12-01 09:52:04 +01:00
Michal Krol
f33c064f32 draw: Update for renamed sampler/texture state setters. 2009-12-01 09:52:01 +01:00
Michal Krol
fd4aa4f323 cso: Add support for separate vertex sampler state. 2009-12-01 09:51:59 +01:00
Michal Krol
15d1b406af gallium: Introduce separate vertex texture/sampler state.
Previously, gallium shared sampler and texture state between vertex
and fragment shader stages. This change generalises this concept by
providing separate entrypoints for vertex and fragment sampler state
setting.

A new capability bit is added to query the driver for the number
of samplers that can be utilised by a vertex and fragment shader
at the same time.
2009-12-01 09:51:56 +01:00
Michal Krol
2fd1aee217 tgsi/sanity: Up MAX_REGISTERS to 1024. 2009-12-01 09:51:54 +01:00
Ian Romanick
f17dbe256b mesa: set version string to 7.7-rc1 2009-11-30 17:56:07 -08:00
Ian Romanick
650e02003f Merge branch 'mesa_7_6_branch' into mesa_7_7_branch
Conflicts:
	progs/util/shaderutil.c
	src/mesa/drivers/dri/r600/r600_context.c
	src/mesa/main/version.h
2009-11-30 17:47:07 -08:00
Brian Paul
344a2a9abb progs/trivial: added two simple texture tests
One draws a series of quads with different textures.
The other draws with one texture which is changed with glTexSubImage2D().
2009-11-30 15:31:34 -07:00
Roland Scheidegger
decf6ed810 fixups for interface changes (mostly state trackers) 2009-11-30 23:02:49 +01:00
Brian Paul
7505510c7b llvmpipe: add a bunch of comments 2009-11-30 14:02:01 -07:00
Brian Paul
7d042ac2a2 llvmpipe: minor refactoring of bin rasterization code 2009-11-30 14:01:31 -07:00
Roland Scheidegger
ac400ffce6 gallium: interface cleanups, remove nblocksx/y from pipe_texture and more
This patch removes nblocksx, nblocksy arrays from pipe_texture (can be
recalculated if needed). Furthermore, pipe_format_block struct is gone
completely (again, contains just derived state).
nblocksx, nblocksy, block are also removed from pipe_transfer, together with
the format enum (can be obtained from the texture associated with the transfer).
2009-11-30 20:29:18 +01:00
Brian Paul
bfa1a766d6 llvmpipe: update C_SOURCES 2009-11-30 10:43:23 -07:00
Keith Whitwell
bb1cde755b i965g: turn on texture tiling by default 2009-11-30 16:16:30 +00:00
Brian Paul
7725744433 st/mesa: handle front/back-face +1/-1 vs. 1/0 conversion
Fixes progs/glsl/twoside.c demo.
2009-11-30 08:57:04 -07:00
Keith Whitwell
6781f624af i965g: pass backbuffer tiling information to driver
The gem winsys gets this information, needs to pass it on.
2009-11-30 15:37:27 +00:00
Keith Whitwell
1fd3a2773b ws/i965: more debug output 2009-11-30 15:37:27 +00:00
Keith Whitwell
1dfdc0a615 ws/i965: rename and change sense of I965_SEND_CMD to BRW_NO_HW 2009-11-30 15:37:27 +00:00
Keith Whitwell
cddc7e3a9c brw: add dumping to gem winsys 2009-11-30 15:37:27 +00:00
Keith Whitwell
4490122d0c i965g: remove redundant nr_attrs member 2009-11-30 15:37:27 +00:00
Vinson Lee
270d36da14 mesa: Fix array out-of-bounds access by _mesa_TexParameterf.
_mesa_TexParameterf calls set_tex_parameterf, which uses the params
argument as an array.
2009-11-29 21:17:44 -05:00
Vinson Lee
a201dfb6bf mesa: Fix array out-of-bounds access by _mesa_TexParameterf.
_mesa_TexParameterf calls set_tex_parameteri, which uses the params
argument as an array.
2009-11-29 18:18:23 -05:00
Richard Li
a1b9c4e22a r600 : clena up a bit for last commit. 2009-11-29 12:33:14 -05:00
Richard Li
2db72f329f r600 : add read port allocation for uniform;
mapping ps input based on vs output;
       fix bugs including constants updating for vs.
2009-11-29 12:33:14 -05:00
Maciej Cencora
63c00c53a3 radeon: update miptree code a little
Simplify gl image level <-> miptree level mapping (are equal now).
Don't allocate miptree for images that won't fit in it (fixes #25230).
2009-11-29 17:27:48 +01:00
Maciej Cencora
2773556d55 radeon: don't check the same miptree many times when looking for matching miptrees 2009-11-29 17:27:47 +01:00
Maciej Cencora
e8f0c8ab9d radeon: add some debugging info 2009-11-29 17:27:47 +01:00
Christoph Bumiller
c332525ad3 nv50: update linkage on rasterizer change
We need to update VP_RESULT_MAP and/or COORD_REPLACE_MAP
when light_twoside and/or point_sprite are changed.
2009-11-29 13:41:47 +01:00
Christoph Bumiller
7494b82905 nv50: match VP outputs to FP inputs ourselves
For each FP input, don't assume that the VP output will be
at the same position, but scan the semantics instead, then
put the correct output reg indices into VP_RESULT_MAP.

Position is still assumed to be the first output/input.

See 07fafc7c93, which renders
previous assumptions incorrect.
2009-11-29 13:41:47 +01:00
Christoph Bumiller
3f471c7948 nv50: don't permanently negate src in emit_ddy 2009-11-29 13:41:47 +01:00
Dave Airlie
ca9b0e942c i965g: remove surface from views list before freeing
this fixes a crash with the xorg state tracker, however it then locks
up the GPU once rendering is enabled but at least it doesn't crash.

Signed-off-by: Dave Airlie <airlied@linux.ie>
2009-11-29 18:59:19 +10:00
Vinson Lee
ca5a7aadb4 mesa: Fix array out-of-bounds access by _mesa_TexGenf.
_mesa_TexGenf calls _mesa_TexGenfv, which uses the params argument
as an array.
2009-11-29 00:50:48 -05:00
Vinson Lee
d55fb7c835 mesa: Fix array out-of-bounds access by _mesa_TexGeni.
_mesa_TexGeni calls _mesa_TexGeniv, which uses the params argument
as an array.
2009-11-28 23:47:23 -05:00
Vinson Lee
919898e92f dri: Fix potential null pointer dereference in driBindContext. 2009-11-28 23:22:31 -05:00
Vinson Lee
a11d60d14c mesa: Fix array out-of-bounds access in _mesa_TexEnvf.
_mesa_TexEnvf calls _mesa_TexEnvfv, which uses the param argument
as an array.
2009-11-28 22:08:20 -05:00
Maciej Cencora
e5159996a4 radeon: need to flush cs when moving images between mipmap trees 2009-11-28 21:36:59 +01:00
Corbin Simpson
287bdd8e75 util: Fix bad code.
Uf. How embarrassing.
2009-11-28 10:45:17 -08:00
Corbin Simpson
c93dcbfea7 util: Improve bitcount.
Sorry for not pushing this before, it got lost in stashes.
2009-11-28 10:14:42 -08:00
Dave Airlie
6f1bc4267f i965g: link xorg state tracker with -ldrm_intel 2009-11-28 17:44:28 +10:00
Christoph Bumiller
cad14c2542 nv50: do conversion of last insn to 64 bit format first
Simplifies things since the second to last one will then
be converted in the subsequent pass that ensures alignment
automatically.
2009-11-27 21:29:38 +01:00
Christoph Bumiller
510fd280b5 nv50: bswap32 the polygon stipple pattern
The hardware wants the pattern the same way it is
passed to glPolygonStipple.
2009-11-27 21:29:22 +01:00
Christoph Bumiller
e65258abf5 gallium/util: added util_bswap32() 2009-11-27 21:28:56 +01:00
José Fonseca
2348f6d490 scons: Promote pointer arithmetic to error.
All code covered by scons is being built on multiple OSes, so pointer
arithmetic must really be addressed when spotted.
2009-11-27 17:06:12 +00:00
José Fonseca
5976d8e6f1 configs: Warn about pointer arithmetic.
It's not portable. Warn to help catching it early.
2009-11-27 17:06:12 +00:00
José Fonseca
f62f976e3f mesa: Avoid void pointer arithmetic. 2009-11-27 17:06:12 +00:00
Roland Scheidegger
7fa1bcc05a svga: fix for not using texture width/height/depth arrays 2009-11-27 17:41:42 +01:00
Roland Scheidegger
b748a9f574 r300g,llvmpipe: fix some more merge problems 2009-11-27 17:40:24 +01:00
Roland Scheidegger
c95cbd45c6 Merge branch 'width0'
Conflicts:
	src/gallium/drivers/r300/r300_texture.c
	src/gallium/state_trackers/xorg/xorg_exa.c
	src/mesa/state_tracker/st_cb_texture.c
2009-11-27 17:15:47 +01:00
Keith Whitwell
4236493899 st/xorg: proper fix for compositing after rounding up
Basically don't round up shared textures.  This fixes compiz,
but I'm afraid that rounding up texture sizes here in the driver
is doomed, as it will inevitably break texture wrap modes.
2009-11-27 15:30:18 +00:00
José Fonseca
1310811469 rbug: Mention where the GUI can be found. 2009-11-27 14:55:20 +00:00
José Fonseca
6dd9676a8f svga: Re-add shader dumping. 2009-11-27 14:04:47 +00:00
Keith Whitwell
6810ce005a Revert "st/xorg: fix composite after texture size changes"
This reverts commit 124ae59680.

Pushed by mistake
2009-11-27 14:03:10 +00:00
Keith Whitwell
124ae59680 st/xorg: fix composite after texture size changes 2009-11-27 13:59:22 +00:00
José Fonseca
dc86f4a20b wgl: Fix copy'n'paste typo in comment. 2009-11-27 13:35:04 +00:00
José Fonseca
135d7e1299 svga: Handle comment tokens when dumping. 2009-11-27 13:34:13 +00:00
José Fonseca
d3f26a8420 svga: Use consistent names for public symbol names of shader dumping facilities. 2009-11-27 13:34:07 +00:00
José Fonseca
178407f33c svga: Use consistent file names for dumping facilities. 2009-11-27 13:34:04 +00:00
Keith Whitwell
cf3cdda5cc st/xorg: speculatively round textures up to nearest POT
I'm not sure if this is a great change, but helps with caching.
Probably we want to turn this on/off on a driver-by-driver basis.
2009-11-27 12:24:57 +00:00
Keith Whitwell
e595dd4c17 st/xorg: free last fence 2009-11-27 12:24:57 +00:00
Keith Whitwell
b84b7f19df svga: flush our command buffer after the 8th distinct render target
This helps improve the surface cache behaviour in the face of the
large number of single-use render targets generated by EXA and the xorg
state tracker.  Without this we can reference hundreds of individual
render targets from a command buffer, which leaves little scope for
sharing or reuse of those targets.

Flushing early means we can start reusing textures much sooner.

This shouldn't have much effect on normal 3d rendering as it's pretty
rare to have a command buffer with >8 different render targets in that
world.
2009-11-27 12:24:57 +00:00
Keith Whitwell
b911688b87 svga: add DEBUG_CACHE option 2009-11-27 12:24:57 +00:00
Michal Krol
5285de7c0f vega: Update shader headers.
Drop the 1.1 version suffix.
2009-11-27 10:13:53 +01:00
Michal Krol
9a4e4e035c python/tests: Update shader headers.
Drop the 1.1 version suffix.
2009-11-27 10:13:19 +01:00
Michal Krol
456b5bd5d0 svga: Update text shader header. 2009-11-27 10:11:18 +01:00
Michal Krol
72420daa21 vl: Do not emit tgsi_version token. 2009-11-27 10:07:07 +01:00
Michal Krol
e6133564bf tgsi: Remove tgsi_version token. 2009-11-27 10:06:41 +01:00
Michal Krol
5455e88f1c gallium: Remove tgsi_version token.
Not really needed, never served its purpose.
2009-11-27 09:19:01 +01:00
Vinson Lee
69671df74c svga: Prevent potential null pointer dereference in vmw_surface.c. 2009-11-26 23:03:53 -05:00
Roland Scheidegger
d509f84543 gallium: fix more statetrackers/drivers for not using texture width/height/depth arrays 2009-11-26 22:51:45 +01:00
Michal Krol
884007546c tgsi/exec: Fix orientation of DDY. 2009-11-26 20:41:46 +01:00
Michal Krol
a2c101029d tgsi/exec: Force return from a subroutine at ENDSUB. 2009-11-26 20:41:43 +01:00
Keith Whitwell
3bae72e204 draw: Fix max_index check.
We want to fallback to draw splitting when vertex element indices
might be too high for atomic draw path (currently limited to 4095).
2009-11-26 20:41:41 +01:00
Michal Krol
75df599e30 tgsi/ureg: Add forgotten goto in ureg_DECL_constant(). 2009-11-26 20:41:38 +01:00
José Fonseca
953b74d116 llvmpipe: Fake missing SSSE3 when simulation less capabable machines.
SSE3 != SSSE3 and so far we only use the later.
2009-11-26 11:16:35 +00:00
José Fonseca
da1c40260d llvmpipe: Update/correct CPU requirements.
There are no hard requirements at the moment.

We don't really emit any sse3 yet. Just some ssse3.

Thanks to Roland for spotting these incorrections.
2009-11-26 11:16:34 +00:00
Roland Scheidegger
4dcdf3b9c6 Merge commit 'origin/st-shader-varients'
Conflicts:
	src/mesa/state_tracker/st_atom_shader.c
	src/mesa/state_tracker/st_program.c
2009-11-26 01:15:25 +01:00
José Fonseca
9e3728c858 scons: Make it work with MinGW build of LLVM 2.6.
LLVM 2.5 is no longer supported on windows.
2009-11-25 18:07:27 +00:00
Michal Krol
e13add8cae tgsi: Fix token builder. 2009-11-25 16:08:36 +01:00
Michal Krol
ea6b36ca3f tgsi: Update raw token dumper after token definition changes. 2009-11-25 15:56:10 +01:00
Michal Krol
77a0a3e5ca glsl/apps: Make compile more shell friendly. 2009-11-25 14:59:29 +01:00
Michal Krol
ee27b713dc slang/library: Don't need the *_gc.h files, they are autogenerated now. 2009-11-25 14:53:37 +01:00
Michal Krol
3371f7e502 scons: Autogenerate GLSL builtin library *_gc.h from *.gc files. 2009-11-25 14:52:21 +01:00
Dave Airlie
ce56a867f7 r600: add ARB_texture_non_power_of_two support.
This makes the miptree rounds up to the near POT for each level for
all radeons, however since mipmaps aren't support with NPOT on previous
radeons this calculation shouldn't cause any problems. If it does
we can just make it r600 only.

I tested a few mipmap demos on r500 and they all seem to work.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-11-25 15:45:31 +10:00
Jakob Bornecrantz
949d95e88a vmware/xorg: Remove gem include 2009-11-25 02:22:35 +01:00
Michel Dänzer
42db8c8cdb st/xorg: Use pipe clear hook for solid fills of whole pixmaps.
Can give a little boost e.g. for anti-aliased text rendering.
2009-11-26 16:46:13 +01:00
Keith Whitwell
b96218c656 svga: hash the whole key, not just the first four bytes 2009-11-26 15:25:42 +00:00
Michel Dänzer
3eb3bfb7c7 st/xorg: Make sure DRI2 blits use GPU copy contents even for software fallback.
Fixes 3D apps not updating with a non-GL compositing manager and Option
"2DAccel" "off".

Also clean up a little pixmap vs. drawable mess.
2009-11-26 16:00:06 +01:00
Keith Whitwell
ecfe1352cc st/xorg: fix refcounting bugs introduced in earlier commit 2009-11-26 14:23:24 +00:00
Keith Whitwell
dfb871d403 st/xorg: formatting
This directory needs indent run over it.
2009-11-26 14:23:07 +00:00
Keith Whitwell
41423c01b2 st/xorg: remove debugging flush
Accidentally committed in 7fbdbad5c0
('st/xorg: consolidate some dest surface state setting')
2009-11-26 12:53:36 +00:00
José Fonseca
c783f5cfd8 svga: Remove spurious argument to SVGA_DBG. 2009-11-26 12:02:59 +00:00
Keith Whitwell
7b0e4adaf2 st/xorg: render throttling in block handler
Similar to the classic swapbuffer throttling in GL drivers, put an
upper bound on the number of outstanding chunks of rendering the state
tracker can generate -- where calling the block handler denotes a
chunk.

Currently that number is set at around 4 "chunks", but could be
tweaked up or down.  If a better measure for the amount of outstanding
rendering is found, that would be fine too.

As it stands, this improves interactivity by preventing the X server
from queueing up arbitary amounts of rendering.
2009-11-26 11:55:47 +00:00
Keith Whitwell
8544c309d0 st/xorg: split copy operation into prepare/copy/done phases
Any high-overhead one-off tasks are moved into the prepare hook.
2009-11-26 11:23:37 +00:00
Keith Whitwell
91a5131e6b st/xorg: don't set up constant buffer for non-xv fragment shaders
These currently don't reference any constants.  Can add this back
if newer shaders need them, but in the meantime don't create
a new constant buffer every time we do a blit.
2009-11-26 11:23:36 +00:00
Keith Whitwell
fa799f81de st/xorg: split up shared Done call
The two users of composite (Composite and Solid) now call a new
xorg_composite_done() from their Done functions, while CopyDone
is directly implemented on top of xorg_renderer.c.
2009-11-26 11:23:36 +00:00
Keith Whitwell
b4ea1eb871 st/xorg: set up rasterizer state in init 2009-11-26 11:23:36 +00:00
Keith Whitwell
86ba5139a8 st/xorg: remove redundant clipping code 2009-11-26 11:23:36 +00:00
Keith Whitwell
899d20cfaa st/xorg: don't bother with cso save and restore in copy func 2009-11-26 11:23:36 +00:00
Keith Whitwell
7fbdbad5c0 st/xorg: consolidate some dest surface state setting 2009-11-26 11:23:36 +00:00
Vinson Lee
808f037660 glu/sgi: Fix memory leak in gluBuild2DMipmapLevelsCore. 2009-11-26 00:35:31 -05:00
Richard Li
11dce74030 r600 : reset stack flag with one channel only. 2009-11-24 16:00:25 -05:00
Jakob Bornecrantz
45d9ea3619 vmware/xorg: Link against libkms
If the system doesn't have libkms installed it wont try to link against it.
2009-11-24 19:20:59 +01:00
Jakob Bornecrantz
77529a2cf2 vmware/xorg: Clean Makefile a bit 2009-11-24 19:16:37 +01:00
Jakob Bornecrantz
522e840a91 vmware/xorg: Don't link against libdrm_intel 2009-11-24 18:47:15 +01:00
Jakob Bornecrantz
eca5d6944a vmware/xorg: Stage driver in lib/gallium 2009-11-24 18:46:40 +01:00
Richard Li
d4c2f53ca5 r600 : fix stack depth setting bug. 2009-11-24 12:16:39 -05:00
José Fonseca
8bf4e5d617 llvmpipe: Update instructions. 2009-11-24 16:01:01 +00:00
Keith Whitwell
91a4e6d53f tgsi: rename fields of tgsi_full_src_register to reduce verbosity
SrcRegister -> Register
SrcRegisterInd -> Indirect
SrcRegisterDim -> Dimension
SrcRegisterDimInd -> DimIndirect
2009-11-24 15:13:17 +00:00
Keith Whitwell
5b0824dfe5 tgsi: rename fields of tgsi_full_dst_register to reduce verbosity
DstRegister -> Register
DstRegisterInd -> Indirect
2009-11-24 15:08:55 +00:00
Keith Whitwell
fe2b31e4a8 tgsi: rename fields of tgsi_full_declaration to reduce verbosity
DeclarationRange -> Range
2009-11-24 15:04:18 +00:00
Keith Whitwell
7d6c8f980d tgsi: rename fields of tgsi_full_instruction to avoid excessive verbosity
InstructionPredicate -> Predicate
InstructionLabel -> Label
InstructionTexture -> Texture
FullSrcRegisters -> Src
FullDstRegisters -> Dst
2009-11-24 15:02:23 +00:00
Keith Whitwell
763426a025 tgsi: reduce repetition of structure name in its members
Rename Semantic.SemanticName to Semantic.Name.  Similar for
SemanticIndex, and the members of the tgsi_version struct.
2009-11-24 14:53:29 +00:00
José Fonseca
f3a0615fb0 svga: Handle comment tokens when dumping. 2009-11-24 14:49:21 +00:00
Keith Whitwell
42ae003069 tgsi: remove unnecessary full_token init and free functions 2009-11-24 14:45:56 +00:00
Keith Whitwell
9fbfe6b65d tgsi: remove unused Flags member from full_instruction 2009-11-24 14:44:45 +00:00
José Fonseca
d185c2fd13 svga: Use consistent names for public symbol names of shader dumping facilities. 2009-11-24 14:43:30 +00:00
José Fonseca
a71f836504 svga: Use consistent file names for dumping facilities. 2009-11-24 14:37:45 +00:00
José Fonseca
1325361abe util: Describe a few more formats. 2009-11-24 14:25:21 +00:00
José Fonseca
4ae3e88dc9 llvmpipe: Use assert instead of abort. Only verify functions on debug builds. 2009-11-24 14:25:21 +00:00
José Fonseca
066991c8d1 llvmpipe: Fix memory leak. 2009-11-24 14:25:20 +00:00
José Fonseca
2282fb7710 llvmpipe: Use the generic conversion routine for depths.
This allows for z32f depth format to work correctly.
2009-11-24 14:25:20 +00:00
José Fonseca
b375526b50 llvmpipe: Be more conservative with the supported formats.
We'll likely support much more formats, but doing this allows to run
more testsuites without immediately hit assertion failures.
2009-11-24 14:25:20 +00:00
José Fonseca
c6d663e6dc wgl: Fix copy'n'paste typo in comment. 2009-11-24 14:25:20 +00:00
José Fonseca
52df532b02 llvmpipe: Fix typo in comparison operator. 2009-11-24 14:25:20 +00:00
Keith Whitwell
56ee132f96 gallium: try and update r300 and nv drivers for tgsi changes
It would be nice if these drivers built under the linux-debug header
so that these types of interface changes can be minimally propogated
into those drivers by people without the hardware.  They don't have to
generate a working driver -- though a command-dumping winsys would be
an excellent for regression checking.
2009-11-24 14:09:24 +00:00
Jakob Bornecrantz
7fac8ce73b st/xorg: Pass mode types from the kernel to X 2009-11-24 14:53:03 +01:00
Keith Whitwell
ba1ca28cc6 gallium: simplify tgsi tokens further
Drop anonymous 'Extended' fields, have every optional token named
explicitly in its parent.  Eg. there is now an Instruction.Label flag,
etc.

Drop destination modifiers and other functionality which cannot be
generated by tgsi_ureg.c, which is now the primary way of creating
shaders.

Pull source modifiers into the source register token, drop the second
negate flag.  The source register token is now full - if we need to
expand it, probably best to move all of the modifiers to a new token
and have a single flag for it.
2009-11-24 13:41:03 +00:00
Jakob Bornecrantz
ee40b20e7a st/xorg: Add libkms integration 2009-11-24 12:57:32 +01:00
Jakob Bornecrantz
1a19b9dbc2 st/xorg: Touch up xorg_crtc.c 2009-11-24 12:57:32 +01:00
Jakob Bornecrantz
def9b0e586 st/xorg: Rename driver functions 2009-11-24 12:57:32 +01:00
Jakob Bornecrantz
431e85f894 st/xorg: Rename output functions 2009-11-24 12:57:31 +01:00
Jakob Bornecrantz
6713a83bb8 st/xorg: Rename dri2 functions 2009-11-24 12:57:31 +01:00
Jakob Bornecrantz
26f9eeddf4 st/xorg: Standardise all function names defined in xorg_tracker.h 2009-11-24 12:57:31 +01:00
Keith Whitwell
2946aea110 svga: try harder to make the cachable flag work
It doesn't though.
2009-11-25 17:14:07 +00:00
Zack Rusin
c712f33746 st/xorg: accelerate src luminance 2009-11-25 10:20:08 -05:00
Zack Rusin
d228e3cc8e util: also print out memory statistics 2009-11-25 10:20:08 -05:00
Keith Whitwell
55b0157860 svga: revert packing of surface key
Over-ambitious packing of values broke my cursor.
2009-11-25 11:45:20 +00:00
Dave Airlie
92c6a26a8a radeon: fix context destroy needing lock for flushing.
Thanks to Intel code which I've just stolen pretty much as usual.

This fixes fdo bug 22851 which is a dri1 regression since rewrite.

Tested by: fpiobaf (Fabio) on #radeon
Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-11-25 20:40:15 +10:00
Vinson Lee
94bcb9f1a4 glu/sgi: Fix memory leak in gluBuild1DMipmapLevelsCore. 2009-11-25 00:39:37 -05:00
Vinson Lee
0d89f3dc7f glu/sgi: Fix memory leak in gluBuild2DMipmapLevelsCore. 2009-11-25 00:28:56 -05:00
Vinson Lee
f895abbd97 glu/sgi: Fix memory leak in gluBuild3DMipmapLevelsCore. 2009-11-25 00:18:49 -05:00
Keith Whitwell
f1ce37f74a svga: cache textures as well as buffers 2009-11-24 21:15:35 +00:00
Keith Whitwell
4509f3cbad st/xorg: use surface_copy for blits if available
Even if its not available, we really want to be coalescing blit
operations better.
2009-11-24 21:15:35 +00:00
Michal Krol
3c46bbee1b tgsi: Document Declaration Semantic token and FACE semantic name. 2009-11-24 11:58:01 +01:00
Michal Krol
bae9ece685 slang: Fix allocation size.
We don't need 16K+ to store a single pointer.
2009-11-24 11:22:03 +01:00
Michal Krol
53d9b7d361 mesa: Fix pointer arithmetic. 2009-11-24 11:17:16 +01:00
Michal Krol
0c54d76f37 tgsi: Implement predicated instructions in exec. 2009-11-24 09:05:31 +01:00
Michal Krol
59a70c364d tgsi: Add ureg_DECL_loop(). 2009-11-24 09:05:29 +01:00
Michal Krol
5ee0d9f632 tgsi: Account for gallium shader token representation changes. 2009-11-24 09:05:28 +01:00
Michal Krol
57221c5438 gallium: Refactor the instruction predicate TGSI token.
Rename it to tgsi_instruction_predicate -- it's no longer an extended
token. Its presence is indicated by a new flag in tgsi_instruction that
indicates whether an instruction is predicated.

Also, change predicate index representation to match the other
tokens that specify register indices.
2009-11-24 09:05:26 +01:00
Dave Airlie
2176b3ed9a r300: fix swtcl bo leak problem.
We can get a lot of swtcl bo allocations - need to probably abstract
this a bit further.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-11-24 11:56:45 +10:00
Dave Airlie
bd13e6e5e2 radeon/r200/r300/r600: make bo mapping be explicit
This moves the bo mapping outside the DMA layer and makes it explicit,
this should in theory make it simpler to split the clean up the dma/cmdbuf
linkage that I created before that is broken.

Tested on: r600, rv380 (tcl/no-tcl), rv200 (tcl/no-tcl)

Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-11-24 11:38:36 +10:00
Brian Paul
863ad9a683 mesa: use gcc __builtin_popcount() 2009-11-23 18:09:46 -07:00
Brian Paul
8d80b5400a r300g: use util_bitcount() 2009-11-23 18:06:19 -07:00
Brian Paul
0a27c7b963 egl: use util_bitcount() 2009-11-23 18:04:47 -07:00
Brian Paul
15740eb03c gallium/util: added util_bitcount() 2009-11-23 18:04:22 -07:00
Jakob Bornecrantz
acc51ac0ac svga: Filter out pendantic and ansi flags
Rather have the driver compile without the flags then
having to disable them.
2009-11-24 01:16:17 +01:00
Vinson Lee
326b66d724 glu/sgi: Fix memory leak in gluBuild3DMipmapLevelsCore. 2009-11-24 01:23:12 -05:00
Vinson Lee
364070b1f2 dri: Fix potential null pointer deference in dri_put_drawable. 2009-11-24 00:57:55 -05:00
Maciej Cencora
5173d14cb5 Merge commit 'origin/mesa_7_7_branch' 2009-11-23 22:14:48 +01:00
Maciej Cencora
960464e42d radeon: fix errors in miptree related function
- typo
- memory leak
- off by one (spotted by airlied)
2009-11-23 21:59:08 +01:00
Maciej Cencora
635823d267 Merge branch 'mesa_7_7_branch' of http://anongit.freedesktop.org/git/mesa/mesa into mesa_7_7_branch 2009-11-23 21:28:22 +01:00
Michal Krol
03f0ebe3bd slang: Fix order of parameters to sl_pp_tokenise(). 2009-11-23 20:12:17 +01:00
Jakob Bornecrantz
86710c3334 svga: Scrub Makefiles a bit
Remove x86 specific hacks. Not that they will ever be used on
none x86 arches, but they are built by default. And the way the
flags where added was a hack.
2009-11-23 20:09:00 +01:00
Michal Krol
18384af749 slang: Check return value from emit_instruction(). 2009-11-23 13:22:04 +01:00
Michal Krol
c511e0b844 tgsi: Clamp the source argument in micro_exp2() to avoid Inf. 2009-11-23 11:32:58 +01:00
Michal Krol
eacdd8fa75 tgsi: Remove code that actually had no effect. 2009-11-23 11:29:29 +01:00
Michal Krol
cc93fa3527 softpipe: Initialise TGSI machine's Face. 2009-11-23 10:51:07 +01:00
Michal Krol
cc35a454da tgsi: Fix POSITION and FACE fragment shader inputs. 2009-11-23 10:49:41 +01:00
Michal Krol
b7590cde4a tgsi: Bring BGNFOR/ENDFOR implementation up to spec. 2009-11-23 10:40:05 +01:00
Michal Krol
cde758a2b5 tgsi: Fake TXD implementation in exec. 2009-11-23 10:29:08 +01:00
Michal Krol
f359ac5486 tgsi: Add execution debugging facilities to exec. 2009-11-23 10:29:07 +01:00
Michal Krol
f61865799d slang: Be more robust with memory in concat_shaders(). 2009-11-23 10:29:05 +01:00
Vinson Lee
67125c7f9a mesa: Initialize variable in _mesa_get_texel_fetch_func. 2009-11-23 01:52:59 -05:00
Vinson Lee
4b0b250aae glx: Prevent potential null pointer deference in driCreateContext. 2009-11-23 01:30:32 -05:00
Vinson Lee
5b925b7daa glu/sgi: Fix memory leak in bitmapBuild2DMipmaps. 2009-11-23 01:09:06 -05:00
Vinson Lee
b611f639b4 glu/sgi: Fix memory leak in gluScaleImage3D. 2009-11-23 00:57:37 -05:00
Keith Whitwell
0a89ad80d9 i965g: gs nr_attrs also tracks nr fragment shader inputs
Or, equivalently, nr of outputs of active vertex shader varient.
2009-11-23 03:06:58 +00:00
Keith Whitwell
cd0e6619e6 i965g: correct test for unfilled modes 2009-11-23 03:00:47 +00:00
Richard Li
a12b468d00 r600 : add support for shader instruction trunc and discard. 2009-11-22 21:37:44 -05:00
Keith Whitwell
968a7dfb29 i965g: use correct key size for vs upload 2009-11-23 01:47:57 +00:00
Keith Whitwell
21172d4358 i965g: apply linear math to both linear and perspective attrs 2009-11-23 00:58:13 +00:00
Dave Airlie
c3c8c40cab r600: hopefully fix segfault. 2009-11-23 06:44:29 +10:00
Dave Airlie
f9b0f1dfa1 r600: fix inline issues 2009-11-23 06:31:29 +10:00
Richard Li
1f8c23d9db r600 : add stack depth calculation, enable CF pop. 2009-11-22 13:03:20 -05:00
Richard Li
a02938a842 r600 : use cf for all pop now, left optimization for future. 2009-11-22 13:03:19 -05:00
Maciej Cencora
e0fda04013 r300: fix VP source conflict resolution on 64-bit machines
On 32bit machines we were lucky because the sizeof(reg) == sizeof(rc_src_register).
On 64bit machines pointers are 8 bytes long, so we were overwriting other data.
2009-11-22 15:08:46 +01:00
Maciej Cencora
dfe440c856 r300: fix SIN/COS/SCS instructions for R300 fp 2009-11-22 14:13:18 +01:00
Vinson Lee
a9c540f5de glu/sgi: Fix memory leak in gluScaleImage. 2009-11-22 01:57:35 -05:00
Vinson Lee
d3b4c99c70 glu: Fix memory leak in __gl_meshMakeEdge. 2009-11-22 01:45:53 -05:00
Vinson Lee
57d389aab5 svga: Prevent potential null pointer deference in vmw_surface.c. 2009-11-22 01:26:32 -05:00
Vinson Lee
b62a74d3b9 svga: Fix memory leak in vmw_screen_ioctl.c 2009-11-22 01:20:07 -05:00
Vinson Lee
88aab56a26 st/xorg: Prevent potential null pointer deference in xorg_xv.c. 2009-11-22 01:10:38 -05:00
Vinson Lee
46feb7db71 st/xorg: Reorder cases in switch statement.
Silences missing break statement warning.
2009-11-22 00:55:52 -05:00
Corbin Simpson
2b07b64061 r300g: Build fix.
Oops.
2009-11-21 19:13:26 -08:00
Marek Olšák
44c0aaf990 r300g: do not reallocate r300_vertex_info and r300_rs_block all the time 2009-11-21 14:52:26 -08:00
Marek Olšák
3a2cd66af8 r300g: clean up vs/fs tabs
Instead of vs_tab, we use vs_output_tab and it's local now. fs_tab hasn't
been used anywhere, so I removed it and r300_update_fs_tab too.
2009-11-21 14:52:26 -08:00
Michal Krol
6199a0cf89 glsl/apps: No need to purify source text for tokeniser. 2009-11-21 20:44:16 +01:00
Michal Krol
1cf021475a slang: No need to purify source text for tokeniser. 2009-11-21 20:43:02 +01:00
Michal Krol
abe1f33298 glsl/pp: Do purification and tokenisation in a single step. 2009-11-21 20:41:48 +01:00
Maciej Cencora
563fe6e8f6 radeon: fix compressed mipmapped textures
Tested on r300 only, other cards may require adjusting texture_compressed_row_align.
2009-11-21 16:49:18 +01:00
Maciej Cencora
1d1f81af93 radeon: fix glCompressedTexSubImage 2009-11-21 16:49:18 +01:00
Maciej Cencora
d20b79172d radeon: fix compressed mipmapped textures
Tested on r300 only, other cards may require adjusting texture_compressed_row_align.
2009-11-21 16:30:48 +01:00
Maciej Cencora
df87877636 radeon: fix glCompressedTexSubImage 2009-11-21 16:30:41 +01:00
Roland Scheidegger
465fee75ee intel: make CopyTex[Sub]Image fallback debug messages more consistent 2009-11-21 04:41:43 -08:00
Roland Scheidegger
c367f4d46e mesa: handle different RowStride in _mesa_get_compressed_teximage
drivers storing compressed textures with non-native stride but relying on
_mesa_get_compressed_teximage for GetCompressedTexImage otherwise won't
work correctly (for instance i965 compressed mipmaps).
2009-11-21 04:41:43 -08:00
Eric Anholt
8451b29d96 i965: Fix several memory leaks on exit.
Bug #25194.
2009-11-21 13:33:57 +01:00
Marek Olšák
435c495549 r300g: silence warnings 2009-11-20 18:06:21 -08:00
Marek Olšák
624a0cd9c1 r300g: fix typo in r300_reg.h to prevent the RS unit from doing random things
And reorder fragment shader inputs so that the colors are before texcoords,
as is allocated by the shader compiler. This commit makes VS->FS attribute
routing work on R500.
2009-11-20 18:05:21 -08:00
Marek Olšák
4e1236e602 r300g: fix updating a vertex format
We must update PSC when we change the vertex format, e.g. vertex colors
from RGBA to BGRA.
2009-11-20 18:04:06 -08:00
Marek Olšák
b7078a8811 r300g: add texture lod clamping
These now work:
piglit/lodclamp
piglit/levelclamp
2009-11-20 17:58:13 -08:00
Keith Whitwell
8bf75f28de i965g: get basic texturing working again
Revert to fixed-layout surface binding table -- it's probably the best
way to do this.  Pass sampler and texture numbers separately even
though we're always keeping them the same at present.
2009-11-21 01:52:22 +00:00
Corbin Simpson
1c181a7eff r300g: Begin separating HW TCL and SW TCL state and setup.
This patch removes draw_context entirely from the HW TCL path and cleans up
a few other things along the way. Hopefully, nothing got broken.

Thanks to Marek Olšák for testing, review, and pointing out my bugs. :3
2009-11-20 17:48:10 -08:00
Vinson Lee
052b127842 st/egl: Fix memory leak in egl_tracker.c. 2009-11-20 16:33:25 -08:00
Vinson Lee
ea98e9820d draw: Initialize variable in draw_pt.c. 2009-11-20 16:03:48 -08:00
Vinson Lee
e19195c185 progs/xdemos: Fix memory leak in pbinfo.c. 2009-11-20 15:52:53 -08:00
Vinson Lee
e0857962b9 progs/xdemos: Fix memory leak in pbdemo.c. 2009-11-20 15:48:29 -08:00
Vinson Lee
538a8df652 progs/xdemos: Fix memory leak in glxpbdemo.c. 2009-11-20 15:18:19 -08:00
Marek Olšák
015e7e7724 r300g: emit R300_TEX_ENABLE to indicate there are no textures bound
Previously, this reg wasn't emitted at all if texture_count == 0.
2009-11-20 15:12:18 -08:00
Marek Olšák
ae70cd1f02 r300g: remove variant states from emit_state_invariant 2009-11-20 15:08:52 -08:00
Vinson Lee
a4720a1a32 progs/xdemos: Remove duplicate code in glxinfo.c. 2009-11-20 15:06:56 -08:00
Vinson Lee
66a4ec14c3 progs/xdemos: Add assert in corender.c. 2009-11-20 15:03:16 -08:00
Corbin Simpson
6a95996abb r300g: Texrect factor cleanup.
(0, 0, 0, 1) is a much saner default value, and texrect factors only need
to be (1/s, 1/t, 0, 1).
2009-11-20 14:56:13 -08:00
Marek Olšák
f4041b37e2 r300g: fix rectangle textures on r3xx
Adapted from Maciej Cencora's patch.
2009-11-20 14:47:31 -08:00
Vinson Lee
f6541773c4 i915g: Add missing break statement in i915_debug.c. 2009-11-20 14:31:42 -08:00
Vinson Lee
36e2074b63 gallium/util: Initialize variables in u_pack_color.h. 2009-11-20 14:20:15 -08:00
Corbin Simpson
06ec216d19 r300g: Clean up bitcounting function.
I didn't see this in u_math; surely somebody else has this wheel
reinvented elsewhere.
2009-11-20 14:10:59 -08:00
Corbin Simpson
6a3eb1f91b r300g: Use MAX3 and MIN3. 2009-11-20 14:10:45 -08:00
Corbin Simpson
37ba97421c util: Add MAX3 and MIN3. 2009-11-20 14:08:58 -08:00
Marek Olšák
beea241374 r300g: set better values in the R300_VAP_CNTL register 2009-11-20 13:33:37 -08:00
Alan Hourihane
0295edf596 Fix comment to use /* */ rather than // 2009-11-20 18:11:30 +00:00
Alan Hourihane
904469dcd2 Fix indentation. 2009-11-20 18:10:54 +00:00
Alan Hourihane
8f648cd3e4 Fix vega compilation. 2009-11-20 18:09:10 +00:00
Alan Hourihane
a24631bcd7 Fix memory leak. 2009-11-20 18:08:29 +00:00
Richard Li
08e5d1ecad r600 : eliminate Wondows line ending for test code. 2009-11-20 11:03:09 -05:00
Michal Krol
b89cd8afc5 glsl/pp: Expand unknown identifiers to 0 in if/elif expressions. 2009-11-20 08:59:50 +01:00
Keith Whitwell
95d7aca4b9 i965g: fix typo converting wm src regs 2009-11-19 20:40:41 -08:00
Keith Whitwell
9507a6c206 i965g: fragment shader immediates working 2009-11-19 20:02:42 -08:00
Keith Whitwell
63b0af0775 i965g: first pass at vs immediates in curbe 2009-11-19 19:51:14 -08:00
Keith Whitwell
3fafe2b969 progs/vp: add param and imm test 2009-11-19 19:50:19 -08:00
Keith Whitwell
d2f4c80c8b i965g: get linear vs perspective interpolation working again 2009-11-19 19:41:25 -08:00
Keith Whitwell
4fb77ef840 i965g: include interpolation info in fs signature 2009-11-19 19:31:32 -08:00
Keith Whitwell
34a01929d5 i965g: special case setup when fs has no inputs 2009-11-19 19:29:33 -08:00
Keith Whitwell
47cef2bb8f i965g: add new state flag tracking fs signature changes 2009-11-19 18:55:18 -08:00
Keith Whitwell
c58e20fbbb i965g: fix typo in previous commit 2009-11-19 18:47:07 -08:00
Dave Airlie
3f2c77659c Merge remote branch 'origin/mesa_7_7_branch' 2009-11-20 11:48:10 +10:00
Dave Airlie
f8ea531820 r100: fix texture_from_pixmap and compiz.
r100 state emission has separate rect and non-rect states,
if we are doing TFP for a TEXTURE_2D we shouldn't use the rect
states as they won't get emitted properly.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-11-20 11:47:00 +10:00
Keith Whitwell
7e5cd3eb14 progs/fp: add simple imm, param tests 2009-11-19 16:53:02 -08:00
Keith Whitwell
8db59a1fa3 i965g: setup nr_attrs should track nr fragment shader inputs
This would be equivalent to taking the nr outputs of the vp varient
2009-11-19 16:14:44 -08:00
Keith Whitwell
1b9eda4c74 i965g: get fragment constants sort-of working 2009-11-19 16:09:39 -08:00
Keith Whitwell
9e4f3eaf66 i965g: make the load-before-use vs immediate path work 2009-11-19 15:04:00 -08:00
Keith Whitwell
25cbf9b4da i965g: fix initialization of texture width/height/depth arrays
Will remove these arrays in another branch - they're completely redundant.
2009-11-19 14:47:24 -08:00
Richard Li
b09e74901a r600 : Clean up a bit test code mess. 2009-11-19 17:41:10 -05:00
Vinson Lee
8b808d50e2 st/xorg: Fix infinite loop in copy_packed_data. 2009-11-19 14:40:00 -08:00
Keith Whitwell
683e35f726 gallium: don't use arrays for texture width,height,depth 2009-11-19 14:39:34 -08:00
Vinson Lee
4ab8dbe593 progs/xdemos: Add missing break statement in offset.c. 2009-11-19 14:20:26 -08:00
Brian Paul
4e6c79ac16 st/mesa: replace st_flush() with pipe->flush()
We only need to flush the gallium driver in this case.
Fixes a recursive state validation bug.
2009-11-19 15:18:23 -07:00
Brian Paul
2198497203 vbo: added recursion check in vbo_exec_FlushVertices() 2009-11-19 15:17:56 -07:00
Richard Li
48dfd3938e r600 : change shader pop method for now. 2009-11-19 16:55:16 -05:00
Brian Paul
dc41d62250 st/mesa: get rid of compressed_num_bytes() code 2009-11-19 14:35:38 -07:00
Brian Paul
92863109af st/mesa: remove is_compressed_mesa_format() 2009-11-19 14:17:31 -07:00
Brian Paul
273f4d6b5f st/mesa: remove pointless assertion 2009-11-19 14:17:31 -07:00
Brian Paul
3f40166500 softpipe: whitespace/indentation fixes 2009-11-19 14:17:31 -07:00
Richard Li
49b3f4a6bc Merge branch 'master' of ssh://richardradeon@git.freedesktop.org/git/mesa/mesa 2009-11-19 16:17:13 -05:00
Richard Li
6345a7ba44 r600 : check in shader code test enable flag: if flag
R600_ENABLE_GLSL_TEST defined, IL shader code will goto r600 assembler.
The test base is /mesa/progs/glsl/brick, and changes
shader code in CH06-brick.frag/vert to test different logic op
combination. (if,else,while,function,...). The stack depth code is not
in yet, so it is hard coded now. So complex code would not run (such as
things like 8 loops embeded loop in loop).
2009-11-19 16:05:43 -05:00
Vinson Lee
3790c6a13b progs/trivial: Redraw upon keypress. 2009-11-19 13:03:12 -08:00
José Fonseca
90e69c81e4 pb: Make fenced buffers threadsafe. 2009-11-19 19:46:21 +00:00
Brian Paul
367cfca808 softpipe: add missing check in softpipe_is_texture_referenced()
Check if the named texture is referenced by the texture cache.
2009-11-19 11:39:24 -07:00
Michel Dänzer
31ea323b4d st/xorg: Replace compile-time acceleration switch with Option "2DAccel".
This option can be used to disable 2D acceleration. DRI2 and XVideo blits will
still be accelerated, at least to some degree even with compositing.
2009-11-19 17:52:55 +01:00
Michel Dänzer
10c67f9381 st/xorg: Miscellaneous XVideo fixes.
* Make sure the destination pixmap has a texture to render into.
* Fix damage reporting so the EXA migration code can do the right thing.
* Fix destination coordinates for redirected windows.
2009-11-19 17:47:21 +01:00
Michel Dänzer
34145fc3b7 st/xorg: Try harder to ensure a shared texture has valid contents right away. 2009-11-19 17:30:32 +01:00
Michel Dänzer
012d0193cc st/xorg: Don't complain about convolution filter being 'unknown'.
Also add a newline to the complaint so it'll be a little less annoying if we
actually encounter an unknown filter value again.
2009-11-19 17:25:05 +01:00
Eric Anholt
827ba44f6e intel: Remove non-GEM support.
This really isn't supported at this point.  GEM's been in the kernel for
a year, and the fake bufmgr never really worked.
2009-11-19 11:47:22 +01:00
Eric Anholt
667760f53c intel: Remove dead intel_context members and move some packing around. 2009-11-19 11:47:21 +01:00
Eric Anholt
ee64347979 intel: Remove our special color packing macros and just use colormac.h. 2009-11-19 11:47:21 +01:00
Eric Anholt
c4b7c47fe3 intel: Pack colors for blit at blit time, rather than at ClearColor. 2009-11-19 11:47:21 +01:00
Eric Anholt
a376e5c482 intel: Consistently use no_batch_wrap in intel_context struct. 2009-11-19 11:47:21 +01:00
Eric Anholt
edd449fb97 i965: Pack brw_wm_fragment_program better. 2009-11-19 11:47:21 +01:00
Eric Anholt
15fa484f51 mesa: Remove gratuitous padding in prog_dst_register.
The padding was there to indicate the amount of space left from the
number of expected bytes in the struct minus allocated bits.  But
uint bitfields get packed so that they don't cross uint boundaries, and we
ended up allocating an extra dword to hold the pad field!
2009-11-19 11:47:21 +01:00
Eric Anholt
92d35b91f1 i965: Pack the brw_wm_prog_key better. 2009-11-19 11:47:21 +01:00
Eric Anholt
cc39fcad89 i915: Remove dead meta_draw_quad code. 2009-11-19 11:47:05 +01:00
Eric Anholt
37c79d4d76 tnl: Replace deprecated FogCoordPtr with AttribPtr[_TNL_ATTRIB_FOG] 2009-11-19 11:47:05 +01:00
Eric Anholt
0a91878015 tnl: Replace deprecated ColorPtr[] with AttribPtr or new BackfaceColorPtr. 2009-11-19 11:47:05 +01:00
Eric Anholt
fc9a2970dc tnl: Replace deprecated IndexPtr[] with AttribPtr[] or new BackfaceIndexPtr 2009-11-19 11:47:05 +01:00
Eric Anholt
165b860da6 tnl: Replace deprecated ObjPtr with AttribPtr[_TNL_ATTRIB_POS] 2009-11-19 11:47:05 +01:00
Eric Anholt
df582ca767 tnl: Replace deprecated TexCoordPtr with AttribPtr[_TNL_ATTRIB_TEX*] 2009-11-19 11:47:05 +01:00
Eric Anholt
22bcb59a95 tnl: Replace NormalPtr with AttribPtr[_TNL_ATTRIB_NORMAL] 2009-11-19 11:47:04 +01:00
Eric Anholt
abed06421b tnl: Remove unused NotifyInputChanges() tnl dd hook. 2009-11-19 11:47:04 +01:00
Michel Dänzer
10dbdee056 st/xorg: Remove superfluous flushes from the EXA WaitMarker hook.
Thanks to Thomas Hellström for pointing this out.
2009-11-19 10:54:49 +01:00
Michel Dänzer
ea114345a6 st/xorg: Don't initialize non-existing fields. 2009-11-19 10:38:08 +01:00
Michal Krol
f56b95e407 identity: Add missing screen methods. 2009-11-19 08:25:25 +01:00
Michal Krol
c5dc8d7ecc tgsi: Provide ultimate solution for SOA dependencies in exec.
Reorder STOREs in such a way that they appear after the last FETCH.
2009-11-19 08:25:23 +01:00
Vinson Lee
e3cfd78969 progs/tests: Fix memory leak in texdown.c if malloc fails. 2009-11-18 17:30:50 -08:00
Keith Whitwell
6b1ede0110 i965g: remove more references to nr_vp_outputs in wm compilation
We're really more concerned about how many inputs the fragment shader
is expecting.
2009-11-18 14:40:43 -08:00
Richard Li
eec4282800 r600 : update PS and VS emit count for loop constants. 2009-11-18 15:38:45 -05:00
Richard Li
de46087160 r600 : add some defs 2009-11-18 15:38:45 -05:00
Richard Li
3132853e12 r600 : Initial version of glsl fc. 2009-11-18 15:38:45 -05:00
Zack Rusin
fafc016e1f st/xorg: enable yv12 for xv 2009-11-18 12:06:49 -05:00
Jakob Bornecrantz
5109484bd9 st/xorg: Flush any pending operations on upload 2009-11-18 17:49:38 +01:00
Jakob Bornecrantz
8d6da811d4 st/xorg: Unbind any textures in solid
Helps debuging with rbug
2009-11-18 17:49:37 +01:00
Alan Hourihane
910b58039a Fix vega compilation. 2009-11-20 21:15:25 +00:00
Alan Hourihane
1dbf3642b9 Fix memory leak. 2009-11-20 21:15:22 +00:00
Vinson Lee
8556fad751 progs/xdemos: Silence unused value warnings in sharedtex_mt.c. 2009-11-20 13:09:42 -08:00
Vinson Lee
f080567f4c progs/xdemos: Fix memory leak in glxinfo.c. 2009-11-20 13:01:22 -08:00
Vinson Lee
02c3e0b82d progs/tests: Silence unused value warnings in sharedtex.c. 2009-11-20 12:49:50 -08:00
Eric Anholt
c4e8918cd2 mesa: Fix NULL deref in optimizer when NumInstructions == 0.
Bug #24984.
2009-11-20 21:46:48 +01:00
Vinson Lee
48deddaa6f progs/tests: Initialize variable in getprocaddress.c. 2009-11-20 12:34:21 -08:00
Vinson Lee
e26135a744 progs/util: Exit RawImageGetData early if malloc fails.
Prevents a null pointer deference later on.
2009-11-20 12:11:55 -08:00
Vinson Lee
c88b18a4df progs/slang: Check for ftell failure in vstest.c. 2009-11-20 11:34:21 -08:00
Vinson Lee
d36cb2396c progs/util: Fix memory leak if malloc fails in RawImageOpen. 2009-11-20 11:22:13 -08:00
Vinson Lee
08cb1d0ce4 st/xorg: Fix type of 'unknown'. 2009-11-20 00:03:10 -08:00
Vinson Lee
b98db7bf69 progs/vpglsl: Fix psiz-mul.glsl compilation error on Mac OS. 2009-11-19 23:56:07 -08:00
Vinson Lee
760cf71572 progs/vp: Fix memory leak in vp-tris.c. 2009-11-19 22:59:01 -08:00
Vinson Lee
9553a42f63 progs/trivial: Redraw upon keypress. 2009-11-19 22:52:05 -08:00
Vinson Lee
881f55236a progs/glsl: Redraw upon keypress. 2009-11-19 22:46:19 -08:00
Brian Paul
3ba983bf5d docs: setup 7.8 release notes file 2009-11-18 07:46:17 -07:00
Brian Paul
d252f9d278 mesa: bump version to 7.8 2009-11-18 07:26:28 -07:00
Brian Paul
61a3716ab5 mesa: bump version to 7.8 2009-11-18 07:26:28 -07:00
Jakob Bornecrantz
e12c9a6f3a st/xorg: Init all functions and fix spelling 2009-11-18 10:59:42 +01:00
Vinson Lee
cde6643724 progs/fp: Redraw upon keypress. 2009-11-18 14:41:40 -08:00
Jakob Bornecrantz
9ab3c70f65 st/xorg: Make the #if more easier to read 2009-11-18 10:44:07 +01:00
Jakob Bornecrantz
e73553bff7 st/xorg: Use the correct DRI2BufferPtr struct on 1.6.4 servers 2009-11-18 10:44:07 +01:00
Vinson Lee
4b3ec2acf2 progs/glsl: Fix trirast GLSL compilation errors on Mac OS. 2009-11-18 14:02:20 -08:00
Vinson Lee
0d31990b47 progs/glsl: Fix noise GLSL compilation error on Mac OS. 2009-11-18 13:50:49 -08:00
Maciej Cencora
3bf12c8bea r300: allow disabling s3tc support if libtxc_dxtn is available 2009-11-18 22:19:25 +01:00
Maciej Cencora
cefee4e327 Merge branch 'radeon-texrewrite-clean' into mesa_7_7_branch 2009-11-18 22:09:33 +01:00
Maciej Cencora
7118db8700 r600: align for mipmap tree changes 2009-11-18 22:02:48 +01:00
Vinson Lee
d4dc2e30da progs/glsl: Fix multinoise GLSL compilation errors on Mac OS. 2009-11-18 12:49:31 -08:00
Vinson Lee
04442841fb progs/glsl: Fix mandelbrot GLSL compilation error on Mac OS. 2009-11-17 23:15:25 -08:00
Ian Romanick
70dca0c273 AL1616: Fix cut-and-paste bug
One of the PACK_COLOR_88 cases was left over from copying
_mesa_texstore_al88 to _mesa_texstore_al1616.
2009-11-17 22:53:06 -08:00
Brian Paul
89e20ab3ae progs/glsl: use ShadersSupported() 2009-11-17 19:22:29 -07:00
Brian Paul
6acb82dab0 progs/util: warn when GLSL not supported 2009-11-17 19:22:11 -07:00
Ian Romanick
5606dfb572 Merge branch 'outputswritten64'
Add a GLbitfield64 type and several macros to operate on 64-bit
fields.  The OutputsWritten field of gl_program is changed to use that
type.  This results in a fair amount of fallout in drivers that use
programs.

No changes are strictly necessary at this point as all bits used are
below the 32-bit boundary.  Fairly soon several bits will be added for
clip distances written by a vertex shader.  This will cause several
bits used for varyings to be pushed above the 32-bit boundary.  This
will affect any drivers that support GLSL.

At this point, only the i965 driver has been modified to support this
eventuality.

I did this as a "squash" merge.  There were several places through the
outputswritten64 branch where things were broken.  I foresee this
causing difficulties later for bisecting.  The history is still
available in the branch.

Conflicts:
	src/mesa/drivers/dri/i965/brw_wm.h
2009-11-17 16:25:38 -08:00
Ian Romanick
b43887cf7e ARB_fbo: Enable extensions related to GL_ARB_framebuffer_object for GLX 2009-11-17 16:25:38 -08:00
Ian Romanick
4e7476f601 ARB_fbo: Add missing GLX render opcode for glFramebufferTextureLayerEXT
Also regenerate the GLX protocol files from this change.
2009-11-17 16:25:38 -08:00
Ian Romanick
5fbfd88338 Add missing XML files to API_XML
When the files missing from the list were modified, the generated files
weren't regenerated.
2009-11-17 16:25:38 -08:00
Ian Romanick
4d6ec21439 ARB_fbo: Enable GL_EXT_framebuffer_multisample
All of this functionality is already included in ARB_fbo.  This just
enables the string.

I was a bit lazy in using FEATURE_ARB_framebuffer_object for this
feature as well.  I don't think it makes much difference in the long run.
2009-11-17 16:25:38 -08:00
Ian Romanick
7fd44005ae ARB_fbo: Regenerate files from previous commits. 2009-11-17 16:25:37 -08:00
Ian Romanick
50b05e7c1f ARB_fbo: Move EXT_fb_blit to EXT_framebuffer_object.xml
This extension is layered on GL_EXT_framebuffer_object, so it should
live in the same XML file.
2009-11-17 16:25:37 -08:00
Ian Romanick
afab8d9958 ARB_fbo: Add GL_EXT_framebuffer_multisample
Add GL_EXT_framebuffer_multisample.  Make
glRenderbufferStorageMultisampleEXT in GL_EXT_framebuffer_object alias
glRenderbufferStorageMultisample.  Also add the missing GLX render
opcode to glRenderbufferStorageMultisample.

Since this extension is layered on GL_EXT_framebuffer_object, I put it
in EXT_framebuffer_object.xml.
2009-11-17 16:25:37 -08:00
Ian Romanick
daad31d527 EXT_pds: Alias GL_NV_packed_depth_stencil to GL_EXT_packed_depth_stencil
GL_EXT_packed_depth_stencil is a functional superset of
GL_NV_packed_depth_stencil.   If a driver enables EXT_pds, make NV_pds
available as well.
2009-11-17 16:25:37 -08:00
Ian Romanick
b244b702b3 EXT_pds: Add GL_EXT_packed_depth_stencil 2009-11-17 16:25:37 -08:00
Ian Romanick
92b38bc305 EXT_fbo_blit: Add missing GLX protocol render opcode 2009-11-17 16:25:37 -08:00
Ian Romanick
30f09573ed ARB_fbo: Add missing protocol "Get" information 2009-11-17 16:25:37 -08:00
Ian Romanick
c185ff96c9 ARB_fbo: Remove _EXT from enum names 2009-11-17 16:25:37 -08:00
Brian Paul
4440d8adb6 docs: libGL documentation, from the xorg-docs tree
This is pretty old and needs some updating but might be useful or
interesting to some people.
2009-11-17 16:33:22 -07:00
Vinson Lee
773de83d3c progs/tests: Fix memory leak in arbgpuprog.c. 2009-11-17 15:24:40 -08:00
Brian Paul
a54033bedb mesa: remove old comment 2009-11-17 16:18:29 -07:00
Brian Paul
133501bef2 mesa: fix assorted compiler warnings 2009-11-17 16:16:30 -07:00
Brian Paul
bc8fb028c6 mesa: fix incorrect type in store_texel_al1616() 2009-11-17 16:16:30 -07:00
Brian Paul
7e3955d8e8 i915g: replace //-style comments 2009-11-17 16:16:30 -07:00
Brian Paul
c4c11eb456 gallium/util: replace //-style comments 2009-11-17 16:16:30 -07:00
Brian Paul
845ddbc9aa i915g: remove trailing commas in enum lists to silence warnings 2009-11-17 16:16:30 -07:00
Brian Paul
fc3c5ffcc8 progs/xdemos: change //-style comments 2009-11-17 16:16:30 -07:00
Brian Paul
b08f447547 progs/glsl: change //-style comments 2009-11-17 16:16:30 -07:00
Brian Paul
1888a72765 progs/demos: silence warnings 2009-11-17 16:16:30 -07:00
Brian Paul
0422053eca mesa: remove trailing comment to silence warning 2009-11-17 16:16:30 -07:00
Brian Paul
e36751ec81 mesa: remove a bit of old code 2009-11-17 16:16:30 -07:00
Keith Whitwell
1877e6cd2d i965g: handle special vs outputs specially
Where vs output semantic tags indicate an output is signficant for
fixed function processing (such as clipping, unfilled modes, etc),
retain information about that output so that we can get to it easily
later on.

Fix up the unfilled processing, but hard-wire edgeflag to one for now.

With this change, trivial/tri-unfilled works.
2009-11-17 14:50:49 -08:00
Keith Whitwell
d299ee771b i965g rename offset_edge to offset_edgeflag 2009-11-17 14:50:49 -08:00
Vinson Lee
e8eec93854 progs/slang: Fix potential null pointer dereference in cltest.c. 2009-11-17 14:22:35 -08:00
Vinson Lee
47b5f584a6 progs/redbook: Fix memory leak in quadric.c. 2009-11-17 14:10:35 -08:00
Maciej Cencora
afe84fa698 r200: align for mipmap tree changes 2009-11-17 19:46:59 +01:00
Maciej Cencora
93eb2ab8c3 radeon: align for mipmap tree changes 2009-11-17 19:46:37 +01:00
Jakob Bornecrantz
46492f11f6 svga: More -Werror removal 2009-11-17 12:09:19 +01:00
Vinson Lee
d9508e8df9 progs/util: Fix memory leak if fopen fails in RawImageOpen. 2009-11-17 13:49:31 -08:00
Jakob Bornecrantz
8c5a108dc3 svga: Remove -Werror for now as GCC 4.4.x raises a bunch of warnings 2009-11-17 11:24:39 +01:00
Maciej Cencora
aef769207d r300: fix reads and writes for MESA_FORMAT_S8Z24 buffer
Regression was introduced by texformat-rework branch merge.
2009-11-17 13:40:43 -07:00
Brian Paul
d888bbc45a progs/xdemos: added -lX11 -lpthread for GNU gold linker 2009-11-17 13:40:00 -07:00
Vinson Lee
11905da883 progs/util: Fix memory leak if fread returns 0 in CompileShaderFile. 2009-11-17 12:00:22 -08:00
Brian Paul
6418ce7df6 mesa: move -ansi -pedantic to CFLAGS 2009-11-17 12:47:54 -07:00
Vinson Lee
b8dcb79c53 progs/glsl: Change tangentAttrib from GLuint to GLint in bump.c.
tangentAtrrib is assigned the result of glGetAttribLocation.
The assertion 'assert(tangentAtrrib >= 0)' would be a no-op if
tangentAttrib is a GLuint.
2009-11-17 11:37:48 -08:00
Vinson Lee
786d539511 progs/util: Fix memory leak if malloc fails in tkRGBImageLoad. 2009-11-17 11:04:24 -08:00
Patrice Mandin
b353106467 nouveau: nv30: Check for NULL front (happens with DRI2) 2009-11-17 19:50:37 +01:00
Patrice Mandin
49289f1d25 nouveau: nv30: Add missing include to fix warning 2009-11-17 19:49:56 +01:00
Michel Dänzer
52be96b7fe Remove unconditional use of glibc specific bswap_16() macro.
Fixes unresolved symbol bswap_16 on non-glibc or little endian glibc platforms.
2009-11-17 19:41:29 +01:00
Brian Paul
63bc736f90 docs: list the new VMware SVGA Gallium driver in release notes 2009-11-17 11:23:19 -07:00
Dan Nicholson
cf65d81cf1 dri: Ensure subdirs have finished before linking driver
Recursive make is hard. If there are subdirectories in the DRI drivers,
it's pretty certain we want to finish building in them before linking
the driver. Add a new target to serialize the rules.

Signed-off-by: Dan Nicholson <dbn.lists@gmail.com>
2009-11-17 11:23:19 -07:00
Vinson Lee
041cd0e110 progs/util: Fix memory leak if LoadRGBImage fails. 2009-11-17 10:11:50 -08:00
Michel Dänzer
33e93f4277 r600: More span breakage fixes.
At least now the compiler doesn't complain about implicitly declared functions
anymore...
2009-11-17 19:02:03 +01:00
Vinson Lee
0e783c7d03 progs/glsl: Fix memory leak in deriv.c. 2009-11-17 09:54:54 -08:00
Michel Dänzer
29f3e7e1d1 r600: Attempt to fix span breakage introduced by big endian fixes.
Only compile tested; I happened to notice people on IRC reporting

.../r600_dri.so: undefined symbol: radeon_ptr_2byte_8x2
2009-11-17 18:47:24 +01:00
Vinson Lee
28b8e4bcd7 progs/util: Fix memory if LoadRGBMipmaps2 fails. 2009-11-17 08:29:36 -08:00
Michel Dänzer
081bf9563f radeon: Depth/stencil span code fixes for big endian.
Fixes e.g. text in progs/demos/arbocclude.
2009-11-17 11:09:09 +01:00
Michel Dänzer
592ce48ce9 radeon: Fix occlusion queries on big endian. 2009-11-17 11:08:21 +01:00
Michal Krol
547ac2869b glsl/pp: Fix macro formal argument parsing, more descriptive error msgs. 2009-11-17 09:06:53 +01:00
Michel Dänzer
2262765425 radeon: Fix software fallbacks with KMS on big endian. 2009-11-17 08:05:23 +01:00
Michel Dänzer
f2651264d3 radeon: FBO fixes for big endian. 2009-11-17 08:05:22 +01:00
Michel Dänzer
2d0c295256 Add MESA_FORMAT_XRGB8888_REV. 2009-11-17 08:05:22 +01:00
Dave Airlie
e015a4c29b radeon: rn50's have no 3D engine so don't try and init 3D driver. 2009-11-17 16:06:26 +10:00
Vinson Lee
0e790ac353 progs/util: Fix memory leak if LoadYUVImage fails. 2009-11-16 18:24:06 -08:00
Jakob Bornecrantz
60769b232c svga: Build svga driver 2009-11-17 03:18:06 +01:00
Jakob Bornecrantz
f7109aaf6c svga: Add vmwgfx_drm.h file from vmwgfx kernel driver
Add the vmwgfx_drm.h header for now, this allows the svga driver
to be enabled by default without forcing people to install the
vmwgfx_drm.h header on their system.

To be removed once vmwgfx_drm.h is in libdrm.
2009-11-17 03:18:05 +01:00
Jakob Bornecrantz
3192633d4a svga: Add svga driver 2009-11-17 03:18:04 +01:00
Vinson Lee
6b480dc21d progs/demos: Fix memory leak in ray.c. 2009-11-16 18:06:40 -08:00
Jakob Bornecrantz
648e8b4c46 st/xorg: Fix copy-pasto
Thanks Alan.
2009-11-17 01:48:53 +01:00
Vinson Lee
ee555e3d69 progs/demos: Fix memory leak in projtex.c. 2009-11-16 16:31:34 -08:00
Vinson Lee
a1afe303de progs/demos: Fix memory leak in ipers.c. 2009-11-16 15:44:52 -08:00
Ian Romanick
fdfbae3381 i965: Use MESA_FORMAT_AL1616 when appropriate 2009-11-16 15:23:17 -08:00
Ian Romanick
b1616b2a81 Move 'static' to start of declaration to silence compiler warning 2009-11-16 15:23:16 -08:00
Ian Romanick
12982e381d AL1616: Enable MESA_FORMAT_AL1616 for software paths 2009-11-16 15:23:16 -08:00
Ian Romanick
3325dc91be AL1616: Add TexImage storage path 2009-11-16 15:23:16 -08:00
Ian Romanick
975871b4d5 AL1616: Add texel fetch / store routines 2009-11-16 15:23:16 -08:00
Ian Romanick
eb437fabe0 AL1616: Add formats for GL_LUMINANCE16_ALPHA16 textures 2009-11-16 15:23:16 -08:00
Ian Romanick
5fb07a4046 AL1616: Add macros to pack two GLushorts into a texel 2009-11-16 15:23:16 -08:00
Vinson Lee
aef3218f0b progs/demos: Fix memory leak in fslight.c. 2009-11-16 14:56:07 -08:00
Jakob Bornecrantz
cb060f3b98 st/xorg: Fix comp alpha code and deal with luminance masks
There are two fixes in here one is a one liner that fixes
component alpha logic. The other deals better with luminance
formats used for masks, sources not yet implemented.

Fixes component alpha text and icons in gnome. There are a one
or two cases that this code misses. Like if src_luminance is set
but no mask image is given.
2009-11-16 23:33:45 +01:00
Jakob Bornecrantz
5438ee3ecf st/xorg: Incase of format missmatch swizzle channels and set alpha
This path is only hit for icons in gnome so far
2009-11-16 23:33:44 +01:00
Alex Deucher
d683acb101 r600: don't force Z order
Let the hw decide (early vs late Z)
fixes fdo bug 25092

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
2009-11-16 15:03:48 -05:00
Corbin Simpson
0f060250fc docs: Update r300g status. 2009-11-16 10:46:20 -08:00
Brian Paul
664b7303c2 docs: fixes, changes for Mesa 7.7 2009-11-16 11:33:45 -07:00
Brian Paul
fcf8dea36c progs/tests: silence warning 2009-11-16 11:33:45 -07:00
Brian Paul
f549f4c4b6 mesa: remove unused vertex array driver hooks 2009-11-16 11:33:44 -07:00
Brian Paul
652828ec0e mesa: check BaseLevel, MaxLevel in _mesa_GenerateMipmapEXT() 2009-11-16 08:25:17 -07:00
Brian Paul
a719395b45 mesa: use _mesa_get_current_tex_object() 2009-11-16 08:21:28 -07:00
Brian Paul
ecb03d75a2 mesa: added another check in check_gen_mipmap()
We don't need to call ctx->Driver.GenerateMipmap() if we're updating
a texture level >= MAX_LEVEL.
2009-11-16 08:18:03 -07:00
Michel Dänzer
d3a37d93ab st/xorg: Only reference new picture formats when they're defined.
Fixes http://bugs.freedesktop.org/show_bug.cgi/?id=25094 .
2009-11-16 11:59:39 +01:00
Brian Paul
afae49cc15 st/mesa: comments for st_draw.c 2009-11-15 16:22:53 -07:00
Brian Paul
4581f70578 st/egl: add some basic comments 2009-11-15 16:22:52 -07:00
Keith Whitwell
c5f9713bd3 i965g: remove droppings in xlib winsys 2009-11-15 12:25:18 -08:00
Keith Whitwell
07fafc7c93 mesa/st: refactor vertex and fragment shader translation
Translate vertex shaders independently of fragment shaders.

Previously tried to make fragment shader semantic indexes always start
at zero and exclude holes.  This was unnecessary but meant that vertex
shader translation had to be adjusted to take this into account.

Now use a fixed scheme for labelling special FS input semantics
(color, etc), and another fixed scheme for the generics.

With this, vertex shaders can be translated independently of the bound
fragment shader, assuming mesa has done its own job and ensured that
the vertex shader provides at least the inputs the fragment shader is
looking for.  The state-tracker didn't attempt to do anything about
this previously, so it shouldn't be needed now.
2009-11-15 11:23:30 -08:00
Keith Whitwell
1454f20a99 mesa/st: emit tgsi vertex shader directly for drawpixels
One of several cases where we build mesa shaders and then translate
them to tgsi.  Many of those cases it's because we're combining two
mesa programs and there are helpers for that, but in this case at
least can go straight to tgsi.
2009-11-15 11:23:29 -08:00
Keith Whitwell
9953fe4cb4 mesa/st: don't calculate unused output_flags data either 2009-11-15 11:23:29 -08:00
Keith Whitwell
0ffdd1c1e8 mesa/st: don't calculate unused input_flags data 2009-11-15 11:23:29 -08:00
Keith Whitwell
b44b70dc11 mesa/st: don't calculate unused vs input semantic tags 2009-11-15 11:23:29 -08:00
Francisco Jerez
abefd7dcdf nv20: Fix build for the last nouveau_class.h changes.
Signed-off-by: Francisco Jerez <currojerez@riseup.net>
Signed-off-by: Pekka Paalanen <pq@iki.fi>
2009-11-15 18:20:19 +02:00
Francisco Jerez
ed9c4933af nv10: Fix build for the last nouveau_class.h changes.
Signed-off-by: Francisco Jerez <currojerez@riseup.net>
Signed-off-by: Pekka Paalanen <pq@iki.fi>
2009-11-15 18:20:19 +02:00
Vinson Lee
a420056750 progs: Ignore Mac OS dSYM directories. 2009-11-14 21:39:31 -08:00
Keith Whitwell
d03a1c2216 i965g: restore check on line smooth state 2009-11-14 16:06:57 -08:00
Maciej Cencora
ad83aeccdc radeon: return false on texture validation if texture isn't complete 2009-11-14 18:11:16 +01:00
Maciej Cencora
23ec7c4574 radeon: rework mipmap tree 2009-11-14 16:55:39 +01:00
Maciej Cencora
8f88cf3938 radeon: more texture code refactoring 2009-11-14 16:55:38 +01:00
Maciej Cencora
9d0af686b2 radeon: minor refactoring of texture code
Also properly set dstImageOffsets for TexSubImage case.
2009-11-14 16:55:38 +01:00
Maciej Cencora
7628b06ba3 radeon: rework mipmap tree reference counting 2009-11-14 16:55:34 +01:00
Maciej Cencora
6e5d473cc1 r300: fix regression introduced in 1d5a06a1f7
Spotted by Dave Airlie
2009-11-14 14:43:34 +01:00
Maciej Cencora
aa19561158 radeon: use radeon_bo_is_referenced_by_cs for query objects 2009-11-14 14:43:18 +01:00
Maciej Cencora
d3fa67c9b8 radeon/r300: don't flush cmdbuf if not necessary 2009-11-14 14:43:10 +01:00
Maciej Cencora
286bf89e5a radeon/r300: no need to flush the cmdbuf when changing scissors state in KMM mode 2009-11-14 14:42:48 +01:00
Maciej Cencora
f6d0993212 radeon: fix glBufferSubData 2009-11-14 14:42:34 +01:00
Maciej Cencora
084f43c150 radeon: add radeon_bo_is_referenced_by_cs function 2009-11-14 14:42:26 +01:00
Maciej Cencora
49876ab6a7 radeon: remove unnecessary call to radeonEmitState
fixes bo space accounting errors
2009-11-14 14:42:19 +01:00
Maciej Cencora
0aad2aee66 r300: add missing texformat 2009-11-14 14:42:10 +01:00
Maciej Cencora
e92492295b r300: remove unneeded includes 2009-11-14 14:42:01 +01:00
Eric Anholt
57f40b1837 i965: Share OPCODE_TXB between brw_wm_emit.c and brw_wm_glsl.c
This should fix TXB on G45 and older in the GLSL case.
2009-11-13 16:04:13 -08:00
Eric Anholt
1be0efcbdc i965: Share OPCODE_TEX between brw_wm_emit.c and brw_wm_glsl.c.
New comments should explain some of the confusion about how this message
works.
2009-11-13 16:04:10 -08:00
Eric Anholt
a0fd49b334 i965: Clean up emit_tex a bit. 2009-11-13 15:17:24 -08:00
Eric Anholt
3d36d6b4cf Merge remote branch 'origin/mesa_7_6_branch' 2009-11-13 14:45:29 -08:00
Eric Anholt
99077e7792 i965: Flag BRW_NEW_CONTEXT on some context state.
Fixing this is a prereq for avoiding flagging all state at new
batch time.  Eliminating that still causes problems, though (notably
glean logicOp fails on my GM965).
2009-11-13 14:39:09 -08:00
Eric Anholt
1ffd0a7789 intel: Remove some dead context structure fields. 2009-11-13 13:18:57 -08:00
Eric Anholt
3727858ceb i965: Remove an unused cache_item field. 2009-11-13 13:18:57 -08:00
Eric Anholt
b54f8eeae8 i965: Remove long dead structures for ffvertex_prog.c. 2009-11-13 13:18:57 -08:00
Eric Anholt
ded0ec1ea5 i965: Use bo_map instead of subdata to upload the bits of constant buffer.
Saves CPU time, resulting in a 2.5% FPS win on ETQW.
2009-11-13 13:18:57 -08:00
Eric Anholt
8e8586e626 i965: Validate the number of URB entries selected for the VS. 2009-11-13 13:18:56 -08:00
Eric Anholt
3c05c1eb63 intel: When subdataing a busy buffer, use a temporary and blit in.
This cuts a massive number of waits in ET:QW, which uses a VBO ringbuffer.
Unfortunately it doesn't BufferData when wrapping back to 0, so we can't
be clever with tracking what's been initialized.
2009-11-13 13:18:56 -08:00
Eric Anholt
4e50ce35ee i965: Clean up Ironlake sampler type definitions.
They're the same regardless of execution width for 8, 4x2, and 16.
2009-11-13 13:18:56 -08:00
Eric Anholt
91bd593109 i965: Avoid moving the current value back into the accumulator for MAD.
This is a 2.9% (+/-.3%) performance win for my GL demo, which hits MAD
sequences for matrix transforms.
2009-11-13 13:18:56 -08:00
Eric Anholt
d6690ce15f mesa: Improve the eliminate-move-use to work across multiple instructions.
This shaves more instructions off of the VS of my GL demo, but no
performance difference this time at n=6.  This also fixes a regression
that was in this path, which is now piglit's glsl-vs-mov-after-deref.
2009-11-13 13:18:22 -08:00
Zack Rusin
654122ba7b st/xorg: try to fix non-uniform transforms 2009-11-13 14:58:35 -05:00
Michal Krol
eaa34c2dea glsl/apps: Report syntax parser errors. 2009-11-13 19:51:49 +01:00
Michal Krol
3f147c71ed slang: Report syntax parser errors. 2009-11-13 19:51:24 +01:00
Michal Krol
99c89ebdb0 glsl/cl: Add simple error reporting. 2009-11-13 19:51:02 +01:00
Michal Krol
b385312bc7 slang: Regenerate .gc files. 2009-11-13 06:03:56 +01:00
Michal Krol
7593562a61 slang: Get rid of the old syntax file and utilities. 2009-11-13 05:58:46 +01:00
Michal Krol
cd5553b457 slang: Plug in the new syntax parser. 2009-11-13 05:52:39 +01:00
Michal Krol
f5b6e06390 gdi: Link to glslcl. 2009-11-13 05:49:25 +01:00
Michal Krol
38a1f0b5d1 glsl/apps: Add GLSL compiler that translates source text into binary stream.
Should be used in place of gc_to_bin utility to precompile builtin library.
2009-11-13 03:02:14 +01:00
Michal Krol
08e90bdea1 glsl/cl: Add a hard-coded syntax parser. 2009-11-13 03:00:45 +01:00
Vinson Lee
43080e40aa progs/glsl: Add missing break statement in multinoise.c. 2009-11-12 16:21:49 -08:00
Ian Romanick
b6b753f727 intel: Don't check for context pointer to be NULL during extension init
Thanks to Chia-I Wu's changes to the extension function
infrastructure, we no longer have to tell the loader which extensions
the driver might enable.  This means that intelInitExtensions will
never be called with a NULL context pointer.  Remove all the NULL checks.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Eric Anholt <eric@anholt.net>
2009-11-12 15:43:09 -08:00
Ian Romanick
a736d3f439 intel: Remove unused enable_imaging parameter to intelInitExtensions 2009-11-12 15:43:09 -08:00
Keith Whitwell
2f54d02d20 i965g: consult fs inputs when laying out vs output regs
Vertex shader now emits just the FS inputs, in the positions and order
expected by the fragment shader.

This means potentially regenerating the vertex shader to match
different fragment shader's input layouts.
2009-11-11 18:51:58 -08:00
Keith Whitwell
0c547d63c4 i965g: skip over vertex position output when preallocating FS inputs 2009-11-11 18:51:57 -08:00
Keith Whitwell
a010307e0a i965g: some more cases where file_max[] is used without obligatory +1 2009-11-11 18:51:57 -08:00
Keith Whitwell
e4d174ea1b i965g: smaller upload buffer for index data 2009-11-11 18:51:57 -08:00
Keith Whitwell
d86e9079a8 i965g: fix off-by-one on curbe upload 2009-11-11 18:51:57 -08:00
Keith Whitwell
e243279a48 i965g: avoid use of internally generated immediates
Currently not working, so don't generate more of them.
2009-11-11 18:51:57 -08:00
Keith Whitwell
98c2b53381 trivial: make tri-orig more closely match the original version of tri... 2009-11-11 18:51:57 -08:00
Zack Rusin
4d72f8f520 st/xorg: use an immediate instead of a full blown const 2009-11-11 21:47:28 -05:00
Zack Rusin
72b4a7d67f st/xorg: don't use flow control 2009-11-11 21:43:40 -05:00
Brian Paul
0a39620d6d swrast: handle additional Z24 formats in read_depth_pixels() 2009-11-11 19:38:19 -07:00
Vinson Lee
7dfea5c072 demos/glsl: Add missing break statement to noise test. 2009-11-11 17:39:58 -08:00
Zack Rusin
2cfbbc76e4 st/xorg: implement repeatnone and make some code smell less like ass 2009-11-11 19:55:50 -05:00
Zack Rusin
493d599af4 st/xorg: fallback until daddy can implement you properly 2009-11-11 19:55:50 -05:00
Brian Paul
2ff4f5a7fe progs/tests: add alpha/blend testing to packedpixels.c 2009-11-11 12:25:08 -07:00
Corbin Simpson
cbee31a1f8 r300, r300g: Add missing registers. 2009-11-11 10:24:19 -08:00
Corbin Simpson
d030ce6a84 dri-st: Add some required GL 2.0 extensions.
Two-sided stencil and NPOT textures.
2009-11-11 10:24:06 -08:00
Michal Krol
d44cebd1ee glsl/pp: Add sl_pp_purify_getc(). 2009-11-10 20:49:45 +01:00
Chia-I Wu
9f38553018 Update config linux-opengl-es.
Build demos that require EGL_MESA_screen_surface, and build egl_i915.so
that supports EGL_MESA_screen_surface.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-10 11:25:00 -07:00
Chia-I Wu
b30876658b progs/es1: Port eglgears to OpenGL ES 1.1.
This demo requires EGL_MESA_screen_surface to run.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-10 11:24:53 -07:00
Chia-I Wu
381cbc7192 progs/es1: Port egltri to OpenGL ES 1.1.
This demo requires EGL_MESA_screen_surface to run.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-10 11:24:39 -07:00
Chia-I Wu
4b9cc50345 st/egl: Allow APIs other than OpenGL.
This is done by stopping linking to libmesagallium.a and removing DRI
related stuff.  The state tracker an application links to decides the
API supported.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-10 11:24:26 -07:00
Chia-I Wu
5f0ea53747 egl_softpipe: Clean up Makefile.
Fix generation of depend.  Link to the dynamic libraries used.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-10 11:24:10 -07:00
Chia-I Wu
0b9f0ba706 progs/es: Add .gitignore.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-10 11:23:47 -07:00
Chia-I Wu
9de051e85e mesa/es: Add .gitignore.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-10 11:23:40 -07:00
Jakob Bornecrantz
e4a19ffb13 st/xorg: Fallback if picture format doesn't match texture format 2009-11-10 10:05:40 +01:00
Jakob Bornecrantz
3201c655e4 st/xorg: Don't segfault when debug printing 2009-11-10 10:00:04 +01:00
Zack Rusin
fca8b2c3ae st/xorg: wrap to border color 2009-11-10 20:30:48 -05:00
brian
b81f213157 swrast: update renderbuffer format assertions 2009-11-10 18:23:59 -07:00
brian
a65b84d955 mesa: fix some begin/end render-to-texture logic
Before, we weren't aggressive enough in checking for the start or end
of render-to-texture.  In particular, if only the ctx->ReadBuffer had
texture attachments, we were treating that as a render-to-texture case.

This fixes a regression from commit 75bdbdd90b
"intel: Don't validate in a texture image used as a render target."
2009-11-10 18:09:13 -07:00
brian
bc569cd6be mesa: move check_begin/end_texture_render() calls 2009-11-10 18:09:13 -07:00
brian
d96e55fa7b mesa: new vars: oldDrawFb, oldReadFb in _mesa_BindFramebufferEXT() 2009-11-10 18:09:13 -07:00
brian
e6f60d3037 mesa: rename vars in _mesa_BindFramebufferEXT() 2009-11-10 18:09:13 -07:00
brian
a492ab765a mesa: added comment for check_begin_texture_render() 2009-11-10 18:09:12 -07:00
Jakob Bornecrantz
4c54f8e9aa st/egl: Probe hardware for depth stencil format 2009-11-10 08:29:41 +01:00
Zack Rusin
d2c886c8ca st/xorg: cleanup the naming 2009-11-10 19:42:03 -05:00
Zack Rusin
e08512f3d4 st/xorg: print ouf the picture formats when compositing 2009-11-10 19:42:02 -05:00
Eric Anholt
e42b156fac Merge remote branch 'origin/mesa_7_6_branch' 2009-11-10 16:01:28 -08:00
Eric Anholt
c5413839b3 i965: avoid memsetting all the BRW_WM_MAX_INSN arrays for every compile.
For an app that's blowing out the state cache, like sauerbraten, the
memset of the giant arrays ended up taking 11% of the CPU even when only a
"few" of the entries got used.  With this, the WM program compile drops back
down to 1% of CPU time.

Bug #24981 (bisected to BRW_WM_MAX_INSN increase).
2009-11-10 16:00:30 -08:00
Eric Anholt
eb6a1f8a00 i965: Add a note explaining the data cache domain. 2009-11-10 16:00:30 -08:00
Vinson Lee
520b6abdec i915g: Fix memory leak when pci id is unknown. 2009-11-10 12:39:42 -08:00
Eric Anholt
56ab92bad8 i965: Unalias src/dst registers for SGE and friends.
Fixes piglit vp-sge-alias test, and the googleearth ground shader.  \o/

Bug #22228
2009-11-10 10:54:15 -08:00
Eric Anholt
d52d78b4bc i965: Allow use of PROGRAM_LOCAL constants in ARB_vp.
Fixes piglit arl.vp.
2009-11-10 10:46:57 -08:00
Michal Krol
28039ffdc8 slang: Fix return value check. 2009-11-10 19:25:51 +01:00
Michel Dänzer
5e17c89ead st/xorg: Fix SCons build.
Check for new DPMS header and add xorg_renderer.c source file.
2009-11-10 10:09:56 -08:00
Michal Krol
413e933fd5 slang: Check OOM conditions for alloc_node_storage(). 2009-11-10 18:30:10 +01:00
José Fonseca
eef5a0b3a3 llvmpipe: Fix derived blend color state. 2009-11-10 05:22:15 -08:00
Michal Krol
cc470bf0ca slang: Check return value from new_instruction(). 2009-11-10 04:03:55 +01:00
Michal Krol
b2a29ad309 slang: Fix signed/unsigned int handling in _slang_free_temp(). 2009-11-10 03:25:06 +01:00
Michal Krol
b5d8a7b6dc tgsi/exec: Exit early on error. 2009-11-10 03:12:02 +01:00
Michal Krol
e44c77028c tgsi/ureg: Simplify logic in tokens_expand(). 2009-11-10 03:08:21 +01:00
Michal Krol
83760d961f slang: Handle OOM condition in new_instruction(). 2009-11-10 02:46:24 +01:00
Michal Krol
4703d7d3f8 slang: Update for glsl/pp interface changes. 2009-11-10 00:16:09 +01:00
Michal Krol
b5c8c87eab glsl/apps: Update for glsl/pp interface changes. 2009-11-10 00:15:54 +01:00
Michal Krol
d37f7694b6 glsl/pp: Have sl_pp_purify() return error msg/line no. 2009-11-10 00:15:33 +01:00
Zack Rusin
031fbb9681 st/xorg: remove deprecated rendering code 2009-11-09 18:04:21 -05:00
Zack Rusin
a6d527d7b8 st/xorg: fix composite batching
quite a large performance optimization (text demo from 1.6fps to 9fps)
2009-11-09 18:04:21 -05:00
Jerome Glisse
216319fc0f r600/r700: typo, fix mask of DB_ALPHA_TO_MASK 2009-11-09 22:37:41 +01:00
Alex Deucher
66d6f9e860 r600: rework DB render setup
- consolidate DB render setup
- only enable perfect ZPASS counts and cull disable
when OQ is active
- enable early Z
2009-11-09 12:20:47 -05:00
Alex Deucher
37676b396a r600: don't emit htile regs
These are needed for HiZ which is not currently used and
the _BASE reg requires a reloc which is not currently supported
in the drm.
2009-11-09 12:16:55 -05:00
Alex Deucher
a9035f3dc3 r600: add missing ZPASS setup bits for r7xx+ 2009-11-09 12:16:55 -05:00
José Fonseca
bc9d51bb0e llvmpipe: Ensure stack variables in unit tests are properly aligned. 2009-11-09 07:26:08 -08:00
Christoph Bumiller
7204b92101 nv50: clarify data for method 0x121c 2009-11-09 14:30:32 +01:00
Corbin Simpson
c9167d868c r300g: Fix up SW TCL rendering functions.
They don't work, but at least they're clean now.
2009-11-08 14:53:29 -08:00
Corbin Simpson
fe89863808 r300g: Protect against possibly missing Draw pointer.
Part of the SW TCL revival.
2009-11-08 14:53:29 -08:00
Corbin Simpson
11d9edf4c9 r300g: Unify context names for counts.
From the SW TCL fixups.
2009-11-08 14:53:29 -08:00
Corbin Simpson
b6f93e2607 r300g: Enable PSC/RS dump with new debugging flags. 2009-11-08 14:53:15 -08:00
Corbin Simpson
0525cb1273 r300g: Fix is_buffer_referenced. 2009-11-08 09:56:02 -08:00
Corbin Simpson
ee28a69188 r300g: Fix build error on old compilers.
This dead code was still getting compiled, causing a bad ref in the lib.
2009-11-08 09:35:07 -08:00
Corbin Simpson
a12fc1a9c4 r300g: Organize inlined state. 2009-11-07 14:32:31 -08:00
Corbin Simpson
547e939afb r300g: DCE.
This must never have been called before; it's completely wrong.
2009-11-07 14:14:19 -08:00
Corbin Simpson
9f49db6f84 r300g: Minor code cleanup to avoid confusion. 2009-11-07 13:37:07 -08:00
Corbin Simpson
fa6916cfef r300g: Remove do-nothing functions. 2009-11-07 13:12:15 -08:00
Corbin Simpson
c4fa0e4caa r300g: Remove faulty assert. 2009-11-07 13:07:52 -08:00
Corbin Simpson
b7322fd874 Merge branch 'r300g-vbo'
This is an experimental HW TCL fastpath for r300g. It should run alright.

Thanks to osiris for making this possible.
2009-11-07 12:03:04 -08:00
Corbin Simpson
0fe5f0c09a r300g: Be more verbose in what's killing us WRT vert formats. 2009-11-07 11:55:29 -08:00
Corbin Simpson
cd5b2a93d5 r300g: Comments. 2009-11-07 11:55:29 -08:00
Corbin Simpson
ef513776b5 r300g: Don't assert on oversized VBOs, just return FALSE. 2009-11-07 11:55:25 -08:00
Corbin Simpson
746c01b3b2 r300g: Moar vbo cleanup. 2009-11-07 11:53:14 -08:00
Corbin Simpson
b6c3954138 r300g: s/false/FALSE/
Also s/true/TRUE/
2009-11-07 11:53:14 -08:00
Corbin Simpson
7da3cc4241 r300g: Clean up indexbuf render, switch to RELOC macro. 2009-11-07 11:53:14 -08:00
Corbin Simpson
7518d9b1b7 r300g: Clean up r300_setup_vertex_buffers. 2009-11-07 11:53:14 -08:00
Corbin Simpson
96b729f926 r300g: Don't pass hw_prim around in the context.
And some other fixes.
2009-11-07 11:53:14 -08:00
Corbin Simpson
24c6fdbd32 r300g: Use common state funcs for translating vert formats. 2009-11-07 11:53:14 -08:00
Maciej Cencora
1ef0341ea7 r300g: don't hang GPU on misbehaving apps 2009-11-07 11:53:13 -08:00
Maciej Cencora
3445f47697 r300g: VBOs WIP 2009-11-07 11:53:13 -08:00
Maciej Cencora
d8592d1724 r300g: add missing flush 2009-11-07 11:53:13 -08:00
Maciej Cencora
c7dfffc5d5 r300g: enable CS dumping 2009-11-07 11:53:13 -08:00
Maciej Cencora
6acb26eadf r300g: move vborender context function to seperate file
r300g: Un-migrate r300_draw_render.

It'll make maintaining the SW TCL path easier.
2009-11-07 11:53:06 -08:00
Jakob Bornecrantz
57d77c6a44 i915g: Fix comment in is buffer referenced 2009-11-07 19:31:18 +00:00
Jakob Bornecrantz
cbad97b685 i965g: Fixup texture formats 2009-11-07 17:47:00 +00:00
Jakob Bornecrantz
229f6b9a7e i965g: Formalize on S8Z24 as the suported depth format 2009-11-07 15:47:21 +00:00
brian
18768393d1 mesa: move code after decl
Fixes bug 24967.
2009-11-07 08:18:07 -07:00
Christoph Bumiller
44cb5b5c66 nv50: enable all 32 threads of a warp
This should be the default setting.
See also 7d967b9b7c.
2009-11-07 10:48:36 +01:00
Eric Anholt
8baee3d25b i965: Use Compr4 instruction compression mode on G4X and newer.
No statistically significant performance difference at n=3 with either
openarena or my GL demo, but cutting program size seems like a good
thing to be doing for the hypothetical app that has a working set near
icache size.
2009-11-06 21:24:22 -08:00
Eric Anholt
ec66644ed0 i965: Share min/max between brw_wm_emit.c and brw_wm_glsl.c 2009-11-06 21:08:55 -08:00
Eric Anholt
cfa927766a i965: Share emit_fb_write() between brw_wm_emit.c and brw_wm_glsl.c
This should fix issues with antialiased lines in GLSL.
2009-11-06 21:08:55 -08:00
Eric Anholt
2b58c31257 i965: Share most of the WM functions between brw_wm_glsl.c and brw_wm_emit.c
The PINTERP code should be faster for brw_wm_glsl.c now since brw_wm_emit.c's
had been improved, and pixel_w should no longer stomp on a neighbor to dst.
2009-11-06 21:08:55 -08:00
Eric Anholt
1e5400c575 i965: Share math functions between brw_wm_glsl.c and brw_wm_emit.c. 2009-11-06 21:08:54 -08:00
Eric Anholt
7059aa0eff i965: Share the sop opcodes between brw_wm_glsl.c and brw_wm_emit.c. 2009-11-06 21:08:54 -08:00
Eric Anholt
726ad15606 i965: Share OPCODE_MAD between brw_wm_glsl.c and brw_wm_emit.c 2009-11-06 21:08:54 -08:00
Eric Anholt
bad5b120be i965: Share the DP3, DP4, and DPH between brw_wm_glsl.c and brw_wm_emit.c 2009-11-06 21:08:54 -08:00
Eric Anholt
06c1bc8a22 i965: Add generic GLSL code for unaliasing a 3-arg opcode, and share LRP code. 2009-11-06 21:08:54 -08:00
Eric Anholt
90629704ef i965: Use a normal alu1 emit for OPCODE_TRUNC. 2009-11-06 21:08:54 -08:00
Eric Anholt
71af508072 i965: Share basic ALU ops between brw_wm_glsl and brw_wm_emit.c
This drops support for get_src_reg_imm in these, but the prospect of getting
brw_wm_pass*.c onto our GLSL path is well worth some temporary pain.
2009-11-06 21:08:54 -08:00
Eric Anholt
0f34cdf621 i965: Collect GLSL src/dst regs up in generic code.
This matches brw_wm_emit.c, which we'll be using shortly.  There's a
possible penalty here in that we'll allocate registers for unused channels,
since we aren't doing ref tracking like brw_wm_pass*.c does.  However, my
measurements on GM965 don't show any for either OA or UT2004 with the GLSL
path forced.
2009-11-06 21:08:54 -08:00
Zack Rusin
e521bf7706 st/xorg: implement batching for the composite op
something is broken so disabled for now
2009-11-06 22:08:21 -05:00
Zack Rusin
4322346f3f st/xorg: batch solid fill requests
instead of lots of very small transfers, one larger is a lot better
for performance
2009-11-06 22:08:21 -05:00
Zack Rusin
e1730632aa st/xorg: start accumulating vertices in a common buffer 2009-11-06 22:08:21 -05:00
Zack Rusin
3f7df23ff5 st/xorg: use quads instead of triangle fans
easier to split, accumulate and batch those
2009-11-06 22:08:21 -05:00
Zack Rusin
6c44d399bd st/xorg: make the buffer size global 2009-11-06 22:08:21 -05:00
Eric Anholt
6b0bcfafab mesa: Reduce the source channels considered in optimization passes.
Depending on the writemask or the opcode, we can often trim the source
channels considered used for dead code elimination.  This saves actual
instructions on 965 in the non-GLSL path for glean glsl1, and cleans up
the writemasks of programs even further.
2009-11-06 14:27:35 -08:00
Chia-I Wu
97ea8e9263 Add new config for OpenGL ES.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-06 14:19:24 -07:00
Chia-I Wu
1046f70a7d gallium: Allow state trackers to install files.
State trackers like es or vega need to install their libraries.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-06 14:19:24 -07:00
Chia-I Wu
7fb41df2cb mesa/main: linear_to_nonlinear is not always available.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-06 14:19:24 -07:00
Chia-I Wu
37dca7955a mesa/es: Improve support for parallel execution of make.
Running make with -j for the first time might fail because glapi headers
haven't been generated.  This commit should make it more reliable.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-06 14:19:23 -07:00
Chia-I Wu
f1c7874cd9 mesa/es: Fix symbol conflicts and warnings.
drawtex.c was listed in LOCAL_ES1_SOURCES twice.  My mistake when
merging the patches.

Also, run gl_apitemp.py with -c to silence warnings and add target
"install".

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-06 14:19:23 -07:00
Chia-I Wu
1af44e9e5a glapi: Add OpenGL ES compatibility mode to scripts.
When the mode is on, the scripts would generate headers that are
suitable for OpenGL ES.  There are two differences.  One is that they
will generate function prototypes for OpenGL ES specific functions.  The
other is that, when a function has multiple names, SET/GET/CALL macros
would be generated for each of names.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-06 14:19:23 -07:00
Eric Anholt
f3cacfe216 mesa: Fix remove_instructions to successfully remove when removeFlags[0].
This fixes the dead code elimination to work on the particular code
mentioned in the previous commit.
2009-11-06 13:16:49 -08:00
Eric Anholt
e4e312d493 mesa: Add an optimization path to remove use of pointless MOVs.
GLSL code such as:
	vec4 result = {0, 1, 0, 0};
	gl_FragColor = result;

emits code like:
  0: MOV TEMP[0], CONST[0];
  1: MOV OUTPUT[1], TEMP[0];

and this replaces it with:
  0: MOV TEMP[0], CONST[0];
  1: MOV OUTPUT[1], CONST[0];

Even when the dead code eliminator fails to clean up a now-useless MOV
instruction (since it doesn't do live/dead ranges), this should at reduce
dependencies.
2009-11-06 13:16:49 -08:00
Eric Anholt
ee0a9e6e10 mesa: Fix up the remove_dead_code pass to operate on a channel basis.
This cleans up a bunch of instructions in GLSL programs to have limited
writemasks, which would translate to wins in shaders that hit the i965
brw_wm_glsl.c path by depending less on in-driver optimizations.  It will
also help hit other optimization passes I'm looking at.
2009-11-06 13:16:49 -08:00
Brian Paul
3105f3aa88 intel: better front color buffer test in intelClear() 2009-11-06 13:52:48 -07:00
Jakob Bornecrantz
1f94c06d3f i965g: Fixup buffer creation function
First tri!
2009-11-06 20:45:40 +00:00
Jakob Bornecrantz
9708ce874e i965g: Add texture transfer functions
They don't seem to work. Maybe we are forgetting to flush the gpu or something.
2009-11-06 20:45:08 +00:00
Eric Anholt
8395da2e8a i965: Always pass the size argument to brw_cache_data.
This keeps the individual state files from having to export their
structures for brw_state_cache initialization.
2009-11-06 11:37:32 -08:00
Eric Anholt
1166294d1d intel: Finish removing the fallback code for bug #16697.
I fixed it properly as of 7216679c19.
2009-11-06 11:37:32 -08:00
Eric Anholt
75bdbdd90b intel: Don't validate in a texture image used as a render target.
Otherwise, we could lose track of rendering to that image, which could
easily happen during mipmap generation.
2009-11-06 11:37:32 -08:00
Eric Anholt
6b68482e68 mesa: Attempt to pair up Driver.RenderTexture and FinishRenderTexture()
This is probably not 100% complete (bind vs unbind may still not pair up
exactly), but it should help out drivers which are relying on
FinishRenderTexture to be called when we're done rendering to a particular
texture level, not just when we're done rendering to the object at all.
This is the case for the one consumer of FinishRenderTexture() so far: the
gallium state tracker.  Noticed when trying to make use of FRT() in the intel
driver.
2009-11-06 11:37:32 -08:00
Eric Anholt
8df81bca17 intel: Clean up some extra struct indirection in finalize. 2009-11-06 11:37:32 -08:00
Eric Anholt
ee7dfbbd6c intel: Use _mesa_get_current_tex_object() to clean up TFP path. 2009-11-06 11:37:31 -08:00
Eric Anholt
8f30ceaaef intel: Remove duplicated arguments from intel_miptree_match_image(). 2009-11-06 11:37:31 -08:00
Eric Anholt
2bc8bcdcd3 i965: Remove an XXX comment for testing some code that seems to work. 2009-11-06 11:37:31 -08:00
Eric Anholt
bb2dd50be0 intel: Remove obsolete comment about GEM in the spans code. 2009-11-06 11:37:31 -08:00
Eric Anholt
8e0f40d287 intel: Use PIPE_CONTROL on gen4 hardware for doing pipeline flushing.
This should do all the things that MI_FLUSH did, but it can be pipelined
so that further rendering isn't blocked on the flush completion unless
necessary.
2009-11-06 11:37:31 -08:00
Eric Anholt
caf3038123 Make a convenient int for what chipset generation we're on.
gen2/3/4 are easier to say than "8xx, 915-945/g33/pineview, 965/g45/misc",
and compares on generation are often easier than stringing together a bunch
of chipset checks.
2009-11-06 11:37:31 -08:00
Ian Romanick
4e4c2ee1fd Merge branch 'mesa_7_6_branch'
This should fix the memory leaks in the assembly parser without the
regressions.

The conflicts in program_lexer.l were related to changes in returning
strings between the branches (always return IDENTIFIER vs. returing
either IDENTIFIER or USED_IDENTIFIER).

The conflicts in program_parse.y were related to two changes in master
One change prints a variable name in an error message.  The other
change adds outputVarSize to the OUTPUT_statement rule.  The cause the
position of the IDENTIFIER to change from $2 to $3.

Conflicts:
	src/mesa/shader/lex.yy.c
	src/mesa/shader/program_lexer.l
	src/mesa/shader/program_parse.tab.c
	src/mesa/shader/program_parse.y
2009-11-06 11:17:00 -08:00
Jakob Bornecrantz
dc97a5d782 i965g: Match pitch modification on get buffer as well
This is a ugly hack in order to match what the intel
X driver gives us. However putting this in the winsys
where it fits better forces it reach more into the
driver then it already does.
2009-11-06 19:05:41 +00:00
Jakob Bornecrantz
8353162a4c progs/trivial: Ignores 2009-11-06 18:40:23 +00:00
Jakob Bornecrantz
833f5bbfaf i965g: First clear! 2009-11-06 18:34:23 +00:00
Keith Whitwell
4fbe6c4e4e i965g: get rid of cc key, simplify state upload
Keep a valid reloc table active between uploads, avoid
recalculating it every time.
2009-11-06 17:26:52 +00:00
Jakob Bornecrantz
0532cc0c86 i965g: trivial/clear can now send stuff to hardware
Added a flag if we should send commands to hardware
as what we send isn't all that correct.
2009-11-06 17:03:01 +00:00
Jakob Bornecrantz
2eb6b0defe i965g: Fix texture blanket function 2009-11-06 16:40:54 +00:00
Jakob Bornecrantz
215b49ae1e i965g: Add functions needed by the winsys 2009-11-06 15:55:06 +00:00
Jakob Bornecrantz
6949d5c777 i965g: Winsys whitespace 2009-11-06 15:55:06 +00:00
Jakob Bornecrantz
68b5a501c5 i965g: Build winsys again 2009-11-06 15:55:06 +00:00
Jakob Bornecrantz
12ea198fd2 i965g: Header whitespace 2009-11-06 15:55:06 +00:00
Keith Whitwell
86c32df3e0 i965g: get brw_state_debug.c building 2009-11-06 15:40:16 +00:00
José Fonseca
96e938f62c llvmpipe: Fix build with llvm 2.6.
Fixes bug 24949.
2009-11-06 15:08:05 +00:00
Brian Paul
38d3c156dc intel: call intel_check_front_buffer_rendering() in intelClear()
fixes bug 24953.
2009-11-06 08:00:38 -07:00
Keith Whitwell
4d1ae7a546 i965g: propogate index size state 2009-11-06 14:18:28 +00:00
Keith Whitwell
11805726d3 i965g: remove references to brw_surface_bo() 2009-11-06 13:41:52 +00:00
Keith Whitwell
eacd13bcc8 i965g: plumb through fb_write target and eot data 2009-11-06 13:28:04 +00:00
Keith Whitwell
3e14a482da i965g: propogate nr_cbufs into wm prog key 2009-11-06 12:51:26 +00:00
José Fonseca
577a598dc9 mesa: Export S3_s3tc as well.
Used in Quake3.
2009-11-06 12:06:45 +00:00
José Fonseca
f611425101 mesa: Translate MAP_UNSYNCHRONIZED_BIT. 2009-11-06 12:06:44 +00:00
José Fonseca
244591ae7b gallium: Add UNSYNCHRONIZED cpu access flag. Document others. 2009-11-06 12:06:44 +00:00
Keith Whitwell
1e3910a878 i965g: init saturate field in fp dst_reg helper 2009-11-06 12:01:11 +00:00
Keith Whitwell
a485341455 i965g: add dumping for our new pass_fp output 2009-11-06 11:56:52 +00:00
Keith Whitwell
381cd2d63f i965g: disassemble each instruction as generated 2009-11-06 11:45:01 +00:00
Keith Whitwell
aab9601a75 i965g: hardwire linear interpolation for now
seems to generate saner code, need to go back and fix perspective
interpolation (and remove the hard-wire) once this is working.
2009-11-06 11:21:08 +00:00
Keith Whitwell
caf2cf884c i965g: fix some reloc counts 2009-11-06 10:38:19 +00:00
Keith Whitwell
212fb8adbd i965g: don't set up vs stack register for non-branching shaders 2009-11-06 10:24:19 +00:00
Keith Whitwell
1d6b5957c6 i965g: add DEBUG_MIN_URB flag 2009-11-06 10:19:39 +00:00
Keith Whitwell
5d7c0cf563 i965g: tgsi outputs cannot be used as source regs 2009-11-06 10:19:24 +00:00
Keith Whitwell
b216f1aa47 i965g: use curr.vertex_element state directly 2009-11-06 09:38:14 +00:00
Keith Whitwell
5a24c66915 trivial: add vbo-tri, an even simpler version of tri.c 2009-11-06 09:34:02 +00:00
Keith Whitwell
c22b47ebb1 i965g: don't emit line stipple packet if stipple disabled 2009-11-06 08:57:40 +00:00
Keith Whitwell
fc7fa678f5 i965g: populate brw_context chipset id 2009-11-06 08:57:02 +00:00
Keith Whitwell
0e80e4ea75 i965g: make sure blend color packet header is initialized
We will emit this packet at startup (dirty == ~0), even if we haven't
had the state tracker call into brw_set_blend_color() yet.

This way is a little more efficient also.
2009-11-06 08:54:01 +00:00
Keith Whitwell
018e2250b8 i965g: remove/disable inactive state atoms 2009-11-06 08:33:10 +00:00
Keith Whitwell
4a3e24522b i965g: populate wm reloc array earlier
Still have to calculate the reloc background in two places.
2009-11-06 08:29:09 +00:00
Keith Whitwell
b8e63e9210 i965g: point_rast_rule comment no longer applies
Not sure exactly what state we want here now, will need to experiment.
2009-11-06 08:28:17 +00:00
Keith Whitwell
b9bb41321a i965g: scissor off by one 2009-11-06 08:27:43 +00:00
Keith Whitwell
a49ccf0fd2 i965g: restore code to populate the relocation background
I'm emitting this in two places now, to the data presented
for upload and also in the delta field of the reloc struct.
Probably want to remove the delta field and just pull the
background from the key.
2009-11-06 07:47:07 +00:00
Zack Rusin
25728860fc st/xorg: unify vertex buffer handling
first step on our way to batching
2009-11-06 00:19:54 -05:00
Chia-I Wu
5b85cada60 progs/es: OpenGL ES 1.x and 2.X demo programs.
The demo programs are written by Brian Paul, and cherry-picked from
opengl-es branch.  Several minor issues such as a linking problem are
fixed.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-05 20:04:21 -07:00
Chia-I Wu
d14ac1073c st/es: Add OpenGL ES state trackers.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-05 20:04:21 -07:00
Chia-I Wu
34064756a5 mesa/es: Add support for GL_OES_draw_texture.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-05 20:04:20 -07:00
Chia-I Wu
bfa66bd6f9 mesa/es: Add OpenGL ES overlay.
This is primitive support for OpenGL ES.  It uses a subset of mesa
sources to build libesXgallium.a and libesXapi.a, where X is 1 for
OpenGL ES 1.x, 2 for OpenGL ES 2.x.  The static libraries serve the same
purpose as libmesagallium.a and libglapi.a do for OpenGL.

This is based on the work of opengl-es branch.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-05 20:04:20 -07:00
Chia-I Wu
f68bf0621d mesa/es: Add OpenGL ES XMLs.
These XMLs define OpenGL ES 1.x and 2.x APIs.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-05 20:04:20 -07:00
Chia-I Wu
7cdf8ab096 mesa/main: Make _mesa_TexGenf and _mesa_GetTexGenfv global again.
They are needed by OpenGL ES overlay.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-05 20:04:20 -07:00
Chia-I Wu
5b426288c2 glapi: Include headers with directory prefixes.
This allows different sets of generated sources and headers to be used.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-05 20:04:11 -07:00
Chia-I Wu
7df4c7e1b8 glapi: Avoid hardcoded category names in remap helper script.
The output of the script is unchanged.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-05 20:04:10 -07:00
Chia-I Wu
6418f836d4 glapi: Add is_abi() to test if a function is in the ABI.
The test is done by checking if the offset is manually assigned.  The
generated headers are unchanged.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-05 20:04:10 -07:00
Chia-I Wu
8d2edbf139 mesa/main: Add more OpenGL ES types to glheader.h.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-05 20:04:10 -07:00
Chia-I Wu
c3d61d3785 mesa/main: Add support for point size array in _mesa_GetPointerv.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-05 20:04:10 -07:00
Chia-I Wu
6678f597e7 gallium/xlib: Fix missing symbols when GLX_INDIRECT_RENDERING is defined.
When GLX_INDIRECT_RENDERING is defined, some symbols are used in
libglapi.a but are not defined.  Define them through the help of
glapitemp.h.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-05 20:03:57 -07:00
Chia-I Wu
888429360a mesa/xlib: Fix missing symbols when GLX_INDIRECT_RENDERING is defined.
When GLX_INDIRECT_RENDERING is defined, some symbols are used in
libglapi.a but are not defined.  Define them through the help of
glapitemp.h.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-05 20:03:57 -07:00
Chia-I Wu
7870298086 glapi: Allow normal entry points to be skipped.
Reorganize glapitemp.h such that it is possible to skip normal entry
points or protocol entry points by defining
_GLAPI_SKIP_NORMAL_ENTRY_POINTS or _GLAPI_SKIP_PROTO_ENTRY_POINTS.

Protocol entry points are those with different GLX protocols.  They are
skipped in libglapi.a when GLX_INDIRECT_RENDERING is defined.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-11-05 20:03:56 -07:00
Keith Whitwell
c93d9c1ce3 i965g: clean up winsys dumping code a little 2009-11-05 22:51:34 +00:00
Keith Whitwell
4c196ed7a8 i965g: pass relocation information in an array with bo_subdata
Makes it easier to dump as we get all of the information
about the upload in a single hit.

Opens the window to simplification in the driver if these
relocation arrays can be maintained statically rather than
being recreated whenever we check for a new upload.

Still needs some cleanup to avoid uglyness introduced with the
delta values.
2009-11-05 22:43:36 +00:00
Keith Whitwell
3763457892 i965g: propogate map-buffer-range semantics down to winsys 2009-11-05 21:09:51 +00:00
Keith Whitwell
963728665a i965g: make the winsys responsible for all buffer->offset handling
The winsys now inserts the presumed offset into referring buffers from
inside of bo_emit_reloc().  Remove the many locally coded places where
this was happening in the driver and eliminate the worry of getting it
wrong.

No longer need to expose offset values to the driver at all, so no need
to worry about what to do in the driver when they change.  Just use
zero values wherever we had offsets previously -- the relocations will
fix it all up for us.
2009-11-05 20:34:27 +00:00
Brian Paul
d971069fc6 mesa: fix infinite loop bug in _mesa_drawbuffers()
Fixes bug 24946.
This regression came from 8df699b3bb.
2009-11-05 13:17:21 -07:00
Keith Whitwell
658da189b6 i965g: remove duplicate viewport state in brw_context 2009-11-05 19:58:02 +00:00
Keith Whitwell
8f0e51be47 i965g: correct sense of writedisable flags 2009-11-05 19:57:59 +00:00
Keith Whitwell
b229ee342f brw: push more dumping into the winsys 2009-11-05 19:57:28 +00:00
José Fonseca
67034b9efc softpipe: Implement PIPE_BLENDFACTOR_SRC_ALPHA_SATURATE for destination.
It is a valid and tested combination on D3D9.
2009-11-05 19:44:07 +00:00
Keith Whitwell
a70e6178d4 i965g: correct size of surf_bo array 2009-11-05 17:42:38 +00:00
Keith Whitwell
205871c76a i965g: use Elements in loops over arrays 2009-11-05 17:42:13 +00:00
Keith Whitwell
674c390aaf i965g: add const qualifiers 2009-11-05 17:41:35 +00:00
Keith Whitwell
aa9773d056 i965g: disassemble more than one instruction at a time 2009-11-05 15:34:18 +00:00
Keith Whitwell
203adb8ea6 i965g: remove old dumping code 2009-11-05 15:15:04 +00:00
Keith Whitwell
61a8ab3359 i965g: call dissassembler for appropriate data uploads 2009-11-05 15:10:22 +00:00
Keith Whitwell
c796aed5dd i965g: add lots of error checks and early returns
Any allocation that may fail should be checked, and propogate the
error upwards.  At the highest level we will flush batch and retry.

This is an alternate strategy to what the original DRI driver did of
attempting to flush batch from the lowest levels (eg inside
BEGIN_BATCH).  The trouble with that strategy was that flushes could
occur at unexpected times, and additionally there was a need for a
wierd notification mechanism to propogate the 'lost context' state
back up to higher levels.

Propogating the errors directly gives us a lot of flexibility how to
deal with these states, at the expense of a lot more checking in the
code.

Will add some sanity checks later to make sure that out-of-memory
conditions are properly escalated and not lost halfway up the stack.
2009-11-05 14:01:37 +00:00
José Fonseca
31b8b1dd36 i965g: Don't dump pads or dwords aliases. 2009-11-05 12:45:23 +00:00
Keith Whitwell
09454f68e5 i965g: hook up dumpers in dumping winsys 2009-11-05 12:35:22 +00:00
José Fonseca
9069c791d0 i965g: Dumper for i965 structures. 2009-11-05 12:22:01 +00:00
Keith Whitwell
6ac38232ee i965g: add data type tags to aid dumping/decoding 2009-11-05 10:59:02 +00:00
Cooper Yuan
e0590159ce g3dvl: remove a debug line 2009-11-05 16:06:01 +08:00
Keith Whitwell
b2bf5f98d9 i965g: use pipe_error return value for brw_batchbuffer_require_space
trivial/tri runs without crashing (on debug winsys) but still produces
obviously incorrect command buffers.
2009-11-05 08:01:48 +00:00
Keith Whitwell
2475e5db67 i965g: fix compiler warning 2009-11-05 08:00:33 +00:00
Cooper Yuan
c621c100b2 g3dvl: add scissor setting 2009-11-05 15:59:27 +08:00
Marek Olšák
c2e47191d7 r300g: add polygon mode
Signed-off-by: Corbin Simpson <MostAwesomeDude@gmail.com>
2009-11-04 18:19:34 -08:00
Marek Olšák
4671005a43 r300g: fix the size of CS when emitting the fragprog constant buffer
Signed-off-by: Corbin Simpson <MostAwesomeDude@gmail.com>
2009-11-04 18:19:34 -08:00
Marek Olšák
07190888bd r300g: set the correct offset in a colorbuffer surface
Suggested by Joakim Sindholt.

Also, put flushing of colorbuffers _before_ the framebuffer state setup,
suggested by docs.

Signed-off-by: Corbin Simpson <MostAwesomeDude@gmail.com>
2009-11-04 18:19:34 -08:00
Marek Olšák
ad96c0d851 r300g: add color channel masking
Signed-off-by: Corbin Simpson <MostAwesomeDude@gmail.com>
2009-11-04 18:19:34 -08:00
Jakob Bornecrantz
47cbbb7253 i965g: Builds with scons
But there are some missing symbols, "nm -u i965_dri.so"
[SNIP]
                 U brw_surface_bo
                 U brw_surface_pitch
                 U brw_texture_blanket_winsys_buffer
                 U brw_texture_get_winsys_buffer
                 U brw_update_dirty_counts
[SNIP]
2009-11-05 01:22:10 +00:00
Jakob Bornecrantz
643bb3419d i965g: Fix debug check 2009-11-05 01:22:10 +00:00
Jakob Bornecrantz
ce4f23aab9 i965g: Build with configure 2009-11-05 01:22:10 +00:00
Jakob Bornecrantz
37c6820d0d i965g: Do not create a symlink for i965_dri.so 2009-11-05 01:22:10 +00:00
Jakob Bornecrantz
9bc59a9b6d i915g: Do not create a symlink for i965_dri.so 2009-11-05 01:22:10 +00:00
Brian Paul
898de4a9d5 Merge branch 'mesa_7_6_branch'
Conflicts:

	src/mesa/drivers/windows/gdi/mesa.def
2009-11-04 17:57:20 -07:00
Brian Paul
fe86f8d732 ARB prog parser: include variable name in error text 2009-11-04 17:27:49 -07:00
Keith Whitwell
ffc2446391 i965g: enable line stipple packet emit
With this change, trivial/tri manages to build and emit
a fairly unconvincing command buffer (to the debug winsys),
and then crashes.
2009-11-04 23:44:25 +00:00
Keith Whitwell
c2e51effe6 i965g: fix order of calculation of brw->wm.nr_surfaces 2009-11-04 23:41:30 +00:00
Keith Whitwell
220566d8dc i965g: consolidate some includes 2009-11-04 23:37:52 +00:00
Keith Whitwell
e84e86ecb2 i965g: fix some asserts 2009-11-04 23:33:08 +00:00
Keith Whitwell
7a49bd6d15 i965g: remove redundant screen pointer in brw context struct 2009-11-04 23:30:52 +00:00
Keith Whitwell
e3e084c660 i965g: initialize winsys pointer in surface cache 2009-11-04 23:27:50 +00:00
Keith Whitwell
518171a887 i965g: init pointer to null, avoid segfault 2009-11-04 23:27:30 +00:00
Keith Whitwell
bf4a518cf2 i965g: clean up wm init_registers func 2009-11-04 23:22:48 +00:00
Keith Whitwell
1b611f99b4 i965g: hook up some missing vertex shader code 2009-11-04 23:18:07 +00:00
Zack Rusin
4c5a758d06 st/xorg: these flushes shouldn't be necessary
performance optimization
2009-11-04 18:10:33 -05:00
Keith Whitwell
cc8105d740 i965g: hook up some vertex state funcs 2009-11-04 23:09:23 +00:00
Keith Whitwell
18efe9a687 ws/i965: allow NULL buffer in winsys::bo_unreference
Special case to avoid clutter in the driver
2009-11-04 23:09:05 +00:00
Alex Deucher
9fce12b894 r600: rework draw functions
Seems INDX_OFFSET doesn't work properly on some cards,
so change back to immediate mode indices.  Seems to only
affect DRI1.  Needs more investigation.

Rework and clean up the draw functions.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
2009-11-04 16:59:13 -05:00
Keith Whitwell
951fdac566 i965g: pull in a copy of intel_decode.c for now
With the stubbed out, non-hardware xlib winsys, trivial/clear runs and
prints a plausible command stream
2009-11-04 21:37:07 +00:00
Keith Whitwell
cde48bc8d1 i965g: hook up flush-frontbuffer 2009-11-04 21:12:48 +00:00
Keith Whitwell
b8bb48f452 i965g: fix up batchbuffer confusion 2009-11-04 21:05:34 +00:00
Keith Whitwell
c5ed7b6e76 i965g: plumb in some surface state 2009-11-04 20:36:48 +00:00
Keith Whitwell
e18f223da7 i965g: hook up pipe_clear functions 2009-11-04 20:26:41 +00:00
Alex Deucher
70dade8afe r600: fix count prediction for IB case
Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
2009-11-04 14:43:24 -05:00
Keith Whitwell
19119517ce i965g: add constant buffer setter 2009-11-04 19:41:02 +00:00
Keith Whitwell
4e335a213a i965g: add missing is_*_referenced callbacks 2009-11-04 19:32:44 +00:00
Keith Whitwell
0cf432c7a1 i965g: initialize surface refcount 2009-11-04 19:03:06 +00:00
Keith Whitwell
58e3360c11 i965g: add more missing pipe callbacks 2009-11-04 18:26:34 +00:00
Keith Whitwell
99394a737a i965g: add some missing texture creation code 2009-11-04 16:42:44 +00:00
Keith Whitwell
5f8dde99ed i965g: stubs for brw_pipe_vertex.c 2009-11-04 16:03:52 +00:00
Keith Whitwell
7373bc0e02 i965g: hook up pipe sampler callbacks 2009-11-04 15:59:56 +00:00
Keith Whitwell
9706a83bc9 i965g: hook up more pipe_context functions 2009-11-04 15:25:42 +00:00
Keith Whitwell
a09b3d5097 i965g: add missing buffer functions 2009-11-04 15:10:34 +00:00
Alan Hourihane
3040b2ee9d Fix YTILE spantmp functions 2009-11-04 14:48:25 +00:00
Keith Whitwell
82a19f0974 ws/i965: add load-time driver registration
Otherwise xlib state-tracker doesn't know about us.
2009-11-04 14:03:25 +00:00
Keith Whitwell
b549bbb498 ws/i965: add butt-ugly linker hack
Need more linker magic to keep the glX symbols externally visible even
though they started off in a .a file.
2009-11-04 13:59:59 +00:00
Keith Whitwell
b1d2933214 i965g: hook up brw_screen.c 2009-11-04 13:54:44 +00:00
Keith Whitwell
211d7ab22b i965g: add standalone xlib debug winsys
Create a dummy winsys that just debug-prints on calls into the winsys
functions.  Will use this to get to the point where we are generating
sane-looking debug dumps and diassembly.

Also fix various warnings generated with the new compiler flags set in
this config.
2009-11-04 13:03:35 +00:00
José Fonseca
0b4ea45e8a util: Remove homegrown Windows KM profiler.
It's not sampling based so its results are biased towards functions called
many times.
2009-11-04 12:15:29 +00:00
Michal Krol
767bc8eb5a tgsi/ureg: Allow for multiple extended instruction tokens.
For example, we would like to have a predicate and texture token
in one instruction to do predicated texture sampling.
2009-11-04 11:47:10 +00:00
Keith Whitwell
a277bb20de i965g: convert read/write domain pairs into single usage value
Easier to understand what's going on in the driver sources, convert
stereotype usage values back to GEM read/write domain flags in the
winsys.
2009-11-04 10:09:39 +00:00
Christoph Bumiller
618e3b89f6 nv50: fix shader emit_tex for cube textures 2009-11-04 00:53:52 +01:00
Christoph Bumiller
317ccfe0df nv50: add abs-modifier for emit_minmax 2009-11-04 00:53:51 +01:00
Christoph Bumiller
040e1d008f nv50: add 3d texture tiling and mip-mapping
Mip-mapped 3D textures are not arrays of 2D layers
with a mip-map layout like 2D textures, therefore we
cannot use image_nr == depth for them.

Making use of "volume tiling" modes now, the allowed
modes are 0xZY where Z <= 5 and y <= 5.
2009-11-04 00:53:51 +01:00
Vinson Lee
c475079ef2 progs/util: Fix memory leak if fail to load/compile shader
Signed-off-by: Brian Paul <brianp@vmware.com>
2009-11-03 14:49:41 -07:00
Michal Krol
ceb6728725 llvmpipe: Sanitise shader semantic and interpolator handling.
Handle the remaining semantic names and indices.
Respect color interpolator when not flatshading.

Based on Michal's softpipe commit
eb699d64ec.
2009-11-03 17:12:34 +00:00
Keith Whitwell
026cf84bbb llvmpipe: remove old prim_setup draw stage
Everything now goes through the draw_vbuf handler, the same as
regular drivers.

Based on Keith's commit 4fe0fc3eba.
2009-11-03 17:12:34 +00:00
José Fonseca
677a055fa0 llvmpipe: Respect gl_rasterization_rules in primitive setup.
Based on Michal's identical commit for softpipe
(ca9c413647).
2009-11-03 17:12:34 +00:00
José Fonseca
3e8f665c1e python/retrace: Cope with null constant buffers. 2009-11-03 17:12:33 +00:00
José Fonseca
a2e868b977 python/retrace: Add missing colon. 2009-11-03 17:12:33 +00:00
Brian Paul
a017ad2861 progs/tests: debug code for getting texture component sizes 2009-11-03 10:01:10 -07:00
Michal Krol
7ccf60ae40 tgsi: Up tgsi_exec's control flow nesting to 32. 2009-11-03 16:56:50 +00:00
Brian Paul
4bced42341 Merge branch 'mesa_7_6_branch' 2009-11-03 09:54:09 -07:00
Brian Paul
800e553e7a mesa: clean-up, remove some flushing in FBO functions
Remove some unneeded flushes.
Replace FLUSH_CURRENT w/ FLUSH_VERTICES in other places.
2009-11-03 09:52:25 -07:00
Brian Paul
4de18fb093 mesa: fix indentation 2009-11-03 09:52:25 -07:00
Brian Paul
5698d7cd75 mesa: clean-up formatting 2009-11-03 09:52:25 -07:00
Brian Paul
18af75e501 mesa: avoid extraneous _NEW_BUFFER changes in _mesa_BindFramebufferEXT() 2009-11-03 09:52:25 -07:00
Brian Paul
c7048f9d9f mesa: use FLUSH_VERTICES() in _mesa_drawbuffers() 2009-11-03 09:52:25 -07:00
Brian Paul
8df699b3bb mesa: avoid extraneous _NEW_BUFFER state in _mesa_drawbuffers() 2009-11-03 09:52:25 -07:00
Brian Paul
b28c637382 mesa: use ffs() to shorten loop in _mesa_drawbuffers() 2009-11-03 09:52:25 -07:00
Brian Paul
2d11c48223 mesa: added assertion, another comment 2009-11-03 09:52:25 -07:00
Brian Paul
bcbfda71b0 intel: avoid unnecessary front buffer flushing/updating
Before, if we just called glXMakeCurrent() and didn't render anything we'd
still trigger a flushFrontBuffer() call.

Now only set the intel->front_buffer_dirty field at state validation time
just before we draw something.

NOTE: additional calls to intel_check_front_buffer_rendering() might be
needed if I missed some rendering paths.
2009-11-03 09:52:25 -07:00
Brian Paul
644d8fd363 mesa: added comment 2009-11-02 19:38:35 -07:00
Brian Paul
7157479b25 mesa: use _mesa_get_current_tex_object() 2009-11-02 19:38:35 -07:00
Brian Paul
1afe60e802 mesa: use _mesa_get_current_tex_object() 2009-11-02 19:38:35 -07:00
Brian Paul
b8fdb900fb mesa: make _mesa_get_current_tex_objec() public 2009-11-02 19:38:35 -07:00
Ian Romanick
731810f854 ARB prog parser: Fix a couple issues with previous merge from mesa_7_6_branch
Since the addition of support for Nvidia condition codes, the lexer internally
uses handle_ident to select between returning IDENTIFIER and USED_IDENTIFIER.
Also, use return_string instead of strdup.

Fixes bug #24809.
2009-11-02 12:44:14 -08:00
Pierre Ossman
213ec8251c r600: implement LOG op in compiler 2009-11-02 11:30:00 -05:00
Pierre Ossman
d00cbba403 r600: implement EXP op in compiler 2009-11-02 11:29:54 -05:00
Michal Krol
c379fbbe24 tgsi/ureg: Add negate and swizzle for predicates. 2009-11-02 14:59:52 +00:00
Brian Paul
c02cd82b46 mesa: fix incorrect approx bits/channel for fxt1 formats
See bug 24806.
2009-11-02 06:52:10 -07:00
Brian Paul
a40055f4b6 gallium/util: add casts to silence warnings 2009-11-02 06:51:47 -07:00
Michal Krol
962ece9540 tgsi/ureg: Update for gallium interface changes. 2009-11-02 09:44:21 +00:00
Michal Krol
aa2b2e5d7d tgsi: Update for gallium interface changes. 2009-11-02 09:44:20 +00:00
Michal Krol
0a7d50ed7e gallium: Cleanup predicate and condition code TGSI tokens.
There is little point in having a special TGSI token just to handle
predicate register updates. Remove tgsi_dst_register_ext_predicate token
and instead use a new PREDICATE register file to update predicates.
Actually, the contents of the obsolete token are being moved
to tgsi_instruction_ext_predicate, where they should be
from the very beginning.

Remove the NVIDIA-specific condition code tokens -- nobody uses them
and they can be emulated with predicates if needed.

Introduce PIPE_CAP_SM3 that indicates whether a driver supports
SM3-level instructions, and in particular predicates.

Add PIPE_CAP_MAX_PREDICATE_REGISTERS that can be used to query the driver
how many predicate registers it supports (currently it would be 1).
2009-11-02 09:44:18 +00:00
Michal Krol
eb699d64ec softpipe: Sanitise shader semantic and interpolator handling.
Handle the remaining semantic names and indices.
Respect color interpolator when not flatshading.
2009-11-02 09:44:16 +00:00
Keith Whitwell
4ea94c04c9 i965g: format RELOCs similarly 2009-11-02 08:50:16 +00:00
Keith Whitwell
23c2ba8280 i965g: rename brw_constant_buffer to brw_curbe_buffer
Now that there are real constant buffers, try to reduce naming confusion.
2009-11-02 08:48:26 +00:00
Younes Manton
87d7c1aa15 nouveau: Assume all texture blankets are linear for now. 2009-11-01 18:27:47 -05:00
Corbin Simpson
1f630fa016 r300g: Miscellania. Avoid draw segfaults, s/true/TRUE/, etc.
Cleared out my git stash.
2009-11-01 11:54:52 -08:00
Keith Whitwell
15a8ac2c9d i965g: driver and winsys compile
A milestone of sorts.  Still a long way from something working --
the old one compiled too, at least some of the time...
2009-11-01 19:30:53 +00:00
Maciej Cencora
3d73852121 r300g: fix geometry corruptions
PVS flush is needed before changing the vertex shader or vertex shader constants.
2009-11-01 11:02:02 -08:00
Maciej Cencora
2db46af875 r300g: split constant buffer and shader emittion 2009-11-01 11:01:40 -08:00
Keith Whitwell
efda453d64 i965g: the whole drivers/i965 directory is compiling
That was a lot more work than I expected.  Still the winsys to go,
then the small matter of making it work and re-enabling the
missing functionality.
2009-11-01 17:55:16 +00:00
Corbin Simpson
cab749a1d0 r300g: Adopt osiris' PSC data and swizzle.
A fair amount more flexible and easier to maintain.
2009-11-01 09:24:02 -08:00
Keith Whitwell
4a3e002cf9 i965g: more files compiling 2009-11-01 17:18:56 +00:00
Keith Whitwell
6981bbfabe i965g: more files compiling 2009-11-01 15:59:21 +00:00
Keith Whitwell
15e7a3b8bb i965g: more files compiling 2009-11-01 14:33:01 +00:00
Christoph Bumiller
5de8f97440 nv50: handle TGSI_SEMANTIC_FACE 2009-11-01 14:28:08 +01:00
Christoph Bumiller
496c9eaacf nv50: make IF condition safe
Don't assume that a SET that writes to IF's argument
directly precedes the IF.
2009-11-01 14:28:04 +01:00
Christoph Bumiller
99e308a0e0 nv50: implement TGSI_OPCODE_AND/OR/XOR
Will use AND for gl_FrontFacing, the face input
is either 0 or 0xffffffff.
2009-11-01 14:27:35 +01:00
Keith Whitwell
39448a9aa0 i965g: more files compiling 2009-11-01 13:11:56 +00:00
Keith Whitwell
9b18ca0955 i965g: more work on compilation -- surface management 2009-11-01 12:08:14 +00:00
Keith Whitwell
e7b7600082 i965g: more work on compilation 2009-10-31 20:05:19 +00:00
Christoph Bumiller
1cc16e1b83 nv50: fix textures with block size != cpp
First, using width * block size as pitch is evidently
wrong if a block contains more than 1 texel.

For tiled textures, since a block occupies a contiguous
area of memory, y addressing in m2mf has to be done by
block index, not the y coordinate itself.

This should fix compressed textures.
2009-10-31 20:51:09 +01:00
Keith Whitwell
f202a34cb1 i965g: non-glsl fragment shader path is compiling
Disabled glsl code for now, probably want to clean this up somehow.
2009-10-31 18:23:14 +00:00
Keith Whitwell
5d61b6f1f6 i965g: wip on fragment shaders 2009-10-31 15:05:01 +00:00
Younes Manton
91232b7004 nouveau: Support X8R8G8B8 textures on nv30, nv40 and RTs on nv10-nv40. 2009-10-31 09:42:49 -04:00
Christoph Bumiller
9831e1f76c nv50: use SIFC also for shader upload
Adds a more generic SIFC transfer function.
2009-10-31 13:40:33 +01:00
Christoph Bumiller
525f529d13 nv50: make MRTs work
We have to indicate to the hw whether the FP exports
multiple colour results.
Method 0x121c is used to specify the number of RTs.
Also deactivate zeta explicitly if there's no zsbuf.
2009-10-31 13:40:33 +01:00
Dave Airlie
73b45b0669 radeon: add missing include 2009-10-31 21:24:50 +10:00
Marek Olšák
c9928ac3ee r300g: correct the pitch calculation for smaller mipmaps 2009-10-31 07:30:48 +01:00
Marek Olšák
3f60130b87 r300g: pretend NPOT support
It's requires to get GL2.1, therefore, much more piglit tests can be used
for testing. Figure out later how to emulate this.
2009-10-31 07:30:48 +01:00
Marek Olšák
a8f85dceb5 r300g: fix reading from the destination buffer in blending 2009-10-31 07:30:48 +01:00
Marek Olšák
63c9450ae7 r300g: add precalculating of pixel pitch, add a new NPOT flag 2009-10-31 07:30:48 +01:00
Marek Olšák
11180b4471 r300g: remove unnecessary assertions
Also, correct typos in comments.
2009-10-31 07:30:48 +01:00
Marek Olšák
ace78d90de r300g: fix crash in r300_is_texture_referenced
Also, a subtle fix in emitting a texture state
2009-10-31 07:30:47 +01:00
Dave Airlie
5cf7c8e2d5 radeon: use _mesa_get_current_tex_unit 2009-10-31 15:50:12 +10:00
Brian Paul
5e9f97f0ea ARB prog parser: regenerated files 2009-10-30 19:08:19 -06:00
Brian Paul
df5615de1f ARB prog parser: new set_src_reg(), set_dst_reg() helpers
These functions do sanity checks on the register file and index.
2009-10-30 19:08:18 -06:00
Brian Paul
a71edc9455 mesa: better error message 2009-10-30 19:08:18 -06:00
Eric Anholt
7c8bed62e0 intel: Use GTT mapping when available for swrast.
This improves piglit quick.tests runtime from 19:33 minutes to 6:06 on
my GM45.  It should also hide most of the A17 swizzling issues, though
they'll still exist when swapping occurs (which is the kernel's problem
either way).
2009-10-30 17:35:12 -07:00
Eric Anholt
d63c29ef20 x86: Fix the test for negative pixel count in optimized rgb565 spans.
There's a bunch of bogus looking stuff the count handling in this code, but
this fixes the testcases we have.
2009-10-30 17:35:11 -07:00
Eric Anholt
21a3a79371 intel: Fix up z24_x8 depth spans since the texformat merge. 2009-10-30 17:35:11 -07:00
Vinson Lee
9c3197ef0a prog/tests: Fix MSVC build.
Signed-off-by: Brian Paul <brianp@vmware.com>
2009-10-30 15:30:13 -06:00
Eric Anholt
cb132406de i965: Add an index assert on get_fp_inst array like other compiler arrays. 2009-10-30 13:28:44 -07:00
Eric Anholt
2c30ee9bd6 i965: Fix BRW_WM_MAX_INSN to reflect current limits.
Part of fixing bug #24355.
2009-10-30 13:20:34 -07:00
Eric Anholt
2073006c95 intel: Set the texture format in the TFP path.
This fixes a regression in piglit's tfp test as of
11caea687e.  Additionally, set the texture
format for the RGB textures to MESA_FORMAT_XRGB8888 and support it in the
hw paths so that hopefully sw fallbacks involving TFP get better alpha
behavior.

The radeon drivers appear to need the same fix.

Bug #24803
2009-10-30 12:41:28 -07:00
Alex Deucher
b568a2c808 r600: remove duplicate line 2009-10-30 15:08:09 -04:00
Alex Deucher
703a836d40 r600: fill in some missing tex formats
This improves shadowtex since the component ordering
is at least correct now, but I'm not sure how to
deal with texturing from a depth surface yet due to
differences in depth and color tile layouts.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
2009-10-30 15:02:34 -04:00
Alex Deucher
57864f6e04 r600: fix a warning, update comments 2009-10-30 11:52:02 -04:00
Vinson Lee
a8ed066858 progs/tests: fix MSVC build.
Signed-off-by: Brian Paul <brianp@vmware.com>
2009-10-30 09:40:04 -06:00
Andre Maasikas
5f7d5d3ea3 r600: use AUTO_INDEX for draw - saves cmd buffer space
also seems we can use INDX_OFFSET if start != 0
2009-10-30 17:18:00 +02:00
Brian Paul
409469fb70 intel: fix up some XRGB breakage
We weren't choosing the right XRGB span functions for reading the
framebuffer.  XRGB formats still aren't turned on yet though.
2009-10-30 09:13:04 -06:00
Brian Paul
730a3de9f9 mesa: fix inverted buffer object test
Fixes bug 24799.
2009-10-30 08:31:01 -06:00
Brian Paul
71cd40bccf mesa: fix incorrect format info for MESA_FORMAT_SL8
Fixes bugs 24798 and 24801.
2009-10-30 08:21:16 -06:00
Michal Krol
ca9c413647 softpipe: Respect gl_rasterization_rules in primitive setup. 2009-10-30 08:05:40 +00:00
Brian Paul
4a253431ab intel: update intel_create_renderbuffer(format), add XRGB support
Pass a gl_format to intel_create_renderbuffer() instead of GLenum.
Add cases for MESA_FORMAT_XRGB8888 textures and renderbuffers.
However, we don't yet create any renderbuffers or textures with that
format.  It seems the default alpha value is zero instead of one.
Need to investigate that first.
2009-10-29 19:12:50 -06:00
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
Keith Whitwell
99cc0fd675 i965g: work in progress on fragment shaders 2009-10-29 20:18:01 +00: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
1e2c517026 progs/tests: also test GL_BGRA format in getteximage.c 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
Brian Paul
1f196b786d Merge branch 'texformat-rework'
Conflicts:
	src/mesa/drivers/dri/radeon/radeon_fbo.c
	src/mesa/drivers/dri/s3v/s3v_tex.c
	src/mesa/drivers/dri/s3v/s3v_xmesa.c
	src/mesa/drivers/dri/trident/trident_context.c
	src/mesa/main/debug.c
	src/mesa/main/mipmap.c
	src/mesa/main/texformat.c
	src/mesa/main/texgetimage.c
2009-10-28 21:24:11 -06:00
Brian Paul
086f9fc0e2 swrast: fix RGB, RGBA texturing code
Fix backward component ordering for RGB textures.
Only optimize RGBA texture case if running little endian.  This restriction
could be lifted with a little work.
2009-10-28 19:46:28 -06:00
Brian Paul
88bb4b5935 swrast: check for single texture unit in _swrast_choose_triangle() 2009-10-28 19:41:24 -06:00
Brian Paul
0103d7a47a swrast: clean up and remove dead code in triangle functions 2009-10-28 19:40:56 -06:00
Brian Paul
1e7517f059 swrast: fix texel decoding in opt_sample_rgba_2d() 2009-10-28 19:38:12 -06:00
Brian Paul
7ac233ec15 mesa: choose texture format in _mesa_get_fallback_texture() 2009-10-28 19:33:48 -06:00
Brian Paul
0ea575d721 Merge branch 'mesa_7_6_branch' 2009-10-28 18:27:25 -06:00
Keith Whitwell
81b8589f06 i965g: still working on compilation 2009-10-28 21:24:03 +00:00
Zack Rusin
24c61c8c2e st/xorg: fix src coordinates in the video acceleration paths 2009-10-28 16:53:50 -04:00
Alex Deucher
660acd60d0 r600: add occlusion query support
Based on initial patch from Stephan Schmid <stephan_2303@gmx.de>.

Basic idea is to dump the zpass count at the start and end of the query
and subtract to get the total number of visible fragments.  HW writes
alternating qwords for up to 4 DBs.  On the first pass, we start at
buffer address + 0; on the second pass, we start at buffer address + 8
(bytes). The resulting buffer at the end of the query looks like:

qw[0]: db0 start
qw[1]: db0 end
...
qw[6]: db3 start
qw[7]: db3 end

The MSB of each qword is the valid bit and the lower 63 bits are
the zpass count for that DB.

OQ on RV740 is disabled at the moment as it only seems to report
results for half of its DBs.  This needs further investigation.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
2009-10-28 15:53:24 -04:00
Corbin Simpson
f3d8d534e6 r300g: Use u_trim_pipe_prim to prevent lockups from incorrect vert counts.
Adapted from osiris' version on his tree.
2009-10-28 12:15:35 -07:00
Corbin Simpson
23d8d15bed r300g: Keep texture formats organized. 2009-10-28 12:15:35 -07:00
Maciej Cencora
e7c8a27638 r300g: add some texture formats 2009-10-28 12:15:35 -07:00
Corbin Simpson
6007e2e008 r300g: Clear up a bit of the buffer reference stuff.
Still need to actually get reference info from winsys somehow. Doing added
buffers is easy, but knowing whether a flush has happened is a bit tricky.
2009-10-28 12:15:34 -07:00
Corbin Simpson
81c51bb67f r300g: Fix XXX.
Nothing strange here.
2009-10-28 12:15:34 -07:00
Marek Olšák
bcfde42913 r300g: fix emitting the stencil-ref and alpha-ref values
Signed-off-by: Corbin Simpson <MostAwesomeDude@gmail.com>

DSA really needs its head examined someday. ~ C.
2009-10-28 12:15:34 -07:00
Marek Olšák
a1d726aae8 r300g: fix the WRAP_T mode when using 1D textures
Signed-off-by: Corbin Simpson <MostAwesomeDude@gmail.com>
2009-10-28 12:15:34 -07:00
Marek Olšák
0e44884aad r300g: fix blending and do some optimizations
Signed-off-by: Corbin Simpson <MostAwesomeDude@gmail.com>
2009-10-28 12:15:34 -07:00
Marek Olšák
c451011d99 mesa/st: fix crash in st_texture_image_copy
Signed-off-by: Corbin Simpson <MostAwesomeDude@gmail.com>
2009-10-28 12:15:33 -07:00
Brian Paul
7d56caabe4 Merge branch 'mesa_7_6_branch'
Conflicts:

	src/mesa/shader/lex.yy.c
	src/mesa/shader/program_lexer.l
2009-10-28 11:33:51 -06:00
José Fonseca
182ff3e47a llvmpipe: Make sure the JIT engine and X86 target are linked on MSVC build.
Basically mimic the llvm 2.6 way of linking execution engines and
targets.
2009-10-28 11:26:26 +00:00
José Fonseca
5eba607db6 util: Drop return value from cpuid(). 2009-10-28 11:26:26 +00:00
José Fonseca
0426227b68 util: Fix cpuid on MSVC. 2009-10-28 11:26:26 +00:00
José Fonseca
095e66f695 llvmpipe: Implement round() for MSVC. 2009-10-28 11:26:26 +00:00
Brian Paul
6bc1e9fd69 mesa: consolidate _mesa_CompressedTexSubImage[123]DARB() functions 2009-10-27 21:39:44 -06:00
Brian Paul
f3c29bd74f mesa: consolidate CompressedTexSubImage1/2/3DARB() error checking 2009-10-27 21:15:48 -06:00
Brian Paul
9519603f74 mesa: simplify teximage code with get_current_tex_object() 2009-10-27 21:15:36 -06:00
Brian Paul
dd5691e802 mesa: code refactoring to eliminate a switch stmt in bind_buffer_object() 2009-10-27 20:10:59 -06:00
Brian Paul
b44304efde glsl: avoid redundant state changes in _mesa_use_program() 2009-10-27 20:10:59 -06:00
Zack Rusin
2947d14202 st/xorg: fix xv 2009-10-27 21:00:47 -04:00
Brian Paul
52374d7e4c radeon: add case for MESA_FORMAT_X8_Z24 in radeon_create_renderbuffer() 2009-10-27 17:05:08 -06:00
Brian Paul
f8155ef51f intel: silence warning 2009-10-27 17:01:26 -06:00
Brian Paul
21f8d31cfd mesa: debug code for glBlitFramebuffer() 2009-10-27 17:00:31 -06:00
Brian Paul
507cf530b9 via: silence unused var warnings 2009-10-27 17:00:31 -06:00
Brian Paul
3c71666921 intel: minor clean-up, comments 2009-10-27 17:00:31 -06:00
Brian Paul
7fd8c6ca2a intel: use _mesa_get_current_tex_unit() helper 2009-10-27 17:00:31 -06:00
Brian Paul
05ec586851 mesa: s/Bilt/Blit 2009-10-27 17:00:31 -06:00
Brian Paul
403181b913 mesa: more texture debug code changes, improvements 2009-10-27 17:00:31 -06:00
Brian Paul
58a4328e96 mesa: minor code clean-up in client_state() 2009-10-27 17:00:31 -06:00
Brian Paul
72cb441c2f mesa: avoid redundant state setting in glClientActiveTexture
Plus add code for verbose/debugging.
2009-10-27 17:00:31 -06:00
Brian Paul
33531614de intel: fix comment, formatting 2009-10-27 17:00:31 -06:00
Brian Paul
3bee7610be progs/tests: added new blitfb.c test
Tests glBlitFramebuffer() between two texture/renderbuffer surfaces.
In particular, blit from level[1] of a cube map face to a 2D texture.

Used to find/fix bug in intel do_copy_texsubimage().
See commit aef1ab1073f3e30d699b99dae17518ed48b57c72
2009-10-27 17:00:31 -06:00
Brian Paul
3e45788d5d intel: fix src offset bug in do_copy_texsubimage()
Use src->draw_offset intead of zero.  Zero usually worked, except when
the src renderbuffer is actually a texture mipmap level higher than zero.
Fixes progs/test/blitfb.c test.
2009-10-27 17:00:31 -06:00
Brian Paul
4c2a7bc438 glsl: fix memory leak
A slightly modified version of a patch from Vinson Lee.
2009-10-27 17:00:30 -06:00
Eric Anholt
4f9f5a7840 i915: Fix driver for the miptree x/y offset changes.
Bug #24734.
2009-10-27 17:00:30 -06:00
Brian Paul
e9b17d6477 i965: be clear that the Fallback field is a boolean, not a bitfield 2009-10-27 16:59:44 -06:00
Brian Paul
755161b888 Revert "i965: fix hacked Fallback usage in brw_prepare_vertices()"
This reverts commit 8810b8f671.

It turns out the i965 driver uses the intel->Fallback field as a boolean,
not as a bitmask.  The intelFallback() function is a no-op in the i965
driver.  It would have been nice if there were some comments about this.
I'll fix that next...
2009-10-27 16:59:44 -06:00
Vinson Lee
b7ab7d3627 draw: Fix memory leak.
This would only be hit if we got and invalid index_size.
2009-10-27 16:59:44 -06:00
Brian Paul
b73c4ad98b docs: document Intel glBitmap fixes 2009-10-27 16:59:44 -06:00
Brian Paul
fe818ea797 intel: fix GL state bugs in intel_texture_bitmap()
Need to push texture state and polygon state too.
Fixes rendering glitches seen in progs/demos/engine when changing
the rendering mode (wireframe, texture modes).
This makes bitmap rendering a little slower, unfortunately.
2009-10-27 16:59:43 -06:00
Christoph Bumiller
7d967b9b7c nv50: activate more lanes in a warp
Some cards have crippling defaults set and use only 4
of 32 lanes. This should activate 16 on these.
Those that allow 32 by default should still do so.

Found out by Marcin Kościelnicki.
2009-10-28 00:57:18 +01:00
Jakob Bornecrantz
8a1f239ca9 st/xorg: Adopt to new dirty clip rect type 2009-10-27 17:40:55 +01:00
Keith Whitwell
7ba2fe40fa i965g: still working on compilation 2009-10-27 00:29:21 +00:00
Vinson Lee
50e113e375 progs/tests: Fix MSVC build. 2009-10-26 15:03:52 -06:00
José Fonseca
ad0975f701 scons: Define _USE_MATH_DEFINES on MSVC. 2009-10-26 15:17:26 +00:00
Brian Paul
87127c83dc windows: added remap.[ch] to project files
Untested.  Other updates may be needed to reflect the current source files.
2009-10-26 09:06:00 -06:00
Chia-I Wu
c9d715da39 mesa: Add remap.c to SConscript.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-26 09:01:29 -06:00
Zack Rusin
b5fb60041e st/xorg: initialize indexes before reswizzling for yuv 2009-10-26 08:15:48 -04:00
Zack Rusin
0b069d648b st/xorg: stop overflowing yuv buffers 2009-10-26 08:15:48 -04:00
Zack Rusin
a9f8baf00b st/xorg: add yuv vertex shader
plus some general fixes
2009-10-26 08:15:48 -04:00
Zack Rusin
6b8ce4cc4f st/xorg: add yuv shaders 2009-10-26 08:15:48 -04:00
Keith Whitwell
5a304995e0 i965g: still working on compilation 2009-10-26 01:35:05 +00:00
Marek Olšák
5241b9568c r300g: read occlusion query results from both Z pipes on RV530 2009-10-26 02:07:32 +01:00
Marek Olšák
827002f5ff r300g: add cubemap support
Also, set a pitch for rectangles only.
2009-10-26 02:07:26 +01:00
Keith Whitwell
09c231f84a i965g: still working on compilation 2009-10-26 00:20:33 +00:00
Brian Paul
d8ded352ec progs/tests: disable blending while drawing text 2009-10-25 18:10:45 -06:00
Brian Paul
11caea687e mesa: choose texture format in core mesa, not drivers
Call the ctx->Driver.ChooseTextureFormat() function from core Mesa's
_mesa_[Copy]TexImage functions instead of in the driver functions.
One less thing for drivers to do.
2009-10-25 18:06:24 -06:00
Brian Paul
355b5bde50 mesa: remove _mesa_compressed_texture_size_glenum() stub 2009-10-25 17:32:56 -06:00
Brian Paul
20c6c58532 mesa: remove _mesa_compressed_row_stride() 2009-10-25 17:25:46 -06:00
Brian Paul
e3f2efc4f1 mesa: remove calls to _mesa_compressed_row_stride() 2009-10-25 17:23:37 -06:00
Brian Paul
c83b758760 glide: remove _mesa_compressed_row_stride() calls
And fix incorrect first parameter.
2009-10-25 17:21:27 -06:00
Brian Paul
253e7fee5d mesa: remove _mesa_compressed_row_stride() calls 2009-10-25 17:21:11 -06:00
Brian Paul
2594168e9f mesa: begin removing _mesa_compressed_row_stride() calls
Use equivalent _mesa_format_row_stride() function instead.
2009-10-25 17:20:24 -06:00
Brian Paul
82bcc1c5d2 mesa: simplify texture_row_stride() helper 2009-10-25 17:15:02 -06:00
Brian Paul
07ad6393cb mesa: fix-up error checking related to compressed texture block size 2009-10-25 17:07:27 -06:00
Brian Paul
54bb414e00 mesa: clean-up, simplify compressed texture size checking 2009-10-25 16:59:08 -06:00
José Fonseca
3a49497f10 gallium: Move enum pipe_error into p_defines.h.
It's really just another define. No need for its own header.
2009-10-25 21:11:54 +00:00
José Fonseca
88e08d7c6d llvmpipe: Human friendlier sampler state dump. 2009-10-25 12:27:14 +00:00
José Fonseca
47f0529806 util: Human readable output of texture states. 2009-10-25 12:26:39 +00:00
José Fonseca
5fcb75758c llvmpipe: Dump the sampler state of the shader key. 2009-10-25 11:49:01 +00:00
José Fonseca
e4c5e01c10 llvmpipe: Immediate multiplication. 2009-10-25 11:48:17 +00:00
Keith Whitwell
590949553f i965g: start hooking up some to the gallium context interfaces
- create/bind/destroy blend and depth state
- framebuffer and viewport
- etc.
2009-10-25 11:37:39 +00:00
José Fonseca
e1342f871b llvmpipe: Fast path for sampling rgba8 textures with linear filtering.
Implement Keith's suggestion of doing most of the sampling with 16x8
and 8x16 AoS, and only doing the conversion to floating point SoA at
the very last step.

Improves gloss performance by 10%.
2009-10-25 09:53:49 +00:00
José Fonseca
f3893ca9c8 llvmpipe: Make lerping work for 8.8 fixed point values. 2009-10-25 09:53:49 +00:00
José Fonseca
bfd7a9ca96 llvmpipe: New module to help make assertions about formats. 2009-10-25 09:53:49 +00:00
José Fonseca
47d241be9f llvmpipe: New function to unpack rgba8 formats into 4 x u8n AoS. 2009-10-25 09:53:49 +00:00
José Fonseca
abff4214ef llvmpipe: Split the format swizzling step from the unpacking. 2009-10-25 09:53:48 +00:00
José Fonseca
8d80fd3f55 llvmpipe: Allow different signs when unpacking. 2009-10-25 09:53:48 +00:00
José Fonseca
b544ab7299 llvmpipe: Add inlines to quickly generate types matching the native SIMD register bitwidth. 2009-10-25 09:53:48 +00:00
José Fonseca
a55b305c5b llvmpipe: Merge lp_build_load_rgba_soa into lp_build_sample_texel. 2009-10-25 09:53:48 +00:00
José Fonseca
bc93e9181c llvmpipe: Factor our pixel offset computation. 2009-10-25 09:53:48 +00:00
José Fonseca
fedd054d53 llvmpipe: Share testing infrastructure with lp_test_format. 2009-10-25 09:53:48 +00:00
José Fonseca
17afb6dd69 llvmpipe: Eliminate lp_build_store_rgba_aos. 2009-10-25 09:53:48 +00:00
José Fonseca
232b586464 llvmpipe: Eliminate lp_build_load_rgba_aos. 2009-10-25 09:53:48 +00:00
José Fonseca
b4f6907b8d llvmpipe: Move a few format/sampling functions into better space. 2009-10-25 09:53:47 +00:00
Marek Olšák
c2df759cd7 r300g: fix redefining mipmaps and fetching from them 2009-10-25 10:16:59 +01:00
Marek Olšák
118dfe1688 r300g: added support for 3D textures
Mipmaps not tested. Also, I am not sure why piglit/texturing/tex3d needs
to have color tolerance +-1 to pass. The classic Mesa driver doesn't
need that.
2009-10-25 08:06:19 +01:00
Keith Whitwell
562ca4eae2 i965g: more compiling wip 2009-10-25 01:20:56 +01:00
Keith Whitwell
4dd2f6640b i965g: more work on compiling, particularly the brw_draw files 2009-10-25 00:02:16 +01:00
Brian Paul
d6ee86c77a mesa: remove _mesa_compressed_texture_size()
Use _mesa_format_image_size() instead.
2009-10-24 16:50:00 -06:00
Brian Paul
4c00981b22 mesa: remove ctx->Driver.CompressedTextureSize() hook
It always just called _mesa_compressed_texture_size() anyway.
2009-10-24 16:34:25 -06:00
Brian Paul
35efc6a1b3 mesa: change compressed texture size calls
Replace calls to ctx->Driver.CompressedTextureSize with calls to
_mesa_format_image_size.  The former always called the later.
2009-10-24 16:28:27 -06:00
Brian Paul
bea245ac2f mesa: minor clean-ups in _mesa_store_compressed_texsubimage2d() 2009-10-24 12:04:09 -06:00
Brian Paul
5c82827696 mesa: simplify _mesa_compressed_row_stride(), _mesa_compressed_image_address()
_mesa_compressed_row_stride() can go away soon.
_mesa_compressed_image_address() can be generalized and moved to formats.c
2009-10-24 11:52:36 -06:00
Brian Paul
1ad9671db7 mesa: s/GLuint/gl_format/ 2009-10-24 11:41:25 -06:00
Brian Paul
2c3787f513 mesa: move assertion after declaration 2009-10-24 11:34:27 -06:00
Brian Paul
d255aaf54f mesa: remove hard-coded block sizes 2009-10-24 11:33:58 -06:00
Brian Paul
7b16c43e43 mesa: added _mesa_get_format_block_size() 2009-10-24 11:33:10 -06:00
Brian Paul
51bc12d623 progs/tests: fix sub texture offsets 2009-10-24 11:08:01 -06:00
Keith Whitwell
4f7931bb35 i965g: more work on compiling 2009-10-24 17:07:28 +01:00
Brian Paul
bee6794eb1 mesa: added _mesa_get_format_name() 2009-10-24 08:43:16 -06:00
Brian Paul
eb732b1bbb mesa: additional comments in format code 2009-10-24 08:41:08 -06:00
Keith Whitwell
074606a806 i965g: more files compiling 2009-10-24 13:19:26 +01:00
Keith Whitwell
7ee60648a3 i965g: hook into build system 2009-10-24 11:55:25 +01:00
Keith Whitwell
357e5c9a0e ws/i965: renames from i915, hook up makefiles 2009-10-24 11:55:05 +01:00
Keith Whitwell
d71af266df i965g: first compiling file 2009-10-24 11:53:43 +01:00
Joakim Sindholt
94a63dccdd r300g: fix scons build yet again 2009-10-24 02:43:21 +02:00
Brian Paul
46a784b7fd Merge branch 'mesa_7_6_branch' 2009-10-23 18:38:43 -06:00
Brian Paul
26f1ad65b9 mesa: simplify att->CubeMapFace assignment 2009-10-23 18:31:03 -06:00
Brian Paul
346250b190 mesa: refactor, new print_shader_info() 2009-10-23 18:31:03 -06:00
Brian Paul
81a4d34f07 mesa: rework error checking code for glGetCompressedTexImage()
Do all error checking in new getcompressedteximage_error_check() func.
Move some additional PBO checks out of the driver fallbacks into the
error checking functions.
2009-10-23 18:31:03 -06:00
Brian Paul
d66965c9a1 mesa: remove misplaced VERBOSE_TEXTURE tests 2009-10-23 18:31:02 -06:00
Brian Paul
9b50ceac03 mesa: more detailed error messages in fbo code 2009-10-23 18:31:02 -06:00
Zack Rusin
b17c885a8a st/xorg: fix text with component alpha rendering 2009-10-23 19:39:16 -04:00
Keith Whitwell
c93d2e4540 ws/i965: pull in the rest of the i915 winsys tree.
The intel_xorg file looks like it's got quite a bit of code that could
be lifted up into the xorg state tracker -- should really just have a
list of pci ids and a pointer to a screen create func.
2009-10-23 23:37:45 +01:00
Keith Whitwell
b7efe646b6 ws/i965: clone the i915 winsys
I'll want to rework this, not sure trying to share this code is a very
good idea at least until the interfaces from the two drivers calm
down.
2009-10-23 23:36:02 +01:00
Keith Whitwell
22906f7301 i965g: wip on removing GL stuff, trying to get a few files compiling 2009-10-23 23:27:43 +01:00
Eric Anholt
49d402e275 Merge remote branch 'origin/mesa_7_6_branch'
Conflicts:
	src/mesa/drivers/dri/intel/intel_fbo.c
	src/mesa/drivers/dri/intel/intel_mipmap_tree.c
	src/mesa/drivers/dri/intel/intel_mipmap_tree.h
	src/mesa/drivers/dri/intel/intel_tex_copy.c
	src/mesa/drivers/dri/intel/intel_tex_image.c
2009-10-23 15:21:05 -07:00
Eric Anholt
bfd51dc34d i965: Annotate _NEW_COLOR dependency for brw_update_renderbuffer_surface(). 2009-10-23 14:13:57 -07:00
Christoph Bumiller
683722740c nv50: do SIGN_SET as one instruction 2009-10-23 22:24:13 +02:00
Christoph Bumiller
99e728a13e nv50: fix saturation outside of tx_insn case 2009-10-23 22:24:09 +02:00
Christoph Bumiller
ad67326f12 nv50: allow all 127 TEMP regs
We should really learn to not waste so many though.
2009-10-23 22:24:03 +02:00
Christoph Bumiller
c738c9ab67 nv50: fix address reg code
Contained some rather obvious thinking errors before,
and didn't consider offsets from TGSI ADDRESS regs.
2009-10-23 22:17:44 +02:00
Christoph Bumiller
255a90a7bd nv50: add depth texture formats, and a few others, too 2009-10-23 22:17:34 +02:00
Vinson Lee
952bf63e2c progs/tests: Fix MSVC build. 2009-10-23 13:49:13 -06:00
Keith Whitwell
6b48fb0022 i965: ignore cliprect_mode 2009-10-23 20:19:14 +01:00
Patrice Mandin
d9014a13e7 nouveau: nv30: Relax some limits. We can render to z24s8 buffer even if color buffer is 16 bits. 2009-10-23 18:42:21 +02:00
Patrice Mandin
c84a056764 nouveau: nv30: use r5g6b5 as z16 format 2009-10-23 18:40:13 +02:00
Keith Whitwell
57a920cb1a i965g: wip 2009-10-23 17:03:45 +01:00
Keith Whitwell
2f5f7c0773 i965g: re-starting from the dri driver 2009-10-23 17:03:45 +01:00
Chia-I Wu
6e99e6ddbf glapi: Always build libglapi.a.
This is made possible by making glapioffsets.h and glapidispatch.h
internal headers of glapi.  They should only be included indirectly
through dispatch.h by mesa.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-23 09:10:04 -06:00
Chia-I Wu
22884db174 glapi: Move dispatch marcos to glapidispatch.h.
dispatch.h is kept as a wrapper to glapidispatch.h.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-23 09:10:04 -06:00
Chia-I Wu
3d16088ff0 mesa/dri: Remove extension_helper.h.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-23 09:10:04 -06:00
Chia-I Wu
17ef1f6074 mesa: Enable remap table in core.
This enables the remap table in core.  driInitExtensions is adapted to
use the remap table.  All uses of extension_helper.h are replaced by
remap_helper.h.  The chicken-egg problem of the DRI drivers is also
solved.

It is now also possible to pass NULL extensions to driInitExtensions.
It will cause driInitExtensions to map all known functions.  This
functionality is used by software drivers and EGL_i915.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-23 09:10:04 -06:00
Chia-I Wu
d7d3fb925b mesa/main: Add support for remap table.
This commit only adds the source files.  It is supposed to replace the
remap table in DRI drivers.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-23 09:10:04 -06:00
Zack Rusin
bec5230a1f st/xorg: lots of fixes related to compositing
fixes transformations, rendering with multiple bound textures, xrender
matrix conversions plus some cleanups
2009-10-23 11:11:00 -04:00
Andre Maasikas
d4d4733e6c r600: remove duplicate stride setting
Stride is set already in r700SetVertexFormat and there it works
correctly for 0 also
2009-10-23 17:16:46 +03:00
Andre Maasikas
738b394769 r600: for position invariant programs reading vert_pos is not always known at this point 2009-10-23 17:16:23 +03:00
Keith Whitwell
da253319f9 gallium: remove extended negate also, and also the ExtSwz token
Likewise, the extended negate functionality hasn't been
used since mesa switched to using tgsi_ureg to build programs,
and has been translating the SWZ opcode internally to a single MAD.
2009-10-23 14:50:02 +01:00
Keith Whitwell
8a571b809a cell: typo from ExtSwizzle commit 2009-10-23 14:38:30 +01:00
Keith Whitwell
b9cb74c7f8 gallium: remove the swizzling parts of ExtSwizzle
These haven't been used by the mesa state tracker since the
conversion to tgsi_ureg, and it seems that none of the
other state trackers are using it either.

This helps simplify one of the biggest suprises when starting off with
TGSI shaders.
2009-10-23 14:31:24 +01:00
Keith Whitwell
4e1d51786e gallium: remove noise opcodes
Provide a dummy implementation in the GL state tracker (move 0.5 to
the destination regs).

At some point, a motivated person could add a better
implementation of noise.  Currently not even the nvidia
binary drivers do anything more than this.  In any case, the
place to do this is in the GL state tracker, not the poor
driver.
2009-10-23 13:56:07 +01:00
Keith Whitwell
19403935aa progs/demos: add fps to multiarb 2009-10-23 13:56:07 +01:00
Cooper Yuan
9b6c86b8be r300g: last changes's typo, miss a include file 2009-10-23 16:40:31 +08:00
Cooper Yuan
6df12aad2f r300g: add flush_frontbuffer function to display video surface 2009-10-23 14:46:29 +08:00
Cooper Yuan
0072a26662 g3dvl: pass display and screen to g3dvl when creating video private context 2009-10-23 14:44:27 +08:00
Alex Deucher
45eb9d2f6d r600: remove remains of old tnl pipeline 2009-10-23 01:01:19 -04:00
Alex Deucher
fc38a3cfe8 r600: fix render size prediction 2009-10-23 01:01:19 -04:00
Alex Deucher
614e8f2203 r600: remove old tnl pipeline 2009-10-23 01:01:19 -04:00
Alex Deucher
95328c7cf9 r600: clean up context creation
Make it more consistent with other radeon drivers.
2009-10-23 01:01:18 -04:00
Ian Romanick
286611d990 Revert "Store clipping distance for user clip planes as part of vertex processing"
This reverts commit f058b25881.

This change is completely wrong in so many ways.  When clip distances
are generated as part of vertex processing, they must be interpolated
to perform clipping.  Geometric clipping goes right out the window.
2009-10-22 19:21:21 -07:00
Brian Paul
1160acbfea dri/drivers: update driNewRenderbuffer() to take a gl_format
Now pass a specific MESA_FORMAT_x token to indicate the renderbuffer's
format.  This is better than passing a GLenum and having to guess the
specific format.

I'm unable to test all the drivers, but any issues should be easy to fix.
2009-10-22 19:57:32 -06:00
Brian Paul
cf0e25d4c8 radeon: simplify radeon_create_renderbuffer() 2009-10-22 19:57:06 -06:00
Brian Paul
ab9d1011f5 Merge branch 'mesa_7_6_branch' 2009-10-22 18:38:19 -06:00
Brian Paul
347fb3737b docs: document 'useprog' debug option 2009-10-22 18:35:13 -06:00
Brian Paul
fdce832437 mesa: fix up vbo comments 2009-10-22 18:35:13 -06:00
Brian Paul
488e67bab2 mesa: added _mesa_dump_texture() 2009-10-22 18:35:12 -06:00
Zack Rusin
fb22e80169 st/xorg: fix the makefile when used with new xextproto 2009-10-22 19:33:04 -04:00
Corbin Simpson
04ec113e09 r300g: Enable more stuff in r300_screen, cleanup comments.
Also enable 24-bit depth buffers without stencil.
2009-10-22 14:29:48 -07:00
Corbin Simpson
ff9e1c0198 r300g: Cleanup PSC setup math a bit and stop using Draw formats. 2009-10-22 14:29:48 -07:00
Christoph Bumiller
198925caa1 nv50: handle PIPE_TEX_FILTER_ANISO case
Set the same bits as for linear filtering (in addition
to max anisotropy), and 2 unknown bits I've seen set.
2009-10-22 23:05:12 +02:00
Patrice Mandin
4b8de9bd7c nouveau: nv30: rewrite so we can render only in depth buffer 2009-10-22 22:01:53 +02:00
Patrice Mandin
f9a69c0f04 nouveau: nv30: use a8r8g8b8 as depth texture format for z24s8 2009-10-22 22:00:46 +02:00
Corbin Simpson
fd7ee2bcb7 Kill off trident.
Hm. I could have said "chew trident and spit it out," or perhaps
"spear trident," instead. Dohoho.
2009-10-22 12:57:13 -07:00
Corbin Simpson
8e4657a9d4 Nuke s3v.
As per FDO #17889.
2009-10-22 12:29:30 -07:00
Corbin Simpson
06e464c2d5 r300g: Clean up duplicate code in r300_render. 2009-10-22 11:50:51 -07:00
Corbin Simpson
1f7f9bab81 r300g: Move render functions to r300_render.
Part of the fastpath cleanup.
2009-10-22 11:50:51 -07:00
Alex Deucher
dd36006a4e r600: fix depth span macros for format changes 2009-10-22 14:48:45 -04:00
Brian Paul
eb1b8ed148 radeon: fix some renderbuffer format bugs 2009-10-22 12:26:17 -06:00
José Fonseca
bf48447caf scons: Hack LLVM support on Windows.
Doesn't quite work yet though, as small differences in the compilation flags
used when building LLVM and Mesa cause link failures for STL symbols.
2009-10-22 19:12:14 +01:00
José Fonseca
719984afca llvmpipe: Avoid yet another variable size array. 2009-10-22 19:12:14 +01:00
José Fonseca
ba8c11923a llvmpipe: Define rdtsc for MSVC. 2009-10-22 19:12:14 +01:00
José Fonseca
9aafa1fbd2 llvmpipe: Avoid variable size arrays.
Not really variable size, but MSVC still doesn't like them.
2009-10-22 19:12:14 +01:00
José Fonseca
01b85e2923 llvmpipe: Use the pack/unpack functions for 8bit unsigned norm multiplication. 2009-10-22 19:12:13 +01:00
José Fonseca
4458695bda llvmpipe: Utility function to double the bit width of a type. 2009-10-22 19:12:13 +01:00
José Fonseca
421507de06 llvmpipe: Factor vector packing/unpacking to a separate source file.
These functions will be needed to implement many of the 8bit operations,
and they are quite complex on its own.
2009-10-22 19:12:13 +01:00
José Fonseca
a07437f8a6 llvmpipe: Call util_cpu_detect() from the unit tests. 2009-10-22 19:12:13 +01:00
José Fonseca
4797ce0d19 util: Set cpu endianness too. 2009-10-22 19:12:13 +01:00
José Fonseca
1acd891ed3 scons: Disable more MSVC pedantic security warnings. 2009-10-22 19:12:12 +01:00
Alex Deucher
f8bee0e412 Merge branch 'master' of git+ssh://agd5f@git.freedesktop.org/git/mesa/mesa 2009-10-22 12:29:36 -04:00
Keith Whitwell
280c8acc43 llvmpipe: fix the worst of the depth regressions since switch to 4x4 2009-10-22 17:21:37 +01:00
Zack Rusin
1f5b568fbe st/xorg: cleanup the checks for whether the op is accelerated 2009-10-22 12:21:35 -04:00
Alex Deucher
5e77b61e39 Merge branch 'mesa_7_6_branch' of git+ssh://agd5f@git.freedesktop.org/git/mesa/mesa 2009-10-22 12:02:31 -04:00
Zack Rusin
c4af8ce69e st/xorg: lots of render fixes
fixes all the blend modes, fixes flushing/finishing semantics, adds
acceleration for the component alpha modes that we can support, fixes
src in mask shader and general cleanups
2009-10-22 11:53:10 -04:00
Chia-I Wu
4e2bdd6635 progs/egl: Add support for pixmap and pbuffer surface to xeglgears.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-22 09:33:27 -06:00
Chia-I Wu
60cf250d47 egl_glx: Add support for eglWaitClient and eglWaitNative.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-22 09:33:27 -06:00
Chia-I Wu
7ffe64a7ae egl_glx: Clean up eglGetProcAddress.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-22 09:33:27 -06:00
Chia-I Wu
a206436577 egl_glx: Clean up context functions.
This lifts the requirement that a context must be direct.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-22 09:33:27 -06:00
Chia-I Wu
c407c70244 egl_glx: Clean up surface functions.
Separete Drawable and GLXDrawable.  Add support for pbuffer and pixmap
surfaces on GLX <= 1.3.  Remove surface binding code that will never
work.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-22 09:33:27 -06:00
Chia-I Wu
78c3a351bc egl_glx: Clean up the initialization code.
Proper detection of GLX extensions.  Convert fbconfigs or visuals in a
more unified way and validate the resulting configs.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-22 09:33:27 -06:00
Chia-I Wu
326baecd75 egl: Correct conversion of native visual type.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-22 09:33:27 -06:00
Ben Skeggs
eebf4b5299 nv50: support 3D class 0x8597, remove redundant unknown chipset detection 2009-10-22 21:56:32 +10:00
Corbin Simpson
511bd5f32b r300g: Check for NULL Draw during flush.
Split from the fastpath WIP.
2009-10-22 00:21:08 -07:00
Corbin Simpson
0a8cd4862c r300g: Update comments, function names in r300_state_inlines. 2009-10-21 23:26:02 -07:00
Corbin Simpson
034db65f08 r300g: Update comments, asserts, indents in r300_texture.
I wish I knew enough about textures to really really REALLY fix that file.
2009-10-21 23:23:37 -07:00
Corbin Simpson
5a653ada41 r300g: Remove unused debug flag. 2009-10-21 22:54:52 -07:00
Corbin Simpson
40247d87d2 r300g: Cleanup old static shader state. 2009-10-21 22:53:37 -07:00
Brian Paul
82ffc5884c progs/tests: draw Z values as luminance, no pixel zoom 2009-10-21 21:51:19 -06:00
Brian Paul
3c68560866 i915: replace MESA_FORMAT_Z24_S8 with MESA_FORMAT_S8_Z24
And change parameter type.
2009-10-21 21:48:03 -06:00
Brian Paul
6e1ddd34c6 radeon: get rid of z24s8 <-> s8z24 conversions in span code
Can just use s8z24 everywhere.
Note: the WRITE_DEPTH macro for R600 may need to be fixed.
2009-10-21 21:20:05 -06:00
Brian Paul
c18b022d0d radeon: replace MESA_FORMAT_Z24_S8 with MESA_FORMAT_S8_Z24
Core Mesa deals with MESA_FORMAT_S8_Z24 everywhere it should so
we shouldn't have to use MESA_FORMAT_Z24_S8 anymore.
2009-10-21 21:14:44 -06:00
Brian Paul
68d94a608a intel: use MESA_FORMAT_S8_Z24 format and avoid z24s8/s8z24 conversions 2009-10-21 20:02:33 -06:00
Brian Paul
4bd70b5cff i965: change parameter type to gl_format 2009-10-21 20:00:43 -06:00
Brian Paul
c55b355fd4 mesa: use MESA_FORMAT_X8_Z24 2009-10-21 19:58:00 -06:00
Brian Paul
832f29770d mesa: use MESA_FORMAT_X8_Z24 format 2009-10-21 19:56:18 -06:00
Brian Paul
e4c700dbbf mesa: added MESA_FORMAT_X8_Z24 format
24-bit Z in 32-bit pixel.  We could probably use the MESA_FORMAT_S8_Z24
format but this there's a few places where we explicitly don't want stencil.
This format may go away at some point in the future.
2009-10-21 19:55:44 -06:00
Marc Dietrich
b2b239691d gallium/util: fix cpu detection on ppc
As we are compiling with -D_BSD_SOURCE, sigjmp_buf and siglongjmp
should be replaced by the non-sig functions (see man 3 setjmp).
Tested on linux/cell.
2009-10-21 15:15:03 -06:00
Brian Paul
2cc5a0e6bb mesa: added _mesa_dump_renderbuffers() debug code 2009-10-21 15:14:30 -06:00
Patrice Mandin
d364f662c6 nouveau: nv30: Do not use assert to return NULL 2009-10-21 22:01:03 +02:00
Patrice Mandin
cb351bdd6e nouveau: nv30: check number of colour buffers to bind 2009-10-21 21:56:09 +02:00
José Fonseca
ce98860012 llvmpipe: Remove extraneous name in lp_type pre-declaration. 2009-10-21 15:53:37 +01:00
Keith Whitwell
694f05ac18 llvmpipe: remove one of two definitions of TILESIZE 2009-10-21 15:21:11 +01:00
Corbin Simpson
3b8dad47f8 r300g: No debug in r300_state. 2009-10-21 06:52:25 -07:00
Corbin Simpson
6a448a525b r300g: Cleanup header includes. 2009-10-21 06:52:25 -07:00
Corbin Simpson
babadb8bb9 r300g: Don't use getenv; use debug_get_*_option instead. 2009-10-21 06:52:24 -07:00
Corbin Simpson
5a0598f235 r300g: Don't use the hashtable internally.
As osiris pointed out, glxgears slowly gets slower for some reason
when it's enabled, and it's not helping at the moment, so just turn
it off.
2009-10-21 06:52:24 -07:00
Corbin Simpson
b589e39809 r300g: Examine vertex attribute type on HW TCL too. 2009-10-21 06:52:23 -07:00
Corbin Simpson
b21df2620e r300g: Also kill r300_shader_inlines with fire. 2009-10-21 06:52:23 -07:00
Corbin Simpson
58abfebaad r300g: Kill r300_surface with fire.
If you really want to see it again, check the history.
2009-10-21 06:52:22 -07:00
Keith Whitwell
341edde1d2 llvmpipe: remove dead code 2009-10-21 14:35:54 +01:00
Eric Anholt
d56125a298 intel: Fix flipped condition in ARB_sync GetSYnciv(GL_SYNC_STATUS).
Bug #24435
2009-10-20 14:52:58 -07:00
Eric Anholt
cbd20e18a0 meta: Fix the BufferSubData in meta clear to be BufferData.
Fixes a 3.4% +/- 1.3% performance regression in my GL demo (n=3).  The
other meta code could probably also use the same treatment.
2009-10-20 13:07:49 -07:00
Jakob Bornecrantz
478332b0c1 st/xorg: Move drm init to own function 2009-10-20 18:11:51 +02:00
Jakob Bornecrantz
fc07ca004a trace: Check for destroy before calling it 2009-10-20 17:19:05 +02:00
Jakob Bornecrantz
a9f71b3bba st/xorg: Cleanly shutdown 2009-10-20 17:19:04 +02:00
Keith Whitwell
cccb184209 llvmpipe: minor opts to setup_tri 2009-10-20 10:11:52 +01:00
Keith Whitwell
3199c6e764 llvmpipe: move block list into rast struct 2009-10-20 09:44:23 +01:00
Keith Whitwell
8d752a20c6 llvmpipe: build list of 4x4 blocks to be shaded 2009-10-20 08:56:58 +01:00
Keith Whitwell
1735325a23 llvmpipe: recursive rasterization within a tile 2009-10-20 03:38:07 +01:00
Keith Whitwell
7b116e13a2 llvmpipe: pass mask as a linear encoding of the 4x4 block 2009-10-20 03:17:17 +01:00
Keith Whitwell
7670628061 llvmpipe: precalculate some offsets 2009-10-20 02:46:00 +01:00
Keith Whitwell
5b07d4de38 llvmpipe: remove a leftover 8x2 usage 2009-10-19 17:10:48 +01:00
Keith Whitwell
b0828b0adc llvmpipe: calculate masks in format desired by shader
Also remove branches calculating masks for quads.
2009-10-19 16:41:27 +01:00
Keith Whitwell
3fd6b724cc llvmpipe: pre-multiply some constants by fixed_one 2009-10-19 14:55:05 +01:00
José Fonseca
2f5f357c5b llvmpipe: Reshape the shader input from 8x2 to 4x4.
Incorrect rendering until the interpolation code generation is updated.
2009-10-19 14:02:01 +01:00
Keith Whitwell
0580079864 llvmpipe: fixed-point rasterization 2009-10-19 13:36:55 +01:00
José Fonseca
301c1494b2 llvmpipe: Reset the pointer to stored jit context. 2009-10-19 13:14:33 +01:00
José Fonseca
f2be08ae0e llvmpipe: Allocate the blend color from the data store, and ensure it's aligned. 2009-10-19 11:53:22 +01:00
Keith Whitwell
269342d916 llvmpipe: correctly scale top/left fill adjustments
Was overdoing it previously.
2009-10-19 11:29:05 +01:00
Keith Whitwell
d9f44abe3b llvmpipe: fix typo correcting for fill convention
Adjustments for top-left fill convention were being lost.
2009-10-19 11:23:43 +01:00
Jakob Bornecrantz
5f8f14e5ca st/xorg: Remove output functions not used 2009-10-19 07:52:16 +02:00
Zack Rusin
b7fbcfdb3b st/xorg: makefile garbage 2009-10-19 23:48:38 -04:00
Zack Rusin
a39a3cc14e st/xorg: implement basic src/mask transformations
plus fix filters
2009-10-19 23:45:31 -04:00
Corbin Simpson
e5f1f6a0be r300g: Demonstratory kludge to unbreak glxgears.
We *must* recalculate something in vformat every rebind; let's see
if we can't narrow it down a bit.
2009-10-19 14:43:33 -07:00
Corbin Simpson
973aab1a52 dri-st: Add EXT_provoking_vertex.
Hm, I could have sworn I did this before?
2009-10-19 14:43:32 -07:00
Jakob Bornecrantz
e1b39c673d st/xorg: Switch to set_mode_major 2009-10-18 15:46:25 +02:00
Jakob Bornecrantz
846da0bfda st/xorg: Massivly redo root pixmap creation 2009-10-18 15:46:25 +02:00
Jakob Bornecrantz
e9e6152cb3 st/xorg: Clean up cursor functions a bit 2009-10-18 15:46:25 +02:00
Jakob Bornecrantz
b8843c6056 st/xorg: Support more then one output of a given type 2009-10-18 15:46:24 +02:00
Jakob Bornecrantz
68b5dc9634 st/xorg: Change how disable accel is handled 2009-10-18 15:46:24 +02:00
Christoph Bumiller
ec5c23551c nv50: add support for address regs
Allow indirect uniform access and increase the
limit on parameters from 128 to 512.
2009-10-19 18:25:09 +02:00
Christoph Bumiller
eb7ea97e7f nv50: cleanup emit_kil 2009-10-19 18:25:09 +02:00
Christoph Bumiller
2eef2017ac nv50: implement TGSI_OPCODE_CMP 2009-10-19 18:25:09 +02:00
Christoph Bumiller
f204eb1842 nv50: quick fix for insn src negation
We only have a per nv50_reg negation flag, if an
nv50_reg is used more than once in a TGSI op with
different sign modes, we'd generate wrong code.

We probably can't do much better without more
invasive changes.
2009-10-19 18:25:09 +02:00
Christoph Bumiller
1635e8d6f4 nv50: add support for DDX and DDY opcodes 2009-10-19 18:25:09 +02:00
Christoph Bumiller
c0e80cf0e9 nv50: submit user vbo data through the fifo
Requesting a new real buffer from the kernel and
copying all the data is wasteful e.g. if only a
few (but widely spread) vertices are accessed.
2009-10-19 18:25:08 +02:00
Christoph Bumiller
fba2eabe13 nv50: use SIFC for TIC, TSC upload
Add proper flushes for TIC and TSC and remove
the costly 2D.0110 flush in nv50_flush.

Correct TIC and TSC bo sizes.
2009-10-19 18:25:08 +02:00
Christoph Bumiller
6ab2fcca9d nv50: nicer texture format switch
Similar to nv40.
2009-10-19 18:25:08 +02:00
Alex Deucher
620270c76e Merge branch 'mesa_7_6_branch' of git+ssh://agd5f@git.freedesktop.org/git/mesa/mesa
regenerated lex.yy.c
2009-10-19 12:10:59 -04:00
Ben Skeggs
35b98e2884 nouveau: implement is_{texture,buffer}_referenced properly 2009-10-19 09:49:02 +10:00
Ben Skeggs
869d3eea37 drm/nv50: write tic/tsc setup to correct slots when skipping units 2009-10-19 09:49:02 +10:00
Corbin Simpson
16a06fea73 r300g: Fix up a bunch of warnings. 2009-10-18 16:09:01 -07:00
Corbin Simpson
d2e29b502e r300g: Add another ZTOP condition.
I don't even know if texkill works right now.
2009-10-18 10:30:18 -07:00
José Fonseca
838da1d4ae llvmpipe: Allocate texture storage for whole quads. 2009-10-18 14:31:58 +01:00
José Fonseca
2e3580d994 llvmpipe: Maintain a copy of the shader constants to prevent clobbering. 2009-10-18 11:57:43 +01:00
Corbin Simpson
bb567357bc gallium: Permit surface_copy and surface_fill to be NULL.
Uf. Lots of files touched. Would people with working vega, xorg, dri1, etc.
please make sure you are not broken, and fix yourself up if you are.

There were only two or three places where the code did not have painful
fallbacks, so I would advise st maintainers to find less painful workarounds,
or consider overhauling util_surface_copy and util_surface_fill.

Per ymanton, darktama, and Dr_Jakob's suggestions, clear has been left as-is.

I will not add PIPE_CAP_BLITTER unless it is deemed necessary.
2009-10-17 21:32:56 -07:00
Corbin Simpson
bfd877e470 r300g: Squash format warning.
Won't ever be supported.
2009-10-17 20:53:19 -07:00
Corbin Simpson
11056ca86f r300g: Use a dirty test to bring framerate back up.
This is just split out from the next commit, that's all.
2009-10-17 20:47:45 -07:00
Corbin Simpson
51173e4e53 r300g: Also have rs_block keyed to the current shader combo.
Eliminates part of the glxgears corruption here. Need to clean up PSC more,
to get rid of the rest of it.
2009-10-17 20:29:27 -07:00
Corbin Simpson
ce9ae4a483 r300g: Fix u_hash_table rename. 2009-10-17 20:05:23 -07:00
Corbin Simpson
4a98d19d1b Merge branch 'master' of ssh://git.freedesktop.org/git/mesa/mesa 2009-10-17 19:58:23 -07:00
Patrice Mandin
114417a2f5 nouveau: nv40: Use same workaround as i915 for segfault related to vbo 2009-10-17 20:49:18 +02:00
Patrice Mandin
66aab9a1f6 nouveau: nv30: Remove duplicate case. Was a typo for X8R8G8B8, but that will never be use for front buffer. 2009-10-17 20:46:19 +02:00
Patrice Mandin
67356ae047 nouveau: nv30: Use same workaround as i915 for segfault related to vbo 2009-10-17 20:27:24 +02:00
José Fonseca
5d42e3988d util: Rename from u_* to util_* while we're at it.
To be consistent with the rest.
2009-10-17 11:45:04 +01:00
Chris Wilson
60a39b6799 intel: Disallow relocations to the byte beyond the end of the buffer 2009-10-17 08:26:54 +01:00
Brian Paul
a335d334d4 mesa: fix/update some comments 2009-10-16 13:07:43 -06:00
Brian Paul
f094b86bb5 mesa: lift default symlinks target into Makefile.template
Driver Makefiles can still add symlink dependencies/rules if needed.
2009-10-16 13:07:43 -06:00
Brian Paul
db2046580f mesa: use EXTRA_MODULES and SUBDIRS to build r300 compiler
This is a bit cleaner and avoids rebuilding the r300_dri.so library all
the time.
2009-10-16 13:07:43 -06:00
Brian Paul
d9fd207133 mesa: added SUBDIRS support in dri/Makefile.template 2009-10-16 13:07:43 -06:00
Brian Paul
f0503726bf mesa: move a comma 2009-10-16 13:07:43 -06:00
Brian Paul
2ee7fd8d58 mesa: added MESA_GLSL=useprog debug flag
This logs glUseProgram() calls to stderr.
2009-10-16 13:07:43 -06:00
Corbin Simpson
3e56bef5a5 radeon-gallium: Use debug_get_bool_option instead of getenv. 2009-10-16 09:45:07 -07:00
Corbin Simpson
fc8a156cfc r300g: Use a hash table to look up vertex info.
Need to move rs_block to this, too.

Also, I'm getting massive amounts of flicker for some reason; I bet we've gotta
re-re-examine PSC and friends. :C
2009-10-16 08:43:02 -07:00
Corbin Simpson
3924d86115 util: Change function names to begin with u_.
Avoids link-time clashes with Mesa's internal hash table.
2009-10-16 08:43:02 -07:00
José Fonseca
166957abeb progs/tests: Use rand() instead of random().
Forgot these on previous commit.
2009-10-16 11:42:13 +01:00
José Fonseca
699260b195 progs/tests: Use rand() instead of random().
More portable. Same implementation on Linux.
2009-10-16 11:39:29 +01:00
Vinson Lee
60b6c74583 prog/tests: Fix MSVC build. 2009-10-16 11:36:09 +01:00
Corbin Simpson
e4f21be13a r300g: Set logical ID for each emitted texture/sampler.
multitexarray works on my r300, but texrect doesn't.
2009-10-15 16:58:26 -07:00
Brian Paul
fa3046431a dri/common: updated #includes 2009-10-15 14:57:45 -06:00
Brian Paul
a37c9ac8ee dri/common: use _mesa_little_endian() and update comments 2009-10-15 14:54:32 -06:00
Brian Paul
9bf2aa3329 dri/common: fix broken _dri_texformat_* initializations 2009-10-15 14:49:53 -06:00
Patrice Mandin
a5a05fd782 nouveau: nv30: Hack to enforce same number of bits as front buffer, for render targets 2009-10-15 22:41:09 +02:00
Patrice Mandin
13580aa3d1 nouveau: nv30: refuse binding a colour buffer with a zeta buffer with different bits, till the backend can tell Mesa not to do that. 2009-10-15 21:58:44 +02:00
Zack Rusin
108273c5ed st/xorg: refix source over 2009-10-15 15:23:04 -04:00
Brian Paul
5b7d9053a0 progs/egl: put declarations before code 2009-10-15 13:00:03 -06:00
Chia-I Wu
6c21c8862b egl: Rework the synchronization primitives.
This adds error checking to the synchronization primitives.  And
eglWaitGL is now implemented by eglWaitClient.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-15 12:54:00 -06:00
Chia-I Wu
57da499d7b egl: Rework eglSwapInterval.
This adds error checking to eglSwapInterval and clamps the swap
interval.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-15 12:54:00 -06:00
Chia-I Wu
bbfd0e2615 egl: Rework error checking in eglSwapBuffers.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-15 12:53:58 -06:00
Chia-I Wu
aaa1253b09 egl: Update comments about eglapi.c.
Mention that opaque handles are looked up and checked.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-15 12:53:57 -06:00
Chia-I Wu
6190663120 egl: Rework error checking in eglGetCurrentSurface.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-15 12:53:57 -06:00
Chia-I Wu
8bb2485ed0 egl: Include GL header in eglconfigutil.h.
This is just a cosmetic change.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-15 12:53:56 -06:00
Chia-I Wu
29d115092e egl: Fix GLX_USE_TLS build.
Remove an extraneous semicolon.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-15 12:53:56 -06:00
Chia-I Wu
2fc1614e7a egl: Fix eglCheckConfigHandle.
A stupid bug by me made the check void.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-15 12:53:55 -06:00
Brian Paul
c47b03ebeb radeon: initialize renderbuffer Format field in radeon_create_renderbuffer()
Plus, use MESA_FORMAT_S8_Z24 everywhere.
2009-10-14 13:15:05 -06:00
Jakob Bornecrantz
72fd1cf292 trace: Handle transfer returning null 2009-10-14 11:44:09 +02:00
Zack Rusin
074e069910 st/xorg: fix most of the composition modes 2009-10-15 00:06:43 -04:00
Corbin Simpson
a82fc97c64 r300g: Move ZTOP to its own state atom.
It may seem pointless, but this avoids a fair amount of predicted CSO pain.
2009-10-14 20:06:38 -07:00
Brian Paul
91bd87c06e progs/demos: try different depth formats in fbo_firecube.c 2009-10-14 19:13:32 -06:00
Brian Paul
85fb3e4027 docs: document more MESA_GLSL env var options 2009-10-14 19:09:08 -06:00
Brian Paul
24e2f61469 mesa: assorted top-level Makefile clean-ups 2009-10-14 19:09:08 -06:00
Brian Paul
2fd5cb7133 mesa: added VERBOSE_SWAPBUFFERS 2009-10-14 19:08:39 -06:00
Brian Paul
f9784072fe vbo: clean-ups, reformatting 2009-10-14 19:08:38 -06:00
Brian Paul
ade1cc9924 mesa: added MESA_VERBOSE option 'draw' to debug glDrawArrays/Elements, etc. 2009-10-14 19:08:38 -06:00
Brian Paul
d9099f8602 mesa: rename VERBOSE_IMMEDIATE->VERBOSE_MATERIAL to reflect what it does 2009-10-14 19:08:38 -06:00
Brian Paul
73fc0ca4c3 mesa: remove unused ctx->Driver.PrioritizeTextures() hook 2009-10-14 19:08:38 -06:00
Brian Paul
0187e042b6 mesa: remove unused ctx->Driver.TextureMatrix() hook 2009-10-14 19:08:38 -06:00
Jakob Bornecrantz
ef067b5f01 st/xorg: Fix dpms include problems 2009-10-13 19:16:21 +02:00
Jakob Bornecrantz
5c4bdbd825 autoconf: Fix case for not having package 2009-10-15 01:25:48 +01:00
Zack Rusin
59cf40059a st/xorg: get transparency on fills working (fixes Qt/KDE apps) 2009-10-14 19:04:29 -04:00
Jakob Bornecrantz
96c9b39a6a i915g: Fix warnings 2009-10-14 23:05:55 +01:00
Alex Deucher
f22c427bd6 r600: enable EXT_vertex_array_bgra extensions 2009-10-14 14:19:12 -04:00
José Fonseca
3ce3c03257 util: Fix cpu detection on Windows. Cleanup. 2009-10-14 17:27:06 +01:00
José Fonseca
4046c3bab4 llvmpipe: Use ALIGN_STACK. 2009-10-14 17:24:22 +01:00
José Fonseca
68edb4eac5 gallium: New ALIGN_STACK macro to tell gcc to align stack pointer. 2009-10-14 17:24:22 +01:00
José Fonseca
5ba645f0fb scons: Disable SSE intrinsics on MinGW.
-mstackrealign causes stack corruption on MinGW. And without it the ability
to use SSE instrinsics goes down the drain. Even if we use
__attribute__((force_align_arg_pointer)) for the functions we explicitly
use SSE instrinsics, the SSE code automatically generated by gcc will
cause assertion failures. What a nightmare.

Thankfully LLVM gets this right, so all runtime generated SSE code just
works. rtasm code doesn't assume 16byte alignment. Therefore the bulk of
our performance sensitive code is not affected by this.

Still, intrinsics can be convenient, and it would be nice
to get this working again some day, sp will try to get a reduced test
case.
2009-10-14 17:24:21 +01:00
Brian Paul
9fd7e9ef05 Merge branch 'mesa_7_6_branch' 2009-10-14 09:40:05 -06:00
Brian Paul
ce3801ab87 Merge branch 'mesa_7_6_branch' 2009-10-14 09:22:30 -06:00
Brian Paul
98eb7a14a4 mesa: remove left-over debug printf 2009-10-14 07:52:39 -06:00
Vinson Lee
ea862ec8ff prog/tests: Fix MSVC build. 2009-10-14 07:52:39 -06:00
Corbin Simpson
fd63f89e95 r300g: Move ztop to derived state.
Need to get it into its own atom instead of piggybacking on DSA.
2009-10-14 03:09:41 -07:00
Corbin Simpson
f13e507798 r300g: Compiler warning cleanup. 2009-10-14 01:58:18 -07:00
Dave Airlie
88b697fb0a r300g: remove buffer add that should be unnecessary.
This should be handled in the emit fine
2009-10-14 18:24:34 +10:00
Dave Airlie
fa581580b1 r300g: add QUERY to KITCHEN_SINK
I missed this, thanks to Corbin for pointing it out.
2009-10-14 18:24:05 +10:00
Dave Airlie
ce5cba040c r300g: add one more ZTOP disable bit.
Still missing the frag uses kill support, hopefully nha can point that out.
2009-10-14 18:05:14 +10:00
Dave Airlie
51d1cf55da r300g: port over last parts of oq support.
Add support for begin/end in each CS so we don't get any other
processes rendering in between.

TODO:
blame other parts of driver for this not working like Z.
2009-10-14 17:44:19 +10:00
Dave Airlie
47791697ab r300g: convert query to a state for emitting.
This means we don't emit in the begin query but when we have
to flush. Similiar to classic.

TODO:
make query object actually work.
2009-10-14 17:14:43 +10:00
Dave Airlie
c1bee7bdea r300g: fixup arb occulsion query support.
1: add rv530 support
   - num z pipes cap
   - add proper start/finish query options for rv530

2: convert to use linked list properly.

3: add flushing required check.

4: initial Z top disabling support.

TODO:
make it actually work on my rv530.
2009-10-14 16:53:12 +10:00
Dave Airlie
210481ae16 r300g: attempt to make bo space check sane.
This attempts to make r300g do proper bo space checking as opposed
to whatever it was doing now.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-10-14 15:13:25 +10:00
Dave Airlie
23c0c820e2 r300g: fix case where texture unit 0 is disabled but unit 1 is enabled.
to reproduce, start texrect, disable 0 texture in menu.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-10-14 11:42:05 +10:00
Brian Paul
220f72a8d0 mesa: minor tweak to printf string 2009-10-13 16:33:36 -06:00
Brian Paul
435623b3f0 mesa: rework _mesa_read_shader() debug hook
Look for shaders named "newshader_<CHECKSUM>" to replace the incoming
shader text.  For debug purposes.
2009-10-13 16:33:36 -06:00
Brian Paul
dfefde38c7 mesa: don't print pointer in _mesa_fprint_parameter_list() 2009-10-13 16:33:36 -06:00
Ian Romanick
f058b25881 Store clipping distance for user clip planes as part of vertex processing
Once the clipping distance is calculated and stored per vertex, the
distances can be re-used when clipping is actually performed.  This
doesn't have any immediate benefit, but it paves the way for
implementing gl_ClipDistance in vertex shaders and result.clip[] in
vertex programs.

This has not produces any oglconform regressions on my G31 system
which uses software TNL.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
2009-10-13 15:15:20 -07:00
Patrice Mandin
cf33aaf8fe nouveau: nv30: use texture width,height for render target dimensions 2009-10-13 22:53:32 +02:00
Chia-I Wu
f1c5cab552 egl: Improve logging facility.
Add _eglSetLogger and _eglSetLogLevel to allow drivers to change the
message logger or report level.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-13 12:00:37 -06:00
Chia-I Wu
310c76812e egl: Allow binding to any client API.
As a result, EGL_NONE is no longer a valid client API.  And it is
possible that no config supports the current bound API.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-13 12:00:36 -06:00
Chia-I Wu
e787ffcd02 egl: Preload a driver if eglGetProcAddress is called early.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-13 12:00:36 -06:00
Chia-I Wu
9061d733d3 egl: Remove core functions from eglGetProcAddress.
eglGetProcAddress may not be used to query core (non-extension)
functions.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-13 12:00:36 -06:00
Chia-I Wu
5541988578 egl: Add support for driver built-in.
This allows an EGL driver to be compiled together with libEGL.so.  It
eliminates the need to specify a driver, or support module loading on
new platforms.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-10-13 12:00:36 -06:00
Zack Rusin
1cc1c3a033 st/xorg: solid fills with masks are supported
gradients are supported, but not enabled by default due to little
testing they got
2009-10-13 13:04:00 -04:00
Brian Paul
83f4e72009 intel: fix broken sw generate mipmap path
Need to restore code that fixed up the intel_texture_image state.
2009-10-13 10:38:34 -06:00
Zack Rusin
89bb33fb20 st/xorg: fix and enable by default xrender acceleration
src in mask was broken
2009-10-13 12:25:13 -04:00
Brian Paul
eefecf5d2a mesa: whitespace fixes 2009-10-13 09:05:02 -06:00
Brian Paul
c8413351c3 mesa: do RTT check in _mesa_meta_check_generate_mipmap_fallback()
We need to check that we can actually render to the texture's format
before doing mipmap generation.

This may fix bug 24219.
2009-10-13 09:05:02 -06:00
Corbin Simpson
ca8cafda0b r300g: More debug flags. 2009-10-12 21:48:08 -07:00
Corbin Simpson
a4a4f7abc2 r300g: Surface debug.
It gets really annoying watching r300g tell me how it's filling surfaces.
Or falling back during filling surfaces.
2009-10-12 21:48:08 -07:00
Corbin Simpson
95a05621eb r300g: Fallback on surfaces we can't render to or from.
Still not sure why st keeps handing down things we can't render to.
2009-10-12 21:48:07 -07:00
Corbin Simpson
36ccdf09b8 r300g: Prevent multiple-use textures from getting incorrectly approved. 2009-10-12 21:48:07 -07:00
Corbin Simpson
05fc9cdfdf r300g: Clean up texture formats. 2009-10-12 21:48:07 -07:00
Brian Paul
3f928b3552 mesa: save/set/restore texture base/wrap state in blitframebuffer_texture() 2009-10-12 18:12:01 -06:00
Brian Paul
b5d6a8e88f mesa: minor clean up in check_begin_texture_render() 2009-10-12 18:12:01 -06:00
Brian Paul
47a7535f41 intel: whitespace/formatting clean-up 2009-10-12 18:12:00 -06:00
Brian Paul
3732d0a77d intel: replace extern decl with #include 2009-10-12 18:12:00 -06:00
Brian Paul
b9c2897957 intel: added INLINE keyword to minify()
This is mainly just to silence some warnings.
2009-10-12 18:12:00 -06:00
Brian Paul
c932e21fa8 intel: code clean-ups 2009-10-12 18:12:00 -06:00
Brian Paul
e6594a22f2 intel: pass zslice to intel_miptree_image_offset()
This lets us get rid of intel_miptree_depth_offsets() and simplify all
of the calling code.
2009-10-12 18:12:00 -06:00
Brian Paul
15d2ef6024 i965: remove unused var 2009-10-12 18:12:00 -06:00
Vinson Lee
96fd13c1a0 prog/tests: Fix MSVC build. 2009-10-12 18:05:23 -06:00
Brian Paul
6c1cd4c558 mesa: print program Id when printing 2009-10-12 18:05:23 -06:00
Patrice Mandin
a5348d435d Add support for more 8 and 16 bits formats 2009-10-12 21:03:26 +02:00
Andre Maasikas
7a32c0a19e r600: implement ProgramStringNotify
need this to properly test with piglit/glean vert/fragprog tests
copied mostly from r300, many thanks to osiris, nha, airlied, others...
2009-10-12 16:28:36 +03:00
Andre Maasikas
da66d9e12d r600: LIT dst.y gets value from src.x
seems I overlooked this when removing hardcoded swizzles for this
one previously
2009-10-12 16:28:25 +03:00
Andre Maasikas
97dd35bd6f r600: DPH adds w comp of second operand, so set first one to 1 instead 2009-10-12 16:28:16 +03:00
Zack Rusin
150d4968e3 st/xorg: initialize pipe in the renderer 2009-10-11 21:52:10 -04:00
Zack Rusin
319a588238 st/xorg: lots of rendering and xv changes
extract all the rendering code to xorg_rendedrer, make both exa and xv
share that code. in the process cleanup the rendering code and implement
a lot more of the xv infrastructure.
2009-10-11 20:02:47 -04:00
Zack Rusin
59ae3d5155 configs: fix some remains of the i915simple driver 2009-10-11 20:02:47 -04:00
Zack Rusin
4969d014e5 st/xorg: implement basics of xv 2009-10-11 20:02:47 -04:00
Nicolai Hähnle
f096cc7dc1 r300g: Fix fragment program constants upload on R300
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-10-11 12:41:18 +02:00
Dave Airlie
3611d01a44 r300g: fix blending default state + alpha separate.
this makes the default state same as r300
2009-10-11 19:30:23 +10:00
José Fonseca
0177c6e66c llvmpipe: Only invoke the shader if necessary. 2009-10-10 18:44:46 +01:00
Vinson Lee
cbf46ed670 progs/perf: Fix MSVC build. 2009-10-10 10:45:16 -06:00
Brian Paul
57e3eb1b17 Merge branch 'mesa_7_6_branch' 2009-10-10 09:25:34 -06:00
Brian Paul
39daa763b5 softpipe: fix multi-drawbuffers regression
This is part of the fix for bug 24401.
2009-10-10 09:24:22 -06:00
Cooper Yuan
a74e53ddba r300g: add video surface create and destroy functions 2009-10-10 14:41:44 +08:00
José Fonseca
7908c239e0 llvmpipe: Additional checks for binner block lists. 2009-10-09 19:17:30 +01:00
José Fonseca
61f3eeb640 llvmpipe: Use framebuffer coords consistently. 2009-10-09 19:16:36 +01:00
José Fonseca
8c80413360 llvmpipe: Fix type in tri bounding box check. 2009-10-09 17:14:11 +01:00
Keith Whitwell
b4924d62c7 llvmpipe: fill in tri min/max values 2009-10-09 16:59:24 +01:00
José Fonseca
6464ec4836 llvmpipe: Remove partial tile override. 2009-10-09 16:50:32 +01:00
José Fonseca
8c34c86d19 llvmpipe: Undo debug override. 2009-10-09 16:23:00 +01:00
Keith Whitwell
05131f7502 llvmpipe: properly clip tile writes 2009-10-09 16:20:56 +01:00
José Fonseca
c2e926b72d llvmpipe: Pass framebuffer coords to shader. 2009-10-09 16:18:38 +01:00
José Fonseca
b0cd386e77 llvmpipe: Tell setup shader inputs. 2009-10-09 16:18:37 +01:00
Keith Whitwell
82ec7f018d llvmpipe: correct binning maths for iterating over whole tiles 2009-10-09 16:07:58 +01:00
José Fonseca
8599969582 llvmpipe: Get jit_context/jit_function across the rasterizer. 2009-10-09 15:53:53 +01:00
Keith Whitwell
f406ffaea6 llvmpipe: set block count/used values back to zero on reset 2009-10-09 15:29:10 +01:00
Keith Whitwell
da1808ccc9 llvmpipe: just bin whole tiles for now 2009-10-09 15:10:15 +01:00
Keith Whitwell
402c189af7 llvmpipe: always call begin_binning on transition to active state 2009-10-09 15:07:18 +01:00
Keith Whitwell
dec35d04ae llvmpipe: add LP_DEBUG env var 2009-10-09 14:59:35 +01:00
Keith Whitwell
082b3b0a89 llvmpipe: initialize setup data store 2009-10-09 14:36:41 +01:00
Keith Whitwell
163a31952c llvmpipe: initialize setup line/tri/point funcs 2009-10-09 14:34:23 +01:00
José Fonseca
608c222723 llvmpipe: Put jit_context in store. 2009-10-09 14:33:21 +01:00
Keith Whitwell
e0e2008f1d llvmpipe: trivial/clear works 2009-10-09 14:29:25 +01:00
Keith Whitwell
295aea0489 llvmpipe: more debug 2009-10-09 14:07:40 +01:00
José Fonseca
659609e0ae llvmpipe: Replace util_pack_color with straight float_to_ubyte. 2009-10-09 14:03:24 +01:00
Keith Whitwell
4e1334ced6 llvmpipe: debug, crash fixes 2009-10-09 14:02:39 +01:00
Keith Whitwell
b0475a4b0d llvmpipe: fix crash on init 2009-10-09 13:55:04 +01:00
Keith Whitwell
1928c965b1 llvmpipe: fix a couple of warnings 2009-10-09 13:53:14 +01:00
José Fonseca
c0e3e35b03 llvmpipe: Add stub lp_setup_is_texture_referenced. 2009-10-09 13:44:24 +01:00
José Fonseca
d904ed88c1 llvmpipe: Pass state to setup. 2009-10-09 13:41:33 +01:00
José Fonseca
00ffef383c util: Force ESI register for cpuid's ebx result.
Fixes a segfault and better code. Unfortunately using an arbitrary
register ("=r") causes the gcc to abort when the code is optimized saying
it can't satisfy the constraint. Setting seems to do the trick.
2009-10-09 13:25:16 +01:00
José Fonseca
c4d54b62f5 llvmpipe: Eliminate constant mapping/unmapping. 2009-10-09 13:25:15 +01:00
Keith Whitwell
c1013f5d40 llvmpipe: remove dead code 2009-10-09 12:26:49 +01:00
Keith Whitwell
e215f94f15 llvmpipe: get lp_setup_tri building 2009-10-09 12:19:49 +01:00
Keith Whitwell
4cdd10cb4b llvmpipe: use union lp_cmd_rast_arg directly, rather than through a pointer
The union itself consists of pointers.  We don't need to be passing
pointer to pointers.
2009-10-09 11:29:01 +01:00
Keith Whitwell
415b271b51 llvmpipe: hook up some state, add stub line and point functions 2009-10-09 10:44:07 +01:00
José Fonseca
47510040a6 llvmpipe: Follow write_color/write_zstencil. 2009-10-09 10:37:24 +01:00
Keith Whitwell
84ab7dcf48 llvmpipe: calculate overall width and height, pass to rasterizer 2009-10-09 10:24:19 +01:00
Keith Whitwell
de902d3275 llvmpipe: more wip on coefficients 2009-10-09 10:23:53 +01:00
Brian Paul
45e76d2665 mesa: remove a bunch of gl_renderbuffer fields
_ActualFormat is replaced by Format (MESA_FORMAT_x).
ColorEncoding, ComponentType, RedBits, GreenBits, BlueBits, etc. are
all replaced by MESA_FORMAT_x queries.
2009-10-08 20:27:27 -06:00
Keith Whitwell
253dfed939 llvmpipe: get lp_setup compiling 2009-10-08 23:08:41 +01:00
Keith Whitwell
1814395b7e llvmpipe: triangle struct owns its copy of shader inputs 2009-10-08 22:46:21 +01:00
Keith Whitwell
0718c77005 llvmpipe: work on clears and coefficients 2009-10-08 19:58:54 +01:00
José Fonseca
21489d2275 llvmpipe: Remove quad headers. 2009-10-08 19:56:01 +01:00
José Fonseca
df8cedf989 llvmpipe: Adjust interpolation coeffs declaration. 2009-10-08 19:53:56 +01:00
José Fonseca
7ef36171d5 llvmpipe: Call lp_rast_shade_quads from tri rasterizer. 2009-10-08 19:53:14 +01:00
José Fonseca
07ee87e664 llvmpipe: Fix typo. 2009-10-08 19:18:52 +01:00
Keith Whitwell
c7227f4b8d llvmpipe: rast_tri updates 2009-10-08 19:17:44 +01:00
José Fonseca
86dba3e414 llvmpipe: Final adjustments to rasterizer methods. 2009-10-08 19:16:47 +01:00
José Fonseca
f92787679d llvmpipe: More assorted build fixes. 2009-10-08 19:03:35 +01:00
José Fonseca
ab76b2a8b8 llvmpipe: Complete more rasterizer methods.. 2009-10-08 19:03:14 +01:00
José Fonseca
35a90e67eb llvmpipe: Assorted build fixes. 2009-10-08 17:59:57 +01:00
José Fonseca
37b86aa55c llvmpipe: Implement some of the rasterizer functions. 2009-10-08 17:59:44 +01:00
Keith Whitwell
1caa26202c llvmpipe: start cleaning up 2009-10-08 17:53:12 +01:00
Keith Whitwell
d0c918b87a llvmpipe: remove some old sampler support structs 2009-10-08 17:53:12 +01:00
José Fonseca
921584181e llvmpipe: Fix up lp_rast_shade_quads. 2009-10-08 17:26:13 +01:00
José Fonseca
5974b80380 llvmpipe: Remove dead files from SConscript. 2009-10-08 17:06:49 +01:00
José Fonseca
ce7ac8e743 llvmpipe: Update lp_setup_clear invocation. 2009-10-08 17:06:32 +01:00
José Fonseca
ee3383bc5a llvmpipe: Update more copyright headers. 2009-10-08 17:06:03 +01:00
Keith Whitwell
6b65685def llvmpipe: remove tex tile cache and related code 2009-10-08 16:33:12 +01:00
Keith Whitwell
d2e2b75633 llvmpipe: rewrite llvmpipe_clear() 2009-10-08 16:32:03 +01:00
Keith Whitwell
931210424b llvmpipe: wip me harder 2009-10-08 15:46:29 +01:00
Jakob Bornecrantz
db828ed758 st/xorg: Old X servers don't deal well with failing accesses 2009-10-08 14:54:38 +02:00
Jakob Bornecrantz
6d629d4aa2 st/xorg: More fallback debugging
Change the fallback debugging around a bit and do the old commit correctly
2009-10-08 14:50:40 +02:00
Jakob Bornecrantz
992b143b25 Revert "st/xorg: Debug fallbacks for composite as well"
This commit included a change that should have been in
its own commit, and turns out that you can do what was
suposed to go in it in much better way as well.

This reverts commit 5080e8bea6.
2009-10-08 14:46:29 +02:00
José Fonseca
d614ced756 llvmpipe: Update includes and copyright headers. 2009-10-08 12:51:46 +01:00
José Fonseca
46df37ebfa llvmpipe: Update SConscript. 2009-10-08 12:44:52 +01:00
José Fonseca
a6676d896e llvmpipe: Add the rast -> jit shader glue.
Ugly code. Will eventually be reduced to a very thin inlined function.
2009-10-08 12:44:30 +01:00
Jakob Bornecrantz
5080e8bea6 st/xorg: Debug fallbacks for composite as well 2009-10-08 13:42:44 +02:00
Jakob Bornecrantz
552efdae06 st/xorg: Use A8 textures for depth 8 pixmaps
There is no hardware out there that can render to I8 textures.
2009-10-08 13:42:40 +02:00
Jakob Bornecrantz
a31d16cbfa st/xorg: Fix depth stencil buffers on old X servers
Sanity checking is for the weak.
2009-10-08 13:42:31 +02:00
Vinson Lee
76d2ec3a0a progs/tests: Add tests to Makefile. 2009-10-09 07:24:37 -06:00
Brian Paul
f36123323c softpipe: restore/fix print_vertex() debug helper 2009-10-09 07:24:37 -06:00
Jakob Bornecrantz
023bab675a progs/perf: Ignores! 2009-10-09 14:00:15 +01:00
José Fonseca
c595dea23c util: Force ESI register for cpuid's ebx result.
Fixes a segfault and better code. Unfortunately using an arbitrary
register ("=r") causes the gcc to abort when the code is optimized saying
it can't satisfy the constraint. Setting seems to do the trick.
2009-10-09 13:22:42 +01:00
José Fonseca
69588d7ed5 llvmpipe: Eliminate constant mapping/unmapping. 2009-10-09 11:29:33 +01:00
José Fonseca
d54e9f54d0 progs: Remove unused empty file. 2009-10-09 11:08:17 +01:00
José Fonseca
b858257ca6 gdi: Fix the build when llvmpipe is requested (the default) but llvm is not present. 2009-10-09 11:08:17 +01:00
Andre Maasikas
44c6c20b69 r600: fixup KIL instruction a bit
- KILLGT takes 2 arguments
- arb KIL has no dst register
- add TODO about clause ending but currently piglit fp-kil passes and
  does not hang the card
2009-10-09 11:52:48 +03:00
Brian Paul
90692486aa docs: bump libdrm version requirement
Probably need to bump other version requirements too...
2009-10-08 20:49:36 -06:00
Eric Anholt
859828cc4f mesa: Bump the required libdrm version to reflect reality.
Not all drivers require the latest version, but distros are good at
tracking it since we've got a good record as far as not regressing, and
it sure beats having a weird compile failure in someone else's driver
later on.
2009-10-08 17:18:12 -07:00
Eric Anholt
9b8d2e76c3 i965: Use bo_references for the state cache delete function.
This appears to shave about 3% off the CPU usage in cairo-gl for firefox.
2009-10-08 17:12:23 -07:00
Eric Anholt
193dddb04e intel: Use new drm_intel_bo_references() to avoid flushing. 2009-10-08 17:12:23 -07:00
Brian Paul
f49d53594c mesa: free display list state after freeing shared state
Fixes bug 24402.
2009-10-08 12:50:44 -06:00
Brian Paul
f67bc2e872 Merge branch 'mesa_7_6_branch'
Conflicts:

	src/mesa/drivers/common/meta.c
2009-10-08 09:28:07 -06:00
Vinson Lee
f7455ad7af progs/tests: Fix MSVC build. 2009-10-08 08:08:11 -06:00
Keith Whitwell
5e13dfe618 llvmpipe: whip out the intra-tile code from lp_setup_tri.c
The "setup" module handles building per-tile display lists.
Intra-tile rendering is handled by lp_rast*.c
2009-10-08 12:15:12 +01:00
Keith Whitwell
e529170c11 llvmpipe: more wipping 2009-10-08 11:49:49 +01:00
Keith Whitwell
89498d0153 llvmpipe: import experimental softpipe rasterizer code, wip binning code
WIP, does't build or run.

Rasterizer code is based on Nick Capen's devmaster posts and the
larrabee articles, but currently doesn't share either the performance
or correctness of either...
2009-10-08 08:32:43 +01:00
Brian Paul
f001cc0981 mesa: clean up extended opcode code 2009-10-07 16:51:26 -06:00
Brian Paul
33e9ac20e3 mesa: move gl_list_instruction and gl_list_extensions to dlist.c 2009-10-07 16:41:18 -06:00
Brian Paul
15f05e97aa mesa: added _mesa_free_display_list_data() 2009-10-07 16:32:25 -06:00
Brian Paul
fc995c7298 mesa: clean-up display list mem allocation, fix NULL handling
The -1 term in alloc_instruction() foiled later NULL pointer checks.
2009-10-07 16:22:24 -06:00
Brian Paul
77be195cf6 main: replace ALLOC_INSTRUCTION macro with regular function 2009-10-07 16:12:26 -06:00
Brian Paul
6e1697bee7 mesa: rename display list functions
_mesa_alloc_instruction() sounded like it was related to vertex/fragment
program instructions, but it wasn't.
2009-10-07 16:03:09 -06:00
Vinson Lee
0083d2e40a i915g: Fix MSVC build. 2009-10-07 14:29:23 -06:00
Brian Paul
2b9418b278 softpipe: new comments 2009-10-07 13:30:48 -06:00
Brian Paul
0fb71be217 softpipe: whitespace and comment fixes 2009-10-07 13:21:57 -06:00
Brian Paul
9a0ff33ad6 softpipe: prefix non-static functions with sp_ 2009-10-07 13:17:20 -06:00
Joakim Sindholt
cf6209b274 r300compiler: fix scons build again 2009-10-07 21:02:18 +02:00
Nicolai Hähnle
7ca7220ea1 Merge branch 'master' into r300g-glsl
Conflicts:
	src/gallium/drivers/r300/r300_tgsi_to_rc.c

Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-10-07 20:45:08 +02:00
Nicolai Hähnle
5b4c0b864a Merge branch 'mesa_7_6_branch' 2009-10-07 20:39:22 +02:00
Keith Whitwell
3f5a316f36 util: do some more util_blit_pixels cases without temporaries
When the source surface is pointing at a 2d texture with only one
mipmap level, use that directly rather than creating a temporary.
Probably want to cover more cases, but this is a start.
2009-10-07 18:15:21 +01:00
Keith Whitwell
c0de2ed505 mesa/st: add missing mesa constant file name
There are many different names for constants in mesa, we were missing
one since the ureg rewrite.
2009-10-07 18:15:20 +01:00
Brian Paul
2ef1aae163 st/mesa: pass pipe_screen, not pipe_context to st_choose_format() functions
These don't depend on context state, but use a screen pointer.
2009-10-07 09:58:34 -06:00
Michel Dänzer
de81b2cf0a st/dri: Add missing front buffer case in dri_get_buffers().
This seems to help for compiz at least with some drivers.

Also add an assert(0) to catch unhandled cases in the future.
2009-10-07 16:36:39 +02:00
Jakob Bornecrantz
0f0127f6f9 i915g: Use buffer write instead of map for lit vertices 2009-10-07 14:04:48 +01:00
Jakob Bornecrantz
f8ba93aefd i915g: Change order of buffer_write arguments
They now follow the pipe_buffer_write style,
	its the gallium driver that sets the interface not
	the winsys.
2009-10-07 13:48:32 +01:00
Jakob Bornecrantz
030723fc5d i915g: Disable vbuf fifo and minor commenting of vbuf code
The vbuf fifo doesn't appear to help once the libdrm
	reuse flag has been set.
2009-10-07 13:48:32 +01:00
Brian Paul
74d61d03b5 mesa: added MESA_FORMAT_XRGB8888 2009-10-06 22:30:01 -06:00
Younes Manton
aec2c010f6 nv04-nv40: Fix swizzle transfers for NPOT sizes.
Workarounds not necessary, SIFM can handle NPOT, we just weren't setting
dst dimensions properly. SIFM can't handle odd w,h though, that still
needs fixing.
2009-10-06 22:11:07 -04:00
Brian Paul
c5b7254892 mesa: added case for MESA_FORMAT_SIGNED_RGBA_16 2009-10-06 19:01:43 -06:00
Brian Paul
c13b9a141d mesa: added MESA_FORMAT_SIGNED_RGBA_16 for accum buffers 2009-10-06 19:00:09 -06:00
Brian Paul
f7b5e616e0 mesa: added _mesa_get_format_color_encoding() 2009-10-06 18:56:29 -06:00
Brian Paul
edfd2f7c4f mesa: accept more pnames in _mesa_get_format_bits() 2009-10-06 18:54:13 -06:00
Vinson Lee
9c778a90ea progs/tests: fix MSVC build. 2009-10-06 16:02:47 -06:00
Nicolai Hähnle
57abb76e10 r300/compiler: Fix R300 vertex program dumps
The source register field has 8 bits.

Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-10-06 21:24:44 +02:00
Nicolai Hähnle
bcfba138cc r300/compiler: Fix yet another regression in register allocation
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-10-06 21:13:27 +02:00
Nicolai Hähnle
a09bd685da r300/compiler: Fix a really stupid logic inversion in the generic dataflow code
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-10-06 20:25:07 +02:00
Nicolai Hähnle
9e42f0ebc7 r300/compiler: Fix regression in pair scheduling
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-10-06 20:08:32 +02:00
Vinson Lee
017fae04ec progs/perf: Fix MSVC build. 2009-10-06 09:13:14 -06:00
Andre Maasikas
ec58dac86d r600: r700PredictRenderSize can flush, so move index buffer setup after it 2009-10-06 16:17:03 +03:00
Ben Skeggs
340436d8d2 nv50: fix segfault when there's gaps in enabled texture units
Tested with progs/demos/multiarb.
2009-10-06 13:57:51 +10:00
Ben Skeggs
4911443d36 nouveau: fix buffer object leak
Very apparent with resizing windows on DRI2.
2009-10-06 13:31:43 +10:00
Jakob Bornecrantz
db8b363eb9 i915g: Add more defines to tweek batchbuffer 2009-10-06 03:09:16 +01:00
Jakob Bornecrantz
ce3c2b51a2 i915g: Tweek vertexbuffer size 2009-10-06 03:09:01 +01:00
Brian Paul
3e34a2a2b9 drivers: don't include texformat.h
And remove other unneeded #includes while we're at it.
2009-10-05 18:11:37 -06:00
Brian Paul
90cd968300 mesa: don't include texformat.h 2009-10-05 17:56:31 -06:00
Brian Paul
019bc97bd9 mesa: move _mesa_format_to_type_and_comps() to formats.c 2009-10-05 17:54:20 -06:00
Brian Paul
be0765cd6e mesa: move gl_format_info struct to formats.c
This is a private datatype.
2009-10-05 17:50:36 -06:00
Brian Paul
7e7f38a67d mesa: remove feature tests 2009-10-05 17:48:22 -06:00
Brian Paul
6ec3db6cab mesa: use FetchTexelf() instead of FetchTexelc() 2009-10-05 17:28:39 -06:00
Brian Paul
41bee4cff5 mesa: add parenthesis 2009-10-05 17:27:50 -06:00
Brian Paul
1a2bb37264 mesa: lift _mesa_set_fetch_functions() calls out of drivers
Call it from in the main Mesa glTexImage functions.
2009-10-05 17:12:40 -06:00
Brian Paul
bbbf55fa84 mesa: make _mesa_get_texel_fetch_func() static 2009-10-05 16:52:26 -06:00
Brian Paul
722ae91722 i965g: remove 965/brw files from XLIB_WINSYS_SOURCES 2009-10-05 14:43:38 -06:00
Brian Paul
55770d09c1 Merge branch 'mesa_7_6_branch'
Conflicts:

	src/gallium/auxiliary/util/u_cpu_detect.c
2009-10-05 14:42:08 -06:00
Jakob Bornecrantz
f00da2a3ff 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.
2009-10-05 19:48:08 +01:00
Jakob Bornecrantz
c4b821a4c6 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.
2009-10-05 19:48:03 +01:00
Joakim Sindholt
1f39d59a29 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.
2009-10-05 19:25:04 +02:00
José Fonseca
6971be783b 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.
2009-10-05 16:49:21 +01:00
José Fonseca
75e0a376cd mesa: Copy textures' base format into wrapper renderbuffer.
Otherwise st_copy_texsubimage will fallback to software blit due to
inconsistent base formats.
2009-10-05 16:49:21 +01:00
Keith Whitwell
b02ef740b9 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...
2009-10-05 15:51:55 +01:00
Keith Whitwell
6a085184eb 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().
2009-10-05 15:51:55 +01:00
Andre Maasikas
0b032eabc7 r600: update vertex program selection for draw path 2009-10-05 13:38:53 +03:00
Ben Skeggs
d47de50540 st/dri: avoid segfault if we can't get a pixmap's buffers
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2009-10-05 15:52:33 +10:00
Ben Skeggs
7bfc3172e8 nv50: support PIPE_FORMAT_X8R8G8B8_UNORM
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2009-10-05 15:36:06 +10:00
Ben Skeggs
5313f1be11 nouveau: return pitch value from local_handle_from_texture()
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2009-10-05 15:36:02 +10:00
Ben Skeggs
7aeaca33c3 mesa: fix return value when clipping {Read,Draw}Pixels height <= 0
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2009-10-05 15:35:40 +10:00
Ben Skeggs
1336989ec6 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>
2009-10-05 15:32:55 +10:00
José Fonseca
7a2271c659 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.
2009-10-04 22:03:16 +01:00
José Fonseca
77ef705058 llvmpipe: Ensure tile cache transfers are mapped before flushing it. 2009-10-04 22:03:16 +01:00
José Fonseca
589ec337f0 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.
2009-10-04 22:03:16 +01:00
José Fonseca
7a7dfb09aa util: Fix cpuid invocation for x86_64. 2009-10-04 22:03:15 +01:00
José Fonseca
eb2e41f0c6 llvmpipe: Remove loop testing from format testing.
Loop building will be rewritten.
2009-10-04 22:03:15 +01:00
José Fonseca
10981c0a76 llvmpipe: Match header's protection macro with filename. 2009-10-04 22:03:15 +01:00
José Fonseca
cd0a396813 llvmpipe: Adjust format assertion.
We support array layout too -- if it has a single channel.
2009-10-04 22:03:15 +01:00
Nicolai Hähnle
a6b300ac98 r300/compiler Add support for more of the Sxx set instructions
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-10-04 18:31:18 +02:00
Nicolai Hähnle
12e89e0e51 r300/compiler: Emit flow control instructions and ALU result writes on R500
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-10-04 18:30:52 +02:00
Corbin Simpson
2a929a08ab 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
2009-10-04 09:30:30 -07:00
Nicolai Hähnle
a30560e6f0 r300/compiler: Refactor the radeon_pair code to support control flow instructions
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-10-04 16:50:07 +02:00
Nicolai Hähnle
995135479d r300/compiler: Refactor to allow different instruction types
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-10-04 11:41:03 +02:00
Nicolai Hähnle
e6b137dcce r300/compiler: Introduce aluresult register for branch operation support
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-10-04 11:13:13 +02:00
Chris Wilson
f194d2737b 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>
2009-10-03 23:08:39 +01:00
Chris Wilson
470ec8d42e 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>
2009-10-03 23:06:39 +01:00
Nicolai Hähnle
b7cf887ca7 r300/compiler: Introduce control flow instructions and refactor dataflow
Note that control flow instruction support isn't actually fully functional yet.

Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-10-03 23:37:16 +02:00
José Fonseca
cbb57bf726 llvmpipe: Fetch tile only if a color buffer is bound. 2009-10-03 19:42:22 +01:00
Nicolai Hähnle
6d25b9125e Merge branch 'master' into r300-compiler 2009-10-03 19:30:48 +02:00
Nicolai Hähnle
7d2699aedc prog_parameter: Document the fact that Size may be > 4
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-10-03 19:30:05 +02:00
Nicolai Hähnle
81e5188f66 r300g: Do not abort on fragment program compiler error
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-10-03 19:29:48 +02:00
Nicolai Hähnle
59b20b760d r300g: Fix memory leak in radeon_texture_from_shared_handle
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-10-03 18:07:34 +02:00
Sedat Dilek
aa6aa77a1b 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 ]
2009-10-03 18:01:58 +02:00
Michel Dänzer
b330cebe01 radeon: Cope better with texture images with no miptrees.
Fixes crash with compiz magnifier plugin.
2009-10-03 18:01:58 +02:00
Michel Dänzer
f741c1eed4 swrast: Move up state validation in _swrast_ReadPixels.
This ensures the driver won't map the wrong set of textures.
2009-10-03 18:01:58 +02:00
Michel Dänzer
4a6759b778 meta: Make sure texImage->TexFormat is valid for CopyTex(Sub)Image. 2009-10-03 18:01:57 +02:00
Nicolai Hähnle
26df8af4fe r300g: Remove an unnecessarily created pipe buffer (and thus fix a leak)
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-10-03 17:51:09 +02:00
Nicolai Hähnle
fce2095a90 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>
2009-10-03 17:42:50 +02:00
Nicolai Hähnle
751aa58e01 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>
2009-10-03 17:27:50 +02:00
Nicolai Hähnle
ebbd65eb06 st/dri: Install ARB_vertex_array_object functions
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-10-03 11:45:19 +02:00
Brian Paul
be16acaafa 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.
2009-10-02 14:00:02 -06:00
Eric Anholt
4182b58169 i965: Use a little stack space to avoid a malloc in wm_get_binding_table. 2009-10-02 11:42:19 -07:00
Eric Anholt
6d0fc3cfde 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.
2009-10-02 11:42:07 -07:00
Eric Anholt
f019577f0c Revert "Flush driver, not just tnl module."
This reverts commit df058298e1.  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
2009-10-02 11:41:29 -07:00
Eric Anholt
3d78a86cd7 intel: Remove an unexplained flush from intelClearWithBlit. 2009-10-02 11:38:36 -07:00
Alex Deucher
3f623cfffe r600: remove support for host-based ibs
no longer used now that the hw supports this natively.

Also, clean up some formatting.
2009-10-02 14:34:28 -04:00
Keith Whitwell
918199fb0f 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.
2009-10-02 19:03:15 +01:00
Michel Dänzer
316b4ddcf7 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.
2009-10-02 18:13:26 +02:00
Michel Dänzer
9db647bb7a 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.
2009-10-02 18:13:26 +02:00
Michel Dänzer
47e41b024e 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.
2009-10-02 18:13:26 +02:00
Brian Paul
7d4b348c67 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).
2009-10-02 09:03:27 -06:00
Brian Paul
f1cab802b8 mesa: added _mesa_meta_check_generate_mipmap_fallback() 2009-10-02 09:03:27 -06:00
Brian Paul
32aa40eee4 mesa: removed gl_texture_image::CompressedSize field
Just call ctx->Driver.CompressedTextureSize() when we need to get
the compressed image size.
2009-10-01 21:13:34 -06:00
Younes Manton
f9f7646fe6 g3dvl: Formatting. 2009-10-01 22:57:39 -04:00
Younes Manton
577f12fbba g3dvl: Delete state_trackers/g3dvl, other unused files. 2009-10-01 22:57:39 -04:00
Younes Manton
fcb595c04f g3dvl: Copyright blocks. 2009-10-01 22:53:00 -04:00
Younes Manton
62db9b21da st/xvmc: Set default CSC matrix to BT.601, no ProcAmp, full range RGB. 2009-10-01 22:52:59 -04:00
Younes Manton
e00da1476f 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).
2009-10-01 22:52:59 -04:00
Brian Paul
8c92a531fb mesa: reformatting 2009-10-01 19:01:02 -06:00
Brian Paul
bb659f6e53 progs/tests: additional debug code 2009-10-01 16:43:22 -06:00
Brian Paul
4ca9ba2544 mesa: move mesa_set_fetch_functions() 2009-10-01 16:42:37 -06:00
Brian Paul
073d55f584 radeon: fix tx_table[] entry
XXX need to still verify that the table entries are in correct order.
2009-10-01 16:41:52 -06:00
Brian Paul
4208a8c026 savage: s/Xfree/_mesa_free/ 2009-10-01 16:41:24 -06:00
Brian Paul
354d66e2f5 mesa: simplify _mesa_compressed_texture_size() 2009-10-01 16:30:47 -06:00
Brian Paul
b6bdafdf2c mesa: remove gl_texture_image::IsCompressed field
Use _mesa_is_format_compressed() instead.
2009-10-01 16:29:44 -06:00
Brian Paul
040fd7ed44 mesa: added _mesa_format_row_stride() 2009-10-01 16:27:23 -06:00
Brian Paul
1c7ec97ec4 mesa: added _mesa_format_image_size() 2009-10-01 15:59:13 -06:00
Eric Anholt
81aa5d717b 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.
2009-10-01 14:54:15 -07:00
Eric Anholt
862a2a55b3 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.
2009-10-01 14:52:44 -07:00
Eric Anholt
67f4d626d3 i915: Add support or fallbacks for GLSL fragment shader opcodes. 2009-10-01 14:31:04 -07:00
Eric Anholt
f9f31b2574 i915: Add support for varying inputs. 2009-10-01 14:31:04 -07:00
Eric Anholt
7d4b7460b0 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.
2009-10-01 14:31:03 -07:00
Eric Anholt
96a3c69d48 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.
2009-10-01 14:31:03 -07:00
Eric Anholt
61b512c47c 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.
2009-10-01 14:31:03 -07:00
Eric Anholt
d6fbf87575 Revert "i915: don't validate PS program when falling back to software"
This reverts commit e7044d552c.  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.
2009-10-01 14:31:03 -07:00
Eric Anholt
4ff816751f i915: Bail when the fragment program has too many total instructions.
Previously, we'd go trashing the heap.
2009-10-01 14:31:03 -07:00
Eric Anholt
994d1db079 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.
2009-10-01 14:31:03 -07:00
Brian Paul
5d2413fca4 Merge branch 'mesa_7_6_branch' 2009-10-01 13:35:42 -06:00
Brian Paul
15c57648cd objviewer: remove disabled code 2009-10-01 13:14:50 -06:00
Brian Paul
9745e26adb objviewer: mouse/keyboard info in README file 2009-10-01 13:14:50 -06:00
Brian Paul
d622c4ddba docs: added objviewer to release notes 2009-10-01 13:14:50 -06:00
Brian Paul
24f31ab861 mesa: add objviewer to PROGRAM_DIRS 2009-10-01 13:14:50 -06:00
Brian Paul
0b1de63ad8 mesa: add progs/objviewer to tarball list 2009-10-01 13:14:50 -06:00
Brian Paul
8d93a4c639 objview: clean up drawing VBO code 2009-10-01 13:14:50 -06:00
Brian Paul
c7c62521fb objview: set skybox texture filter 2009-10-01 13:14:50 -06:00
Brian Paul
336994e54c objview: check GL version/extension 2009-10-01 13:14:49 -06:00
Brian Paul
ca1bda552d progs/objviewer: Wavefront .obj file loader/viewer demo
Adapted from code written by Nate Robins.  See README.txt.
2009-10-01 13:14:48 -06:00
Michel Dänzer
e32a341be6 st/xorg: Check that ms->api->destroy is not NULL before calling it.
Fixes potential crash on X server shutdown.
2009-10-01 16:45:11 +02:00
Robert Noland
0b466c8705 util: Enable sockets on BSD
I think this should be safe for all of the BSDs.

Signed-off-by: Robert Noland <rnoland@2hip.net>
Signed-off-by: Brian Paul <brianp@vmware.com>
2009-10-01 08:42:48 -06:00
Robert Noland
908ecb3faa util: define PIPE_OS_FREEBSD to correct u_cpu_detect on FreeBSD.
Since the various BSDs use some different features here,
define PIPE_OS_OPENBSD and PIPE_OS_NETBSD as well

Signed-off-by: Robert Noland <rnoland@2hip.net>
2009-10-01 08:40:30 -06:00
Brian Paul
f8d8f45278 mesa: better debug message 2009-10-01 08:38:38 -06:00
Keith Whitwell
4456006ba6 gallium: remove depth.occlusion_count flag
This was redundant as drivers can just keep track of whether they are
inside a begin/end query pair.  We want to add more query types later
and also support nested queries, none of which map well onto a flag like
this.  No driver appeared to be using the flag.
2009-10-01 14:34:23 +01:00
Cooper Yuan
ae2daacbac st/mesa: fix non-mipmap lastLevel calculation.
reviewed by Brian Paul.
2009-10-01 17:54:27 +08:00
Brian Paul
8c36ca707c swrast: fix some texformat regressions
Need to be careful with component ordering for MESA_FORMAT_RGB888
and MESA_FORMAT_RGBA8888.
2009-09-30 22:50:08 -06:00
Brian Paul
3d6a20e5b6 mesa: rename texformat_tmp.h to texfetch_tmp.h 2009-09-30 21:08:06 -06:00
Brian Paul
60843e3ee5 mesa: remove MESA_FORMAT_RGBA4444
Not used by any hardware driver.  ARGB4444 and ARGB4444_REV remain.
2009-09-30 21:04:17 -06:00
Brian Paul
3fa7dbf368 mesa: remove GLchan-based formats; use hw 8-bit/channel formats instead
Removed: MESA_FORMAT_RGBA, RGB, ALPHA, LUMINANCE, LUMINANCE_ALPHA, INTENSITY.
2009-09-30 21:00:16 -06:00
Brian Paul
74ae14a2bd mesa: move texel fetch/store into new texfetch.[ch] files 2009-09-30 20:47:54 -06:00
Brian Paul
884d1abb2a st/mesa: update comment 2009-09-30 20:36:25 -06:00
Brian Paul
bdc761b0f9 mesa: remove gl_texture_format 2009-09-30 20:35:32 -06:00
Brian Paul
1f7c914ad0 mesa: replace gl_texture_format with gl_format
Now gl_texture_image::TexFormat is a simple MESA_FORMAT_x enum.
ctx->Driver.ChooseTexture format also returns a MESA_FORMAT_x.
gl_texture_format will go away next.
2009-09-30 20:28:45 -06:00
Michel Dänzer
81a62edc08 st/xorg: Fix debug option function call typo. 2009-09-30 18:01:46 +02:00
Chia-I Wu
cef97267d6 mesa/main: New feature FEATURE_beginend.
This feature corresponds to the Begin/End paradigm.  Disabling this
feature also eliminates the use of GLvertexformat completely.
2009-09-30 08:31:56 -06:00
Chia-I Wu
a73ba2d31b mesa/main: Make FEATURE_dlist follow feature conventions.
As shown in mfeatures.h, this allows users of dlist.h to work without
knowing if the feature is available.
2009-09-30 08:31:56 -06:00
Chia-I Wu
aefa1f6ab1 mesa/main: Make FEATURE_evaluators follow feature conventions.
As shown in mfeatures.h, this allows users of eval.h to work without
knowing if the feature is available.
2009-09-30 08:31:55 -06:00
Chia-I Wu
42fac11d43 mesa/main: New feature FEATURE_queryobj.
It merges FEATURE_ARB_occlusion_query and FEATURE_EXT_timer_query, and
follows the feature conventions.
2009-09-30 08:31:55 -06:00
Chia-I Wu
80630d1fed mesa/main: New feature FEATURE_arrayelt.
This allows the removal of AEcontext.
2009-09-30 08:31:55 -06:00
Chia-I Wu
cc95de82e5 mesa/main: Make FEATURE_texgen follow feature conventions.
As shown in mfeatures.h, this allows users of texgen.h to work without
knowing if the feature is available.
2009-09-30 08:31:55 -06:00
Chia-I Wu
301a510092 mesa/main: Make FEATURE_feedback follow feature conventions.
As shown in mfeatures.h, this allows users of feedback.h to work without
knowing if the feature is available.
2009-09-30 08:31:55 -06:00
Chia-I Wu
67a2a4e901 mesa/main: Make FEATURE_drawpix follow feature conventions.
As shown in mfeatures.h, this allows users of drawpix.h to work
without knowing if the feature is available.
2009-09-30 08:31:55 -06:00
Chia-I Wu
d25080074f mesa/main: New feature FEATURE_rastpos.
It is separated from FEATURE_drawpix and made to follow the feature
conventions.
2009-09-30 08:31:55 -06:00
Chia-I Wu
cab7ea0368 mesa/main: Make FEATURE_histogram follow feature conventions.
As shown in mfeatures.h, this allows users of histogram.h to work without
knowing if the feature is available.
2009-09-30 08:31:55 -06:00
Chia-I Wu
2b36db496d mesa/main: Make FEATURE_attrib_stack follow feature conventions.
As shown in mfeatures.h, this allows users of attrib.h to work without
knowing if the feature is available.
2009-09-30 08:31:55 -06:00
Chia-I Wu
a833ff0f53 mesa/main: Make FEATURE_accum follow feature conventions.
As shown in mfeatures.h, this allows users of accum.h to work without
knowing if the feature is available.
2009-09-30 08:31:55 -06:00
Chia-I Wu
e82b02c7e8 progs/egl: Make demo3 work again.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-09-30 08:15:30 -06:00
Chia-I Wu
28c2190336 progs/egl: Check EGL_MESA_screen_surface is supported in demo2.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-09-30 08:15:30 -06:00
Chia-I Wu
e0b2848f4f progs/egl: Fix a crash in demo1.
The variable "configs" in main() is used without initialization.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-09-30 08:15:30 -06:00
Chia-I Wu
4b95481e95 st/egl: Fix a double free in drm_destroy_context.
st_destroy_context has destroyed the pipe context for us.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-09-30 08:15:30 -06:00
Chia-I Wu
dd81cc885c st/egl: Fix a crash when unbinding current context.
This fixes a NULL-pointer dereference when
eglMakeCurrent(dpy, EGL_NO_SURFACE, EGL_NO_SURFACE, EGL_NO_CONTEXT)
is called.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-09-30 08:15:30 -06:00
Chia-I Wu
fa8df0c40d progs/egl: Replace EGL_i915 by EGL_DEFAULT_DISPLAY.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-09-30 08:15:30 -06:00
Brian Paul
cb0de06301 mesa: added nopfrag/nopvert options for MESA_GLSL
These options can be used to force vertex/fragment shaders to be no-op
shaders (actually, simple pass-through shaders).  For debug/test purposes.
2009-09-29 10:38:02 -06:00
Brian Paul
c7aee65bb9 mesa: added _mesa_nop_vertex/fragment_program()
For debug/test purposes.
2009-09-29 10:38:02 -06:00
José Fonseca
baddcbc522 llvmpipe: Workaround for bug in llvm 2.5.
The combination of fptosi
and sitofp (necessary for trunc/floor/ceil/round implementation)
somehow becomes invalid code.

Skip the instruction combining pass when SSE4.1 is not available.
2009-09-29 17:28:15 +01:00
José Fonseca
a02ecdf8c2 llvmpipe: First verify LLVM IR, only then run optimizing passes. 2009-09-29 17:28:15 +01:00
José Fonseca
754f48871c llvmpipe: Runtime cpu checks for lp_build_min_simple too. 2009-09-29 17:28:15 +01:00
José Fonseca
741c40a232 llvmpipe: Implement non SSE4.1 versions of floor and round. 2009-09-29 17:28:15 +01:00
Brian Paul
124f5875ea Merge branch 'mesa_7_6_branch'
Conflicts:

	Makefile
	configs/default
	docs/relnotes.html
	src/gallium/drivers/softpipe/sp_context.c
	src/gallium/drivers/softpipe/sp_tile_cache.c
	src/mesa/main/version.h
2009-09-29 09:46:49 -06:00
Chia-I Wu
170bd0c882 egl_xdri: Report full list of supported configs.
Call _eglConfigFromContextModesRec to convert __GLcontextModes to
_EGLConfig.  Single-buffered configs are no longer skipped.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-09-29 08:10:48 -06:00
Chia-I Wu
d845f2754b egl: Add support for querying render buffer.
Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-09-29 08:10:48 -06:00
Chia-I Wu
55893b9439 egl: Add a function to convert __GLcontextModes to _EGLConfig.
_eglConfigFromContextModesRec is used to convert a __GLcontextModes to a
_EGLConfig.  Note that the config is not validated.  An invalid mode
is likely to give an invalid config.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-09-29 08:10:47 -06:00
Chia-I Wu
56822b0812 egl: Rework config lookup.
Make it similiar to how contexts and surfaces are looked up.  It should
be slightly faster, and work better with multiple displays.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-09-29 08:10:47 -06:00
Chia-I Wu
95cdd697e7 egl: Rework configuration management.
This mainly implements the algorithms for configuration selection and
sorting, described in the spec.  User errors should also be correctly
detected and reported.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-09-29 08:10:47 -06:00
Chia-I Wu
358c5a8fd1 egl: Introduce config keys.
Config keys are almost config attributes.  A valid config attribute is a
valid config key, but a valid config key may not be a valid config
attribute.

This commit does not distinguish the differences.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-09-29 08:10:47 -06:00
José Fonseca
7cda8ea44c llvmpipe: Emit SSE intrinsics based on runtime cpu capability check.
Note that llvmpipe still doesn't run on any processor yet: if you don't
have a recent processor with SSE4.1 you will still likely end up
hitting a code path for which a generic non-sse4 version is not
implemented yet.
2009-09-29 13:59:16 +01:00
José Fonseca
a81fb2a0d2 util: Cleanup u_cpu_detect, build. Support X86_64 and detect SSE4.1 too.
I was waiting for the need to use this code to arise, and it finally came.

I've tested building this on Linux and Windows, both x86 and x64_64. But
it might break other platforms. Please bear with me and help me fix it.

Many thanks to Dennis Smit who submitted this, and Eric Anholt whose
work this was based on.
2009-09-29 13:59:16 +01:00
José Fonseca
8210abb113 gallium: New PIPE_OS_UNIX to simplify code that is portable to all unices. 2009-09-29 13:59:16 +01:00
Vinson Lee
60f3f22a52 i915: Fix MSVC build. 2009-09-29 11:10:42 +01:00
José Fonseca
57d0fcba67 python: Update for surface_buffer_create change. 2009-09-29 11:09:55 +01:00
José Fonseca
bd2e36a38f g3dvl: assert.h -> util/u_debug.h 2009-09-29 11:09:55 +01:00
José Fonseca
7db33440a8 g3dvl: Define PIPE_VIDEO_CODEC_UNKNOWN for failures.
gcc 4.4 seems particularly picky with int -> enum conversions.
2009-09-29 11:09:55 +01:00
Brice Goglin
ee9811de78 Prepare changelog for upload 2009-09-29 11:52:04 +02:00
Brice Goglin
adaeac03dd Add bug closers 2009-09-29 11:51:51 +02:00
Brice Goglin
e47955de4e Refresh patches 2009-09-29 11:45:58 +02:00
Brice Goglin
58c42a5b1d New upstream release 2009-09-29 11:43:15 +02:00
Brice Goglin
753604e607 Merge tag 'mesa_7_6' into debian-unstable
Conflicts:
	progs/egl/Makefile
	progs/egl/demo3.c
	progs/slang/vstest.c
	progs/tests/Makefile
	progs/tests/SConscript
	progs/tests/bufferobj.c
	progs/tests/floattex.c
	progs/tests/getprocaddress.c
	progs/tests/getprocaddress.py
	progs/tests/mapbufrange.c
	progs/tests/mapvbo.c
	progs/tests/texcmp.c
	progs/tests/texcompsub.c
	progs/tests/zreaddraw.c
	progs/trivial/.gitignore
	progs/vp/arl-static.txt
	progs/vp/arl-unused.txt
	progs/vp/vp-tris.c
	scons/gallium.py
2009-09-29 11:39:19 +02:00
Andre Maasikas
ac9c8b6359 r600: use CB_TARGET_MASK instead of CB_SHADER_MASK for setting color mask
makes blend functions work better

Signed-off-by: Dave Airlie <airlied@linux.ie>
2009-09-29 19:24:35 +10:00
Andre Maasikas
7c5f3c3d8a r600: user correct alpha blend factor
Signed-off-by: Dave Airlie <airlied@linux.ie>
2009-09-29 19:24:34 +10:00
Andre Maasikas
a230ad2bc4 r600: clear position enable bit when when wpos is not used by FP
Makes doom3 alot nicer..
2009-09-29 16:02:00 +08:00
Jakob Bornecrantz
3a8d525373 st/xorg: Add debug for fallbacks 2009-09-28 21:34:45 -07:00
Jakob Bornecrantz
e226bf8a5d st/xorg: Make debug printing optional 2009-09-28 21:26:13 -07:00
Brian Paul
e2e7bd6c1f mesa: move StoreTexImageFunc typedef to .c file 2009-09-28 21:55:47 -06:00
Brian Paul
0a306daf71 mesa: use _mesa_texstore() 2009-09-28 21:52:43 -06:00
Brian Paul
6480210b89 st/mesa: use _mesa_texstore() 2009-09-28 21:52:23 -06:00
Brian Paul
49263e0856 mesa: make individual texstore functions static 2009-09-28 21:49:38 -06:00
Brian Paul
cb0ef0cbf8 glide: use _mesa_texstore() 2009-09-28 21:49:10 -06:00
Brian Paul
b436d729d1 drivers: use _mesa_texstore 2009-09-28 21:46:34 -06:00
Brian Paul
0b1f4dc0fa drivers: use new _mesa_texstore() function 2009-09-28 21:41:11 -06:00
Brian Paul
660ca9c5a2 mesa: new _mesa_texstore() function 2009-09-28 21:40:50 -06:00
Eric Anholt
d492e7b017 meta: Fix invalid PBO access from DrawPixels when trying to just alloc.
This whole reuse of buffers (TexSubImage instead of TexImage, SubData
instead of Data) is bad for hardware drivers, but it's even worse when
we accidentally try to access the 2x2 PBO to fill the new 16x16 texture
we're creating, producing GL errors.

Fixes piglit pbo-drawpixels.  Bug #14163.
2009-09-28 14:12:15 -07:00
Eric Anholt
e885cb48a0 intel: Drop my generatemipmap code in favor of the new shared code. 2009-09-28 14:12:15 -07:00
Eric Anholt
8b23755ce9 intel: Remove some dead metaops code. 2009-09-28 14:12:09 -07:00
Ian Romanick
41865d991f Merge branch 'mesa_7_6_branch'
Conflicts:
	Makefile
	src/mesa/main/version.h
2009-09-28 12:03:23 -07:00
Brian Paul
05bad193f5 st/mesa: check gl_texture_object::GenerateMipmap field when allocating texmem
In guess_and_alloc_texture() use the gl_texture_object::GenerateMipmap
field as another hint as to whether to allocate space for a whole mipmap.
2009-09-28 10:03:58 -06:00
Brian Paul
8fda97afb8 Merge branch 'mesa_7_6_branch' 2009-09-28 10:02:20 -06:00
Brian Paul
eb82373abb mesa: use _mesa_get_current_tex_unit() helper 2009-09-28 09:22:33 -06:00
Vinson Lee
6920a355c1 progs/perf: Include local headers before installed headers.
Fixes compilation errors on platforms with older installed GL headers.
2009-09-28 09:03:26 -06:00
Brian Paul
653ae04bea progs/tests: print usage info upon SPACE/u 2009-09-28 08:44:43 -06:00
Brian Paul
c8de476189 progs/tests: re-indent mipmap_limits.c 2009-09-28 08:44:43 -06:00
Younes Manton
9871521b30 llvmpipe: Grab a ref when the fb is set.
Based on softpipe commit a77226071f.
2009-09-28 15:35:29 +01:00
José Fonseca
5687053480 softpipe: Fix MSVC build. 2009-09-28 13:03:03 +01:00
José Fonseca
22658c1650 g3dvl: Fix MSVC build.
pipe/p_compiler for integer types. No declarations out of scope.
2009-09-28 13:02:42 +01:00
Cooper Yuan
99e1745af9 r300g: fix r300g cause GPU hang issue.
why there are two input position semantic tags is that ureg doesn't
set vs input semantic due to commit: 6d8dbd3d1e

so use vs input index instead of semantic name.
2009-09-28 17:55:38 +08:00
Michal Krol
c4bd6ccde8 glsl/pp: Expand macro actual arguments before pasting into its body. 2009-09-28 11:30:15 +02:00
Younes Manton
70c44073ad xvmc: Fail on unsupported formats, operations. 2009-09-28 00:17:33 -04:00
Younes Manton
c0745670d8 g3dvl: Missing semicolon. 2009-09-27 23:54:36 -04:00
Brian Paul
729ff875f4 mesa: change _mesa_format_to_type_and_comps() format parameter type 2009-09-27 21:32:12 -06:00
Brian Paul
bd00a7fa4b mesa: sort texstore_funcs[] array, remove search loop 2009-09-27 21:22:57 -06:00
Younes Manton
d52d51ab8a g3dvl: Formatting and cleanups. 2009-09-27 23:14:52 -04:00
Brian Paul
749e50442a mesa: fix render buffer _BaseFormat assignment 2009-09-27 21:14:43 -06:00
Brian Paul
ef089604a9 mesa: use texture format functions 2009-09-27 21:14:12 -06:00
Brian Paul
4fc344790d mesa: update comments 2009-09-27 21:13:46 -06:00
Brian Paul
e987ea9d21 mesa: use more mesa format functions 2009-09-27 21:07:57 -06:00
Brian Paul
5767a677a0 mesa: fix GL_TEXTURE_LUMINANCE_SIZE query 2009-09-27 20:59:28 -06:00
Brian Paul
a2b663fe38 mesa: use more mesa format functions 2009-09-27 20:58:05 -06:00
Brian Paul
af0adb5852 mesa: use more mesa format functions 2009-09-27 20:56:04 -06:00
Brian Paul
5cf5d4be21 mesa: use more format helper functions 2009-09-27 20:51:18 -06:00
Brian Paul
5978cbdf77 mesa: code movement 2009-09-27 20:40:53 -06:00
Brian Paul
ddffe4546a drivers: use more mesa format functions 2009-09-27 20:40:35 -06:00
Brian Paul
9fbb8884f0 mesa/drivers: use _mesa_get_format_bytes() 2009-09-27 20:24:59 -06:00
Brian Paul
e0bc4533eb mesa/drivers: use _mesa_get_format_bytes() 2009-09-27 20:07:41 -06:00
Brian Paul
b58bc12ed4 via: use mesa texture format helper functions 2009-09-27 19:58:18 -06:00
Younes Manton
97c28bb63a g3dvl: Move XvMC under the Xorg state tracker. 2009-09-27 21:54:20 -04:00
Brian Paul
21db8959c1 glide: use _mesa_get_format_bytes() 2009-09-27 19:53:54 -06:00
Brian Paul
2de7683280 mesa: use _mesa_get_format_base_format() 2009-09-27 19:51:45 -06:00
Brian Paul
db8aca3a39 mesa: use _mesa_get_format_bytes() 2009-09-27 19:49:51 -06:00
Brian Paul
5ab5f16919 mesa: added _mesa_get_format_datatype() 2009-09-27 19:42:36 -06:00
Brian Paul
b64d478a5b mesa: use _mesa_get_format_bits() 2009-09-27 19:38:21 -06:00
Brian Paul
c28d78f832 mesa: added _mesa_get_format_bits() 2009-09-27 19:07:44 -06:00
Brian Paul
a608257a02 mesa: remove unused gl_texture_format fields 2009-09-27 18:57:02 -06:00
Brian Paul
e8eed5003b mesa: added MESA_FORMAT_NONE 2009-09-27 18:53:22 -06:00
Brian Paul
cccdc43fa9 mesa: move StoreTexImageFunc to texstore.h 2009-09-27 18:50:04 -06:00
Brian Paul
27e201e9c4 mesa: rework null texel fetch/store funcs 2009-09-27 18:49:14 -06:00
Brian Paul
05e73cc8e2 mesa: replace function pointer types with void *
These fields are no longer used and will be removed soon.
2009-09-27 18:39:52 -06:00
Brian Paul
adce34e23b st/mesa: use _mesa_get_texstore_func() 2009-09-27 18:39:17 -06:00
Brian Paul
f782f90c45 mesa: use _mesa_get_texstore_func() 2009-09-27 18:38:50 -06:00
Brian Paul
d73cd70316 glide: use _mesa_get_texstore_func() 2009-09-27 18:34:12 -06:00
Brian Paul
9525b92efb mesa: NULL-out unused texformat field initializers 2009-09-27 18:28:48 -06:00
Brian Paul
f76cbac04a mesa: use _mesa_get_texstore_func() 2009-09-27 18:28:22 -06:00
Brian Paul
e07862d2c9 st/mesa: use _mesa_get_texstore_func() 2009-09-27 18:27:59 -06:00
Brian Paul
8abb984dc9 mesa: null-out StoreTexImageFunc fields 2009-09-27 18:19:24 -06:00
Younes Manton
e44c85637a g3dvl: Implement XvMC using pipe_video_context. 2009-09-27 20:18:02 -04:00
Brian Paul
431ba64222 mesa: use _mesa_get_texel_store_func() 2009-09-27 18:17:32 -06:00
Brian Paul
da5722bea6 mesa: use new look-up table to get texel fetch/store funcs 2009-09-27 18:09:23 -06:00
Brian Paul
7116ae857c mesa: make some s3tc/fxt1 functions public 2009-09-27 18:08:49 -06:00
Brian Paul
6c6896bd25 progs/tests: disable texturing before printing text 2009-09-27 18:02:02 -06:00
Younes Manton
f547472bfa g3dvl: pipe_video_context interface, softpipe impl, auxiliary libs 2009-09-27 19:49:06 -04:00
Younes Manton
da793b7434 util: Add util_next_power_of_two() for rounding a uint up to a POT. 2009-09-27 19:25:57 -04:00
Brian Paul
0f91e4461f mesa: minor clean-up in _mesa_texstore_srgb8() 2009-09-27 17:07:22 -06:00
Brian Paul
722b761564 mesa: use _mesa_get_texstore_func() to get texture image store func 2009-09-27 17:01:41 -06:00
Maciej Cencora
540039887a r300g: fix erroneous condition 2009-09-27 22:44:29 +02:00
Maciej Cencora
98f6bea168 r300g: don't force vertex position for HW TCL path
It could be generated by vertex shader.
2009-09-27 22:44:28 +02:00
Maciej Cencora
bedc6b7bdf r300g: add some assertions
Not sure why we are getting a shader with two inputs with position semantic, but we don't know how to handle it correctly so it's better to stop the app than lock the machine.
2009-09-27 22:44:28 +02:00
Maciej Cencora
8c8b77a5f3 r300g: plug memory leak 2009-09-27 22:44:27 +02:00
Maciej Cencora
a6eb593072 r300g: add some debugging info 2009-09-27 22:44:27 +02:00
Dave Airlie
d85fe842b8 r300g: fix r300 rs path 2009-09-28 06:42:25 +10:00
Dave Airlie
b1252c7a34 r300g: rewrite RS state setup.
Not 100% sure this is correct, but its more correct than what was here previous
however it may require changes in the input routing for the frag shader.
2009-09-28 06:28:32 +10:00
Dave Airlie
225c3375fd r300g: silence compiler warning 2009-09-28 06:28:31 +10:00
Jakob Bornecrantz
48c45959ee i915g: Submit direct vertex buffers 2009-09-27 13:19:49 -07:00
Jakob Bornecrantz
2d71b541d7 i915g: Fix warning 2009-09-27 13:19:49 -07:00
Jakob Bornecrantz
973e9a774a i915g: Tile shared buffers as well 2009-09-27 13:19:49 -07:00
Jakob Bornecrantz
5aecddc153 i915g: Make sure to map tiled buffers via the gtt 2009-09-27 13:19:49 -07:00
Jakob Bornecrantz
60d72d9e45 i915g: Use boolean 2009-09-27 13:19:48 -07:00
Jakob Bornecrantz
c3663bdc35 i915g: Enable reuse of buffers 2009-09-27 13:19:48 -07:00
Jakob Bornecrantz
dd586078be st/egl: Remove buffer from screen
It is no longer needed since the new drm api code,
	and it incorrectly checked if the buffer where there
	for testing completeness when it should have checked
	the texture instead.
2009-09-27 13:19:48 -07:00
Richard Li
eea30906de r600 : Enable draw_prim. 2009-09-27 14:47:12 -04:00
Younes Manton
a77226071f softpipe: Grab a ref when the fb is set.
Nasty bug when the surface is freed and another is allocated right on
top of it. The next time we set the fb state SP thinks it's the same
surface and doesn't flush, and when the flush eventually happens the
surface belongs to a completely different texture.
2009-09-27 10:56:42 -04:00
Jakob Bornecrantz
bcca927562 progs/rbug: Link to math 2009-09-26 12:36:01 -07:00
Brian Paul
485105ed18 mesa: move _mesa_get_texstore_func() to texstore.c 2009-09-26 12:32:13 -06:00
Brian Paul
22108bb571 mesa: begin removing dependencies on gl_texture_format in texstore code 2009-09-26 12:26:18 -06:00
Brian Paul
a7455f9fc6 mesa: added formats.c to build 2009-09-26 12:25:02 -06:00
Brian Paul
9e7b56c980 mesa: include formats.h 2009-09-26 12:24:17 -06:00
Brian Paul
813870fd95 mesa: initial check-in of new formats.[ch] files 2009-09-26 12:21:03 -06:00
Dave Airlie
eb5dd947fb r300g: add tx depth support in register.
also enable cube/3d bits in txformat reg
2009-09-26 19:32:46 +10:00
Dave Airlie
9bf85f6b95 r300g: only pass complete texture state to hw setup function
No point passing things twice here, also allows more state
to be setup properly.
2009-09-26 18:39:54 +10:00
Dave Airlie
ec9c02187e r300g: add missing break in OQ emit 2009-09-26 18:39:54 +10:00
José Fonseca
1df539ce87 llvmpipe: Allow building with LLVM 2.6 too. 2009-09-26 09:37:43 +01:00
Dave Airlie
28f531e3fe r300g: report GL1.5, enable cap bits for OQ and shadow.
Its not like it works well on 1.3 so may as well reach for greater
heights.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2009-09-26 18:25:00 +10:00
Dave Airlie
20d3c85128 r300g: add z16 unorm texture format 2009-09-26 18:24:34 +10:00
Dave Airlie
07183b73eb r300g: fix texture pitch to correct value.
pitch is pixels - 1, not bytes.
2009-09-26 16:39:13 +10:00
Ian Romanick
8130375e77 Merge branch 'asm-shader-rework-2'
Conflicts:
	src/mesa/shader/program_parse.tab.c
2009-09-25 16:57:38 -07:00
Michel Dänzer
c19482b16f st/xorg: Re-enable accelerated fills and copies.
These seem to work well enough now with the new code. Composite acceleration
isn't quite there yet and thus remains disabled in xorg_composite_bind_state()
for now.
2009-09-25 20:49:53 +02:00
Michel Dänzer
07e2d6edfa st/xorg: Flush render cache if but only if a source has pending write operations. 2009-09-25 20:49:53 +02:00
Michel Dänzer
626553f327 st/xorg: Reject Composite acceleration for some cases not working yet. 2009-09-25 20:49:53 +02:00
Michel Dänzer
9c449502a2 st/xorg: Make sure struct is fully initialized.
gcc complained about a missing initializer.
2009-09-25 20:49:00 +02:00
Michel Dänzer
b0ddfe8a3d st/xorg: Use generic semantic for Composite mask coordinates. 2009-09-25 20:38:49 +02:00
Michel Dänzer
ac2e0ddcd8 st/xorg: Flesh out EXA PrepareComposite hook a little.
Check that the formats are supported, and don't crash with source-only
pictures.
2009-09-25 20:38:49 +02:00
Michel Dänzer
b97547027e st/xorg: Use I8 format instead of A8 for depth 8 pixmaps.
Seems to work better for Composite acceleration.
2009-09-25 20:38:49 +02:00
Michel Dänzer
67fb13ba68 st/xorg: Bind rasterizer state for copies. 2009-09-25 20:38:49 +02:00
Michel Dänzer
7edda9350a st/xorg: Source-only pictures always have format PICT_a8r8g8b8.
See xserver/render/picture.c:createSourcePicture(). This both simplifies the
code and avoids a crash because pFormat is NULL.
2009-09-25 20:38:49 +02:00
Michel Dänzer
07f107467e st/xorg: Better checks for unsupported component alpha pictures. 2009-09-25 20:38:49 +02:00
Michal Krol
69c7fc128c softpipe: Grab fs output z from the correct file. 2009-09-25 18:52:13 +02:00
Michal Krol
a0fbc01cea softpipe: Do not advertise support for L16 and YCBCR formats. 2009-09-25 18:52:12 +02:00
Michal Krol
02b81187dc radeon: Fix newlines. 2009-09-25 18:51:55 +02:00
Brian Paul
ecf3091cc7 Merge branch 'mesa_7_6_branch'
Conflicts:

	src/mesa/drivers/dri/intel/intel_clear.c
2009-09-25 09:00:19 -06:00
Christoph Bumiller
5f4f7ad965 nv50: fix TEX for WriteMask not equal 0xf
If you e.g. only need alpha, it ends up in the first reg,
not the last, as it would when reading rgb too.
2009-09-25 11:01:45 +02:00
Christoph Bumiller
513cadf5af nv50: actually enable view volume clipping
Until now, only primitives wholly outside the view volume
were not drawn.
This was only visibile when using a viewport smaller than
the window size, naturally.
2009-09-25 11:01:45 +02:00
Christoph Bumiller
001daf78c8 nv50: RCP and RSQ cannot load from VP inputs 2009-09-25 11:01:45 +02:00
Christoph Bumiller
ef6805710d nv50: fix CEIL and TRUNC
Separated the integer rounding mode flag for cvt.
2009-09-25 11:01:45 +02:00
Christoph Bumiller
e2b8dc3e38 nv50: implement BGNLOOP, BRK, ENDLOOP
There's a good chance a loop won't execute correctly
though since our TEMP allocation assumes programs to
be executed linearly. Will fix later.
2009-09-25 11:01:44 +02:00
Christoph Bumiller
1196f9fbd6 nv50: implement IF, ELSE, ENDIF opcodes 2009-09-25 11:01:44 +02:00
Cooper Yuan
16a6ca9b2b r300g: add texture format for xvmc 2009-09-25 15:15:20 +08:00
Chia-I Wu
5a1e25afac mesa/main: Make FEATURE_convolve follow feature conventions.
As shown in mfeatures.h, this allows users of convolve.h to work without
knowing if the feature is available.
2009-09-24 21:48:39 -06:00
Chia-I Wu
cb4f24e51d mesa/main: Make FEATURE_colortable follow feature conventions.
As shown in mfeatures.h, this allows users of colortab.h to work
without knowing if the feature is available.
2009-09-24 21:48:22 -06:00
Chia-I Wu
dbb8fb8de9 mesa/main: Make FEATURE_pixel_transfer follow feature conventions.
As shown in mfeatures.h, this allows users of pixel.h to work without
knowing if the feature is available.
2009-09-24 21:48:05 -06:00
Chia-I Wu
17099f5e19 mesa/main: Add comments to mfeatures.h.
The comments document the conventions that a feature may follow.
2009-09-24 21:47:45 -06:00
Brian Paul
c9ddd6f810 progs/perf: glGenerateMipmap() test 2009-09-24 19:38:04 -06:00
Brian Paul
0876618a8d mesa: _mesa_meta_GenerateMipmap() now working
Handles GL_TEXTURE_1D, GL_TEXTURE_2D, GL_TEXTURE_CUBE_MAP.
But GL_TEXTURE_3D and texture borders not supported yet.
2009-09-24 19:36:20 -06:00
Brian Paul
e33ea11c14 mesa: remove: unused gl_vertex_program::TnlData field 2009-09-24 19:34:19 -06:00
Ian Romanick
09af58d7ed NV fp lexer: Add UP4B and UP4UB instructions that were previously missing 2009-09-24 18:27:20 -07:00
Zack Rusin
228aa45fcb st/xorg: start working on the Xv acceleration code 2009-09-24 19:20:41 -04:00
Zack Rusin
80965fca74 st/xorg: fills are supported plussome minor clenups 2009-09-24 19:20:41 -04:00
Zack Rusin
53d2fa46e7 st/xorg: add easier way of disabling/enabling acceleration 2009-09-24 19:20:41 -04:00
Brian Paul
01249c6d56 llvmpipe: add missing __FUNCTION__ parameter to debug_printf() calls 2009-09-24 16:08:47 -06:00
Brian Paul
a665a3416e llvmpipe: increase max 3D texture size to 256 2009-09-24 16:07:45 -06:00
Brian Paul
29d27229a9 Merge branch 'mesa_7_6_branch'
Conflicts:

	src/mesa/vbo/vbo_exec_array.c
2009-09-24 16:06:21 -06:00
Pauli Nieminen
fd56bee6c4 Merge branch 'mesa_7_6_branch' 2009-09-24 20:39:16 +03:00
Brian Paul
c9f7a23ef0 Merge branch 'mesa_7_6_branch'
Conflicts:

	src/mesa/drivers/dri/r600/r700_assembler.c
	src/mesa/drivers/dri/r600/r700_chip.c
	src/mesa/drivers/dri/r600/r700_render.c
	src/mesa/drivers/dri/r600/r700_vertprog.c
	src/mesa/drivers/dri/r600/r700_vertprog.h
	src/mesa/drivers/dri/radeon/radeon_span.c
2009-09-24 11:03:16 -06:00
Brian Paul
6be2bc56af gallium/trace: casts to silence warnings 2009-09-24 10:47:42 -06:00
Brian Paul
f85816354c tgsi/sse: remove old comments 2009-09-24 10:45:36 -06:00
Brian Paul
35cd0bbfb1 tgsi/sse: implement SEQ, SGT, SLE, SNE 2009-09-24 10:45:35 -06:00
Keith Whitwell
09a23ac3c1 progs/perf: fix warnings in readpixels test 2009-09-24 16:52:14 +01:00
Keith Whitwell
d93f022936 progs/perf: fix typo in sconscript 2009-09-24 16:50:27 +01:00
Keith Whitwell
90dcfb3b47 trace: fix printf warnings 2009-09-24 16:49:40 +01:00
Keith Whitwell
d3beaf2f32 softpipe: fix compiler warnings 2009-09-24 16:49:27 +01:00
Keith Whitwell
fca7f38441 pipebuffer: fix printf warnings 2009-09-24 16:49:05 +01:00
Keith Whitwell
0c55dd8094 pipebuffer: fix warnings 2009-09-24 16:48:49 +01:00
Keith Whitwell
cd362334ad draw: fix warning 2009-09-24 16:44:58 +01:00
Keith Whitwell
6e0b56edf8 progs/perf: accept GL3.x also 2009-09-24 16:43:15 +01:00
Richard Li
5f06064b61 r600 : fix draw_prim bug: vertex fetcher setting. 2009-09-24 11:29:44 -04:00
José Fonseca
9659aa6482 softpipe: Use portable INLINE macro. 2009-09-24 15:28:55 +01:00
José Fonseca
e8e6d8853d softpipe: Update SConscript. 2009-09-24 15:28:54 +01:00
Richard Li
41c5f113b5 r600 : disable draw_prim for now. 2009-09-24 10:15:19 -04:00
José Fonseca
86962d6f6e gdi: Update for WGL state tracker interface changes. 2009-09-24 13:12:51 +01:00
José Fonseca
4e5ed05b02 wgl: DWM integration. 2009-09-24 13:12:51 +01:00
José Fonseca
9ea277ba7a scons: Don't require -liberty on MinGW.
Not always present.
2009-09-24 13:12:50 +01:00
José Fonseca
622bdecabd mesa: Fix missing finite symbol error on Windows.
Caused by some weird logic regarding the __WIN32__ define which made
the finite definition dependent on the header include order.
2009-09-24 13:12:50 +01:00
Michal Krol
92e33569f3 glsl/pp: Add forward decls to silence gcc warnings. 2009-09-24 10:57:55 +02:00
Michal Krol
69fec23251 glsl/pp: Avoid using `__VERSION__' as an identifier. 2009-09-24 10:57:32 +02:00
Michal Krol
7a95a3c7c4 glsl/pp: Include missing headers. 2009-09-24 10:56:46 +02:00
Michal Krol
e1eed56702 glsl/pp: Allow builds on all platforms. 2009-09-24 10:56:01 +02:00
Michal Krol
e8e3fe15e1 glsl/apps: Include missing header, properly escape format strings. 2009-09-24 10:55:37 +02:00
Michal Krol
db097a9a3f glsl/apps: Allow builds on all platforms. 2009-09-24 10:54:56 +02:00
Michal Krol
a58360dbc2 glsl/pp: Use struct instead of union. 2009-09-24 09:04:15 +02:00
Michal Krol
13f9a39cea glsl/apps: Fix apps after pp interface changes. 2009-09-24 08:43:54 +02:00
Michal Krol
9a1447d449 glsl/pp: Store both line number and file index in a single token. 2009-09-24 08:43:05 +02:00
Alex Deucher
1bf0651d9b r600: fix up ordering of functions in draw prims path
Shaders and IB need to be updated and allocated before
calling validatebuffers.
2009-09-23 19:42:07 -04:00
Alex Deucher
20e7738293 r600: fix r700PredictRenderSize for draw prims path 2009-09-23 16:54:12 -04:00
Richard Li
8a2b0f6415 r600 : add hw index buffer draw support. 2009-09-23 16:16:11 -04:00
Brian Paul
fa0816b17c progs/perf: added glReadPixels benchmark 2009-09-23 14:05:05 -06:00
Brian Paul
489f8bc86f progs/perf: also request a stencil buffer 2009-09-23 14:05:05 -06:00
Adam Jackson
8abe77a75a Finish removing glcore 2009-09-23 15:22:19 -04:00
Alex Deucher
53051b8cb5 r600: fix copy/paste typo 2009-09-23 15:02:19 -04:00
Alex Deucher
ec205bbd57 r600: fix some warnings 2009-09-23 14:58:46 -04:00
Andre Maasikas
2d2f49c919 r600: add support for CUBE textures, also TXP
seems to work here ...
2009-09-23 14:58:46 -04:00
Michal Krol
a0549f6634 progs/perf: Actually bind the newly created vbo. 2009-09-23 20:24:35 +02:00
Brian Paul
35af3f94a3 llvmpipe: move tile cache datatypes into .c file since they're private 2009-09-23 11:53:12 -06:00
Brian Paul
b4a40d1052 softpipe: replace macros with inline functions
And update comments.
2009-09-23 11:51:52 -06:00
Brian Paul
e2329f2795 softpipe: white-space/formatting fixes and updated comments 2009-09-23 11:35:33 -06:00
Brian Paul
5244ce786a llvmpipe: added max texture/surface size sanity check
Carried over from softpipe driver.
2009-09-23 11:05:00 -06:00
Brian Paul
b26f1df920 llvmpipe: increase MAX_WIDTH/HEIGHT to match max texture size 2009-09-23 11:04:07 -06:00
Brian Paul
de25f82067 Merge branch 'mesa_7_6_branch'
Conflicts:

	src/gallium/drivers/softpipe/sp_tile_cache.c
2009-09-23 11:00:04 -06:00
Keith Whitwell
890679d432 Merge branch 'softpipe-opt'
Conflicts:
	progs/demos/cubemap.c
	src/gallium/drivers/softpipe/sp_tex_sample.c
	src/gallium/drivers/softpipe/sp_texture.c
2009-09-23 17:37:28 +01:00
Keith Whitwell
a1fa770c01 gallium/include: update some comments 2009-09-23 17:04:48 +01:00
Zack Rusin
1ddb217d8e st/xorg: fix a typo
it'd be too easy, eh
2009-09-23 12:05:13 -04:00
Zack Rusin
5a7f708530 st/xorg: keep the user buffer contents around
Michel noticed that they were getting out of scope
2009-09-23 12:03:35 -04:00
Brian Paul
aae77319c0 progs/perf: set TexSubImage4=FALSE 2009-09-23 08:06:37 -06:00
José Fonseca
31f1571d1f wgl: Eliminate the shared layer; implement WGL API on top of the ICD callbacks.
While the WGL API has been stale for decades now, the ICD interface has
been updated with new Windows versions, so it is much easier to define
everything in terms of the ICD interfaces, which is pretty much what
Microsoft's opengl32.dll does anyway.
2009-09-23 10:32:52 +01:00
José Fonseca
f8c11526c0 gdi: Update for WGL statetracker source reorg. 2009-09-23 10:32:51 +01:00
José Fonseca
f724036f00 wgl: Flatten the source tree.
It is easier to have the WGL API on top of the ICD callbacks as
Microsoft's own implementation does, than to have a seperate shared
entity. This source reorganization is in antecipation of that.
2009-09-23 10:32:51 +01:00
José Fonseca
8d1af5991d wgl: Fix debug_printf format specifiers. 2009-09-23 10:32:51 +01:00
José Fonseca
21a949365d gallium: Update vendor string. 2009-09-23 10:32:50 +01:00
Michal Krol
8212e4d9fa grammar: Include the correct glsl pp header. 2009-09-23 09:40:40 +02:00
Michal Krol
1ed1dc8b41 glsl/pp: Include missing headers. 2009-09-23 09:40:24 +02:00
Michal Krol
2f89e1a5a1 glsl/pp: Add 0' and 1' to dictionary. 2009-09-23 09:37:37 +02:00
Michal Krol
32966991c6 glsl/pp: Check for reserved macro names. 2009-09-23 09:33:12 +02:00
root
75276ea316 softpipe: fix bugs in POT texture sampling when texture is not square
Before, if level was greater than the logbase2(base size) we were
doing a negative bit shift and winding up with garbage values.
2009-09-22 20:14:10 -06:00
Brian Paul
5dbedf3d7e softpipe: additional assertions 2009-09-22 16:59:28 -06:00
Brian Paul
0670df5cb2 softpipe: disable a _debug_printf() 2009-09-22 16:42:15 -06:00
Brian Paul
02f2bcdf1d Merge branch 'mesa_7_6_branch' 2009-09-22 16:06:18 -06:00
Brian Paul
d04fa73cec progs/perf: added glCopyTex[Sub]Image2D test 2009-09-22 15:39:05 -06:00
Richard Li
98d5ec10d0 r600 : add draw_prim support, make up one lost change. 2009-09-22 17:26:23 -04:00
Richard Li
81283b0bf0 r600 : add draw_prim support. 2009-09-22 17:04:49 -04:00
Keith Whitwell
fe9ca0f718 softpipe: need to write depth/stencil values even when stencil fails 2009-09-22 20:47:37 +01:00
Keith Whitwell
207764894b softpipe: set quad->facing value 2009-09-22 20:47:07 +01:00
Keith Whitwell
b1139e9ad8 softpipe: fix polygon stipple 2009-09-22 19:38:34 +01:00
Brian Paul
da0e4e557b progs/perf: test glGetTexImage() also 2009-09-22 12:26:12 -06:00
Keith Whitwell
b626176f06 softpipe: fix occlusion counting 2009-09-22 19:26:08 +01:00
Jakob Bornecrantz
bade906ed1 st/xorg: Fix two leeks
We where leaking both surfaces in the composit code
	and textures from pixmaps.
2009-09-22 11:06:57 -07:00
Jakob Bornecrantz
19798e17fe i915g: Activate trace 2009-09-22 11:06:57 -07:00
Jakob Bornecrantz
e369294f76 i915g: Do propper references of surfaces in context 2009-09-22 11:06:56 -07:00
Brian Paul
67d7021ae0 progs/perf: add missing texture enable in fbobind.c 2009-09-22 11:15:11 -06:00
Brian Paul
ed113da12e progs/perf: added fbobind.c test to test FBO binding speed 2009-09-22 11:15:11 -06:00
Brian Paul
cfb0f2489d progs/perf: added PerfExtensionSupported() helper 2009-09-22 11:15:11 -06:00
Keith Whitwell
0ec26cce36 teximage: add more tests, image formats
Add a test which creates a new texture from scratch before uploading.
Add more image formats.
Don't run all tests on all image formats.
2009-09-22 18:00:11 +01:00
Brian Paul
bae2d58827 progs/perf: add another VBO test for Create/Draw/Destroy pattern
Report both MB/sec and draw/sec.
2009-09-22 09:53:35 -06:00
Brian Paul
7e5004b298 progs/perf: simplify the code 2009-09-22 09:43:08 -06:00
Brian Paul
aa80851e16 progs/perf: fix comment 2009-09-22 09:29:27 -06:00
Brian Paul
32979ae15f progs/perf: updated comments 2009-09-22 07:50:12 -06:00
Keith Whitwell
6a09c9d2d8 progs/perf: make teximage results easier to read, more reproducible
Always run the same tests on different drivers, give zero results
where test image is too big for driver.

Add a newline between groups of tests.
2009-09-22 12:35:56 +01:00
Keith Whitwell
89f2799dac progs/perf: reset row_length after subimage test
Also test fewer sizes in teximage generally.
2009-09-22 11:58:09 +01:00
Michal Krol
b1e6514a94 slang: Differentiate between uints and floats. 2009-09-22 12:54:45 +02:00
Michal Krol
cd41395073 grammar: Differentiate between uints and floats. 2009-09-22 12:52:53 +02:00
Michal Krol
125691dda3 glsl/apps: Update after recent pp interface changes. 2009-09-22 12:52:21 +02:00
Michal Krol
0481e85af7 glsl/pp: Differentiate between integer and floating-point number tokens. 2009-09-22 12:51:08 +02:00
Keith Whitwell
bf014d03fe progs/perf: clean up swapbuffers test a bit 2009-09-22 11:27:18 +01:00
Keith Whitwell
ac6a5107e2 progs/perf: break up long runs of fullscreen quads
Not all drivers cope gracefully with command-buffers with zillions of
fullscreen quads.
2009-09-22 11:21:10 +01:00
Keith Whitwell
a7b2659f02 progs/perf: add first attempt at a swapbuffers rate test
This is pretty ugly as the original framework assumed you'd set
a single window size at startup and keep it throughout, but for
swapbuffers you want to test the rate at various window sizes.

With luck a nicer solution can be found, but this at least lays out
a marker.
2009-09-22 11:21:09 +01:00
Brian Paul
94a020cfe6 vbo: added comment about max array index 2009-09-21 16:54:35 -06:00
Brian Paul
9a3333f436 vbo: restore some lost warning output 2009-09-21 16:51:34 -06:00
Brian Paul
972e995b14 vbo: disable the GL_ARB_draw_elements_base_vertex rebase path
This was introduced with commit 92d7ed8a20.
It causes rendering of stray polygons (with sw rendering at least) when
running the OGL Distilled / Picking demo (click on an object).

This needs additional debugging to fix/restore.

Found one suspect thing: in _tnl_draw_prims() there's some mixed signed/
unsigned arithmetic/comparing at line 422 that may be incorrect.
2009-09-21 16:10:50 -06:00
Adam Jackson
83019ffc07 selinux: Fix mmap() return value check 2009-09-21 17:04:22 -04:00
Brian Paul
40603526f4 mesa: refine the error checking vbo_exec_DrawRangeElements()
If the 'end' index is out of bounds issue a warning as before.  But instead
of just no-op'ing the draw call, examine the actual array indices to see
if they're OK.  If the max array index is out of bounds, issue another
warning and no-op the draw call.  Otherwise, draw normally.  This is a
debug build-only feature since it could impact performance.

This "fixes" the missing torus in the OGL Distilled / Picking demo.
2009-09-21 14:56:58 -06:00
Brian Paul
e5d29ebb5e mesa: make max_buffer_index() a non-static function 2009-09-21 14:56:40 -06:00
Maciej Cencora
4916a5a2e7 radeon: update buffer map/unmap code for changes introduced in 92033a9516 and 822c796481 2009-09-21 14:56:11 -06:00
Maciej Cencora
d100cbf721 mesa: add some debug info to teximage.c 2009-09-21 14:56:11 -06:00
Maciej Cencora
b1c9c5a800 r300: fix a typo 2009-09-21 14:56:11 -06:00
Brian Paul
d504a7669d swrast: fix cube face selection
If arx and ary are equal, we still want to choose from one of them,
and not arz.

This is the same as Michal's softpipe fix.
2009-09-21 14:56:10 -06:00
Alex Deucher
c63e78b3e5 r600: fix typo in the last commit
128 gprs, 256 reg-based consts
2009-09-21 16:48:55 -04:00
Alex Deucher
1869bdabba r600: various cleanups
- max texture size is 8k, but mesa doesn't support
that at the moment.
- attempt to set shader limits to what the hw actually
supports
- clean up some old r300 cruft
- no need to explicitly disable irqs.  This is fixed
in the drm now.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
2009-09-21 16:33:11 -04:00
José Fonseca
734a498ed4 mesa: Ensure TGSI tokens are freed with gallium's free.
To avoid breaking the gallium's builtin malloc debugging.
2009-09-21 20:12:03 +01:00
Brian Paul
9297e6968a progs/perf: added fill-rate test
Many more fill modes could be tested, but this hits the basics including
blending, texturing and shaders.
2009-09-21 12:17:49 -06:00
Brian Paul
05bce08980 progs/perf: added helpers for creating simple textures and shader programs 2009-09-21 11:58:03 -06:00
Brian Paul
83fbee6e0b progs/perf: offsetof() should be defined in stddef.h, include it
If this breaks mingw, feel free to revert this.
2009-09-21 11:09:47 -06:00
Nicolai Hähnle
9ca94f91a3 r300g: Fix bad formatting parameters in calls to debug_printf
Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-09-21 17:41:54 +02:00
Nicolai Hähnle
496137d8eb gallium debug: Add gcc printf hint to debug_printf
This causes gcc to issue warnings when format parameters do not match up
with the format string in calls to debug_printf.

Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-09-21 17:41:54 +02:00
Keith Whitwell
7ce0421fb7 progs/perf: a few more vbo upload modes
Some tests, eg small SubData are probably overwhelmed by the cost of
performing the draw after each upload.  Add a varient which does a lot
of subdata uploads and then a single draw.

Also try to avoid cache-artifacts in the upload timings.
2009-09-21 15:57:14 +01:00
Keith Whitwell
25a580c841 progs/perf: human-readable drawoverhead output 2009-09-21 15:57:14 +01:00
Keith Whitwell
6ab7c127f7 progs/perf: human-format vertexrate output 2009-09-21 15:57:14 +01:00
Keith Whitwell
ed63bd62d8 progs/perf: add human-readable float formatter 2009-09-21 15:57:13 +01:00
Vinson Lee
d17af7d1e1 progs/glsl: Include local headers before installed headers during compilation.
Fixes compilation errors on platforms with insufficient older installed
GL headers.
2009-09-21 08:44:56 -06:00
Andre Maasikas
2d729e6e3b r600: fix some issues with LIT instruction
- MUL_LIT is ALU.Trans instruction
- some Trans instructions can take 3 arguments
- don't clobber dst.x, use dst.z as temp, it'll get written correct
  value in last insn
- respect source swizzles
2009-09-21 10:14:25 -04:00
Nicolai Hähnle
81c7561d9d Merge branch 'master' into r300-compiler
There were additional non-textual conflicts.

Conflicts:
	src/gallium/drivers/r300/r300_tgsi_to_rc.c
	src/mesa/drivers/dri/r300/compiler/r3xx_vertprog.c
	src/mesa/drivers/dri/r300/compiler/radeon_program.c
	src/mesa/drivers/dri/r300/compiler/radeon_program_alu.c
2009-09-21 13:26:50 +02:00
Nicolai Hähnle
3083ba38f4 Merge branch 'mesa_7_6_branch' 2009-09-21 13:08:34 +02:00
Michel Dänzer
c67bb22fe7 Merge branch 'mesa_7_6_branch' 2009-09-21 10:48:32 +02:00
Ben Skeggs
774db70506 nouveau: allow building modesetting_drv.so 2009-09-21 14:51:39 +10:00
Ben Skeggs
344e2fd1f2 nouveau: drm_api create_screen()'s 'arg' argument can be NULL 2009-09-21 14:46:50 +10:00
Brian Paul
e3384a0d53 windows: call _mesa_meta_init/free() 2009-09-20 22:19:28 -06:00
Brian Paul
2c1937480a xlib: always call _mesa_meta_init/free() 2009-09-20 22:19:06 -06:00
Brian Paul
4a4914e414 dri/swrast: call _mesa_meta_init/free() 2009-09-20 22:13:28 -06:00
Brian Paul
1741bc1a79 osmesa: call _mesa_meta_init/free() 2009-09-20 22:13:09 -06:00
Brian Paul
a1cf9b6abe Revert "st/mesa: Compile in meta.c."
This reverts commit 6c5726cd39.
2009-09-20 22:08:30 -06:00
Brian Paul
1eda10d073 Revert "scons: add meta.c to sources"
This reverts commit 41fefe88c5.
2009-09-20 22:08:21 -06:00
Brian Paul
da9d8f1924 Revert "mesa: move _mesa_meta_init/free() calls to core Mesa"
This reverts commit 651cffd626.

The commit inadvertantly introduced a new gallium dependency on the meta code.
2009-09-20 22:06:03 -06:00
Brian Paul
41fefe88c5 scons: add meta.c to sources 2009-09-20 21:31:45 -06:00
Chia-I Wu
6c5726cd39 st/mesa: Compile in meta.c.
meta was moved to core Mesa since
651cffd626.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-09-20 21:31:45 -06:00
Chia-I Wu
81bac6e2a8 intel: meta clear has a new name.
It was renamed to _mesa_meta_Clear.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
2009-09-20 21:31:45 -06:00
Dave Airlie
e9d6ab72be xorg/st: fixup builds against later dpms headers. 2009-09-21 13:26:48 +10:00
José Fonseca
1a9eec84bd scons: Drop gprof support for profile builds; tweak optimization flags instead.
gprof is useful for shared libraries, hence our drivers. Nevertheless
profilers like oprofile can benefit from disabling some relatively
minor optimizations for more accurate / complete results.
2009-09-20 18:09:34 +01:00
José Fonseca
911a7a82cd llvmpipe: Fix lp_get_cached_tile.
Align coordinates to tile boundaries.
2009-09-20 18:09:34 +01:00
José Fonseca
76c2e34b22 llvmpipe: Update tile status on flush. 2009-09-20 18:09:34 +01:00
Brian Paul
ebf2710b2f Merge branch 'mesa_7_6_branch'
Conflicts:
	src/mesa/drivers/dri/intel/intel_clear.c
2009-09-20 10:36:45 -06:00
Brian Paul
ed4076b5b8 mesa: remove redundant readbuffer check 2009-09-19 17:26:14 -06:00
Brian Paul
4de8e2123e mesa: rename functions to be more consistant with rest of mesa 2009-09-19 17:06:15 -06:00
Brian Paul
232fc7d333 swrast: remove obsolete s_imaging.c file 2009-09-19 16:43:18 -06:00
Brian Paul
7e0f2ce941 swrast: remove prototypes for obsolete functions 2009-09-19 16:43:17 -06:00
Brian Paul
58e843dda0 mesa: remove s_imaging.c from build 2009-09-19 16:43:17 -06:00
Brian Paul
32e4b6c607 windows: replace old ColorTable, Convolution functions with new 2009-09-19 16:43:17 -06:00
Brian Paul
bc1c8d4af7 mesa: use new meta functions 2009-09-19 16:43:17 -06:00
Brian Paul
3e5a35269b mesa: meta functions for glCopyColorTable, glCopyConvolutionFilter, etc 2009-09-19 16:43:17 -06:00
Brian Paul
dc3839ef3d mesa: move readbuffer tests 2009-09-19 16:43:17 -06:00
Brian Paul
883dd9d770 mesa: use _mesa_get_current_tex_unit() helper 2009-09-19 16:43:17 -06:00
Brian Paul
3ed9dab19c mesa: use _mesa_get_current_tex_unit() helper 2009-09-19 16:43:16 -06:00
Brian Paul
b0e9ea6084 mesa: fix some glCopyTex[Sub]Image regressions related to convolution 2009-09-19 16:43:16 -06:00
Brian Paul
651cffd626 mesa: move _mesa_meta_init/free() calls to core Mesa 2009-09-19 16:43:16 -06:00
Alex Deucher
b8477f079b r600: fix point sizes
registers takes radius
2009-09-19 15:18:42 -04:00
Alex Deucher
368fb578f8 r600: fix polygon offset 2009-09-19 14:48:44 -04:00
Brian Paul
67cad78e08 swrast: remove obsolete s_texstore.c
Replaced by new, simpler meta functions.
2009-09-19 11:09:25 -06:00
Brian Paul
2f89044e6f swrast: remove prototypes for obsolete functions 2009-09-19 11:08:49 -06:00
Brian Paul
14869c0984 mesa: remove s_texstore.c from makefile/project files 2009-09-19 11:08:20 -06:00
Brian Paul
a9c64daf02 glapi: replace old TexCopy functions w/ new 2009-09-19 11:05:54 -06:00
Brian Paul
41a171b714 windows: replace old TexCopy functions w/ new 2009-09-19 11:03:33 -06:00
Brian Paul
e2e0735e0e gldirect: remove refs to soon-to-be-obsolete functions
I don't know if this driver is anywhere near build-able, but anyway.
2009-09-19 11:01:27 -06:00
Brian Paul
6f9dbe7739 mesa: use new _mesa_meta_CopyTex[Sub]Image() functions 2009-09-19 10:58:11 -06:00
Brian Paul
af69346446 intel: use new _mesa_meta_CopyTex[Sub]Image() functions 2009-09-19 10:58:07 -06:00
Brian Paul
22f02509f2 glapi: regenerated files 2009-09-19 10:00:55 -06:00
Brian Paul
c9a87ff441 glapi: added tokens, function for GL_ARB_provoking_vertex 2009-09-19 10:00:19 -06:00
Michal Krol
18d0f9a7a3 llvmpipe: Respect input interpolators for the shader.
Cherry-picked from fb2c7b6743
2009-09-19 14:57:24 +01:00
José Fonseca
fdd605e446 mesa: Allow BlitFramebuffer from a texture.
Although GL_EXT_framebuffer_blit does not mention textures, it doesn't
forbid them either, and some thirdparty driver appear to support this.
2009-09-19 14:33:35 +01:00
Michal Krol
de685b37a9 softpipe: Fix cube face selection.
If arx and ary are equal, we still want to choose from one of them,
and not arz.
2009-09-18 14:36:59 +01:00
Michal Krol
bb32b0908f progs/perf: Fix newlines. 2009-09-18 11:42:30 +02:00
Michal Krol
5f9f30a752 glsl/apps: Use glsl pp public interface. 2009-09-18 11:20:42 +02:00
Michal Krol
8302208b02 slang: Use glsl pp public interface. 2009-09-18 11:19:54 +02:00
Michal Krol
95956bb8cb glsl/pp: Define a public interface for external modules.
Make sl_pp_context struct opaque.
Move all public declarations to sl_pp_public.h.
2009-09-18 11:19:25 +02:00
Michal Krol
fb2c7b6743 softpipe: Respect input interpolators for the shader. 2009-09-17 16:06:11 +01:00
Michal Krol
5f0b49e7a9 tgsi: Scan input interpolators, too. 2009-09-17 16:06:09 +01:00
Keith Whitwell
2884c31d94 progs/perf: convert some DOS line-endings
It seems like some of these files were committed with CRLF initially.
2009-09-17 12:09:16 +01:00
Keith Whitwell
e95a3a23dc progs/perf: add scons support, get working under mingw 2009-09-17 12:08:04 +01:00
Michal Krol
2a661c383f Merge commit 'origin/master' into glsl-pp-rework-2
Conflicts:
	src/gallium/winsys/gdi/SConscript
2009-09-17 12:44:24 +02:00
Michal Krol
90daefd1c4 glsl/pp: Add a TODO for FEATURE_es2_glsl. 2009-09-17 12:33:26 +02:00
Michal Krol
4fcda5000e slang/pp: Fix file number parsing. 2009-09-17 12:14:12 +02:00
Michal Krol
ce8f486156 slang/pp: Use a dictionary for the remaining string literals. 2009-09-17 12:12:34 +02:00
Michal Krol
0ddf41d34d glsl/pp: Add remaining error messages. 2009-09-17 11:51:35 +02:00
Michal Krol
69bdd47dba glsl/apps: Always write out error condition. 2009-09-17 10:45:16 +02:00
Brian Paul
21caa29fbd mesa: begin some texstore code refactoring
Next step will be to move the calls to ctx->Driver.ChooseTextureFormat()
into the teximage.c functions so drivers don't have to do it.
2009-09-16 21:50:04 -06:00
Brian Paul
1d8fbef4f2 mesa: meta driver functions for glCopyTex[Sub]Image()
Implement in terms of glReadPixels + glTex[Sub]Image().
This will allow us to get rid of some swrast texture code.
2009-09-16 20:09:07 -06:00
Brian Paul
9abbedad09 progs/perf: initial set of simple performance test programs
Initial tests include:
  drawoverhead - measure overhead of state changes w.r.t drawing commands
  teximage - measure glTexImage2D() and glTexSubImage2D() speed
  vbo - measure glBufferData() and glBufferSubData() speed
  vertexrate - measure vertex rate for immediate mode, glDrawArrays, VBOs, etc.
2009-09-16 19:33:01 -06:00
Brian Paul
4df2f7af5e progs/glsl: minor Makefile clean-ups 2009-09-16 19:28:55 -06:00
Brian Paul
8d47b4906b swrast: remove mipmap generation checks (done in core Mesa now) 2009-09-16 19:28:55 -06:00
Brian Paul
4e84b96d92 s3v: remove unneeded initializations 2009-09-16 19:28:54 -06:00
Brian Paul
1b1125c239 ffb: remove disabled code 2009-09-16 19:28:54 -06:00
Michal Krol
cc629940d4 glsl/apps: Always write out error condition. 2009-09-16 22:04:22 +02:00
Michal Krol
a7382628f2 glsl/pp: Validate numbers. 2009-09-16 21:51:12 +02:00
José Fonseca
f911d196cf llvmpipe: Don't assert due to unsupported texture wrap modes.
Issue a warning and fallback to clamping.
2009-09-16 20:42:09 +01:00
Michal Krol
de0753e4cb glsl/pp: Add more error messages. 2009-09-16 20:40:02 +02:00
Michal Krol
c9de313f1b slang: Propagate error messages from preprocessor. 2009-09-16 20:28:20 +02:00
Michal Krol
d4638f5dce glsl/pp: Add more error messages. 2009-09-16 20:27:59 +02:00
Michal Krol
eeb5202e5d slang: Invoke the preprocessor from withing the slang compiler.
This allows us to validate the shader version number.
2009-09-16 19:24:50 +02:00
Ian Romanick
5ce72c559c Merge branch 'mesa_7_6_branch' 2009-09-16 08:05:36 -07:00
Brian Paul
aabcc6cb23 gallium: remove incorrect 'return' stmt 2009-09-16 08:59:32 -06:00
José Fonseca
c29905aa31 gallium: Deprecate PIPE_CAP_S3TC.
No longer used. S3TC support is queried via
pipe_screen::is_format_supported.
2009-09-16 14:33:52 +01:00
Michal Krol
ec48396e0f softpipe: Do not advertise Z32_UNORM as a supported format. 2009-09-16 13:56:58 +01:00
José Fonseca
b60e1d7630 gdi: Integrate with llvmpipe where available. 2009-09-16 11:35:23 +01:00
José Fonseca
459ea0095c llvmpipe: Make the code portable for MinGW. 2009-09-16 11:35:23 +01:00
Dave Airlie
858a2a2ac7 radeon: cleanup compile defines mess.
I inherited this and really it stayed around far too long,
make it nice and simple.
2009-09-16 13:48:45 +10:00
Dave Airlie
a6a21eb00d radeon: oops remove debugging left on in previous patch 2009-09-16 13:25:02 +10:00
Dave Airlie
2fdb0e5d3b radeon: use txformat to decide to emit rect tex state.
This is more logical, and fixes a TFP issue.
2009-09-16 13:13:43 +10:00
Brian Paul
2914f2b7fd mesa: move generate mipmap calls
Per the suggestion in the Intel driver, move the calls to
ctx->Driver.GenerateMipmap() into core Mesa so that drivers don't
have to worry about it.
2009-09-15 18:17:43 -06:00
Brian Paul
ef6ee07fc7 mesa: minor clean-up 2009-09-15 18:17:43 -06:00
Brian Paul
a31ac84d74 mesa: remove last of gotos 2009-09-15 18:17:43 -06:00
Brian Paul
c352566933 mesa: more goto removal 2009-09-15 18:17:43 -06:00
Brian Paul
ecf6f37fc2 mesa: remove some gotos
This will make some subsequent changes easier...
2009-09-15 18:17:42 -06:00
Brian Paul
c26c2006df mesa: clean-up fbo debug code 2009-09-15 18:17:42 -06:00
Brian Paul
0b0fc4072f progs/demos: use non-default texobj in cubemap.c 2009-09-15 18:17:42 -06:00
Brian Paul
7f86da6c60 progs/demos: create a texture object in lodbias.c
Before, we were using the default texture object (name=0).  This caused
the intel_generate_mipmap() path to fail since passing texture=0 to
glFramebufferTexture2DEXT() causes us to _unbind_ the texture if present.
2009-09-15 18:17:42 -06:00
Zack Rusin
a016043386 st/xorg: fixing copies and composite shaders
copies were busted when src == dst. also the composite shaders
were incorrectly using the fragments instead of the texture coordinate.
2009-09-15 19:50:36 -04:00
Zack Rusin
8adcad0c70 st/xorg: lots of fixes
fixes blending binding and copy coordinates
2009-09-15 19:50:34 -04:00
Brian Paul
f9574e05c2 docs: GL_ARB_provoking_vertex 2009-09-15 16:01:51 -06:00
Brian Paul
2e7a1dd8ca mesa: added GL_ARB_provoking_vertex (same as EXT version) 2009-09-15 16:01:51 -06:00
Alex Deucher
87d40a95bf radeon: don't build non-r600 span code on r600 2009-09-15 17:13:08 -04:00
Alex Deucher
49fc41eeed r600: minor span cleanups 2009-09-15 17:13:08 -04:00
Ian Romanick
ac4e23d784 Merge branch 'mesa_7_6_branch' 2009-09-15 13:14:38 -07:00
Zack Rusin
f1ce6b09cd st/xorg: Brian suggested that those could be mad's
optimizes the common paths
2009-09-15 15:21:42 -04:00
Brian Paul
b0c52e491d mesa: remove incorrect texture state check
Fixes incorrectly textured bitmap text in engine demo.
It's incorrect to test the texture enable bits here since they may have
been changed by disabling the shader above.  Optimization is still possible
but will have to be reexamined.
2009-09-15 12:36:55 -06:00
Maarten Maathuis
26860a6e2f nv50: avoid excessive FIRE_RING
- And reduce RING_SPACE to 2, instead of 3.
2009-09-15 18:59:53 +02:00
Maarten Maathuis
db37279e0b nv50: use flush_notify to reduce number of relocs 2009-09-15 18:59:53 +02:00
Michel Dänzer
0469465c31 st/xorg: Only unreference texture on pixmap destruction, don't destroy it.
Fixes memory corruption if e.g. the driver still has references to the texture.
2009-09-15 18:31:07 +02:00
Michel Dänzer
45cf2696ca st/xorg: Explicitly check whether the driver supports the pixmap formats.
Rather than arbitrarily checking for pixmap depth < 15.
2009-09-15 18:30:58 +02:00
Michel Dänzer
be94a1d3bc st/xorg: Use A8 format for depth 8 pixmaps.
The inconsistent bpp caused issues with UploadTo/DownloadFromScreen.
2009-09-15 18:23:00 +02:00
Brian Paul
be0cdd77ea st/mesa: disable accidentally committed _mesa_print_program() call 2009-09-15 09:52:27 -06:00
Brian Paul
41bbc83951 Merge branch 'mesa_7_6_branch' 2009-09-15 09:47:35 -06:00
Brian Paul
c0cf9dc05e ARB prog parser: regenerated file 2009-09-15 09:40:26 -06:00
Brian Paul
2aad3a855b ARB prog parser: more detailed error message for out of bounds ADDR offsets 2009-09-15 09:40:25 -06:00
Andre Maasikas
5ef40337ab r600: support position_invariant programs 2009-09-15 11:27:51 -04:00
José Fonseca
a18301790c gallium: Use the enum for pipe_transfer::usage. 2009-09-15 16:02:55 +01:00
José Fonseca
cb5f1bce23 gallium: pipe_transfer_destroy helper inline. 2009-09-15 16:02:54 +01:00
Christoph Bumiller
d3a9cf54c0 nv50: fix stupid thinko in emit_set
When swapping sources 0 and 1, EQ of course does *not*
become NE, etc.

Introduced in 2b963f5c72.
2009-09-15 15:37:10 +02:00
Michal Krol
7aee53002c gallium: Fix pointer type casts. 2009-09-15 12:00:27 +01:00
Christoph Bumiller
750c6cae3d nv50: let programs use the whole param buffer
Allocation is unnecessary since all uniforms are
uploaded on every constant buffer change anyway.
2009-09-15 12:13:23 +02:00
Christoph Bumiller
01670ca807 nv50: add preliminary support for point sprites 2009-09-15 12:13:23 +02:00
Christoph Bumiller
06dac41cc5 nv50: add support for point size per vertex 2009-09-15 12:13:23 +02:00
Christoph Bumiller
4d7b4781c8 nv50: add support for light-twoside 2009-09-15 12:13:23 +02:00
Christoph Bumiller
6516594c8e nv50: proper linkage between VP and FP
This moves construction of the mapping between VP outputs
and FP inputs into validation.

The map also contains slots for special outputs like clip
distance and point size, so we need to at least merge the
VP related and FP related parts on validation if we want
to support those.

Now we match every single FP input component with results
from the VP and leave those not read out of the map, or
replace those not written by 0 (xyz) or 1 (w).
The bitmap indicating linear interpolants is also filled,
and flat FP inputs are mapped in only after non-flat ones,
as is required.

Furthermore, we can save some space by only fetching VP
attrs we actually use, and avoid wasting any output regs
because of TGSI using less than 4 components.
2009-09-15 12:13:23 +02:00
Christoph Bumiller
38849c529e nv50: move allocation of pc regs
Make use of tgsi_shader_info to determine how many nv50_regs we
need to allocate, whether program uses KIL, or writes DEPR.
2009-09-15 12:13:23 +02:00
Christoph Bumiller
e0951797cb nv50: nicer initialization of nv50_regs 2009-09-15 12:13:23 +02:00
Christoph Bumiller
849885c7a6 nv50: handle CEIL and TRUNC opcodes 2009-09-15 12:13:23 +02:00
Christoph Bumiller
2b963f5c72 nv50: handle SEQ, SGT, SLE, SNE opcodes 2009-09-15 12:13:23 +02:00
Christoph Bumiller
e774b3c0f2 nv50: SIN and COS use src0.w for dst.w 2009-09-15 12:13:22 +02:00
Christoph Bumiller
81de711fc8 nv50: use broadcast TEMP reg in tx_insn
Makes some opcode cases nicer and might reduce the total
nr of TEMPs required, or save some MOVs.
2009-09-15 12:13:22 +02:00
Christoph Bumiller
234d82ed63 nv50: add nv50_tgsi_insn to handle swizzles safely 2009-09-15 12:13:22 +02:00
Christoph Bumiller
2da8608ad7 nv50: add functions for swizzle resolution
We're going to try to reorder the scalar ops of a vector instr
to accomodate swizzles that would otherwise require us to emit
to an additional TEMP first (like MOV R0.xy, R0.zx).
2009-09-15 12:13:22 +02:00
Christoph Bumiller
5d141b3e3e nv50: extend insn src mask function
Extend its usage to avoiding e.g. emission of negation
instructions in tx_insn for sources we don't need.
2009-09-15 12:13:22 +02:00
Cooper Yuan
287f0072d2 st/g3dvl: pass color values to softpipe clear function 2009-09-15 15:25:47 +08:00
Cooper Yuan
2ef8c60e55 xvmc: Generate new resource ID in _XIDHandler, otherwise it's invalid. 2009-09-15 13:16:56 +08:00
Zack Rusin
ef77462171 st/xorg: add some debugging helpers 2009-09-14 19:03:28 -04:00
Alex Deucher
364ca57aff r600: add span support for 1D tiles
1D tile span support for depth/stencil/color/textures

Z and stencil buffers are always tiled, so this fixes
sw access to Z and stencil buffers.  color and textures
are currently linear, but this adds span support when we
implement 1D tiling.

This fixes the text in progs/demos/engine and progs/tests/z*
2009-09-14 18:10:24 -04:00
Alex Deucher
f662cedae4 r600: fix warning
Noticed by rnoland on IRC.
2009-09-14 18:10:24 -04:00
Brian Paul
909ab3377f st/mesa: minor whitespace, comment clean-ups 2009-09-14 16:01:27 -06:00
Brian Paul
5a87a25a65 st/xorg: fix ureg_DECL_constant() parameters
This fixes the compilation errors reported in bug 23945 but someone more
familiar with the code should review for correctness and close the bug
report.
2009-09-14 15:47:13 -06:00
José Fonseca
d3f5a2e5ab scons: Allow to use only the WINDDK headers. 2009-09-14 20:12:02 +01:00
José Fonseca
a4a4553a80 scons: Allow to use MS's DXSDK headers with MinGW. 2009-09-14 20:12:01 +01:00
José Fonseca
c51bd94a14 gallium: Add pipe_transfer_map/unmap inlines. 2009-09-14 20:12:01 +01:00
José Fonseca
88b88bba68 util: Add _BitScanForward intrinsic's declaration.
It is missing in some Microsoft DDKs.
2009-09-14 20:12:01 +01:00
Brian Paul
aa522e6cc4 intel: minor code clean-ups 2009-09-14 12:42:18 -06:00
Brian Paul
8ec456c68c intel: fix renderbuffer map/unmap regression
Commit 36dd53a3cd caused a few regressions
because the glReadBuffer() buffer wasn't getting mapped when GL_READ_BUFFER
!= GL_DRAW_BUFFER.
2009-09-14 12:42:18 -06:00
Brian Paul
3c31049439 intel: remove unneeded driver function assignments
These default swrast functions are already installed by
_mesa_init_driver_functions().
2009-09-14 12:42:18 -06:00
Brian Paul
284d3b2d9c progs/tests: exercise display lists and pixelstore 2009-09-14 12:42:17 -06:00
Keith Whitwell
d7512521fd mesa/st: remove dead comment 2009-09-14 17:11:09 +01:00
Keith Whitwell
4295b34d25 st/mesa: convert to new tgsi_ureg mechanism for shader emit
Should be easier to read and work with than the older ways of emitting
TGSI tokens.

Also, emit simpler TGSI than previously:
  - translate away source and dest extended modifiers
  - translate away the SWZ opcode
2009-09-14 17:09:15 +01:00
Michal Krol
0f302b60fd glsl/pp: Support GL_ARB_draw_buffers and GL_ARB_texture_rectangle. 2009-09-14 13:09:36 +02:00
Michal Krol
cd26ccf6fe grammar: Adapt to pp interface change. 2009-09-14 13:08:16 +02:00
Michal Krol
169aead1b5 glsl/apps: Adapt to pp interface change. 2009-09-14 13:08:07 +02:00
Michal Krol
a67f32289a glsl/pp: Add a dictionary to a context. 2009-09-14 13:07:25 +02:00
Marcin Kościelnicki
d8a191e314 nv50: Fix m2mf positions. 2009-09-14 12:12:03 +02:00
José Fonseca
b4835ea03d llvmpipe: Make lp_type a regular union.
Union not worth the hassle of violating C99 or adding a name to
the structure.
2009-09-14 11:05:38 +01:00
José Fonseca
fa150debf0 util: Fix a1r5g5b5's format description. 2009-09-14 11:05:38 +01:00
Michal Krol
9f273f1098 Merge commit 'origin/master' into glsl-pp-rework-2 2009-09-14 11:22:05 +02:00
Cooper Yuan
aad0deee4b g3dvl: update tgsi_opcode in order to build g3dvl library 2009-09-14 16:23:03 +08:00
Keith Whitwell
66a7eedaa2 tgsi: handle some src/dst aliasing in tgsi_sse2.c
Src/Dst aliasing (aka SOA dependencies) requires some care to ensure
intermediate results do not overwrite yet-to-be read source registers.

This change ensures that MOV/SWZ handle this correctly, which is poor but
no worse than the current tgsi_exec.c path.  Remove the fallback as there
is nothing to be gained correctness-wise between the two implementations now.

Fixing this properly looks like a bit of work in this code, but might be
easily achieved by sending destination writes to temporary storage.
2009-09-13 11:59:24 -07:00
José Fonseca
86226d5ea1 llvmpipe: Compute derivatives. 2009-09-13 16:22:27 +01:00
José Fonseca
4b32dd3007 llvmpipe: Remove dead references to pipe_winsys. 2009-09-13 16:13:12 +01:00
José Fonseca
5e13e987da llvmpipe: Use const keyword for input array arguments. 2009-09-13 16:12:48 +01:00
José Fonseca
faec23387e llvmpipe: Delay storing into the dst register to prevent clobbering the src registers.
How I'm thankful for regular expressions -- just a couple of them were
all that was needed to do this otherwise tiresome and bug prone change.
2009-09-13 14:42:52 +01:00
José Fonseca
873773ee2b llvmpipe: Translate more TGSI opcodes.
Basically cover all low hanging fruit, and mark the still missing opcodes
as "fixme" or deprecated.
2009-09-13 13:55:08 +01:00
José Fonseca
00dd0156e0 llvmpipe: Add a few more common arithmetic functions.
We are relying on SSE4.1 for round/trunc/ceil/floor. We'll need to
eventually find alternatives for the rest of the world.
2009-09-13 13:50:19 +01:00
José Fonseca
d7aa114e16 llvmpipe: Rename function to free up lp_build_trunc to the usual arithmetic meaning. 2009-09-13 13:45:48 +01:00
Keith Whitwell
18e5f1cee4 tgsi: implement saturation
Fix recent performance regression.
2009-09-12 18:33:46 -07:00
Keith Whitwell
055fe5768c tgsi: add missing implementation of constant decl change 2009-09-12 16:27:25 -07:00
Cooper Yuan
bffa18624d r300g: delete unused flag due to commit: 09b566e161 2009-09-13 07:10:34 -04:00
Keith Whitwell
11f41f54cf ureg: add a mechanism to get the built tokens rather than a full shader
Previously ureg would always call the driver's create-shader function.  This
allows the caller the opportunity to hold onto the tokens if it needs to
reuse them, eg. to create an internal draw shader.
2009-09-12 14:18:50 -07:00
Keith Whitwell
c23894295b ureg: add generic emitters for tex and branch instructions
Couldn't previously emit these except by calling the opcode-specific helper.
2009-09-12 14:18:00 -07:00
Keith Whitwell
ae4704eabc tgsi/ureg: give ureg_DECL_constant an explicit index parameter
Avoid the need to emit all constant declarations in order.  Makes
referring to a specific constant in the constant buffer much easier.
2009-09-12 14:16:00 -07:00
Keith Whitwell
09b566e161 mesa: remove unused SATURATE_PLUS_MINUS_ONE flag
Never set in mesa.  Remove from tgsi translation as well.
2009-09-12 14:15:15 -07:00
Keith Whitwell
6d8dbd3d1e tgsi/ureg: VS inputs don't have any semantic tags, just an index
Fix ureg_DECL_vs_input to reflect this and fix up all callers.
2009-09-12 14:12:35 -07:00
Keith Whitwell
149945c432 tgsi: free tokens on error 2009-09-12 14:07:48 -07:00
Keith Whitwell
e90fb86ac3 tgsi: sanity check ureg programs 2009-09-12 14:05:37 -07:00
Keith Whitwell
983b261e6d tgsi: add const qualifier 2009-09-12 14:04:36 -07:00
Nicolai Hähnle
3cb30e55e4 r300g: There is no such thing as "texture stride"
Individual texture images have a stride, but textures as a whole do not.

There are still pieces of code which are confused about this, but the core of
the confusion is hopefully gone.

Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-09-12 16:55:25 +02:00
Eric Anholt
57d16c4cc3 i965: Move OPCODE_DDX/DDY to brw_wm_emit.c and make it actually work.
Previously, it was trying to mess around with the varying's
WM setup data to produce a result.  Along with not actually working when
passed a varying, this wouldn't work if you did dFd[xy]() on a temporary.
Instead, just calculate the derivative using the neighbors in the subspan.
2009-09-11 14:13:47 -07:00
Andre Maasikas
a79eecb913 r600: fix texcoords from constants
with some minor updates from Richard.
2009-09-11 15:59:55 -04:00
Alex Deucher
08b7d32140 Revert "r600: support tex coords from constants"
This reverts commit 4099bb7614.

Tex coord src has to be a GPR.
2009-09-11 12:11:04 -04:00
Cooper Yuan
622b31925b r300g: only allocate one BO for vertex buffers, default size is 64*1024
it can fix redbook/sceneflat, scene, scenebamb, surface, nurbs and so on
2009-09-11 23:21:28 +08:00
Alex Deucher
4099bb7614 r600: support tex coords from constants
Fixes neverball among other things.
2009-09-11 11:07:58 -04:00
Andre Maasikas
4108ed7e80 r600: enable caching of vertex programs 2009-09-11 10:59:53 -04:00
José Fonseca
672c5f52d1 llvmpipe: set dirty_render_cache in llvmpipe_clear()
Based on Brian's softpipe change on
commit 988db64119. We don't use the tile
cache for zsbuf though, only for color buffers.
2009-09-11 11:29:24 +01:00
José Fonseca
1fc4100225 llvmpipe: Update status in README and TODO/FIXME comments throughout the code. 2009-09-11 11:24:26 +01:00
Eric Anholt
7c0152fbae i965: Enable loops in the VS.
Passes piglit glsl-vs-loop testcase.

Bug #20171
2009-09-10 20:43:44 -07:00
Brian Paul
0ef5b62787 mesa: nicer vertex setup 2009-09-10 19:56:35 -06:00
Brian Paul
4781c1f459 st/mesa: use st_context() helper 2009-09-10 19:40:53 -06:00
Brian Paul
6bc36f29c7 softpipe: remove no-op softpipe_init_texture_funcs() function 2009-09-10 16:51:52 -06:00
Brian Paul
209031701a softpipe: remove unused #includes, move comment 2009-09-10 16:50:18 -06:00
Brian Paul
de059d35c3 util: remove unneeded #includes 2009-09-10 16:45:25 -06:00
Brian Paul
afcaa45a94 softpipe: reformatting, clean-ups, comments 2009-09-10 16:42:47 -06:00
Brian Paul
759696defb util: minor clean-ups, reformatting 2009-09-10 16:39:13 -06:00
Brian Paul
71b3ccc4b0 softpipe: remove unneeded #includes 2009-09-10 16:38:51 -06:00
Ian Romanick
b8e1e8d2d8 Merge branch 'master' into asm-shader-rework-2
Conflicts:
	src/mesa/shader/lex.yy.c
	src/mesa/shader/program_parse.tab.c
	src/mesa/shader/program_parse.tab.h
2009-09-10 15:33:45 -07:00
Ian Romanick
81722c5d7e NV fp parser: Add support for condition codes
Conditional write masks and the condition-code based KIL instruction
are all supported.  The specific behavior of KIL in the following
shader may or may not match the behavior of other implementations:

!!ARBfp1.0
	TEMP	GT;
	MOVC	GT, fragment.texcoord[0];
	KIL	GT.x;
	END

Should be it interpreted as 'KIL srcReg' or as 'KIL ccTest'?  The
current parser will interpret it as 'KIL srcReg'.
2009-09-10 15:04:24 -07:00
Ian Romanick
cdb7193994 ARB prog lexer: Add missing #include to silence compile warning 2009-09-10 14:55:36 -07:00
Brian Paul
d9dc4cb0e4 Merge branch 'mesa_7_6_branch' 2009-09-10 15:41:52 -06:00
Zack Rusin
8c37a4c8fd st/xorg: rename ctx to pipe to match every other gallium state tracker
plus it avoids the "ctx->ctx->" syntax
2009-09-10 17:43:25 -04:00
Ian Romanick
0e7953366f ARB prog parser: Differentiate between used and unused names in the lexer
The lexer will return IDENTIFIER only when the name does not have an
associated symbol.  Otherwise USED_IDENTIFIER is returned.
2009-09-10 14:35:33 -07:00
Zack Rusin
85a716bf62 st/xorg: temporarily disablie copies 2009-09-10 17:21:06 -04:00
Zack Rusin
feb74e7753 st/xorg: implement pipelines surface/texture copies 2009-09-10 17:21:06 -04:00
Zack Rusin
57d0934bc5 st/xorg: unite finalization and stub out pipelined copies 2009-09-10 17:21:06 -04:00
Zack Rusin
974dec2e7b st/xorg: abstract flushing and syncing for the exa code 2009-09-10 17:21:06 -04:00
Zack Rusin
16886c8be3 st/xorg: disable solid fills until copies are accelerated as well 2009-09-10 17:21:06 -04:00
Zack Rusin
6be1a98ab9 st/xorg: implement exasolids with full pipelining
plus fix some small issues with the shaders
2009-09-10 17:21:06 -04:00
Zack Rusin
3167c2e8a0 st/xorg: start adding support for surface fills 2009-09-10 17:21:06 -04:00
Marcin Kościelnicki
18882f4d30 nv50: Fix tiling mode for lower mipmap levels. 2009-09-10 21:06:48 +02:00
Eric Anholt
36dd53a3cd intel: Don't forget to map the depth read buffer in spans.
This broke BlitFramebufferEXT(GL_DEPTH_BUFFER_BIT).
2009-09-10 11:16:18 -07:00
Alex Deucher
e669dc2b0d r300: enable rb3d_discard_src_pixel_lte_threshold for more chips on dri2 2009-09-10 12:04:38 -04:00
Alex Deucher
7dfe54a60e r300: add full support for two sided stencil on r5xx for dri2 2009-09-10 12:01:19 -04:00
Mathias Frohlich
f89751e719 mesa: fix cut&paste typos 2009-09-10 08:50:16 -06:00
Vinson Lee
c7291f69a0 util: Add PIPE_OS_APPLE back to auxiliary/util/u_time.h.
Fixes typo from commit c6c44bf481.
2009-09-10 15:33:57 +01:00
José Fonseca
6a405b4a21 llvmpipe: Fix alpha test. 2009-09-10 13:35:39 +01:00
José Fonseca
4c3a48ad0c llvmpipe: Mask out color channels not present in the color buffer. 2009-09-10 12:37:44 +01:00
José Fonseca
48f19c0bcd llvmpipe: Fix sampling from depth textures. Respect texture compare func.
Fixes Mesa shadowtex sample.
2009-09-10 12:14:53 +01:00
José Fonseca
c3c80c5c22 llvmpipe: Skip blending when mask is zero.
This increases quake3 timedemo fps another 10%.
2009-09-10 12:01:42 +01:00
José Fonseca
8e6b925d2a llvmpipe: Proper control flow builders.
New control flow helper functions which keep track of all variables
and generate the correct Phi functions.

This re-enables skipping the fs execution of quads masked out by
the rasterizer, early z testing, and kill opcode.

This yields a performance improvement of around 20%.
2009-09-10 11:44:03 +01:00
José Fonseca
bd3b59da63 llvmpipe: Copy the texture target into the sampler static state.
Hunk forgotten in previous commit.
2009-09-10 09:19:51 +01:00
José Fonseca
4139bc8f43 llvmpipe: Quick hack for 1D textures. 2009-09-09 21:48:50 +01:00
José Fonseca
b0b131b023 scons: Pass -mstackrealign option to gcc.
It is impossible to have gcc generate SSE code without it, as thirdparty
applications often call us with an unaligned stack pointer.
2009-09-09 21:48:50 +01:00
José Fonseca
abc160b664 llvmpipe: Fix depth mask computation.
Fixes depth test for 24bit depth formats.
2009-09-09 21:48:50 +01:00
José Fonseca
cdbbcdf3bd llvmpipe: Include zsbuf's format in the fragment shader key. 2009-09-09 21:48:50 +01:00
José Fonseca
da912a7a16 util: Fix depth/stencil format description.
Inverse channel order.
2009-09-09 21:48:49 +01:00
José Fonseca
01c831576e llvmpipe: Debug function to check stack alignment.
Doing alignment check in locus is redundant, as gcc alignment assumptions
will optimize away the check.
2009-09-09 21:48:49 +01:00
Eric Anholt
5604b27b93 i965: Fix relocation delta for WM surfaces.
This was a regression in 0f328c90db.

Bug #23688
Bug #23254
2009-09-09 12:52:52 -07:00
Brian Paul
4d85a6b393 i965: fix an overlooked merge conflict 2009-09-09 09:24:38 -06:00
Alex Deucher
49c230709c r600: check if textures are actually enabled before submission
noticed by taiu on IRC.
2009-09-09 11:17:24 -04:00
Brian Paul
7bf6347362 Merge branch 'mesa_7_6_branch' 2009-09-09 09:00:58 -06:00
Brian Paul
94a8157ef6 mesa: regenerate get.c form get_gen.py 2009-09-09 08:55:32 -06:00
Brian Paul
3fed69eb16 mesa: move call to init_c_cliptest() from enable.c to tnl module.
Fixed gallium build breakage.
2009-09-09 08:54:38 -06:00
Alex Deucher
da9ed257a3 r600: fix ftp for dri1
We use t->bo for dri1 since r600 uses CS for dri1.
2009-09-09 01:43:17 -04:00
Zhenyu Wang
ca246dd186 intel: add B43 chipset support
Signed-off-by: Zhenyu Wang <zhenyuw@linux.intel.com>
2009-09-09 13:28:59 +08:00
Dave Airlie
5aaa45de4c r600: don't setup hardware state if TFP
if we have a BO here it means TFP and we should have set it
up already.

tested by b0le on #radeon
2009-09-09 15:02:16 +10:00
Brian Paul
8947cf6728 progs/tests: added Z invert option 2009-09-08 16:47:30 -06:00
Brian Paul
f78eafcacb mesa: bump version to 7.7 2009-09-08 16:46:06 -06:00
Brian Paul
97cbaab541 gallium: added r8g8b8_get/put_tile_rgba() 2009-09-08 16:45:34 -06:00
Brian Paul
079ae4c38c progs/demos: added RGB invert option 2009-09-08 16:45:07 -06:00
Brian Paul
126696caf7 mesa: fix viewport_z_clip breakage 2009-09-08 16:44:49 -06:00
Jakob Bornecrantz
e589a37f7b i915g: Add buffer write callback 2009-09-09 00:43:36 +01:00
Jakob Bornecrantz
d112132840 i915g: Reorg vbuf code a bit 2009-09-09 00:43:36 +01:00
Jakob Bornecrantz
547b726484 i915g: pwrite batchbuffer instead of map 2009-09-09 00:43:36 +01:00
Jakob Bornecrantz
d585616f5b i915g: Keep vertex buffers in a fifo 2009-09-09 00:43:35 +01:00
Jakob Bornecrantz
6e61d06209 util: Add super simple fifo 2009-09-09 00:43:35 +01:00
Jakob Bornecrantz
3833587818 i915g: Map vertex buffers via gtt 2009-09-09 00:43:35 +01:00
Jakob Bornecrantz
530fbd314e i915g: Remove lib prefix from driver 2009-09-09 00:43:35 +01:00
Eric Anholt
9fff4b46d3 docs: Add basic 7.7 relnotes. 2009-09-08 15:12:22 -07:00
Eric Anholt
f959ccdfa6 intel: Add support for ARB_draw_elements_base_vertex.
On the 965, we just drop the value into the primitive packet.  On non-945,
we rely on the sw tnl code handling it.
2009-09-08 15:12:22 -07:00
Eric Anholt
92d7ed8a20 mesa: Add support for ARB_draw_elements_base_vertex. 2009-09-08 15:12:20 -07:00
Eric Anholt
ec9e729580 glapi: Add ARB_draw_elements_base_vertex 2009-09-08 14:48:47 -07:00
Eric Anholt
b11a8ea863 mesa: Expose NV_depth_clamp if ARB_depth_clamp is supported.
The wording of these two is exactly the same, except for the issue
"Can fragments with wc<=0 be generated when this extension is supported?",
which idr thinks is a non-issue for us.
2009-09-08 14:30:18 -07:00
Eric Anholt
0310aafd9e i965: Add support for ARB_depth_clamp. 2009-09-08 14:30:18 -07:00
Eric Anholt
0e5c2598ec Regenerate files for GL_ARB_depth_clamp. 2009-09-08 14:30:18 -07:00
Eric Anholt
b4922b5331 mesa: Add support for ARB_depth_clamp.
This currently doesn't include fixing up the cliptests in the assembly
paths to support ARB_depth_clamp, so enabling depth_clamp forces the C path.
2009-09-08 14:30:15 -07:00
Eric Anholt
3e4539a471 i965: Respect spec requirement for pixel shader computed depth with no zbuffer. 2009-09-08 14:28:23 -07:00
Eric Anholt
15c0cc5cf4 i965: Set NULL WM surfaces as tiled according to requirement by specs. 2009-09-08 14:28:23 -07:00
Eric Anholt
ea6dab2537 i965: Use the renderbuffer surface size instead of region size for WM surfaces.
For drawing to lower mipmap levels, the region size makes the renderbuffer
be the size of the lowest level, instead of the current level.  On DRI1,
Brian previously found that the RB size was incorrect, so leave this broken
there.
2009-09-08 14:28:23 -07:00
Eric Anholt
58a57e3fc4 Revert "intel: helper to debug bufmgr (disabled)"
This reverts commit e0ec405a9f.

This is already available in INTEL_DEBUG=bufmgr in the environment.
2009-09-08 14:28:23 -07:00
Brian Paul
b2de028523 i965: #include clean-ups 2009-09-08 14:33:47 -06:00
Brian Paul
e61215242b intel: #include clean-ups 2009-09-08 14:33:47 -06:00
Brian Paul
8e8d3470be i965: use _mesa_is_bufferobj()
Also, remove unneeded call to _mesa_validate_pbo_access().  It's done by
core Mesa as the comment suggested.
2009-09-08 14:33:47 -06:00
Brian Paul
ced699b37a i965: use _mesa_is_bufferobj() 2009-09-08 14:33:47 -06:00
Brian Paul
abdf2e14bc i965: use _mesa_is_bufferobj() 2009-09-08 14:33:47 -06:00
Brian Paul
00aac1d29a i965: use _mesa_is_bufferobj() 2009-09-08 14:33:47 -06:00
Alex Deucher
e6ad286a80 r600: fix dri2 clipping 2009-09-08 16:03:25 -04:00
Michel Dänzer
e34ea368d9 st/xorg: Add support for EXA_MIXED_PIXMAPS and EXA_SUPPORTS_PREPARE_AUX.
Also make sure not to leak malloced memory when switching pixmaps to texture
based.
2009-09-08 18:08:24 +02:00
Vinson Lee
2c307c7750 scons: Add Mac OS to target platform list. 2009-09-08 12:32:37 +01:00
Michal Krol
fab99092a0 slang: Correctly handle end of tokens marker. 2009-09-08 13:32:20 +02:00
Michal Krol
2ec2936454 slang: Do not parse whitespace.
The preprocessor tokeniser deals with those.
2009-09-08 13:29:17 +02:00
Michal Krol
58fa89c902 slang: Correctly parse numbers from the new preprocessor. 2009-09-08 12:46:34 +02:00
Michal Krol
b837f6c372 grammar: Fix token stripping. 2009-09-08 10:57:39 +02:00
Michal Krol
d06069f305 slang: Remove the old preprocessor. 2009-09-08 10:46:29 +02:00
Michal Krol
7e6e5cd60a slang: Remove dependencies on error tokens. 2009-09-08 10:33:49 +02:00
Michal Krol
0aeff7638b gdi: Fix prototype of gdi_softpipe_surface_buffer_create(). 2009-09-08 10:23:05 +02:00
Michal Krol
fcb94f6e3e gdi: Fix prototype of gdi_softpipe_surface_buffer_create(). 2009-09-08 10:22:07 +02:00
Michal Krol
5ddcdc4227 slang: Adapt shader syntax description to grammar parser changes. 2009-09-07 21:30:34 +02:00
Michal Krol
ce9309d245 grammar: Adapt grammar to the glsl preprocessor. 2009-09-07 21:27:42 +02:00
Michal Krol
d26d77295b gdi: Add glsl to LIBS. 2009-09-07 21:23:43 +02:00
Michal Krol
b97a734658 grammar: Remove dead code. 2009-09-07 17:45:26 +02:00
Vinson Lee
79f48c9f9e scons: Don't set LLVM_VERSION if one of the llvm-config calls fails.
Ubuntu 8.10 has llvm-config version 2.2, which doesn't have
nativecodegen. This triggers an exception.
2009-09-07 15:16:25 +01:00
José Fonseca
b481fb2c6d llvmpipe: Silent debug statement. 2009-09-07 15:02:08 +01:00
José Fonseca
1127201088 llvmpipe: Better abs for floating points. 2009-09-07 15:02:08 +01:00
José Fonseca
e4c76c02f7 llvmpipe: Code generate the texture sampling inside the shader.
Finally a substantial performance improvement: framerates of apps using
texturing tripled, and furthermore, enabling/disabling texturing only
affects around 15% of the framerate, which means the bottleneck is now
somewhere else.

Generated texture sampling code is not complete though -- we always
sample from the base level -- so final figures will be different.
2009-09-07 15:02:08 +01:00
José Fonseca
de8376e2f2 llvmpipe: Texture sampling code generation primitives.
Only supports single level 2d textures, with neareast and bilinear
filtering for now.
2009-09-07 15:02:07 +01:00
José Fonseca
0c2ea24338 llvmpipe: Convenience function to obtain the integer type with same bitdepth of an arbitrary type. 2009-09-07 15:02:07 +01:00
José Fonseca
fa0f4b35be llvmpipe: Utility functions for linear and bilinear interpolation. 2009-09-07 15:02:07 +01:00
José Fonseca
4da20234f3 llvmpipe: Correct implementation of floor. 2009-09-07 15:02:07 +01:00
José Fonseca
b1eff018c7 llvmpipe: Utility function to get the pointer to a structure member. 2009-09-07 15:02:07 +01:00
José Fonseca
866fbacf2b llvmpipe: SoA pixel unpacking specialization. 2009-09-07 15:02:06 +01:00
José Fonseca
6b129a8222 util: Utility function to check if a number is a power of two. 2009-09-07 15:02:06 +01:00
José Fonseca
8be72bb764 llvmpipe: Further abstract the texture sampling generation from TGSI translation. 2009-09-07 15:02:06 +01:00
Michal Krol
8bed21ecf9 grammar: Remove grammar_check(). 2009-09-07 10:55:45 +02:00
Michal Krol
5ad8937752 glsl: Add error messages for version parser. 2009-09-07 10:12:12 +02:00
Michal Krol
b7960b3d3a glsl: Handle file tokens in apps/process. 2009-09-07 10:12:11 +02:00
Michal Krol
a64ba93aab glsl: Handle file numbering. 2009-09-07 10:12:10 +02:00
Michal Krol
2d2d638444 glsl: Actually respect the hash-line directive. 2009-09-07 10:12:09 +02:00
Michal Krol
b6df77fb9a glsl: Handle line tokens in apps/process. 2009-09-07 10:12:08 +02:00
Michal Krol
4aa3222df3 glsl: Correctly handle line numbering. 2009-09-07 10:12:07 +02:00
Michal Krol
0d9c5eafeb glsl: Preserve newline inside comment blocks. 2009-09-07 10:12:06 +02:00
Michal Krol
e8afc65589 glsl: Implement predefinded macros.
The values are hardcoded: __LINE__ = 1, __FILE__ = 0 and __VERSION__ = 110.
2009-09-07 10:12:05 +02:00
Michal Krol
bb8f38ea6f glsl: Implement `line' preprocessor directive. 2009-09-07 10:12:03 +02:00
Michal Krol
ddd8ae7fbc glsl: Output endof token after processing a directive.
Some directives may output tokens as a result of their operation.
2009-09-07 10:12:03 +02:00
Michal Krol
7f187583c1 glsl: Handle extension tokens in apps/proces. 2009-09-07 10:12:02 +02:00
Michal Krol
87d2de04fb glsl: Implement `extension' preprocessor directive.
No extensions supported.
2009-09-07 10:12:00 +02:00
Michal Krol
94321b4441 glsl: Handle pragma tokens in apps/process. 2009-09-07 10:11:59 +02:00
Michal Krol
0e046420e4 glsl: Implement `pragma' preprocessor directive.
Handle `optimize(on|off)' and `debug(on|off)' pragmas.
2009-09-07 10:11:58 +02:00
Michal Krol
c42428c787 glsl: Print out error message in apps/process. 2009-09-07 10:11:56 +02:00
Michal Krol
f9bd6f7152 glsl: Implement `error' preprocessor directive. 2009-09-07 10:11:55 +02:00
Michal Krol
3dc2b5f71c glsl: Implement `undef' preprocessor directive. 2009-09-07 10:11:54 +02:00
Michal Krol
a294715612 glsl: Allow for preprocessor macro redefinition. 2009-09-07 10:11:52 +02:00
Michal Krol
153b179862 glsl: Handle `defined' preprocessor operator. 2009-09-07 10:11:51 +02:00
Michal Krol
3b027bca9d glsl: Support if preprocessor directive and friends. 2009-09-07 10:11:50 +02:00
Michal Krol
3bb446ba6e glsl: Add expression interpreter. 2009-09-07 10:11:49 +02:00
Michal Krol
2dad8ed9d6 glsl: Centralise sl_pp_macro constructor. 2009-09-07 10:11:48 +02:00
Michal Krol
6a11d4150c glsl: Implement macro expansion. 2009-09-07 10:11:47 +02:00
Michal Krol
5e8e3cddae glsl: Rename sl_pp_context_add_str to sl_pp_context_add_unique_str.
Return the same offset for same strings. Allows to compare strings
by comparing their's offsets.
2009-09-07 10:11:46 +02:00
Michal Krol
fd991d845a glsl: Parse define directive in preprocessor. 2009-09-07 10:11:45 +02:00
Michal Krol
3ce5e66818 glsl: Simplify directive parser skeleton. 2009-09-07 10:11:44 +02:00
Michal Krol
f24322fbf6 glsl: Introduce sl_pp_context and maintain a reuseable pool of strings. 2009-09-07 10:11:43 +02:00
Michal Krol
f24ec185c5 glsl: Add `process' test app that returns tokenised and preprocessed text. 2009-09-07 10:11:42 +02:00
Michal Krol
9d336c5264 glsl: Add preprocessor skeleton for directive parsing. 2009-09-07 10:11:40 +02:00
Michal Krol
5d26deef98 glsl: Remove bogus sl_pp_directive.h include. 2009-09-07 10:11:39 +02:00
Michal Krol
b4e92367f3 glsl: Allow for multiple version statements. 2009-09-07 10:11:38 +02:00
Michal Krol
55f75c13f0 glsl/apps: Print out the number of tokens eaten in version test. 2009-09-07 10:11:38 +02:00
Michal Krol
474f754282 glsl: Raise an error on an unfinished comment block. 2009-09-07 10:11:37 +02:00
Michal Krol
af617c6037 glsl/apps: Add version test app. 2009-09-07 10:11:36 +02:00
Michal Krol
229e72956c glsl: Parse optional version directive. 2009-09-07 10:11:33 +02:00
Michal Krol
0d5ef796f8 glsl: Add a tokenise app. 2009-09-07 10:11:32 +02:00
Michal Krol
2c9a627b48 glsl: Add a preprocessor tokeniser. 2009-09-07 10:11:31 +02:00
Michal Krol
121769eeb3 glsl: Add a purify command-line tool. 2009-09-07 10:11:30 +02:00
Michal Krol
0bbf59c305 glsl: Add preprocessor purifier. 2009-09-07 10:11:29 +02:00
Michal Krol
970823978c mesa: Include <unistd.h> only when one is available. 2009-09-07 09:31:17 +02:00
Michal Krol
826d441cdf mesa: Fix calling conventions of sync object api callbacks. 2009-09-07 09:16:35 +02:00
Michel Dänzer
617202b578 r300g: Fix some issues pointed out by compiler warnings. 2009-09-06 18:12:14 +02:00
Michel Dänzer
7b8ec0d8e7 r300g: Handle PIPE_BUFFER_USAGE_DONTBLOCK as intended.
Return NULL if the BO is busy, otherwise just map it.
2009-09-06 18:12:14 +02:00
Brian Paul
23663ae914 mesa: initial version of _mesa_meta_generate_mipmap()
Incomplete and totally untested.  Based on intel_generate_mipmap().
2009-09-06 09:39:50 -06:00
Brian Paul
4d63c626d0 xlib: test _mesa_meta_bitmap() 2009-09-06 09:37:30 -06:00
Brian Paul
886e7b318d mesa: use separate temp texture for bitmaps 2009-09-06 09:37:30 -06:00
Brian Paul
b2951ffe96 mesa: temp_texture changes 2009-09-06 09:37:30 -06:00
Brian Paul
f477fa7a85 mesa: free meta bitmap buffers 2009-09-06 09:37:29 -06:00
Brian Paul
0e5293a240 mesa: use _mesa_set_enable() 2009-09-06 09:37:29 -06:00
Brian Paul
bcb62ae78a mesa: _mesa_meta_bitmap() function 2009-09-06 09:37:29 -06:00
Brian Paul
4fdc96db1d xlib: move misplaced brace 2009-09-06 09:37:29 -06:00
Nicolai Hähnle
1ddb22675c r300g: Fix a number of warnings
Seriously guys....
2009-09-06 15:14:22 +02:00
Nicolai Hähnle
4b01e6f614 r300g: Debug flags infrastructure
So that debugging is no longer a full-spam-or-nothing approach, you are now
supposed to set the RADEON_DEBUG environment flag just like for classic Mesa.

The available debug flags are different, however. Just running an OpenGL
application with RADEON_DEBUG set to an arbitrary string will print out
helpful information.

Everything must be compiled with -DDEBUG for any of this to work
2009-09-06 15:03:52 +02:00
Nicolai Hähnle
f02f63997c Merge branch 'master' into r300-compiler
Conflicts:
	src/gallium/drivers/r300/r300_tgsi_to_rc.c
2009-09-06 13:15:04 +02:00
Nicolai Hähnle
e95e76e125 r300/compiler: New dataflow structures and passes
This replaces the old NQSSADCE code with the same functionality, but quite
different design. Instead of doing a single integerated pass, we now build
explicit data structures representing the dataflow.

This will enable analysis of flow control instruction, and could potentially
open an avenue for several dataflow based optimizations, such as peephole
optimization, fusing MUL+ADD to MAD, and so on.
2009-09-06 11:47:40 +02:00
Cooper Yuan
9778731732 r300g: update the value of register VAP_VF_MAX_VTX_INDX
according to actual vertex index count.
2009-09-05 20:58:32 +08:00
Cooper Yuan
80ea03bd17 r300g: update rs_block state after changing rasterizer 2009-09-05 14:26:39 +08:00
Cooper Yuan
8f990f928b r300g: need to validate scissor and viewport state if bind new rasterizer 2009-09-05 10:26:39 +08:00
Ian Romanick
d0adebb8d5 NV fp parser: Support instruction and TEMP / OUTPUT sizes
Adds support for declaring TEMP and OUTPUT variables as 'LONG' or
'SHORT' precision.  The precision specifiers are parsed, but they are
currently ignored.  Some support for this may be added in the future,
but neither Intel hardware nor, as far as I'm aware, Radeon hardware
support multiple precisions.

Also adds support for instruction precision ('X', 'H', and 'R')
suffixes and instruction condition code output ('C') suffix.  This
results in a fairly major change to the lexer.  Instructions are
matched with all the possible suffix strings.  The suffix string are
then carved off by a context (i.e., which program mode and options are
set) aware parser that converts the suffixes to bits in
prog_instruction.

This could have been handled in the same way _SAT was originally
handled in the lexer, but it would have resulted in a very large lexer
with lots of opportunity for cut-and-paste errors.
2009-09-04 17:31:05 -07:00
Ian Romanick
9ea4319744 ARB prog parser: Add new constructor for asm_instruction
The new constructor copies fields from the prog_instruction that the
parser expects the lexer to set.
2009-09-04 16:35:50 -07:00
Alex Deucher
9ab19a3900 r600: add support for EXT_texture_sRGB 2009-09-04 18:46:16 -04:00
Alex Deucher
60ca65c016 r300: Add support for GL_EXT_provoking_vertex 2009-09-04 18:46:15 -04:00
Alex Deucher
8fd7586bcc r600: Add support for GL_EXT_provoking_vertex 2009-09-04 18:46:15 -04:00
Eric Anholt
0612ad4f19 i965: Don't set the complete field when there is more VUE yet to come.
This should help with things like lightsmark, but I don't have a testcase
for this commit.
2009-09-04 14:20:09 -07:00
Eric Anholt
a47858e45e i965: Add support for 2 threads in the GS.
This brings noop vertex shader throughput from 6.8M verts/sec to 10.4M
verts/sec using GL_QUADs on my GM45.
2009-09-04 14:20:09 -07:00
Eric Anholt
8f7f22ca1d i965: Add support for KIL_NV in brw_wm_emit.c
I ran into this lack of support when writing a shader that always discarded
the fragments.
2009-09-04 14:20:08 -07:00
Julien Cristau
f8f07cb999 Remove unused INSTALL_TARGETS variable
The install targets were removed in the previous commit.
2009-09-04 17:29:21 +02:00
Julien Cristau
c14446ab00 Don't run install from the various configs in parallel
Hopefully this fixes a bug in the previous debian/rules that could lead
to FTBFS.  Thanks to Bernhard R. Link for the suggestions.
2009-09-04 17:22:31 +02:00
Brice Goglin
70fd9421ac Prepare changelog for upload 2009-09-04 11:39:18 +02:00
Brice Goglin
1810757c29 Bump Standards-Version to 3.8.3 to 3.8.3 now that we have README.source 2009-09-04 11:35:10 +02:00
Brice Goglin
4c79e26a9d Add a Mesa-specific README.source inspired from the one in xsfbs 2009-09-04 11:33:17 +02:00
Brice Goglin
1783d52ace Prepare changelog for upload 2009-09-04 10:58:58 +02:00
Brice Goglin
c5bf7f94c0 New upstream release 2009-09-04 10:55:25 +02:00
Brice Goglin
8222bfc1d1 Merge tag 'mesa_7_5_1' into debian-unstable
Conflicts:
	progs/tests/fbotest1.c
	progs/tests/texwrap.c
	progs/trivial/.gitignore
	progs/trivial/Makefile
2009-09-04 10:53:45 +02:00
Ian Romanick
eeb1402c05 NV fp parser: Add support for absolute value operator on instruction operands 2009-09-03 14:32:48 -07:00
Ian Romanick
5db8ebb8f5 Enable GL_NV_fragment_program_option for software rendering
At this point the extension is not fully implemented.
2009-09-03 14:07:07 -07:00
Ian Romanick
b8e389bb03 NV fp parser: Support new scalar constant behavior
ARBfp requires scalar constants have a '.x' suffix, but NVfp_option
does not.  This shows up with instructions that require a scalar
parameter (e.g., COS).
2009-09-03 14:05:18 -07:00
Ian Romanick
8ca6fd8a83 NV fp parser: Parse TXD instruction 2009-09-01 14:16:03 -07:00
Ian Romanick
ede0cd4d8c NV fp lexer: Add new opcodes 2009-08-31 17:00:31 -07:00
Ian Romanick
dc8ec05ace NV fp: Parse 'OPTION NV_fragment_program' in ARB assembly shaders 2009-08-31 16:57:49 -07:00
Ian Romanick
efff7aa980 NV fp: Add tracking for NV_fragment_program_option 2009-08-31 16:43:39 -07:00
Nicolai Hähnle
d1b4351e60 r300: Remove all Mesa dependencies from the shader compiler
In particular, this removes the dependency on prog_instruction, which
unfortunately creates some code duplication, but also opens a path towards
adding some hardware-specific things in there.

Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-08-30 18:51:46 +02:00
Nicolai Hähnle
d6d71e5bf4 r300: Move Mesa -> RC program conversion to classic Mesa driver
This really doesn't belong into the compiler itself, since the compiler
should eventually be independent of Mesa's program representation.

Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
2009-08-30 17:57:20 +02:00
Keith Whitwell
67d4a5b15c mesa/swrast: use one fewer divide in swrast's choose_cube_face also
Same change as for softpipe
2009-08-24 08:26:33 +01:00
Keith Whitwell
fd19e8adcd softpipe: use one fewer divide in sample_cube
GCC won't do this for us.  Makes a bigger difference to cubemap fps
than previous set of compilcated rearrangements.
2009-08-24 08:26:33 +01:00
Keith Whitwell
60adc15ba5 softpipe: separate out 2d and cube img filter functions 2009-08-24 08:26:32 +01:00
Keith Whitwell
81601d85ef softpipe: make the various get_texel routines more similar
Remove arguments, return const float * by default.  Add specialized 3d
versions and remove 3d texture support from the others.
2009-08-24 08:26:17 +01:00
Keith Whitwell
75312b6555 progs/demos: add fps output to cubemap 2009-08-23 23:53:41 +01:00
Keith Whitwell
153e474d22 softpipe: lift tex_address construction up to img_filter
For fastpaths at least, can avoid recalculating this sometimes.
2009-08-23 13:38:10 +01:00
Keith Whitwell
4fe0fc3eba softpipe: remove old prim_setup draw stage
Everything now goes through the draw_vbuf handler, the same as
regular drivers.
2009-08-23 11:22:41 +01:00
Keith Whitwell
47800c572f softpipe: add missing header 2009-08-23 11:13:20 +01:00
Keith Whitwell
7670102468 Merge branch 'tex-tilecache' into softpipe-opt
Conflicts:
	src/gallium/drivers/softpipe/sp_state_derived.c
	src/gallium/drivers/softpipe/sp_state_sampler.c
	src/gallium/drivers/softpipe/sp_tex_sample.c
	src/gallium/drivers/softpipe/sp_tex_sample.h
	src/gallium/drivers/softpipe/sp_tile_cache.c
2009-08-23 10:23:46 +01:00
Julien Cristau
3f970a6d4e Bump debhelper build-dep for dh_lintian 2009-08-22 21:30:15 +02:00
Brian Paul
0f24886f92 softpipe: remove duplicate #include, move another 2009-08-21 14:07:37 -06:00
Brian Paul
d204659c8c softpipe: remove tex sample dependencies on softpipe
The texture sampling code doesn't really have any dependencies on the
rest of softpipe, just the tile cache.
2009-08-21 14:04:51 -06:00
Brian Paul
3adc8c3779 softpipe: minor code refactoring to remove softpipe/tile cache dependencies
The tile cache code now has no hard dependencies on softpipe.
2009-08-21 14:01:58 -06:00
Brian Paul
4256c5829f softpipe: remove unused #includes, white-space clean-up 2009-08-21 13:47:50 -06:00
Brian Paul
46fbc87288 softpipe: remove unneeded const qualifier 2009-08-21 13:45:16 -06:00
Brian Paul
a29447c33d softpipe: per-unit sampler varients
Can't share sampler varients across multiple tex units because the texture
pointer is in the sampler varient.  That prevents different textures per unit.

Fixes progs/demos/multiarb, progs/glsl/samplers, etc.
2009-08-21 12:44:04 -06:00
Brian Paul
87ec83afd5 softpipe: add missing PIPE_TEXTURE_CUBE case in get_lambda_func()
Fixes progs/demos/cubemap
2009-08-21 11:47:31 -06:00
Keith Whitwell
ecfa8be150 softpipe: add missing sp_sampler_varient_destroy 2009-08-21 18:44:56 +01:00
Brian Paul
cf102b031e softpipe: remove redundant comparison, make test easier to understand 2009-08-21 11:43:48 -06:00
Brian Paul
41483627f0 softpipe: fix min/mag filter typo 2009-08-21 11:41:29 -06:00
Brian Paul
4e5c385d21 softpipe: fix s/t/p typos 2009-08-21 11:40:33 -06:00
Keith Whitwell
4fc7d0345a softpipe: rework texture sampling code
Split into component pieces, stitch together at runtime using function
pointers.  Make it possible to utilize the existing fastpaths as image-level
filters for generic mip-filtering routines.

Remove special case for rectangle filtering, as it can now be handled by
the 2d path.

As most of the mesa demo texturing was already covered by fast paths, its
harder to find examples of speedups, but tunnel gets a boost as mip-nearest
filtering is now able to access the img_2d_linear_wrap_POT functions
for sampling within a mipmap level.
2009-08-21 18:14:19 +01:00
Keith Whitwell
b1cc196e6d util: add util_is_power_of_two function 2009-08-21 18:07:35 +01:00
Keith Whitwell
00c8359182 softpipe: allow the existing sampler routines to be hooked up directly
Let eg. sp_get_samples_rect be hooked directly in as the tgsi sampler
routine.

Add a field to determine whether this is a vertex or fragment sampling
call, and massage parameters to match the tgsi call.
2009-08-20 18:36:57 +01:00
Keith Whitwell
0d9979d9ec softpipe: fix xpot calculation typo in sp_get_samples_2d_nearest_clamp_POT 2009-08-20 18:13:25 +01:00
Keith Whitwell
1fd40e506c softpipe: slightly optimized tiling calculation 2009-08-20 18:12:44 +01:00
Keith Whitwell
79a7ddb57a softpipe: fix glitch in texel lookups on fastpaths
Fixes two issues - firstly for mipmap levels with one or more
dimensions smaller than tilesize, the code was sampling off the edge
of the texture (but still within the tile).

Secondly, in the linear_mipmap_linear case, both the default code and
new fastpath were incorrect.  This change fixes the fastpath and adds
a comment to the default path, which still needs to be fixed.
Basically the issue is that the coordinates in the smaller texture
level are/were being computed by just dividing thecoordinates from the
larger texture level by two, as in:

               x0[j] /= 2;
               y0[j] /= 2;
               x1[j] /= 2;
               y1[j] /= 2;

The issues with this are signficant.  Initially x1 is most often equal
to x0+1, but after this, it will likely be equal to x0, so we will not
actually be performing the linear blend within the smaller mipmap.

The fastpath code avoided this (recalculated x1), but was still using
the weighting factors from the larger mipmap level (xw, yw), which
were incorrect.

Change the fastpath code to do two full, independent linear samples of
the two mipmap levels before blending.  The default code needs to do
the same thing.
2009-08-20 17:59:39 +01:00
Keith Whitwell
4f409da345 softpipe: optimized path for simple mipmap sampling
linear-mip-linear-repeat-POT sampling faspath, provides a very nice
speedup to apps that do this common type of texturing.

Test case: demos/terrain, turn fog off, turn texturing on.
Without patch: 12 fps
With patch: 20 fps.
2009-08-20 11:25:20 +01:00
Keith Whitwell
c84abe36a9 softpipe: fix typo in clear_tile 2009-08-18 16:55:10 +01:00
Keith Whitwell
80c78472ad softpipe: split texture and surface tile caches
These do similar jobs but with largely disjoint code.  Will want
to evolve them separately going forward.
2009-08-18 16:55:10 +01:00
Keith Whitwell
d12bae9368 softpipe: move flatshade-first check out of loop 2009-08-18 16:21:12 +01:00
Keith Whitwell
99ec78d946 Revert "softpipe: rearrange blend fastpaths"
This reverts commit 1295cf423e.

The original formulation was easier to understand & work with.  Will
revisit this later.
2009-08-11 18:23:28 +01:00
Keith Whitwell
da319095f2 softpipe: reduce textual differences between exec and sse shader paths
Unshare one function (setup_pos_vector) as we want to push this code
into the generated shader in the SSE case.
2009-08-11 18:06:16 +01:00
Keith Whitwell
b5c389721a softpipe: remove gallivm fragment shaders
However we do llvm integration, it will be different & more comprehensive
than this.
2009-08-11 18:03:01 +01:00
Keith Whitwell
95f7ed4638 softpipe: setup quad outputs from with fs->run 2009-07-30 11:59:32 +01:00
Keith Whitwell
1295cf423e softpipe: rearrange blend fastpaths 2009-07-30 11:35:50 +01:00
Keith Whitwell
73a6178a73 softpipe: add depth-lequal z16 path 2009-07-30 11:35:08 +01:00
Keith Whitwell
572c2fb5bb softpipe: remove unused variable in shade_quad 2009-07-30 11:34:36 +01:00
Keith Whitwell
5fdac2dcea softpipe: fix off-by-one in nearest texcoord routines
Stray '- 0.5' copied from linear versions.
2009-07-27 15:51:15 +01:00
Keith Whitwell
6142de393f softpipe: example fast paths for simple samplers
All these fastpaths are examples of the types of things we'd code-generate
in a more sophisticated version of softpipe.
2009-07-27 12:44:58 +01:00
Keith Whitwell
c611458205 softpipe: fastpath for interpolated z16 less depthtesting
Because this is interpolated (ie. early) depth, we can build in an
assumption about the quads emitted by triangle setup, ie that they
are actually linear spans.  Interpolate z over those spans in z16
format to save on math & conversion.
2009-07-27 12:11:16 +01:00
Keith Whitwell
1078844d18 softpipe: cope with nr_cbufs == 0
Disable blend code when no color buffer
2009-07-27 11:23:51 +01:00
Keith Whitwell
bac8e34c9e softpipe: move all depth/stencil/alpha pixel processing into one stage 2009-07-27 08:17:45 +01:00
Julien Cristau
a151efc6cc Use dh_lintian. 2009-07-27 00:29:45 +02:00
Julien Cristau
05c0e10a9e Override 'package-name-doesnt-match-sonames' lintian warnings 2009-07-27 00:29:44 +02:00
Keith Whitwell
85613cc4f1 softpipe: fix error in scissor state dependencies 2009-07-25 11:01:48 +01:00
Keith Whitwell
ade8984f50 softpipe: cleanup framebuffer state routine slightly 2009-07-25 10:01:06 +01:00
Keith Whitwell
a2f7ab1d15 softpipe: move all color-combine code into sp_quad_blend.c
Consolidate the read-modify-write color combining code from
the blend, colormask and output stages.
2009-07-24 20:19:18 +01:00
Keith Whitwell
42f1757189 softpipe: fix typo 2009-07-24 20:18:52 +01:00
Keith Whitwell
333ec94380 softpipe: example fastpaths in blending 2009-07-24 18:46:17 +01:00
Keith Whitwell
a1dbd7aa15 softpipe: actually pass >1 quad from triangle routine
First attempt
2009-07-24 18:17:05 +01:00
Keith Whitwell
ab9fb51670 softpipe: expand quad pipeline to process >1 quad at a time
This is part one -- we still only pass a single quad down, but
the code can now cope with more.  The quads must all be from the same
tile.
2009-07-24 16:49:35 +01:00
Keith Whitwell
6153a1c28f softpipe: rip out old mulithread support 2009-07-24 16:12:48 +01:00
Brice Goglin
3c4727a4e9 Prepare changelog for upload 2009-07-24 00:29:35 +02:00
Brice Goglin
40f217aea7 Enable i686 optimized libraries on hurd-i386 2009-07-24 00:29:25 +02:00
Brice Goglin
d3403389cd Only install the huge upstream changelog in mesa-common-dev 2009-07-23 23:41:19 +02:00
Brice Goglin
a70d1eb1ee Pull from upstream mesa_7_5_branch 2009-07-23 21:11:22 +02:00
Brice Goglin
d7aa5d5ca0 Merge branch 'mesa_7_5_branch' of git://anongit.freedesktop.org/mesa/mesa into debian-unstable 2009-07-23 21:09:47 +02:00
Keith Whitwell
93a026d4ba softpipe: avoid flushing depth buffer cache on swapbuffers
There's no need to push out depth buffer contents on swapbuffers.

Note that this change doesn't throw away depth buffer changes, it simply
holds them in the cache over calls to swapbuffers.  The hope is
that swapbuffers will be followed by a clear() which means in that case
we won't have to write the changes out.
2009-07-23 11:14:39 +01:00
Keith Whitwell
19097907ef softpipe: also shortcircuit non-texture tile lookups 2009-07-23 09:35:33 +01:00
Keith Whitwell
f911c3b989 softpipe: shortcircuit repeated lookups of the same tile
The sp_tile_cache is often called repeatedly to look up the same
tile.  Add a cache (to the cache) of the single tile most recently
retreived and make a quick inline check to see if this matches the
subsequent request.

Add a tile_address bitfield struct to make this check easier.
2009-07-22 15:08:42 +01:00
Keith Whitwell
13e2d35764 softpipe: remove unused vars in sp_setup.c 2009-07-22 12:48:01 +01:00
Keith Whitwell
0ed99f4552 softpipe: use bitwise logic to setup quad masks in sp_setup 2009-07-22 12:48:00 +01:00
Keith Whitwell
73e7356385 softpipe: simplify flush_spans
No loss of performance, but simpler code.
2009-07-22 12:48:00 +01:00
Keith Whitwell
b5d583efef softpipe: make some small steps to flush texture cache less frequently
No performance gain yet, but the code is a bit cleaner.
2009-07-22 12:48:00 +01:00
Keith Whitwell
07bb026900 gallium/xlib: use XSHM for swapbuffers
Makes some difference, but suprisingly little.  Barely worth the effort.
2009-07-22 12:47:59 +01:00
Keith Whitwell
0ac879dca7 util: _debug_printf should print even when DEBUG is not defined
The leading underscore is meaningful...  This function is used by
_warning and _error functions as well as the more common
debug_printf().

debug_printf (without underscore) gets turned off when DEBUG is
disabled, but warning/error messages still use this function to get
their message out.
2009-07-22 12:47:59 +01:00
Keith Whitwell
aa5db68438 softpipe: remove backwards dependency from tilecache to softpipe
The tile cache is a utility, it shouldn't know anything about the
entity which is making use of it (ie softpipe).

Remove softpipe parameter to all the tilecache function calls, and
also remove the need to keep a softpipe pointer in the sampler structs.
2009-07-22 12:47:59 +01:00
Brice Goglin
04493de67b Prepare changelog for upload 2009-07-21 22:22:07 +02:00
Brice Goglin
e06e2b001f Install the upstream ChangeLog 2009-07-21 22:21:47 +02:00
Brice Goglin
d740456ee5 Install the upstream ChangeLog 2009-07-21 20:42:50 +02:00
Brice Goglin
45c5ed4bb8 Pull from upstream mesa_7_5_branch 2009-07-21 20:38:30 +02:00
Brice Goglin
19a8ce6f70 Merge branch 'mesa_7_5_branch' of git://anongit.freedesktop.org/mesa/mesa into debian-unstable 2009-07-21 20:05:24 +02:00
Brice Goglin
767c0b16f3 Prepare changelog for upload 2009-07-19 12:54:22 +02:00
Brice Goglin
3041819a4e New upstream release 2009-07-19 12:51:08 +02:00
Brice Goglin
4a9beaf2e9 Merge tag 'mesa_7_5' into debian-experimental
Conflicts:
	progs/tests/.gitignore
	progs/tests/Makefile
	progs/tests/SConscript
	progs/trivial/Makefile
	scons/dxsdk.py
	scons/gallium.py
2009-07-19 12:50:28 +02:00
Jakob Bornecrantz
5e6fff7ac4 svga: Do the gallium intel configure trick for svga as well
Since the drivers we produce on systems where we use
configure depend on none stable kernel API the driver
deliverables should not be built by default in the
mesa 7.7 release.

People wishing to shoot them self in the foot have to
pull the trigger themself, we just hand them the gun.
2009-07-19 09:29:14 +02:00
Ian Romanick
bf75ee9ccc mesa: set version string to 7.7-rc3 2009-12-16 09:15:09 -08:00
Ian Romanick
006a526edb Merge branch 'mesa_7_6_branch' into mesa_7_7_branch
Conflicts:
	src/mesa/drivers/dri/unichrome/via_ioctl.c
	src/mesa/drivers/dri/unichrome/via_screen.c
	src/mesa/main/version.h
	src/mesa/state_tracker/st_atom.c
2009-12-16 09:09:51 -08:00
Ian Romanick
42d9409873 mesa: set version string to 7.6.1-rc4 2009-12-16 09:01:58 -08:00
Ian Romanick
11522b74b3 Merge branch 'mesa_7_6_branch' into mesa_7_7_branch
Conflicts:
	src/gallium/drivers/softpipe/sp_quad_blend.c
2009-12-15 12:38:01 -08:00
Ian Romanick
b90f7f3ad3 i965: Use current draw buffer instead of drawable visual to get alpha bits
Use the currently bound draw buffer instead of the visual from the
drawable used to create the context.  This cause problems generating
mipmaps for an RGBA texture in an RGB context.

This fixes the failure in piglit's glsl-lod-bias test reported in bug #25614.
2009-12-14 16:30:53 -08:00
Jakob Bornecrantz
f4de0b176d vmwgfx: Update vmwgfx_drm.h to the on upstream 2009-12-14 22:27:08 +01:00
Jakob Bornecrantz
fb06d8f097 vmware/xorg: Use new stream ioctl 2009-12-14 22:12:20 +01:00
Brian Paul
69346c56a1 mesa/meta: move BindTexture() call in _mesa_meta_GenerateMipmap()
This is a follow-up to commit e3fa700c17.

The call to _mesa_BindTexture() must be before we set any other texture
object state, namely the _mesa_TexParameteri() calls.

This fixes bug 25601 (piglit gen-nonzero-unit failure).
2009-12-14 13:39:21 -07:00
Jakob Bornecrantz
48888b918b vmware/xorg: Fix failure paths and add some debug printing 2009-12-12 20:02:34 +01:00
Jakob Bornecrantz
49e4b624e5 vmwgfx/core: Check for 3D via the get param ioctl 2009-12-12 18:37:16 +01:00
Maciej Cencora
8413a3aefa radeon: fix #25463
This is just a workaroung until we properly fix texture mapping in radeonSpanRenderStart
2009-12-12 02:02:53 +01:00
Maciej Cencora
f1900323ea r300: fix depth textures 2009-12-11 23:56:47 +01:00
Brice Goglin
fe9b9fec39 Enable i686 optimized libraries on kfreebsd-i386 2009-07-17 18:21:27 +02:00
Timo Aaltonen
082f547492 Move dri.pc to mesa-common-dev (closes: #521667) 2009-06-29 15:22:21 +03:00
Julien Cristau
9032d6b40b Prepare changelog for upload 2009-06-28 20:22:05 +02:00
Julien Cristau
489ca73db1 Merge commit 'mesa-7.4.4-1' into debian-experimental
Conflicts:
	debian/changelog
2009-06-28 20:20:56 +02:00
Julien Cristau
2c8046b1bc Prepare changelog for upload 2009-06-28 18:58:41 +02:00
Julien Cristau
18bb120fce Refresh patches 2009-06-28 18:41:21 +02:00
Julien Cristau
d2c8712fa4 Remove some directories absent from the tarballs, and add some missing ones 2009-06-28 18:09:58 +02:00
Julien Cristau
b59211a602 Update changelog 2009-06-28 17:46:10 +02:00
Julien Cristau
adafe6d607 Merge commit 'mesa_7_5_rc4' into debian-experimental
Conflicts:
	progs/fp/point-position.c
	progs/fp/tri-depth.c
	progs/fp/tri-depth2.c
	progs/fp/tri-depthwrite.c
	progs/fp/tri-depthwrite2.c
	progs/fp/tri-inv.c
	progs/fp/tri-param.c
	progs/fp/tri-tex.c
	progs/tests/.gitignore
	progs/tests/Makefile
	progs/tests/zreaddraw.c
2009-06-28 17:41:50 +02:00
Julien Cristau
c38bc21cf5 add bug closer 2009-06-24 19:54:26 +02:00
Julien Cristau
1df36638c0 Don't build gallium for now. 2009-06-24 17:30:00 +02:00
Julien Cristau
dd89f8e3ea Merge branch 'debian-unstable' into debian-experimental
Conflicts:
	debian/changelog
	debian/patches/06_kfreebsd-ftbfs.diff
2009-06-24 17:26:42 +02:00
Julien Cristau
2ca61d4474 Merge commit 'mesa_7_4_4' into debian-experimental 2009-06-24 17:23:34 +02:00
Julien Cristau
22f1c449ae update changelog 2009-06-24 17:20:23 +02:00
Julien Cristau
2be8cd65cb Merge tag 'mesa_7_5_rc3' into debian-experimental 2009-06-24 17:19:16 +02:00
Julien Cristau
ec4c889266 Update 04_osmesa_version.diff, refresh 06_kfreebsd-ftbfs.diff. 2009-06-24 12:37:17 +02:00
Julien Cristau
c84a384fdf Update changelog 2009-06-24 12:32:20 +02:00
Julien Cristau
f56634caea Merge tag 'mesa_7_4_4' into debian-unstable 2009-06-24 12:27:10 +02:00
Brian Paul
d0c391b6a2 docs: set 7.4.4 release date 2009-06-23 18:53:31 -06:00
Brian Paul
eaed8dc609 mesa: bump version to 7.4.4 2009-06-22 15:27:03 -06:00
Brian Paul
b5609e6444 docs: release notes for 7.4.4 2009-06-22 15:26:19 -06:00
Brian Paul
0b870bbb2a docs: 7.4.3 MD5 checksums 2009-06-22 11:24:09 -06:00
Brian Paul
1dbbc39f48 intel: added a null ptr check
This was hit during screen tear-down.
2009-06-22 11:23:44 -06:00
Brian Paul
4b8cd0b0ad intel: call _mesa_unreference_framebuffer() in intelDestroyBuffer()
This was a call to _mesa_reference_framebuffer(ptr, NULL) but the NULL
pointer is incorrect in Mesa 7.4.x.

Fixes a failed assertion during screen tear-down.
2009-06-22 11:23:13 -06:00
Brian Paul
5d387a35ff docs: set 7.4.3 release date 2009-06-19 15:16:01 -06:00
Brian Paul
2ae6859215 docs: bump version to 7.4.3 2009-06-19 15:14:49 -06:00
Brian Paul
afe0ca1f3f mesa: rework viewport/scissor initialization code
The first time a context is bound to a drawable, the viewport and scissor
bounds are initialized to the buffer's size.  This is actually a bit tricky.

A new _mesa_check_init_viewport() function is called in several places
to check if the viewport has been initialized.  We also use a new
ctx->ViewportInitialized flag instead of the overloaded
ctx->FirstTimeCurrent flag.

Hand-picked from mesa_7_5_branch, commit 3f856c6b6b
2009-06-17 08:43:17 -06:00
Brian Paul
6b782231d0 mesa: added null ptr check in Fake_glXCreatePixmap()
Fixes segfault in progs/xdemos/glxgears_pixmap.c

(cherry picked from master, commit d18c57aaea)
2009-06-17 08:40:16 -06:00
Brian Paul
2b890c9818 docs: document GLX/glean makeCurrent fix 2009-06-17 08:06:50 -06:00
Brian Paul
e0b13e15f1 GLX: attempt to fix glean makeCurrent test cases.
Two parts to this:

One we don't keep pointers to possibly freed memory anymore once we unbind the
drawables from the context. Brian I need to figure out what the comment
you made there, can we get a glean/piglit test so we can fix it properly?

If the new gc is the same as the oldGC, we call the unbind even though
we just bound it in that function. doh.

(cherry picked from master, commit 77506dac8e)
2009-06-17 08:05:54 -06:00
Brian Paul
420c74b870 docs: document viewport clamping bug 2009-06-16 09:40:22 -06:00
Brian Paul
a64f994a3a mesa: fix incorrect viewport clamping in _mesa_set_viewport()
A 0 by 0 viewport size is legal.  Don't clamp against lower bound of one.
The error checking earlier in the function prevents negative values.
2009-06-16 09:39:33 -06:00
Brian Paul
c568446dc6 docs: fixed bug 21872 2009-06-16 08:48:26 -06:00
Brian Paul
acbf9c6f3c mesa: fix REMAINDER() macro
The results were incorrect for some negative values of A.
See bug 21872.

(cherry picked from mesa_7_5_branch, commit ed7f4b4230)
2009-06-16 08:48:12 -06:00
Brian Paul
3b842feead docs: recent fixes for 7.4.3 2009-06-15 16:24:03 -06:00
Brian Paul
6d62b8d5c1 intel: Release fb backing regions in intelDestroyBuffer()
Fixes memory leak when destroying framebuffers.

(cherry picked from mesa_7_5_branch, commit d027e8feff)
2009-06-15 16:22:54 -06:00
Brian Paul
02659868e8 glsl: fix warnings, update comments, s/TRUE/GL_TRUE/
(cherry picked from master, commit 7fdd64ab29)
2009-06-10 12:26:12 -06:00
Brian Paul
457f4efab0 glsl: Handle continuation characters in preprocessor.
(cherry picked from master, commit cc22620e4b)
2009-06-10 12:25:35 -06:00
Brian Paul
0269eb5e3f glsl: Fix symbol replacement handling in preprocessor.
(cherry picked from master, commit d9617deb00)
2009-06-10 12:25:11 -06:00
Brian Paul
b7d9be69b2 glsl: Expand nested preprocessor macros.
(cherry picked from master, commit ef8caec29a)
2009-06-10 12:24:52 -06:00
Brian Paul
7b8b856c97 glsl: Fix preprocessor define argument parsing for dead sections.
(cherry picked from master, commit 19a54d9f10)
2009-06-10 12:24:32 -06:00
Brian Paul
24bffc4cc2 glsl: preprocessor debug code (disabled)
(cherry picked from master, commit 854151ba62)
2009-06-10 12:24:11 -06:00
Brian Paul
586341afd9 docs: document recent bug fixes for 7.4.x 2009-06-05 17:30:51 -06:00
Dan Nicholson
1e4334f623 osmesa: Link with -ldl for dlopen code
Now that the dlopen wrappers are built into libmesa.a, we need to link
standalone libOSMesa with libdl to resolve dlopen and friends on
platforms that need it.
(cherry picked from commit 4795dd5950)
2009-06-04 19:45:58 -07:00
Dan Nicholson
8861577fd1 osmesa: Allow building standalone in all three channel widths
autoconf had been designating the 8 bit libOSMesa as the default
standalone osmesa, but the Makefile expected it to be linked to libGL.
Fix up the osmesa Makefile so that it allows any of the combinations of
standalone and channel width to be built.

Fixes bug #21980.
(cherry picked from commit 7441dcd90b)
2009-06-04 19:05:48 -07:00
Brian Paul
cf997e0d2e mesa: fix loop over generic attribs in update_arrays()
(cherry picked from commit 1045481dd9)
2009-06-01 15:04:35 -06:00
Timo Aaltonen
f3496a3cbd mesa-common-dev.install: Don't install glxew.h, conflicts with libglew. 2009-06-01 22:26:27 +03:00
Julien Cristau
4bcb9cc14f Update patches
+ 02_use-ieee-fp-on-s390-and-m68k.patch moved from imports.h to compiler.h
+ 03_optional-progs-and-install.patch refreshed
+ 05_hurd-ftbfs.diff partly applied upstream
+ 06_kfreebsd-ftbfs.diff refreshed
2009-05-31 13:15:00 +02:00
Julien Cristau
537f3e7a1e Install dri.pc, which will be needed to build xorg-server 1.7. 2009-05-31 12:52:47 +02:00
Julien Cristau
2096234053 clarify changelog: this is only a release candidate 2009-05-30 21:08:54 +02:00
Timo Aaltonen
99b4daf5e1 Disable EGL.
Update the changelog too.
2009-05-25 12:47:02 +03:00
Brian Paul
506d340363 demos: fix multitex.c VertCoord attribute mapping
If the multitex.vert shader uses the VertCoord generic vertex attribute
instead of the pre-defined gl_Vertex attribute, we need to make sure that
VertCoord gets bound to generic vertex attribute zero.

That's because we need to call glVertexAttrib2fv(0, xy) after all the other
vertex attributes have been set since setting generic attribute 0 triggers
vertex submission.  Before, we wound up issuing the vertex attributes in
the order 0, 1, 2 which caused the first vertex to be submitted before all
the attributes were set.  Now, the attributes are set in 1, 2, 0 order.

(cherry picked from commit 58fadc6242)
2009-05-22 13:20:48 -06:00
Brian Paul
9dbe32f5eb vbo: fix crash in vbo_exec_bind_arrays()
When a vertex shader uses generic vertex attribute 0, but not gl_Vertex,
we need to set attribute[16] to point to attribute[0].  We were setting the
attribute size, but not the pointer.

Fixes crash in glsl/multitex.c when using the VertCoord attribute instead
of gl_Vertex.

(cherry picked from commit c3538969e1)
2009-05-22 13:19:42 -06:00
Brian Paul
9adca8814d mesa: allow GL_BITMAP type in _mesa_image_image_stride()
It's possible to hand a GL_COLOR_INDEX/GL_BITMAP image to glTexImage3D()
which gets converted to RGBA via the glPixelMap tables.

This fixes a failure with piglit/fdo10370 with Gallium.

(cherry picked from commit 995456f930)
2009-05-22 09:38:18 -06:00
Brian Paul
8125c5ce92 docs: updates for version 7.4.3 2009-05-22 07:13:47 -06:00
Brian Paul
ba3f8dc0aa mesa: bump version to 7.4.3 2009-05-22 07:13:34 -06:00
Brian Paul
85cf1675d4 mesa: bump version to 7.4.3 2009-05-22 07:13:30 -06:00
Brian Paul
3aeace2928 vbo: fix incorrect loop limit in bind_array_obj()
The generic_array[] is 16 elements in size, but the loop was doing 32
iterations.  The out of bounds array write was clobbering the following
inputs[] array but as luck would have it, that didn't matter.

(cherry picked from commit 8da09e6924)
2009-05-22 07:10:47 -06:00
Brian Paul
0edb61afef docs: add glGet case for GL_VERTEX_ARRAY_BINDING_APPLE 2009-05-22 07:08:38 -06:00
Brian Paul
accffe2b73 mesa: add missing glGet*() case for GL_VERTEX_ARRAY_BINDING_APPLE
(cherry picked from commit 70c4b81e88)
2009-05-22 07:07:38 -06:00
Brian Paul
35f5222ae0 mesa: remove texUnit->_Current = NULL assignment
A follow-on to commit 46a2aad2cf which
fixes a texture object memory leak.

See bug 21756.
2009-05-20 08:14:45 -06:00
Brian Paul
1096a6c579 docs: 7.4.3 relnotes edits 2009-05-19 10:06:58 -06:00
Brian Paul
1eb59f49a4 docs: start 7.4.3 release notes 2009-05-19 10:06:09 -06:00
Brian Paul
63d1e89138 mesa: allow depth/stencil textures to be attached to GL_STENCIL_ATTACHMENT
See sourceforge bug #2793846.

(cherry picked from commit 042d9a5132)
2009-05-19 10:04:17 -06:00
Brian Paul
3ed7e9bfcc mesa: assign trb->Base.StencilBits in update_wrapper().
When we render to a depth/stencil texture there are stencil bits.

(cherry picked from commit c99a60c40d)
2009-05-19 10:02:55 -06:00
Brian Paul
46a2aad2cf mesa: fix texture object reference counting in texture_override()
Fixes bug 21756: r200: Mesa-7.4.2 release regression: "Quit on exit".
2009-05-19 09:03:19 -06:00
Timo Aaltonen
73670d56e8 Merge branch 'debian-experimental' into test
Conflicts:
	Makefile
	configs/default
	docs/download.html
	docs/news.html
	docs/relnotes-7.4.2.html
	doxygen/.gitignore
	include/GL/internal/dri_interface.h
	include/GLES/egl.h
	progs/demos/Windows/all.dsp
	progs/demos/Windows/bounce.dsp
	progs/demos/Windows/clearspd.dsp
	progs/demos/Windows/cubemap.dsp
	progs/demos/Windows/demos.dsw
	progs/demos/Windows/drawpix.dsp
	progs/demos/Windows/fire.dsp
	progs/demos/Windows/gears.dsp
	progs/demos/Windows/geartrain.dsp
	progs/demos/Windows/glinfo.dsp
	progs/demos/Windows/gloss.dsp
	progs/demos/Windows/gltestperf.dsp
	progs/demos/Windows/glutfx.dsp
	progs/demos/Windows/ipers.dsp
	progs/demos/Windows/isosurf.dsp
	progs/demos/Windows/loadbias.dsp
	progs/demos/Windows/morph3d.dsp
	progs/demos/Windows/multiarb.dsp
	progs/demos/Windows/occlude.dsp
	progs/demos/Windows/osdemo.dsp
	progs/demos/Windows/paltex.dsp
	progs/demos/Windows/pixeltex.dsp
	progs/demos/Windows/pointblast.dsp
	progs/demos/Windows/rain.dsp
	progs/demos/Windows/ray.dsp
	progs/demos/Windows/readpix.dsp
	progs/demos/Windows/reflect.dsp
	progs/demos/Windows/renormal.dsp
	progs/demos/Windows/shadowtex.dsp
	progs/demos/Windows/spectex.dsp
	progs/demos/Windows/spriteblast.dsp
	progs/demos/Windows/stex3d.dsp
	progs/demos/Windows/teapot.dsp
	progs/demos/Windows/terrain.dsp
	progs/demos/Windows/tessdemo.dsp
	progs/demos/Windows/texcyl.dsp
	progs/demos/Windows/texdown.dsp
	progs/demos/Windows/texenv.dsp
	progs/demos/Windows/texobj.dsp
	progs/demos/Windows/trispd.dsp
	progs/demos/Windows/tunnel.dsp
	progs/demos/Windows/tunnel2.dsp
	progs/demos/Windows/winpos.dsp
	progs/demos/dinoshade.c
	progs/demos/projtex.c
	progs/egl/Makefile
	progs/egl/demo1.c
	progs/egl/demo2.c
	progs/egl/demo3.c
	progs/egl/eglgears.c
	progs/egl/eglinfo.c
	progs/fp/.gitignore
	progs/fp/Makefile
	progs/miniglx/Makefile
	progs/redbook/Windows/redbook.dsw
	progs/redbook/Windows/teapots.dsp
	progs/slang/windows/vc60/cltest.dsp
	progs/slang/windows/vc60/framework.dsp
	progs/slang/windows/vc60/slang.dsw
	progs/slang/windows/vc60/sotest.dsp
	progs/slang/windows/vc60/vstest.dsp
	progs/tests/.gitignore
	progs/tests/Makefile
	progs/tests/afsmultiarb.c
	progs/tests/antialias.c
	progs/tests/api_speed.c
	progs/tests/arbfpspec.c
	progs/tests/arbfptest1.c
	progs/tests/arbfptexture.c
	progs/tests/arbfptrig.c
	progs/tests/arbnpot-mipmap.c
	progs/tests/arbnpot.c
	progs/tests/arbvptest1.c
	progs/tests/arbvptest3.c
	progs/tests/arbvptorus.c
	progs/tests/arbvpwarpmesh.c
	progs/tests/arraytexture.c
	progs/tests/blendminmax.c
	progs/tests/blendsquare.c
	progs/tests/blendxor.c
	progs/tests/bufferobj.c
	progs/tests/bug_3050.c
	progs/tests/bug_3101.c
	progs/tests/bug_3195.c
	progs/tests/copypixrate.c
	progs/tests/crossbar.c
	progs/tests/cva.c
	progs/tests/debugger.c
	progs/tests/drawbuffers.c
	progs/tests/exactrast.c
	progs/tests/ext422square.c
	progs/tests/fbotest1.c
	progs/tests/fbotest2.c
	progs/tests/floattex.c
	progs/tests/fog.c
	progs/tests/fogcoord.c
	progs/tests/fptest1.c
	progs/tests/fptexture.c
	progs/tests/interleave.c
	progs/tests/invert.c
	progs/tests/jkrahntest.c
	progs/tests/lineclip.c
	progs/tests/manytex.c
	progs/tests/minmag.c
	progs/tests/mipmap_limits.c
	progs/tests/multipal.c
	progs/tests/multitexarray.c
	progs/tests/multiwindow.c
	progs/tests/no_s3tc.c
	progs/tests/packedpixels.c
	progs/tests/pbo.c
	progs/tests/prog_parameter.c
	progs/tests/random.c
	progs/tests/readrate.c
	progs/tests/rubberband.c
	progs/tests/seccolor.c
	progs/tests/shader_api.c
	progs/tests/stencil_twoside.c
	progs/tests/stencil_wrap.c
	progs/tests/stencilwrap.c
	progs/tests/subtexrate.c
	progs/tests/tex1d.c
	progs/tests/texcmp.c
	progs/tests/texcompress2.c
	progs/tests/texfilt.c
	progs/tests/texgenmix.c
	progs/tests/texline.c
	progs/tests/texrect.c
	progs/tests/texwrap.c
	progs/tests/unfilledclip.c
	progs/tests/vao-01.c
	progs/tests/vao-02.c
	progs/tests/vparray.c
	progs/tests/vpeval.c
	progs/tests/vptest1.c
	progs/tests/vptest2.c
	progs/tests/vptest3.c
	progs/tests/vptorus.c
	progs/tests/vpwarpmesh.c
	progs/tests/yuvrect.c
	progs/tests/yuvsquare.c
	progs/tests/zreaddraw.c
	progs/trivial/.gitignore
	progs/trivial/Makefile
	progs/trivial/clear.c
	progs/trivial/dlist-dangling.c
	progs/trivial/dlist-edgeflag-dangling.c
	progs/trivial/dlist-edgeflag.c
	progs/trivial/drawarrays.c
	progs/trivial/drawelements.c
	progs/trivial/drawrange.c
	progs/trivial/line-clip.c
	progs/trivial/line-cull.c
	progs/trivial/line-userclip-clip.c
	progs/trivial/line-userclip-nop-clip.c
	progs/trivial/line-userclip-nop.c
	progs/trivial/line-userclip.c
	progs/trivial/line.c
	progs/trivial/lineloop-clip.c
	progs/trivial/lineloop.c
	progs/trivial/point-clip.c
	progs/trivial/point-param.c
	progs/trivial/point-wide.c
	progs/trivial/point.c
	progs/trivial/poly-flat.c
	progs/trivial/poly-unfilled.c
	progs/trivial/poly.c
	progs/trivial/quad-clip-all-vertices.c
	progs/trivial/quad-clip-nearplane.c
	progs/trivial/quad-clip.c
	progs/trivial/quad-degenerate.c
	progs/trivial/quad-flat.c
	progs/trivial/quad-offset-factor.c
	progs/trivial/quad-offset-unfilled.c
	progs/trivial/quad-offset-units.c
	progs/trivial/quad-tex-2d.c
	progs/trivial/quad-tex-3d.c
	progs/trivial/quad-tex-pbo.c
	progs/trivial/quad-unfilled.c
	progs/trivial/quad.c
	progs/trivial/quads.c
	progs/trivial/quadstrip-flat.c
	progs/trivial/quadstrip.c
	progs/trivial/tri-blend.c
	progs/trivial/tri-clip.c
	progs/trivial/tri-cull.c
	progs/trivial/tri-dlist.c
	progs/trivial/tri-edgeflag.c
	progs/trivial/tri-flat-clip.c
	progs/trivial/tri-flat.c
	progs/trivial/tri-tex-3d.c
	progs/trivial/tri-unfilled-clip.c
	progs/trivial/tri-unfilled-smooth.c
	progs/trivial/tri-unfilled-userclip.c
	progs/trivial/tri-unfilled.c
	progs/trivial/tri-userclip.c
	progs/trivial/tri.c
	progs/trivial/tristrip-clip.c
	progs/trivial/tristrip.c
	progs/trivial/vbo-drawarrays.c
	progs/trivial/vbo-drawelements.c
	progs/trivial/vbo-drawrange.c
	progs/trivial/vp-array.c
	progs/trivial/vp-clip.c
	progs/trivial/vp-line-clip.c
	progs/trivial/vp-tri.c
	progs/trivial/vp-unfilled.c
	progs/vp/Makefile
	progs/vp/vp-tris.c
	src/egl/Makefile
	src/egl/drivers/demo/Makefile
	src/egl/drivers/demo/demo.c
	src/egl/drivers/dri/Makefile
	src/egl/drivers/dri/egldri.c
	src/egl/drivers/dri/egldri.h
	src/egl/main/Makefile
	src/egl/main/eglapi.c
	src/egl/main/eglapi.h
	src/egl/main/eglconfig.c
	src/egl/main/eglconfig.h
	src/egl/main/eglcontext.c
	src/egl/main/eglcontext.h
	src/egl/main/egldisplay.c
	src/egl/main/egldisplay.h
	src/egl/main/egldriver.c
	src/egl/main/egldriver.h
	src/egl/main/eglglobals.c
	src/egl/main/eglglobals.h
	src/egl/main/egllog.c
	src/egl/main/eglmode.h
	src/egl/main/eglsurface.c
	src/egl/main/eglsurface.h
	src/egl/main/egltypedefs.h
	src/glx/mini/Makefile
	src/glx/x11/dri2_glx.c
	src/mesa/drivers/allegro/amesa.c
	src/mesa/drivers/dri/intel/intel_buffers.c
	src/mesa/drivers/dri/intel/intel_clear.c
	src/mesa/drivers/dri/intel/intel_context.c
	src/mesa/drivers/dri/intel/intel_pixel.c
	src/mesa/drivers/dri/r300/r300_texstate.c
	src/mesa/drivers/dri/radeon/radeon_screen.c
	src/mesa/drivers/windows/gldirect/dx7/gld_wgl_dx7.c
	src/mesa/drivers/windows/gldirect/dx8/gld_wgl_dx8.c
	src/mesa/drivers/windows/gldirect/dx9/gld_wgl_dx9.c
	src/mesa/main/glheader.h
	src/mesa/main/light.c
	src/mesa/main/teximage.c
	src/mesa/main/texparam.c
	src/mesa/main/version.h
	src/mesa/swrast/s_texfilter.c
2009-05-18 14:05:53 +03:00
Aidan Thornton
b5eafa2d51 Initialize psp->waitX/waitGL for swrast_dri.so.
Fixes http://bugs.freedesktop.org/show_bug.cgi?id=21053 .
(cherry picked from commit f2445dfd85)
2009-05-18 12:51:12 +02:00
Timo Aaltonen
ac00f6a47a Merge commit 'mesa_7_4' into test 2009-05-18 13:21:01 +03:00
Brian Paul
d1fcb4a263 docs 7.4.2 tarball md5 sums 2009-05-15 06:32:24 -06:00
Brian Paul
da709f163f docs: set 7.4.2 release date 2009-05-15 06:21:56 -06:00
Brian Paul
3a1bcbe579 mesa: bump version to 7.4.2 2009-05-14 13:20:13 -06:00
Brian Paul
ec863602f2 i965: fix render to FBO/texture orientation bugs
Anytime we're not rendering to the default/window FBO, need to invert
rendering, not just when rendering to a texture.  Otherwise, if a FBO
consists of a mix of textures and renderbuffers the up/down orientation
was inconsistant.

Fixes shadowtex.c bad rendering.
(cherry picked from commit ba367f68cc)
2009-05-13 14:13:46 -07:00
Brian Paul
2ff47b80f5 docs: updated bug fix list for 7.4.2 2009-05-11 09:49:46 -06:00
Brian Paul
63cde0ea0e mesa: Fixed a texture memory leak
The current texture for any particular texture unit is given an additional
reference in update_texture_state(); but if the context is closed before
that texture can be released (which is quite frequent in normal use, unless
a program unbinds and deletes the texture and renders without it to force
a call to update_texture_state(), the memory is lost.

This affects general Mesa; but the i965 is particularly affected because
it allocates a considerable amount of additional memory for each allocated
texture.

(cherry picked from master, commit c230767d69)
2009-05-11 09:47:17 -06:00
Brice Goglin
ab885d7088 Enable motif in GLw 2009-05-09 20:49:15 +02:00
Eric Anholt
c521d4629b Flag GLSL programs as depending on constant state when they use uniforms.
This is not a cherry-pick, as it got fixed in master with the
_NEW_PROGRAM_CONSTANTS change.  Fixes bad rendering with various GLSL programs
idr and I have been writing.
2009-05-05 12:14:29 -07:00
Brian Paul
e9d5569bf3 glx: replace Xmalloc() calls with Xcalloc()
Fixes a bug where psp->WaitX was uninitialized.  Reported by Chris Clayton.

(cherry picked from commit dd4c142e90)
2009-05-04 08:34:20 -06:00
Julien Cristau
84ae506072 Don't build hardware dri drivers on s390. 2009-05-03 19:30:02 +02:00
Julien Cristau
4842cde28f Prepare changelog for upload 2009-05-03 16:05:30 +02:00
Julien Cristau
b651c02dca Fix Architecture field for libgl1-mesa-dri-dbg 2009-05-03 16:04:39 +02:00
Julien Cristau
ec44d955bb Move -dbg packages to new 'debug' section. 2009-05-03 16:03:58 +02:00
Julien Cristau
914edc46fa Update changelog 2009-05-03 14:31:05 +02:00
Julien Cristau
64cb29deca Merge branch 'mesa_7_4_branch' of git.freedesktop.org:/git/mesa/mesa into debian-unstable 2009-05-03 14:26:30 +02:00
Brian Paul
6337525497 mesa: fix state validation bug for glCopyTex[Sub]Image()
We need to make sure the framebuffer state is up to date to make sure we
read pixels from the right buffer when doing a texture image copy.

(cherry-picked from master, commit 63f0130980)
2009-05-01 20:24:39 -06:00
Brian Paul
7541c3806a docs: fix typos 2009-04-30 17:08:37 -06:00
Michel Dänzer
a1ce4efefb r300: Increase reference count of texture objects referenced by current state.
Fixes a use-after-free reported in
http://bugs.freedesktop.org/show_bug.cgi?id=20539, so this possibly fixes that
bug. It has been confirmed to fix
http://bugs.freedesktop.org/show_bug.cgi?id=17895 .
(cherry picked from commit c28707b507)
2009-04-30 13:50:36 +02:00
Brian Paul
656cd707db mesa: Fix buffer overflow when parsing generic vertex attributes.
(cherry picked from master, commit fa92756400)
2009-04-28 10:58:13 -06:00
Alex Deucher
ce7f78694d R300: add quadpipe overrides
RV410 SE chips only have 1 quadpipe.
Also, handle other R300 chip with quadpipe override
2009-04-28 12:40:04 -04:00
Brian Paul
fd95e8ee33 docs: fix swrast texrect bug 21461 2009-04-28 09:11:05 -06:00
Brian Paul
d2b8c41b7a swrast: add missing break in clamp_rect_coord_linear()
See bug 21461.

(cherry picked from master, commit dcf571aff9)
2009-04-28 09:09:41 -06:00
Alan Hourihane
bfd6bb31a6 demos: ensure display lists are destroyed for next generation 2009-04-24 17:22:52 +01:00
Eric Anholt
c3e7fc394f i965: Support drawing to FBO cube faces other than positive X.
Also fixes drawing to 3D texture depth levels.
(cherry picked from commit 8374379572)
2009-04-23 14:05:58 -07:00
Eric Anholt
dd56897b27 intel: Fix commented-out glViewport in intel_meta_set_passthrough_transform.
Too much commit -a while debugging.
(cherry picked from commit 8910da5b7a)
2009-04-23 14:00:56 -07:00
Brian Paul
e8807a14a6 fixed intel front-buffer rendering segfault 2009-04-20 16:13:04 -06:00
Brian Paul
c38397866d intel: added null screen->dri2.loader pointer check
Fixes front-buffer rendering with DRI1.
2009-04-20 16:12:16 -06:00
Brice Goglin
d7b9a6c9ef Add patch by Aurelien Jarno to fix FTBPS on kfreebsd-i386 2009-04-20 12:36:44 +02:00
Julien Cristau
4f2bc058f3 Add patch by Samuel Thibault to fix FTBFS on hurd-i386. 2009-04-19 00:46:32 +02:00
Julien Cristau
909afc5304 Adjust libgl1-mesa-glx and libgl1-mesa-dri package relationships
Drop the dependency on libgl1-mesa-glx from -dri, and make -glx
recommend -dri instead.  The dri drivers are also loaded by the X
server, which doesn't need libGL.  On the other hand, libGL needs one of
the dri drivers for direct rendering (either software or hardware).
Mark libgl1-mesa-dri as breaking old xserver-xorg-core and
libgl1-mesa-glx, to avoid incompatibilities.
2009-04-18 22:28:35 +02:00
Julien Cristau
4deb679b42 Make libgl1-mesa-dri 'Architecture: any'
swrast_dri.so should get built everywhere.
2009-04-18 22:27:51 +02:00
Brian Paul
dce84002c2 docs: create 7.4.2 release notes page 2009-04-18 11:12:41 -06:00
Brian Paul
c490349825 docs: remove unused sections 2009-04-18 11:12:33 -06:00
Brian Paul
f62d45fd0d docs: MD5 sums for 7.4.1 release 2009-04-18 11:03:25 -06:00
Brian Paul
b2dfc29a82 intel: update driver date, remove RC3 designation 2009-04-18 10:51:41 -06:00
Brian Paul
7c1e61f41c mesa: bump version to 7.4.1 2009-04-18 10:49:35 -06:00
Brian Paul
5654197d12 docs: prep for 7.4.1 release 2009-04-18 10:49:08 -06:00
Brian Paul
87cb55e9c6 mesa: bump version to 7.4.1 2009-04-18 10:48:57 -06:00
Brian Paul
e7d499f935 mesa: add switch case for GL_VERTEX_STATE_PROGRAM_NV in _mesa_new_program()
Fixes bug seen in progs/tests/vptest1.c

(cherry picked from master, commit c5af2ed60f)
2009-04-18 10:21:00 -06:00
Michel Dänzer
51e7600d77 intel: Handle ARB_vertex_buffer_object state in intel_clear_tris().
Fixes gearsvbo app by Michael Clark.
(cherry picked from commit 54fb6f0053)
2009-04-18 15:53:08 +02:00
Brian Paul
69b17abd6b intel: make sure polygon mode is set properly in intel_clear_tris()
Fixes progs/glsl/skinning.c demo.

(cherry picked from master, commit 794d488e6d)
2009-04-17 16:14:39 -06:00
Brian Paul
a975da7aca docs: fixed user clip plane restore bug in glPopAttrib() 2009-04-16 10:16:38 -06:00
Brian Paul
ecf47b5046 mesa: fix bad mask bit in clip plane restore code for glPopAttrib()
(cherry picked from master commit d82876e850)
2009-04-16 10:16:26 -06:00
Brian Paul
fed8dc53ad mesa: add distclean target to top-level Makefile
(cherry picked from master, commit 666702baec)
2009-04-16 09:34:06 -06:00
Brian Paul
1f462e26c0 demos: use larger buffer for snprintf() call, see bug 21220
(cherry picked from master, commit 0d0028e6df)
2009-04-16 09:26:54 -06:00
Ian Romanick
85396d8ef4 intel: Bump driver date 2009-04-15 15:12:48 -07:00
Ian Romanick
f11b84998d docs: more bug fixes for Mesa 7.4.1 2009-04-15 15:10:33 -07:00
Julien Cristau
5d4659e7c7 Install pkgconfig files for libGLU, libOSMesa and libGLw. 2009-04-15 21:31:24 +02:00
Julien Cristau
c422347bee Make libgl1-mesa-dev and mesa-common-dev 'Architecture: any'.
This gets rid of uninstallability when a new upstream version
isn't built on all architectures, and allows us to ship potentially
arch-specific .pc files.
2009-04-15 21:25:17 +02:00
Brian Paul
d2f6791062 glx: added null pointer check in glXGetFBConfigs()
Fixes segfault seen with glxinfo with NVIDIA OpenGL.

(cherry picked from master, commit 05471828dc)
2009-04-15 08:02:38 -06:00
Ian Romanick
49e0c74ddd DRI2: Don't fault on NULL DrawBuffer
It is possible for ctx->DrawBuffer to be NULL, so don't fault when
that happens.  This change is not being committed to master because it
doesn't appear to be necessary there.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2009-04-11 20:24:15 -07:00
Eric Anholt
83e14773c5 dri2: Don't crash if the server returns more buffers than expected.
(cherry picked from commit f967e8b507)
2009-04-09 15:15:33 -07:00
Ian Romanick
4605937843 intel / DRI2: Accept fake front-buffer from loader
Handle the loader returning a fake front-buffer.  Since the driver
never specifically requests a fake front-buffer, the driver assumes
that it will never receive both a fake and a real front-buffer.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kristian Høgsberg <krh@redhat.com>
(cherry picked from commit 6a6e478e55)
2009-04-09 14:44:53 -07:00
Ian Romanick
b8ef30c45c DRI2: Assume that there is always a front buffer
Assume that the front-buffer exists even if the server didn't tell the
client that it exists.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kristian Høgsberg <krh@redhat.com>
(cherry picked from commit e6386e0d9a)
2009-04-09 14:44:44 -07:00
Ian Romanick
4f17040cb1 intel / DRI2: Track and flush front-buffer rendering
Track two flags:  whether or not front-buffer rendering is currently
enabled and whether or not front-buffer rendering has been enabled
since the last glFlush.  If the second flag is set, the front-buffer
is flushed via a loader call back.  If the first flag is cleared, the
second flag is cleared at this time.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kristian Høgsberg <krh@redhat.com>
(cherry picked from commit 43cf0d1eeb)
2009-04-09 14:44:34 -07:00
Ian Romanick
98c2c9ef8c DRI2: Provide an interface for drivers to flush front-buffer rendering
Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Kristian Høgsberg <krh@redhat.com>
(cherry picked from commit 82634ee8df)
2009-04-09 14:44:17 -07:00
Brian Paul
d805c82068 mesa: fix potential recursive locking deadlock in _mesa_HashWalk()
If the walk callback called _mesa_HashRemove() we'd deadlock.

(cherry picked from master, commit deff099215)
2009-04-09 10:55:06 -06:00
Julien Cristau
3d81e934e5 Upload to unstable. 2009-04-08 23:53:54 +01:00
Brian Paul
6c3bec4387 swrast: fix point rendering function selection
Need to clamp default point size to min/max range before checking if it's one.
Fixes glean pointAtten test.

(cherry picked from master, commit 228f20e324)
2009-04-07 13:44:50 -06:00
Brian Paul
7d3561c871 docs: more bug fixes for Mesa 7.4.1 2009-04-07 08:37:22 -06:00
Brian Paul
5c47d53924 mesa: in mesa_add_named_constant(), avoid adding duplicate constants
(cherry picked from master, commit 80197a0c1b)
2009-04-07 08:35:01 -06:00
Brian Paul
a18216308a mesa: fix parameter counting in ARB vertex/fragment program parsing
Duplicated unnamed constants were getting counted more than once.

(cherry picked from master, commit 866bdd0509)
2009-04-07 08:34:32 -06:00
Brian Paul
14f13fbcfa mesa: replace >= with > when testing if we've exceeded max local params
Now a program that uses 256 locals works as it should.

(cherry picked from master, commit a4173956eb)
2009-04-07 08:34:04 -06:00
Brian Paul
ca24095c1e mesa: only clear matrix MAT_DIRTY_INVERSE flag when we actually compute the inverse
If _math_matrix_analyse() got called before we allocated the inverse
matrix array we could lose the flag indicating that we needed to compute
the inverse.  This could happen with certain vertex shader cases.

(cherry picked from master, commit ce461ffc5a)
2009-04-07 08:33:43 -06:00
Brian Paul
d5e0e03d43 mesa: for OPCODE_LIT, use _mesa_pow() instead of exp() and log()
Also, s/pow/_mesa_pow/

(cherry picked from master, commit b8a200ac9d)
2009-04-07 08:32:42 -06:00
Michel Dänzer
775ca8e3fa radeon: Expose a 32 bit RGBA fbconfig even when the screen depth is 16.
Otherwise current xserver / libGL no longer expose a 32 bit RGBA GLX visual,
and compiz fails.

Fixes http://bugs.freedesktop.org/show_bug.cgi?id=20479 .

(Cherry picked from commit e798bf8053)
2009-04-06 09:27:17 +02:00
Brian Paul
39345a4928 mesa: don't normalize spot light direction until validation time
In glLight() we're only supposed to transform the direction by the modelview
matrix, not normalized it too.

(cherry picked from commit 650d147289)
2009-04-03 10:16:31 -06:00
Roland Scheidegger
7be149cfd1 mesa: fix TexParameter functions
premature return in TexParameterf caused mesa to never call Driver.TexParameter
breaking drivers relying on this (fix bug #20966).
While here, also fix using ctx->ErrorValue when deciding to call
Driver.TexParameter. Errors are sticky and uncleared errors thus would cause
this to no longer get called. Since we thus need return value of
set_tex_parameter[if] can also optimize this to only call when value changed.
2009-04-03 00:00:40 +02:00
Brian Paul
8c9d7b2474 docs: fix TXB texture unit bias error 2009-04-02 13:11:56 -06:00
Brian Paul
6ef0951b17 mesa: don't call ctx->Driver.ReadPixels() if width or height is zero
(cherry picked from commit master, 7b9bf39543)
2009-04-02 13:11:33 -06:00
Brian Paul
2b33b77337 mesa: don't call ctx->Driver.Draw/CopyPixels() if width or height is zero
(cherry picked from master, commit f6a3f1f52a)
2009-04-02 13:10:41 -06:00
Brian Paul
0590edeea0 mesa: use correct tex unit lod bias for TXB instruction
(cherry picked from master, commit 1ab225017e)
2009-04-02 13:09:32 -06:00
Brian Paul
7511d76bd7 swrast: fix glDrawBuffer(GL_FRONT_AND_BACK)
We weren't putting the right colors into the back buffer in this mode.

(cherry picked from master, commit 9cc79fc2dc)
2009-04-02 13:07:53 -06:00
Julien Cristau
99f159339e Prepare changelog for upload 2009-04-01 20:25:25 +02:00
Brian Paul
7f30aba920 docs: fix bug 20986 2009-04-01 07:39:43 -06:00
Brian Paul
4fa700260e glsl: fix texgen state variable tokens in emit_statevars()
This fixes broken variable indexing into the gl_Eye/ObjectPlaneS/T/R/Q arrays.
See bug 20986.

(cherry picked from master, commit f8dd6594bf)
2009-04-01 07:39:26 -06:00
Brian Paul
781fb79c59 docs: first 7.4.1 bug fixes 2009-03-31 16:29:23 -06:00
Brian Paul
5b7e9f2f3a mesa: fix bug in GPU codegen for fixed-function two-sided lighting
The 'dots' register wasn't getting properly un-negated and un-swizzled
after emitting the code for back-face lighting.  So, if more than one
light source was enabled, the specular exponent for the next light source
was wrong.

During execution we were evaluating pow(x, y) where y was negative instead
of positive.  This led to the outcome being zero or NaN.

This fixes the occasional black triangles seen in isosurf when hacked to
enable two-sided lighting.

(cherry picked from master, commit 919f57078b)
2009-03-31 16:28:17 -06:00
Brian Paul
d4d4b63d7f docs: prep for Mesa 7.4.1 release notes 2009-03-31 16:26:24 -06:00
Jeremy Huddleston
9e9fe51acd Updated CPU_TO_LE32 to work on darwin 2009-03-31 14:59:28 -07:00
Jeremy Huddleston
b65bc1b6cb Fix compiling indirect.c when GLX_DIRECT_RENDERING is not defined 2009-03-31 14:48:19 -07:00
Jeremy Huddleston
6cb796f6fc Updated darwin config for when X11 is not in the same location as we're installing to
(cherry picked from commit 7817fea0b6)
2009-03-31 14:37:27 -07:00
Timo Aaltonen
4830fab603 update the changelog. 2009-03-30 10:41:39 +03:00
Timo Aaltonen
1e142bf63d Merge commit 'mesa_7_4' into debian-experimental 2009-03-30 10:38:45 +03:00
Brian Paul
de197cf991 docs: 7.4 release md5 sums 2009-03-27 19:12:16 -06:00
Brian Paul
bf1e6581a5 docs: set 7.4 release date 2009-03-27 18:57:39 -06:00
Brian Paul
80ec7843bc mesa: set VERSION=7.4 2009-03-27 18:57:23 -06:00
Brian Paul
366d6e8cd1 mesa: set version to 7.4 2009-03-27 18:57:07 -06:00
Ian Romanick
63ed288396 intel: Add extra, stronger flushes around CopyTexSubImage blits 2009-03-27 15:22:27 -07:00
Eric Anholt
88ce34f400 swrast: Add support for x8r8g8b8 fbconfig.
This lets swrast produce an fbconfig suitable for the root visual now that
the server's not allowing mismatched fbconfigs.
(cherry picked from commit 529d1d720e)
2009-03-27 15:20:09 -07:00
Ian Romanick
f535de8721 Mark current bits as 2009Q1-RC2 for Intel driver. 2009-03-26 15:32:29 -07:00
Eric Anholt
1db913f687 i965: Fix glFrontFacing in twoside GLSL demo.
This also cuts instructions by just using the existing bit in the payload
rather than computing it from the determinant in the SF unit and passing it
as a varying down to the WM.  Something still goes wrong with getting the
backface color right, but a simpler shader appears to get the right result.
(cherry picked from commit 699db6d842)
2009-03-26 15:15:51 -07:00
Eric Anholt
0e5d1f43af i965: Fix fog coordinate g,b,a values when glFrontFacing isn't used.
Previously, we would sample (f,glFrontFacing,undef,undef) instead of the
(f,0,0,1) that fragment.fogcoord is supposed to return.  Due to
glFrontFacing's presence in FOGC.y, we'll still give bad results there when
glFrontFacing is used.

Bug #19122, piglit testcase fp-fog.
(cherry picked from commit 411d913cce)
2009-03-26 15:15:27 -07:00
Eric Anholt
09c587ae55 i965: Clean up a bit of mess with unneeded variables in emit_interp.
(cherry picked from commit b013f945d8)
2009-03-26 15:15:14 -07:00
Brian Paul
775d8431e9 i965: separate emit_op() and emit_tex_op() functions
(cherry picked from commit a79186e29e)
2009-03-26 15:14:56 -07:00
Brian Paul
3217ea8a1d i965: minor clean-up, comments, etc.
(cherry picked from commit 9e7903e492)
2009-03-26 15:14:22 -07:00
Brian Paul
00aea5853d docs: mention Solaris updates in release notes 2009-03-25 21:08:21 -06:00
Brian Paul
20d34b50b5 mesa: bump version to 7.4 rc2 2009-03-25 21:06:41 -06:00
Alan Coopersmith
9cff0acb36 define __builtin_expect for non-gcc compilers in two more glx files
Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
2009-03-25 16:26:03 -07:00
Alan Coopersmith
791b59493f mklib improvements for Solaris
Move flags for linking standard C/C++ libraries from configure.ac to mklib
Use -norunpath flag when linking with Sun C++ compiler
Convert mklib -exports list into a linker mapfile
Set FINAL_LIBS correctly when -noprefix is used

Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>
2009-03-25 16:26:02 -07:00
Michel Dänzer
7dff7029fa Revert "dri2: Avoid round-tripping on DRI2GetBuffers for the same set of buffers."
This scheme breaks when the display connection doesn't receive ConfigureNotify
events. This caused reporoducible problems (cropped / misplaced output) when
starting a 3D application in a guest operating system in VMware Workstation.

This reverts commit dd1c68f151.

Conflicts:

	src/glx/x11/dri2_glx.c
(cherry picked from commit 11da7e02aa)
2009-03-25 15:55:20 +01:00
Brian Paul
f8fd9bc46b docs: update glext.h to version 48 2009-03-25 08:35:15 -06:00
Brian Paul
53f0e141c0 gl: update include/GL/glext.h to version 48 2009-03-25 08:35:02 -06:00
Julien Cristau
af3c568475 Prepare changelog for upload 2009-03-25 11:34:58 +01:00
Julien Cristau
7d01429512 Build-depend on linux-libc-dev >= 2.6.29 on linux archs.
The 2.6.28 kernel headers miss some compat defines.
2009-03-25 01:51:02 +01:00
Brian Paul
14a794300e demos: add LDFLAGS for corender target, bug 20844
(cherry picked from commit c4c4358e08)
2009-03-24 16:09:23 -06:00
Eric Anholt
912ec292c1 i965: Fix occlusion query when no other WM state updates occur.
Turns out that XXX comment was important.  We weren't flagging the WM to
re-update with the statistics enable, so we got zeroes out of our query.

Bug #20740, fixes piglit occlusion_query test.

Signed-off-by: Eric Anholt <eric@anholt.net>
(cherry picked from commit c0d6e07909)
2009-03-23 12:49:31 -07:00
Tom Fogal
e814b5ae2f mesa: fix _glxapi_get_proc_address() for mangled names
(cherry picked from commit 7399d56ec6)
2009-03-23 12:49:13 -07:00
Brian Paul
0fea05915a glapi: update find_entry() for mangled names
(cherry picked from commit 4447fddc82)
2009-03-23 12:49:05 -07:00
Brian Paul
dfa44f0ff9 mesa: regenerated gl_mange.h file
(cherry picked from commit fe0ccf323d)
2009-03-23 12:48:56 -07:00
Julien Cristau
8d088cd34f update changelog 2009-03-23 17:25:04 +01:00
Julien Cristau
094d627885 Merge tag 'mesa_7_4_rc1' into debian-experimental 2009-03-23 17:21:26 +01:00
Brian Paul
f850ff2bcc mesa: remove unused 'out' label 2009-03-23 08:27:00 -06:00
Brian Paul
66f972ab55 Add Solaris to OS'es using PROT_EXEC mmap() to get executable heap space
Signed-off-by: Alan Coopersmith <alan.coopersmith@sun.com>

(cherry picked from master, commit a06dd4de87)
2009-03-23 08:18:48 -06:00
Brian Paul
17db2db9dc docs: prep for 7.4 release 2009-03-20 17:34:54 -06:00
Brian Paul
dba79af9bc mesa: prep for 7.4-rc1 release 2009-03-20 17:26:04 -06:00
Brian Paul
b009a32bf4 r300: don't crash on sw tcl hw if point size vertex attrib is sent
(cherry picked from master, commit 005ad1a71d)
2009-03-20 08:49:39 -06:00
Brian Paul
7122490982 mesa: avoid setting texObj->_Complete = GL_FALSE when there's no state change
Avoid a little bit of unneeded state validation and fixes a bug where the
texture complete flags was set to false, but we didn't signal _NEW_TEXTURE.

Fixes piglit tex1d-2dborder failure.
(cherry picked from commit aad3f546a0)
2009-03-18 14:47:47 -07:00
Brian Paul
6ada1d47d9 mesa: add no-change testing for a few more texture parameters
(cherry picked from commit 37c768b36a)
2009-03-18 10:54:09 -07:00
Robert Ellison
55865335f4 i965: fix polygon stipple when rendering to FBO
The polygon stipple pattern, like the viewport and the
polygon face orientation, must be inverted on the i965
when rendering to a FBO (which itself has an inverted pixel
coordinate system compared to raw Mesa).

In addition, the polygon stipple offset, which orients
the stipple to the window system, disappears when rendering
to an FBO (because the window system offset doesn't apply,
and there's no associated FBO offset).

With these fixes, the conform triangle and polygon stipple
tests pass when rendering to texture.
(cherry picked from commit 29309b45b0)
2009-03-18 10:47:24 -07:00
Robert Ellison
918e5221ef i965: fix polygon face orientation when rendering to FBO
In the i965, the FBO coordinate system is inverted from the standard
OpenGL/Mesa coordinate system; that means that the viewport and the
polygon face orientation have to be inverted if rendering to a FBO.

The viewport was already being handled correctly; but polygon face
was not.  This caused a conform failure when rendering to texture with
two-sided lighting enabled.

This fixes the problem in the i965 driver, and adds to the comment about
the gl_framebuffer "Name" field so that this isn't a surprise to other
driver writers.
(cherry picked from commit 6dceeb2eb8)
2009-03-18 10:47:24 -07:00
Brian Paul
9feb26584a swrast: use better _swrast_compute_lambda() function
The MAX-based function can produce values that are non-monotonic for a span
which causes glitches in texture filtering.  The sqrt-based one avoids that.

This is perhaps slightly slower than before, but the difference
probably isn't noticable given we're doing software mipmap filtering.

Issue reported by Nir Radian <nirr@horizonsemi.com>

(cherry picked from master, commit c334ce273e)
2009-03-17 10:34:45 -06:00
Ian Romanick
a8528a2e86 Mark current bits as 2009Q1-RC1 for Intel driver. 2009-03-16 13:39:32 -07:00
Brian Paul
119360cccd i965: init dest reg CondMask = COND_TR (the proper default)
Plus fix up a debug printf.
(cherry picked from commit 20f49252e1)
2009-03-13 17:38:40 -07:00
Brian Paul
ac2216542d glsl: fix vec4_texp_rect IR code (need projective version) (cherry picked from commit ad2cfa4199) 2009-03-13 17:38:40 -07:00
Brian Paul
37e5c057f1 i965: check if we run out of GRF/temp registers
Before this change we would up emitting instructions with invalid register
numbers.  This typically (but not always) hung the GPU.  For now, just
prevent emitting bad instructions to avoid hangs.  Still need to do some
kind of proper error recovery.
(cherry picked from commit e60b3067d8)
2009-03-13 17:38:40 -07:00
Brian Paul
4d9b8e0f93 mesa: added _mesa_fprintf() wrapper (cherry picked from commit 596b8fbbbf) 2009-03-13 17:38:40 -07:00
Brian Paul
c1b71f46b5 i965: fix emit_math1() function used for scalar instructions
Instructions such as RCP, RSQ, LOG must smear the result of the function
across the dest register's X, Y, Z and W channels (subject to write masking).
Before this change, only the X component was getting written.

Among other things, this fixes cube map texture sampling in GLSL shaders
(since cube lookups involve normalizing the texcoord).
(cherry picked from commit 3485801978)
2009-03-13 17:38:39 -07:00
Brian Paul
4a25ac9564 i965: rewrite the code for handling shader subroutine calls
Previously, the prog_instruction::Data field was used to map original Mesa
instructions to brw instructions in order to resolve subroutine calls.  This
was a rather tangled mess.  Plus it's an obstacle to implementing dynamic
allocation/growing of the instruction buffer (it's still a fixed size).

Mesa's GLSL compiler emits a label for each subroutine and CAL instruction.
Now we use those labels to patch the subroutine calls after code generation
has been done.  We just keep a list of all CAL instructions that needs patching
and a list of all subroutine labels.  It's a simple matter to resolve them.

This also consolidates some redundant post-emit code between brw_vs_emit.c and
brw_wm_glsl.c and removes some loops that cleared the prog_instruction::Data
fields at the end.

Plus, a bunch of new comments.
(cherry picked from commit c51c822ee0)
2009-03-13 17:38:39 -07:00
Eric Anholt
35d965b39b intel: Fix bpp setting of blits to 8bpp targets.
This was causing hangs in cairogears, as we would blit to the 8bpp target
(A8 texture) as 16bpp, and stomp over state objects.
(cherry picked from commit 19e134051c)
2009-03-13 17:38:39 -07:00
Robert Ellison
d0aab00609 i965: add software fallback for conformant 3D textures and GL_CLAMP
The i965 hardware cannot do GL_CLAMP behavior on textures; an earlier
commit forced a software fallback if strict conformance was required
(i.e. the INTEL_STRICT_CONFORMANCE environment variable was set) and
2D textures were used, but it was somewhat flawed - it could trigger
the software fallback even if 2D textures weren't enabled, as long
as one texture unit was enabled.

This fixes that, and adds software fallback for GL_CLAMP behavior with
1D and 3D textures.

It also adds support for a particular setting of the INTEL_STRICT_CONFORMANCE
environment variable, which forces software fallbacks to be taken *all*
the time.  This is helpful with debugging.  The value is:
   export INTEL_STRICT_CONFORMANCE=2
(cherry picked from commit 3468315087)
2009-03-13 17:38:39 -07:00
Brian Paul
ef33d0f103 mesa: don't draw arrays if vertex position array is not enabled
For regular GL, we must have vertex positions in order to draw.  But ES2
doesn't have that requirement (positions can be computed from any array
of data).

See bug 19911.
(cherry picked from commit 97dd2ddbd9)
2009-03-13 17:38:39 -07:00
Robert Ellison
349b819768 i965: texture fixes: bordered textures, fallback rendering
i965 doesn't natively support GL_CLAMP; it treats it like
GL_CLAMP_TO_EDGE, which fails conformance tests.

This fix adds a clause to the check_fallbacks() test to check
whether GL_CLAMP is in use on any enabled 2D texture.  If so,
and if strict conformance is required (via INTEL_STRICT_CONFORMANCE),
a software fallback is mandated.

In addition, validate textures *before* checking for fallbacks,
rather than after; otherwise, the texture state is never validated
and can't be trusted.  (In particular, if texturing is enabled and
the sampler would access any level beyond level 0 of a texture, the
sampler will segfault, because texture validation sets the firstLevel
and lastLevel fields of a texture object so that the valid levels
will be mapped and accessed correctly.  If texture validation doesn't
occur, only level 0 is accessed correctly, and that only because
firstLevel and lastLevel happen to be set to 0.)
(cherry picked from commit 17c7852bf9)
2009-03-13 17:38:39 -07:00
Dave Airlie
50443db882 texmem: fix typo from brianp's changes.
Reported by cjb via tinderbox on irc
(cherry picked from commit 487a55af78)
2009-03-13 17:38:39 -07:00
Brian Paul
c503cacb53 mesa: use an array for current texture objects
Use loops to consolidate lots of texture object code.
(cherry picked from commit 9818734e01)
2009-03-13 17:38:39 -07:00
Brian Paul
e862b4e38f mesa: use an array for default texture objects
Replace Default1D/2D/3D/Cube/etc with DefaultTex[TEXTURE_x_INDEX].
The same should be done with the Current1D/2D/3D/etc pointers...
(cherry picked from commit 4d24b639d1)
2009-03-13 17:38:39 -07:00
Robert Ellison
e9dfc858fb Fix an i965 assertion failure on glClear()
While running conform with render-to-texture:

	conform -d 33 -v 2 -t -direct

the i965 driver failed this assertion:

intel_clear.c:77: intel_clear_tris: Assertion `(mask & ~((1 << BUFFER_BACK_LEFT) | (1 << BUFFER_FRONT_LEFT) | (1 << BUFFER_DEPTH) | (1 << BUFFER_STENCIL))) == 0' failed.

The problem is that intel_clear_tris() is called by intelClear() to
clear any and all of the available color buffers, but intel_clear_tris()
actually only handles the back left and front left color buffers; so
the assertion fails as soon as you try to clear a non-standard color
buffer.

The fix is to have intelClear() only call intel_clear_tris() with
buffers that intel_clear_tris() can support.  intelClear() already backs
down to _swrast_Clear() for all buffers that aren't handled explicitly.
(cherry picked from commit 0ccbc3c905)
2009-03-13 17:38:39 -07:00
Brian Paul
5efbca1e21 intel: fix datatype typo, s/GLboolean/GLuint/
Fixes mysterious failures in glean glsl1 test.
(cherry picked from commit da2b661ee4)
2009-03-13 17:38:39 -07:00
Kristian Høgsberg
d6d8663a88 intel: Fix intelSetTexBuffer miptree leak.
The intelImage also holds a reference to the miptree, so unref that as well.
(cherry picked from commit 5b354d39d4)
2009-03-13 17:38:39 -07:00
Eric Anholt
13990bd98a intel: tell libdrm whether we want a cpu-ready or gpu-ready BO for regions.
This lets us avoid allocing new buffers for renderbuffers, finalized miptrees,
and PBO-uploaded textures when there's an unreferenced but still active one
cached, while also avoiding CPU waits for batchbuffers and CPU-uploaded
textures.  The size of BOs allocated for a desktop running current GL
cairogears on i915 is cut in half with this.

Note that this means we require libdrm 2.4.5.
(cherry picked from commit 40dd024be6)
2009-03-13 17:38:39 -07:00
Eric Anholt
def630d0a2 i965: Fix render target read domains.
We were asking for something illegal (write_domain != 0 && read_domains !=
write_domain) because at the time of writing the region surfaces were used
for texturing occasionally as well, and we weren't really clear on the model
GEM was going to use.

This reliably triggered a kernel bug with domain handling, resulting in
oglconform mustpass.c failure.  Of course, it only became visible after
01bc4d441f cleaned up some gratuitous flushing.
(cherry picked from commit 078e8a61b2)
2009-03-13 17:38:39 -07:00
Eric Anholt
ca2564f1e6 intel: Don't do the extra MI_FLUSH in flushing except when doing glFlush().
Everything other than "make sure the last rendering ends up visible on the
screen" doesn't need that behavior.
(cherry picked from commit 01bc4d441f)
2009-03-13 17:38:38 -07:00
Eric Anholt
711a57f7c7 intel: don't crash when dri2 tells us about buffers we don't care about. (cherry picked from commit f82f1ffba9) 2009-03-13 17:38:38 -07:00
Eric Anholt
058cf2fff1 dri2: Initialize variables for the getbuffers round-trip reduction.
Missed setting the initial values which usually didn't hurt at runtime.
(cherry picked from commit 680c708dee)
2009-03-13 17:38:38 -07:00
Eric Anholt
715f509c5d intel: Fix tri clear to do FBO color attachments as well.
This is a 2% win in fbo_firecube, and would avoid a sw fallback for
masked clears.
(cherry picked from commit fd51cf1531)
2009-03-13 17:38:38 -07:00
Eric Anholt
e704e6c6f3 i965: Fix fallback on stencil drawing to fbo when the visual lacks stencil.
Noticed this with the fbotexture demo.
(cherry picked from commit c06f4e2a37)
2009-03-13 17:38:38 -07:00
Brian Paul
01f34e667a i965: need to disable current shader, if any, in intel_clear_tris()
Fixes bad background in all the progs/glsl/ tests.
(cherry picked from commit 60b3fe6c19)
2009-03-13 17:38:38 -07:00
Eric Anholt
4d0a7b33c5 intel: Speed up glDrawPixels(GL_ALPHA) by using an alpha texture format. (cherry picked from commit 0b63f6449e) 2009-03-13 17:38:38 -07:00
Eric Anholt
fb1d2ed34c intel: Fix some state leakage of {Client,}ActiveTexture in metaops.
Found while debugging cairo-gl.
(cherry picked from commit d11981e0d7)
2009-03-13 17:38:38 -07:00
Eric Anholt
9395fedf98 i965: Remove brw->attribs now that we can just always look in the GLcontext. (cherry picked from commit 052c1d66a1) 2009-03-13 17:38:38 -07:00
Eric Anholt
9abc0d80af i965: Delete old metaops code now that there are no remaining consumers. (cherry picked from commit 14321fcfde) 2009-03-13 17:38:38 -07:00
Brian Paul
90e89c01df i965: init array->Format fields (see bug 19708) (cherry picked from commit 628b52241b) 2009-03-13 17:38:38 -07:00
Eric Anholt
790d93e362 intel: If we're doing a depth clear with tris, do color with it.
This is a 10% win on the ever-important glxgears not-a-benchmark.
(cherry picked from commit 67ee22c89f)
2009-03-13 17:38:38 -07:00
Eric Anholt
e9f3783169 i915: Only call CalcViewport from DrawBuffers instead of Viewport.
This saves an inadvertent round-trip to the X Server on DrawBuffers, which was
hurting some metaops.
(cherry picked from commit ac0dfbdf0f)
2009-03-13 17:38:38 -07:00
Brian Paul
e41780fedc intel: move some driver functions around
A step toward consolidating i915/intel_state.c and i965/intel_state.c
(cherry picked from commit 84c8b5bbf9)
2009-03-13 17:38:38 -07:00
Eric Anholt
d0edbbb3f3 intel: replace custom metaops clear with generic.
No real-world impact on performance seen.  Even glxgears seems to be, if
anything, happier.
(cherry picked from commit c96bac0950)
2009-03-13 17:38:38 -07:00
Brian Paul
e10119c23e intel: make intelUpdateScreenFromSAREA() static (cherry picked from commit aae2729aeb) 2009-03-13 17:38:38 -07:00
Brian Paul
208c087f39 intel: remove unused var (cherry picked from commit 66c7f06413) 2009-03-13 17:38:38 -07:00
Shaohua Li
0c8b40b42b i915: Add support for a new G33-like chipset.
Signed-off-by: Shaohua Li <shaohua.li@intel.com>
Signed-off-by: Eric Anholt <eric@anholt.net>
(cherry picked from commit 40290745ea)
2009-03-13 17:38:37 -07:00
Xiang, Haihao
5199f451bb i965: fix for RHW workaround
It is possible that an object whose vertices all are outside of a
view plane is passed to clip thread due to the RHW workaround. This
object should be rejected by clip thread. Fix bug #19879
(cherry picked from commit 68915fd6fa)
2009-03-13 17:38:37 -07:00
Brian Paul
dd7cde5230 i965: tell GLSL compiler to emit code using condition codes
The default for EmitCondCodes got flipped when gallium-0.2 was merged.
This fixes GLSL if/else/endif regressions.
Drivers that use GLSL should always explicitly set the flag to be safe.
(cherry picked from commit a9e753c84c)
2009-03-13 17:38:37 -07:00
Eric Anholt
ab5746e5d8 tdfx: Fix begin/endquery for current API. (cherry picked from commit 0cb295584f) 2009-03-13 17:38:37 -07:00
Brian Paul
3bd446c0ab i965: add missing break for OPCODE_RET case
This doesn't effect correctness, but we were emitting an extraneous ADD.
(cherry picked from commit 74b6d55864)
2009-03-13 17:38:37 -07:00
Brian Paul
9b78402ee4 mesa: more info in error messages (cherry picked from commit 1ca05a066b) 2009-03-13 17:38:37 -07:00
Brian Paul
cf1ef0f308 mesa: minor error msg improvement (cherry picked from commit 803504e69f) 2009-03-13 17:38:37 -07:00
Chris Wilson
fd1f65ba61 intel: Decode MI operands using specific length masks
The MI opcodes have different variable length masks, so use an operand
specific mask to decode the length.
(cherry picked from commit e92d97d75b)
2009-03-13 17:38:37 -07:00
Chris Wilson
967345b497 intel: Correct decoding of 3DSTATE_PIXEL_SHADER_CONSTANTS
A couple of minor typos that proclaimed an error in the wrong command, and
failed to offset the mask.
(cherry picked from commit 05d130a35a)
2009-03-13 17:38:37 -07:00
Ian Romanick
41ad853a6a glxgears: No, really. Fix the dyslexia. (cherry picked from commit 5b5ddfb89c) 2009-03-13 17:38:37 -07:00
Ian Romanick
842baa29cb Fix dyslexia. (cherry picked from commit 9d6880ec8d) 2009-03-13 17:38:37 -07:00
Ian Romanick
9556d870a1 glxgears: Log a message if synched to vblank
Tries to use either GLX_MESA_swap_control or GLX_SGI_video_sync to
detect whether the display is synchronized to the vertical blank.  If
it detects this, a message will be printed.  HOPEFULLY this will
prevent some of the bug reports such as "glxgears only gets 59.7fps.
What's wrong with my driver?"
(cherry picked from commit 58b9cd411f)
2009-03-13 17:38:37 -07:00
Brian Paul
42ce790086 mesa: refactor glTexParameter code (cherry picked from commit 318e53a4bf) 2009-03-13 17:38:37 -07:00
Robert Ellison
b17769af42 mesa: add missing texture_put_row_rgb() function in texrender.c
The wrap_texture() function doesn't set the renderbuffer PutRowRGB() method,
which is used to implement DrawPixels().  This fix adds an implementation
of this method.
(cherry picked from commit 523febe12e)
2009-03-13 17:38:37 -07:00
Brian Paul
9030277b0d intel: move glClear-related code into new intel_clear.c file (cherry picked from commit 4451eb2e75) 2009-03-13 17:38:37 -07:00
Brian Paul
a37a9bf769 intel: Move swap-related functions from intel_buffers.c to new intel_swapbuffers.c (cherry picked from commit 6fcebbe719) 2009-03-13 17:38:37 -07:00
Brian Paul
8afb8a8145 i965: scissor rect was inverted when rendering to texture (cherry picked from commit 3b23a8e07d) 2009-03-13 17:38:37 -07:00
Brian Paul
801f933694 mesa: consolidate glGetTexEnvi/f() code with new get_texenvi() helper (cherry picked from commit ad338c14c2) 2009-03-13 17:38:36 -07:00
Jesse Barnes
75ecd6ebbf intel: fix the mismerge of the vblank pipe enable sanity check
Fix the last merge fix, had the blocks ordered incorrectly.
(cherry picked from commit e57e398960)
2009-03-13 17:38:36 -07:00
Jesse Barnes
1cd7317fdb intel: move pipe enable sanity check to where it belongs
Bah, applied the patches in the wrong order, not Owain's fault...
(cherry picked from commit 216bff5fd4)
2009-03-13 17:38:36 -07:00
Owain Ainsworth
1865291701 intel: fix vblank crtc selection with DRI1 when only one pipe is enabled.
On Mobile chipsets, we often enable PipeB instead of PipeA, but the test
in here was insufficient, falling back to pipe A if the area
intersection returned zero. Therefore, in the case where a window went
off to the top of the left of the screen, it would freeze, waiting on
the wrong vblank.

Fix this mess by checking the sarea for a crtc being zero sized, and in
that case always default to the other one.
(cherry picked from commit 0b5266ff64)
2009-03-13 17:38:36 -07:00
Owain G. Ainsworth
3edbcce7d5 intel: Prevent an "irq is not working" printf when only pipe B is enabled.
intelMakeCurrent is called before intelWindowMoved (in fact, it calls
it), so calculation of the correct vblank crtc has not happened yet.
Fix this by making a function that fixes up a set of vblank flags and
call if from both functions.
(cherry picked from commit 39b4061bb9)
2009-03-13 17:38:36 -07:00
Robert Ellison
b1fb34d0ac i965: fix line stipple fallback for GL_LINE_STRIP primitives
When doing line stipple, the stipple count resets on each line segment,
unless the primitive is a GL_LINE_LOOP or a GL_LINE_STRIP.

The existing code correctly identifies the need for a software fallback
to handle conformant line stipple on GL_LINE_LOOP primitives, but
neglects to make the same assessment on GL_LINE_STRIP primitives.
This fixes it so they match.
(cherry picked from commit 73658ff04f)
2009-03-13 17:38:36 -07:00
Ian Romanick
606099f545 swrast: Enable GL_EXT_stencil_two_side (cherry picked from commit b5fbdef7ec) 2009-03-13 17:38:36 -07:00
Brian Paul
32e3142071 i965: minor improvements in brw_wm_populate_key() (cherry picked from commit 89fddf978c) 2009-03-13 17:38:36 -07:00
Brian Paul
66eea4e104 mesa: fix/update/restore comments related to two-sided stencil (cherry picked from commit a304cc6cca) 2009-03-13 17:38:36 -07:00
Brian Paul
e428cf3afd mesa: initialize ctx->Stencil._BackFace = 1
Back-face stencil operations didn't work correctly because this value was
zero.  It needs to be 1 or 2.  The only place it's set otherwise is in
glEnable/Disable(GL_STENCIL_TEST_TWO_SIDE_EXT).
(cherry picked from commit 2a968113a9)
2009-03-13 17:38:36 -07:00
Ian Romanick
842b5164d2 Track two sets of back-face stencil state
Track separate back-face stencil state for OpenGL 2.0 /
GL_ATI_separate_stencil and GL_EXT_stencil_two_side.  This allows all
three to be enabled in a driver.  One set of state is set via the 2.0
or ATI functions and is used when STENCIL_TEST_TWO_SIDE_EXT is
disabled.  The other is set by StencilFunc and StencilOp when the
active stencil face is set to BACK.  The GL_EXT_stencil_two_side spec has
more details.

http://opengl.org/registry/specs/EXT/stencil_two_side.txt
(cherry picked from commit dde7cb9628)
2009-03-13 17:38:36 -07:00
Brian Paul
a6f7e909a7 mesa: fix transposed red/blue in store_texel_rgb888/bgr888() functions
(cherry picked from master, commit 862dccd560)
2009-03-12 09:32:55 -06:00
Brian Paul
ca87e5a7bd mesa: add missing _glthread_INIT_MUTEX in _mesa_new_framebuffer()
(cherry picked from master, commit 81569c2f69)
2009-03-12 08:12:54 -06:00
Alan Hourihane
45c4b4dfbd xdemos: On termination with esc close the contexts correctly. 2009-03-11 13:36:26 +00:00
Brian Paul
2adaec1226 xmesa: set back-buffer's drawable field
Fixes back-buffer rendering when MESA_BACK_BUFFER=pixmap

(cherry picked from master, commit 22bac2a1a0)
2009-03-09 16:28:50 -06:00
Brian Paul
549586c319 i965: fix cube map lock-up / corruption
If we're using anything but GL_NEAREST sampling of a cube map, we need to
use the BRW_TEXCOORDMODE_CUBE texcoord wrap mode.  Before this, the GPU
would either lock up or subsequent texture filtering would be corrupted.

(cherry picked from master, commit 6f915b10d5)
2009-03-09 11:57:16 -06:00
Dan Nicholson
463ac421a5 autoconf: Restore _GNU_SOURCE for all Linux systems
This catches the linux-uclibc case and any others that were being set
prior to 98fcdf3f. Fixes bug 20345.

Signed-off-by: Dan Nicholson <dbn.lists@gmail.com>
(cherry picked from commit ac55db1d7d)
2009-03-06 07:59:00 -08:00
Brian Paul
6801240205 mesa: Reads must also be done with lock held.
Otherwise two threads might think each made the refcount go zero.

(cherry picked from master, commit 8bbb6b352a)
2009-03-06 07:51:18 -07:00
Brian Paul
a22088b7d5 mesa: Fix typo.
Windows threads block if one over-unlocks them.

(cherry picked from master, commit f6159ba4d5)
2009-03-06 07:50:55 -07:00
Brian Paul
e89c49147f docs: update glext.h to version 46 2009-03-05 08:25:17 -07:00
Brian Paul
67634240d1 gl: update glext.h to version 46 2009-03-05 08:25:09 -07:00
Brian Paul
819b028a8e mesa: fix sw fallback state validation bug
When a hw driver fell back to swrast, swrast wasn't always getting informed
of program changes.  When fixed function is translated into shaders, flags
like _NEW_LIGHT, _NEW_TEXTURE, etc. should really signal _NEW_PROGRAM.
In this case, swrast wasn't seeing _NEW_PROGRAM when new fragment shaders
were generated.

(cherry picked from master, commit de1caa5507)
2009-03-03 14:25:28 -07:00
Brian Paul
a43c30ef41 mesa: update fragResults array in arb_output_attrib_string()
Plus add some comments.

(cherry picked from master, commit a070937c00)
2009-02-27 13:49:58 -07:00
Brian Paul
b65bfde84d mesa: set bufObj->Pointer = NULL after unmapping
Also, ctx->Driver.UnmapBuffer can never be null, so remove conditional.

(cherry picked from master, commit 67025f7893)
2009-02-27 13:13:31 -07:00
Brian Paul
c39e6917ac mesa: if a buffer object is mapped when glDeleteBuffers() is called, unmap it
(cherry picked from master, commit a7f434b486)
2009-02-27 13:05:51 -07:00
Brian Paul
c79079895f mesa: fix incorrect error handling in glBufferDataARB()
If glBufferDataARB() is called while a buffer object is currently mapped
we're supposed to unmap the current buffer, then replace it.  Don't generate
an error.

(cherry picked from master, commit 75e3ccf6a5)
2009-02-27 12:58:07 -07:00
Alex Deucher
4480e631cd R300: Add support for RS600 chips 2009-02-25 17:48:45 -05:00
Brian Paul
c32661c3ce mesa: Build DRI by default on Linux/sparc
Signed-off-by: David S. Miller <davem@davemloft.net>

(cherry picked from master, commit 32dc28ac7a)
2009-02-24 20:08:00 -07:00
Brian Paul
d5c06bb812 glsl: yet another swizzled expression fix
This fixes swizzled conditional expressions such "(b ? p : q).x"

(cherry picked from master, commit 00f0b05d5f)
2009-02-24 08:32:01 -07:00
Brian Paul
9d5aa36239 glsl: fix another swizzle-related bug
This fixes the case of "infinitely" nested swizzles such as EXPR.wzyx.yxwz.xxyz
This doesn't appear in typical shaders but with function inlining and the
compiler's internal use of swizzles it can happen.
New glean glsl1 test case added for this.

(cherry picked from master, commit d9881356a6)
2009-02-24 08:31:02 -07:00
Brian Paul
e3050c1777 docs: Haiku fixes 2009-02-23 08:16:09 -07:00
Brian Paul
06295ddbdd mesa: fixes for building on Haiku
(cherry picked from master, commit 41172c0430)

Conflicts:
	src/mesa/main/dlopen.c
2009-02-23 08:15:43 -07:00
Brian Paul
e2092bb23c demos: update multitex.c GLSL demo to use vertex arrays or glVertex-mode
Press 'a' to toggle drawing mode.

(cherry picked from master, commit 8e8b25c26a)
2009-02-19 17:05:14 -07:00
Brian Paul
528836d0ad util: added more functions to extfuncs.h
(cherry picked from master, commit 4c5f390328)
2009-02-19 17:04:42 -07:00
Brian Paul
3511442e43 mesa: fix GLSL issue preventing use of all 16 generic vertex attributes
Only 15 actually worked before since we always reserved generic[0] as an
alias for vertex position.

The case of vertex attribute 0 is tricky.  The spec says that there is no
aliasing between generic vertex attributes 0..MAX_VERTEX_ATTRIBS-1 and the
conventional attributes.  But it also says that calls to glVertexAttrib(0, v)
are equivalent to glVertex(v).  The distinction seems to be in glVertex-mode
versus vertex array mode.

So update the VBO code so that if the shader uses generic[0] but not gl_Vertex,
route the attribute data set with glVertex() to go to shader input generic[0].

No change needed for the glDrawArrays/Elements() path.

This is a potentially risky change so regressions are possible.  All the usual
tests seem OK though.

(cherry picked from mesa, commit dea0d4d563)

Follow-up: This patch doesn't seem to be as risky as noted above.
There have been no known regressions on Mesa/master because of it.
2009-02-19 17:01:17 -07:00
Brian Paul
d20c53b511 glsl: update program->InputsRead when referencing input attributes
This info will be used in the linker for allocating generic vertex attribs.

(cherry picked from master, commit 1cb7cd1292)
2009-02-19 17:00:06 -07:00
Brian Paul
091cc122ad glsl: asst improvements, clean-ups in set_program_uniform()
Move the is_boolean/integer_type() calls out of the loops.
Move the is_sampler_type() function near the bool/int functions.
Add a bunch of comments.

(cherry picked from master, commit c4ffbf009e)
2009-02-18 17:53:08 -07:00
Brian Paul
c983abbb9e glsl: fix inequality in set_program_uniform()
We were off by one when checking for too many uniform values.

(cherry picked from master, commit b9d8f717d2)
2009-02-18 17:52:47 -07:00
Brian Paul
a0a81204c2 mesa: bump gl.h version comment to 7.4 (bug 20170) 2009-02-18 15:37:44 -07:00
Brian Paul
409d4f839c glsl: fix link failure for variable-indexed varying output arrays
If the vertex shader writes to a varying array with a variable index,
mark all the elements of that array as being written.

For example, if the vertex shader does:

   for (i = 0; i < 4; i++)
      gl_TexCoord[i] = expr;

Mark all texcoord outputs as being written, not just the first.

Linking will fail if a fragment shader tries to read an input that's not
written by the vertex shader.  Before this fix, this linker test could fail.

(cherry picked from master, commit dac19f17f3)
2009-02-18 14:29:46 -07:00
Brian Paul
0ab36958ea mesa: improved error msg
(cherry picked from master, commit 621c999d82)
2009-02-18 13:41:12 -07:00
Brian Paul
c2445f43a3 mesa: increase MAX_UNIFORMS to 1024 (of vec4 type)
Old limit was 256.  Note that no arrays are declared to this size.
The only place we have to be careful about raising this limit is the
prog_src/dst_register Index bitfields.  These have been bumped up too.

Added assertions to check we don't exceed the bitfield in the future too.

(cherry picked from master, commit 5b2f8dc013)
2009-02-18 13:40:57 -07:00
Brian Paul
f3d1c136b7 glsl: fix a swizzle-related regression
This new issue was exposed by commit 6eabfc27f1

(cherry picked from master, commit 212f41b80f)
2009-02-18 13:37:31 -07:00
Brian Paul
dd10a8b09d docs: 7.4 relnotes: report GLSL 1.20, fixed GLSL array index bug 2009-02-17 16:39:45 -07:00
Brian Paul
dd312366da glsl: silence some uninit var warnings
(cherry picked from master, commit 9d49802b7a)
2009-02-17 16:38:30 -07:00
Brian Paul
d2fe466ef3 mesa: turn on reporting of GLSL version 1.20
The new array features, precision/invariant/centroid qualifiers, etc. were
done a while back.  The glGetString(GL_SHADING_LANGUAGE_VERSION) query returns
"1.20" now (for drivers that support it anyway).

(cherry picked from master, commit f59719c6c7)
2009-02-17 16:37:41 -07:00
Brian Paul
fe5328bfad glsl: fix mistake in a comment
(cherry picked from master, commit be8dd01678)
2009-02-17 16:36:15 -07:00
Brian Paul
c0891dde07 glsl: fix an array indexing bug
This fixes a bug found with swizzled array indexes such as in "array[index.z]"
where "index" is an ivec4.

(cherry picked from master, commit 6eabfc27f1)
2009-02-17 16:35:59 -07:00
Brian Paul
0e6d9c1a55 docs: recent 7.4 bug fixes 2009-02-16 20:35:12 -07:00
Brian Paul
5f74a66132 glsl: allow setting arrays of samplers in set_program_uniform()
Arrays of sampler vars haven't been tested much and might actually be broken.
Will need to be revisited someday.

Another fix for bug 20056.

(cherry picked from master, commit 2b4f0216bf)
2009-02-16 20:30:49 -07:00
Brian Paul
46f8b62d5f glsl: raise GL_INVALID_OPERATION for glUniform(location < -1)
location = -1 is silently ignored, but other negative values should raise
an error.

Another fix for bug 20056.

(cherry picked from master, commit 234f03e90a)
2009-02-16 20:30:06 -07:00
Brian Paul
3e3e80c431 glsl: rework _mesa_get_uniform[fi]v() to avoid using a fixed size intermediate array
(cherry picked from master, commit 4ef7a93296)
2009-02-16 20:29:36 -07:00
Brian Paul
0486d117e4 glsl: fix glUniform() array bounds error checking
If too many array elements are specified, they're to be silently ignored (don't
raise a GL error).

Fixes another issue in bug 20056.

(cherry picked from master, commit 2c1ea0720d)
2009-02-16 20:28:57 -07:00
Brian Paul
29981c14da glsl: fix incorrect size returned by glGetActiveUniform() for array elements.
Fixes one of the issues in bug 20056.

(cherry picked from master, commit 369d1859d7)
2009-02-16 20:28:14 -07:00
Brian Paul
98d5efb2c5 glsl: use _slang_var_swizzle() in a few places to simplify the code.
(cherry picked from master, commit 285b500bb7)
2009-02-16 20:26:58 -07:00
Brian Paul
77a44aafaf mesa: another fix for program/texture state validation
This fixes a regression introduced in 46ae1abbac

Break program validation into two steps, do part before texture state
validation and do the rest after:
1. Determine Vertex/Fragment _Enabled state.
2. Update texture state.
3. Determine pointers to current Vertex/Fragment programs (which may involve
generating new "fixed-function" programs).

See comments in the code for more details of the dependencies.

(cherry picked from master, commit 537d3ed6f3)
2009-02-16 20:23:17 -07:00
Brian Paul
8278c70716 mesa: fix/change state validation order for program/texture state
Program state needs to be updated before texture state since the later depends
on the former.

Fixes piglit texgen failure.  The second time through the modes (press 't'
three times) we disable the fragment program and return to conventional texture
mode.  State validation failed here because update_texture() saw stale fragment
program state.

(cherry picked from master, commit 46ae1abbac)
2009-02-16 20:22:46 -07:00
Alan Hourihane
ac0955f5e2 demos: fix glxpixmap and call glXWaitGL before calling XCopyArea. 2009-02-16 11:55:47 +00:00
Alan Hourihane
4130c35ca8 dri2: support glXWaitX & glXWaitGL by using fake front buffer. 2009-02-16 11:48:24 +00:00
Brian Paul
d440647eb8 autoconf: Use include-fixed directory with makedepend on newer GCC
On newer GCC releases, the compiler's headers have been split between
the include and include-fixed directories. Add both if the directories
exist.

Signed-off-by: Dan Nicholson <dbn.lists@gmail.com>
Signed-off-by: Julien Cristau <jcristau@debian.org>

(cherry picked from master, commit a3d223f0d2)
2009-02-13 09:10:09 -07:00
Brian Paul
7e8f2c56c0 mesa: fix logic error in computing enableBits in update_texture_state()
If we had a vertex shader but no fragment shader (i.e. fixed function) we
didn't get the right enabled texture targets.

Fixes blank/white texture problem.

(cherry picked from master, commit b46611633c)
2009-02-07 12:04:15 -07:00
Brian Paul
a0880a152f mesa: fix tnl->render_inputs_bitset setup for fragment program texcoords
Handle the case where there's no per-vertex texcoords but the fragment shader
needs texcoords.

Fixes piglit shaders/fp-generic/dph test.

(cherry picked from master, commit f6d23943cd)
2009-02-07 12:03:37 -07:00
Brian Paul
4608a9172f swrast: return (0,0,0,1) when sampling incomplete textures, not (0,0,0,0)
Fixes piglit shaders/fp-incomplete-tex test.

(cherry picked from master, commit 1df62651b2)

Conflicts:
	src/mesa/swrast/s_fragprog.c

Also updated the fetch_texel_lod(), fetch_texel_deriv() functions to match
those in git/master.
2009-02-07 12:02:22 -07:00
Brian Paul
d0e38f7ec0 glsl: replace assertion with conditional in _slang_pop_var_table()
We were hitting the assertion when we ran out of registers, which can happen.

Also, add some additional assertions and freshen up some comments.

(cherry picked from master, commit 0744805d58)
2009-02-07 11:57:43 -07:00
Brian Paul
a69bdbbbdd docs: fixed Windows build error, added MESA_GLX_FORCE_DIRECT env var 2009-02-03 15:40:16 -07:00
Brian Paul
88c97a2662 docs: document new MESA_GLX_FORCE_DIRECT env var for the Xlib driver
(cherry picked from master, commit 2f51be75c5)
2009-02-03 15:39:13 -07:00
Brian Paul
ce9c69ddbc xlib: use MESA_GLX_FORCE_DIRECT to make glXIsDirect() always return True
Some apps won't run w/ indirect rendering contexts.
Also, consolidate some context-init code in new init_glx_context() function.

(cherry-picked from master, commit 49e80bf6b1)
2009-02-03 15:38:44 -07:00
Eric Anholt
e430fcb716 dri2: Avoid round-tripping on DRI2GetBuffers for the same set of buffers.
We only wanted to request when asked for the same set of buffers when a resize
has happened.  We can just watch the protocol stream for a ConfigureNotify
and flag to do it then.

This is about a 5% win from doing two glViewport()s per frame in openarena.
2009-02-03 21:36:38 +00:00
Brian Paul
11a363e632 mesa: move code after decls. Fixes Window build failure.
(cherry picked from master, commit 92ced46eaf)
2009-02-02 07:50:31 -07:00
Julien Cristau
9a3a20b2b9 debian/rules: on lpia, only build the i915 and i965 dri drivers
Based on Ubuntu changes, modified to also build swrast.
2009-01-31 23:04:06 +01:00
Julien Cristau
4672811541 debian/control: build the dri drivers on lpia
add lpia to the Architecture field for libgl1-mesa-dri{,-dbg} to match Ubuntu.
2009-01-31 22:30:15 +01:00
Julien Cristau
3cad3d28a5 mangle upstream version in debian/watch
Fix watch file to make uscan not consider release candidates as newer than
actual releases.
2009-01-31 22:07:51 +01:00
Brian Paul
41e63fbdb2 docs: recent bug fixes for 7.4 2009-01-30 16:09:58 -07:00
Brian Paul
b543401a5c mesa: fix incorrect call to clear_teximage_fields() in _mesa_TexImage2D()
Fixes failed assertion / segfault for particular proxy texture tests.

(cherry picked from master, commit ea4b183b8c)
2009-01-30 16:06:52 -07:00
Brian Paul
8c4f08fbad mesa: add missing _mesa_reference_texobj() calls for texture array targets
(cherry picked from master, commit 7c48719a5f)
2009-01-30 16:06:21 -07:00
Brian Paul
f3081a34d2 mesa: remove incorrect refcounting adjustment in adjust_buffer_object_ref_counts()
Fixes bug 19835.  However, a more elaborate fix should be implemented someday
which uses proper reference counting for gl_array_object.

(cherry picked from master, commit 88e0b92a74)
2009-01-30 16:05:51 -07:00
Julien Cristau
cff0971f87 Prepare changelog for upload 2009-01-30 20:00:37 +01:00
Julien Cristau
5ac4c69d83 More superfluous directories 2009-01-30 19:56:29 +01:00
Julien Cristau
a314c40cc4 Document my changes in debian/changelog 2009-01-30 19:42:38 +01:00
Julien Cristau
959fd6b8f6 Add back progs/fbdev
It was added to the tarballs in 22b0b2f47e
2009-01-30 19:34:47 +01:00
Julien Cristau
937f0da04a Delete more directories that aren't in the tarball 2009-01-30 19:25:50 +01:00
Julien Cristau
73bc5967e2 Merge commit '5a458977113e4a0d3c389b03801cf6ce580d3935' into debian-experimental 2009-01-30 19:06:19 +01:00
Brian Paul
7b1d3cf392 docs: i965 fixes 2009-01-28 17:02:39 -07:00
Brian Paul
25515b557e i965: fix bug in pass0_precalc_mov()
Previously, "in-place" swizzles such as:
   MOV t, t.xxyx;
were handled incorrectly.  Fixed by splitting the one loop into two loops so we
get all the refs before assigning them (to avoid potential clobbering).

(cherry picked from master/commit faa48915d2)
2009-01-28 17:01:34 -07:00
Brian Paul
51625ff86e i965: widen per-texture bitfields for 16 texture image units
(cherry picked from master/commit f78c388b6c)
2009-01-28 17:01:03 -07:00
Brian Paul
4d8f661726 intel: check if stencil test is enabled in intel_stencil_drawpixels()
(cherry picked from master/commit 72ee0e247d)
2009-01-28 17:00:23 -07:00
Brian Paul
efa69a2f66 intel: save/restore GL matrix mode in intel_meta_set_passthrough_transform(), intel_meta_restore_transform()
(cherry picked from master, commit 723648f2ee)
2009-01-28 16:55:16 -07:00
Timo Aaltonen
a2dce49158 New changelog entry for 7.3 2009-01-25 17:51:16 +02:00
Timo Aaltonen
e4b28de803 Merge branch 'upstream-experimental' into debian-experimental 2009-01-25 17:30:47 +02:00
Brian Paul
30a6dd78d5 docs: fix typo 2009-01-22 10:39:05 -07:00
Brian Paul
9f75836308 mesa: set version to 7.4 for mesa_7_4_branch 2009-01-22 10:19:39 -07:00
Julien Cristau
f5c47105db Prepare changelog for upload 2009-01-21 19:01:24 +01:00
Julien Cristau
f1939c8685 Refresh patches 03 and 04. 2009-01-21 19:01:17 +01:00
Julien Cristau
3ac4d678ef Delete some more files which aren't in the tarballs 2009-01-21 18:51:07 +01:00
Julien Cristau
fcfec66865 update changelog 2009-01-20 18:50:10 +00:00
Julien Cristau
53426d7113 Merge tag 'mesa_7_3_rc3' into debian-experimental
Conflicts:

	progs/tests/Makefile
2009-01-20 18:49:21 +00:00
Timo Aaltonen
1d4756de06 Update the changelog. 2009-01-16 23:12:14 +02:00
Timo Aaltonen
c1abb821f9 Merge commit 'mesa_7_3_rc2' into debian-experimental 2009-01-16 23:05:20 +02:00
Julien Cristau
88083e9bab Prepare changelog for upload 2009-01-10 22:34:36 +01:00
Julien Cristau
47e54545ed Delete some now unused code from debian/rules. 2009-01-10 22:13:17 +01:00
Julien Cristau
54885ff0ad Delete unused configs/debian-*, and install-source.sh script.
We've switched to using autoconf, and mesa-swx11-source is gone.
2009-01-10 21:55:19 +01:00
Julien Cristau
502fbe7cb3 Merge branch 'debian-unstable' into debian-experimental
Conflicts:

	debian/changelog
	debian/rules
2009-01-10 21:42:57 +01:00
Julien Cristau
08fdb497fb Merge commit 'origin/upstream-unstable' into debian-experimental 2009-01-10 21:38:10 +01:00
Julien Cristau
2a6711c0e5 add bug closers 2009-01-10 21:02:55 +01:00
Julien Cristau
382a8f6e29 Require libdrm-dev 2.4.3. 2009-01-10 20:41:16 +01:00
Julien Cristau
a713ba4399 Update changelog 2009-01-10 20:31:20 +01:00
Julien Cristau
5359febc9b Merge tag 'mesa_7_3_rc1' into debian-experimental
Conflicts:

	progs/tests/Makefile
	progs/tests/floattex.c
2009-01-10 20:30:41 +01:00
Julien Cristau
85d882983f Prepare changelog for upload 2008-12-14 09:59:33 +05:30
Timo Aaltonen
5387880f18 delete progs/trivial/ 2008-12-09 02:16:44 +02:00
Timo Aaltonen
a7a9398411 Build-depend on x11proto-dri2-dev (>= 1.99.3) 2008-12-09 02:01:40 +02:00
Timo Aaltonen
7593023f0b Update the changelog for the snapshot
also drop 01_disable-intel-classic-warn.diff since it's obsolete now.
2008-12-09 01:57:44 +02:00
Timo Aaltonen
92d9a71f60 Merge commit 'origin/debian-experimental' into debian-experimental
Conflicts:
	include/GLES/egltypes.h
	progs/miniglx/glfbdevtest.c
	progs/miniglx/manytex.c
	progs/miniglx/sample_server.c
	progs/miniglx/sample_server2.c
	progs/miniglx/texline.c
	progs/tests/Makefile.win
	progs/tests/antialias.c
	progs/tests/cva.c
	progs/tests/dinoshade.c
	progs/tests/getprocaddress.py
	progs/tests/jkrahntest.c
	progs/tests/manytex.c
	progs/tests/multipal.c
	progs/tests/multiwindow.c
	progs/tests/sharedtex.c
	progs/tests/texline.c
	progs/tests/texrect.c
	progs/tests/texwrap.c
	progs/trivial/Makefile
2008-12-09 01:38:08 +02:00
Timo Aaltonen
661890211e Merge commit 'mesa_7_2' into debian-experimental 2008-12-09 01:36:36 +02:00
Julien Cristau
0206e20240 Also build the x86-specific dri drivers on kfreebsd (closes: #492894). 2008-10-26 15:58:46 +01:00
Julien Cristau
83a4719056 Update changelog 2008-10-26 15:34:37 +01:00
Ian Romanick
6cfe871c75 Use 3Dnow! x86-64 routines only on processors that support 3Dnow!
Added an x86-64 CPUID function and use it to detect 3Dnow!  If 3Dnow!
is available, use _mesa_3dnow_transform_points4_3d_no_rot,
_mesa_3dnow_transform_points4_perspective,
_mesa_3dnow_transform_points4_2d_no_rot, and _mesa_3dnow_transform_points4_2d.

This fixes long standing bug #8724.
(cherry picked from commit 2b8d8989fb)
2008-10-26 15:23:27 +01:00
Julien Cristau
84bb8fc695 Prepare changelog for upload 2008-09-24 14:28:28 +02:00
Julien Cristau
872cb1a0dd intel: don't warn about TTM init failure. 2008-09-24 14:25:30 +02:00
Julien Cristau
ee80a3a623 Remove the build-dep on dri2proto, DRI2 support has been removed. 2008-09-24 12:55:15 +02:00
Timo Aaltonen
e700c5ad99 Update the changelog, refresh patch 04. 2008-09-23 16:09:00 +03:00
Timo Aaltonen
08c0ec7a89 Merge commit 'mesa_7_2' into debian-experimental
Conflicts:

	include/GLES/egl.h
2008-09-23 16:06:40 +03:00
Brian Paul
35fe0e56e6 mesa: docs: remove parenthesis 2008-09-20 09:28:22 -06:00
Brian Paul
69e5311ad3 mesa: set 7.2 version for tarballs 2008-09-20 09:24:17 -06:00
Brian Paul
e884c4db2b mesa: prep for 7.2 release 2008-09-20 09:23:50 -06:00
Adam Jackson
e681bee04e Update to SGI FreeB 2.0.
Under the terms of version 1.1, "once Covered Code has been published
under a particular version of the License, Recipient may, for the
duration of the License, continue to use it under the terms of that
version, or choose to use such Covered Code under the terms of any
subsequent version published by SGI."

FreeB 2.0 license refers to "dates of first publication".  They are here
taken to be 1991-2000, as noted in the original license text:

 ** Original Code. The Original Code is: OpenGL Sample Implementation,
 ** Version 1.2.1, released January 26, 2000, developed by Silicon Graphics,
 ** Inc. The Original Code is Copyright (c) 1991-2000 Silicon Graphics, Inc.
 ** Copyright in any portions created by third parties is as indicated
 ** elsewhere herein. All Rights Reserved.

Official FreeB 2.0 text:

http://oss.sgi.com/projects/FreeB/SGIFreeSWLicB.2.0.pdf

As always, this code has not been tested for conformance with the OpenGL
specification.  OpenGL conformance testing is available from
http://khronos.org/ and is required for use of the OpenGL logo in
product advertising and promotion.
2008-09-20 09:21:34 -06:00
Julien Cristau
07c1fcc604 Prepare changelog for upload 2008-09-20 16:32:02 +02:00
Julien Cristau
7959b95efa Update debian/copyright to the SGI Free Software License B, version 2.0.
It now mirrors the free X11 license used by X.Org (closes: #368560).
http://www.sgi.com/company_info/newsroom/press_releases/2008/september/opengl.html
2008-09-19 18:03:59 +02:00
Brian Paul
3dd48d903f document _tnl_InvalidateState() fix 2008-09-18 15:28:31 -06:00
Brian Paul
e0ea4337fc mesa: fix null ptr deref bug in _tnl_InvalidateState(), bug 15834 2008-09-18 15:27:55 -06:00
Brian Paul
6290d7fd29 mesa: fix bug in previous changes to _slang_resolve_attributes() 2008-09-17 09:13:28 -06:00
Brian Paul
84ad182ab8 document glBindAttribLocation fixes 2008-09-16 16:37:17 -06:00
Brian Paul
a155ead515 mesa: rework GLSL vertex attribute binding
Calls to glBindAttribLocation() should not take effect until the next time
that glLinkProgram() is called.
gl_shader_program::Attributes now just contains user-defined bindings.
gl_shader_program::VertexProgram->Attributes contains the actual/final bindings.
2008-09-16 15:58:05 -06:00
Brian Paul
5b0f652456 mesa: fix display list regression (check if save->prim_count > 0 in vbo_save_EndList()) 2008-09-16 13:32:13 -06:00
Brian Paul
1be50e1638 fix msaa enable/disable bug 2008-09-15 17:15:51 -06:00
Brian Paul
4fefa29d8c mesa: fix MSAA enable state in update_multisample() 2008-09-15 17:14:41 -06:00
Brian Paul
ef479d9f2a document display list bug fix 2008-09-15 09:22:07 -06:00
Brian Paul
fc04604856 mesa: remove some assertions that are invalid during context tear-down 2008-09-15 09:20:30 -06:00
Keith Whitwell
ef2bd7860f mesa: get another class of degenerate dlists working
Primitive begin in one dlist, end in another.
2008-09-15 09:20:23 -06:00
Shane Blackett
dca8b4c964 glut: s/glut_fbc.c/glut_fcb.c/ 2008-09-14 17:51:53 -06:00
Brian Paul
419353dc2f mesa: Makefile: 7.2 release candidate 1 2008-09-13 16:06:12 -06:00
Brian Paul
38d3b2262b mesa: documentation updates for 7.2 release 2008-09-13 14:43:54 -06:00
Brian Paul
4db2a7f36c updated Cell driver info 2008-09-13 14:39:39 -06:00
Brian Paul
1145042fd2 Mesa: version bumps for 7.2 release 2008-09-13 14:36:35 -06:00
Brian Paul
772131280a document 7.2 bug fixes, etc 2008-09-13 14:36:17 -06:00
Jakub Bogusz
ee913c0fcc tdfx: fix crash and lack of visuals bug 2008-09-13 14:34:51 -06:00
Guillaume Melquiond
cd1804c43a i915: fix himask constant init for 64-bit build 2008-09-13 14:26:35 -06:00
Guillaume Melquiond
253784d45e glx: fix 64-bit datatype issue 2008-09-13 14:26:25 -06:00
Guillaume Melquiond
463d19d477 mesa: return after _mesa_problem() calls 2008-09-13 14:26:18 -06:00
Guillaume Melquiond
6e4fd90ca5 mesa: #include <stdio.h> 2008-09-13 14:26:13 -06:00
Guillaume Melquiond
06188c0c5c remove invalid XDestroyWindow() call 2008-09-13 14:26:06 -06:00
Guillaume Melquiond
dec9097647 silence warning 2008-09-13 14:25:59 -06:00
Guillaume Melquiond
e234339dba GLU: fix asst warnings 2008-09-13 14:25:53 -06:00
Ian Romanick
bb09d23e92 Remove DRI2 support
Remove support for the original incarnation of DRI2.  This version has
since been abandoned and will never ship.  This eliminates a build
dependency on a component that only exists in Fedora 9 and in now-dead
up-stream development trees.

I also recommend that we spin a Mesa 7.1.1 release with this patch.

Signed-off-by: Ian Romanick <ian.d.romanick@intel.com>
2008-09-12 13:48:14 -07:00
Xiang, Haihao
1ffbcddb6f i965: Add support for G41 chipset which is another 4 series.
(cherry picked from commit b2e083eba2)
2008-09-12 09:29:00 +08:00
Brice Goglin
5cd892a4e4 Fix grammar and punctuation in glxinfo(1) 2008-09-11 19:13:46 +02:00
Shane Blackett
33cf8f5c06 added 24bpp support 2008-09-11 08:35:37 -06:00
Shane Blackett
7b8d878bed Fixes for Mingw 2008-09-10 08:23:19 -06:00
Brian Paul
86ae34fbb4 mesa: replace MALLOC w/ CALLOC to fix memory error in glPushClientAttrib() 2008-09-05 08:07:07 -06:00
Brian Paul
16f3461fd6 mesa: improved gl_buffer_object reference counting
Use new _mesa_reference_buffer_object() function wherever possible.
Fixes buffer object/display list crash reported in ParaView.
2008-09-04 15:26:07 -06:00
Xiang, Haihao
0ac8886b51 intel: Fix depth_stencil texture.
(cherry picked from commit 0adfd10210)
2008-09-04 11:54:31 +08:00
Xiang, Haihao
1729d37223 mesa: merge stencil values into depth values for MESA_FORMAT_S8_Z24
(cherry picked from commit 218df7f9c5)
2008-09-04 11:54:21 +08:00
Jakob Bornecrantz
81edef6f9f mesa: Support for MESA_FORMAT_S8_Z24 texture
cherry-picked from gallium-0.1
(cherry picked from commit dc44bb8e92)
2008-09-04 11:54:08 +08:00
Brian Paul
e040e18c7b fix BUFFER_DEPTH/BUFFER_ACCUM mix-up 2008-09-02 18:13:53 -06:00
Roland Scheidegger
14d186644b fix no error generated when calling glLight{if}[v] inside begin/end (bug 17408) 2008-09-02 15:49:35 +02:00
Xiang, Haihao
e4535e4d5e i965: force thread switch after IF/ELSE/ENDIF. partial fix for #16882.
A thread switch is implicitly invoked after the issuance of an IF/ELSE/ENDIF
instruction if necessary. Unfortunately it seems sometimes a forced thread
switch is needed.
2008-08-29 10:30:12 +08:00
Xiang, Haihao
a008813890 i965: mask control for BREAK/CONT/DO/WHILE. partial fix fox #16882 2008-08-29 10:30:03 +08:00
Xiang, Haihao
da50dc7bb3 i965: Push/pop instruction state. partial fix for #16882 2008-08-29 10:29:57 +08:00
Brian Paul
7f628d9cbc mesa: bump MAX_INSN to 350 2008-08-28 15:16:33 -06:00
Julien Cristau
f9affb3059 Prepare changelog for upload 2008-08-27 19:52:30 +02:00
Julien Cristau
fd7cc514d2 Some more parallel build updates. 2008-08-27 19:52:14 +02:00
Julien Cristau
f6a927b45f Update changelog 2008-08-27 17:29:28 +02:00
Julien Cristau
8772e02b68 Merge tag 'mesa_7_1' into debian-experimental 2008-08-27 17:28:31 +02:00
Brian Paul
b2ffd0be03 placeholder for upcoming 7.2 release notes 2008-08-26 16:24:37 -06:00
Brian Paul
912b16c689 added 7.1 MD5 sums 2008-08-26 16:11:56 -06:00
Brian Paul
6d9b25e522 mesa: don't check for GLSL 1.2 to advertise GL 2.1
The GLSL 1.2 features are minor...
2008-08-26 15:50:11 -06:00
Corbin Simpson
31bad23f0f note ATI R500 series support 2008-08-26 12:39:27 -06:00
Timo Jyrinki
29b9b25e72 asst. html doc updates 2008-08-26 12:36:23 -06:00
Brian Paul
e794f496c6 mesa: assorted updates/prep for 7.1 release 2008-08-25 14:09:14 -06:00
Brian Paul
68067c66d3 mesa: glsl: regenerated file 2008-08-25 09:16:21 -06:00
Brian Paul
ad5474e995 mesa: glsl: grab latest fixes from gallium-0.1 branch
Includes:
1. Fixes failed asserting about bad swizzles in src reg emit.
2. Tracks uniform var usage.
3. Emit exp() in terms of EXP2 instruction.
2008-08-25 09:15:16 -06:00
Julien Cristau
ac8771ee99 Update changelog 2008-08-24 17:38:03 +02:00
Julien Cristau
16358bb3cc Merge branch 'mesa_7_2_branch' of git.freedesktop.org:/git/mesa/mesa into debian-experimental 2008-08-24 17:34:47 +02:00
Julien Cristau
ef160330e5 Merge tag 'mesa_7_1_rc4' into debian-experimental
Conflicts:

	progs/fp/Makefile
	progs/slang/Makefile
	progs/tools/trace/gltrace_support.cc
	progs/trivial/Makefile
2008-08-16 18:43:53 +02:00
Julien Cristau
332dcfb60b Add parallel build support. 2008-08-04 12:49:03 +02:00
Julien Cristau
a8dde163dc Prepare changelog for upload 2008-07-13 19:42:01 +02:00
Julien Cristau
868d0accef update changelog and patches
01_fix-installdir.patch dropped, applied upstream
04_osmesa_version.diff needed fixing
2008-07-13 19:36:56 +02:00
Julien Cristau
64e57ed257 Merge branch 'master' of git://anongit.freedesktop.org/git/mesa/mesa into debian-experimental
Conflicts:

	progs/tests/antialias.c
	progs/tools/trace/Makefile
2008-07-13 19:20:03 +02:00
Julien Cristau
e325b76444 Prepare changelog for upload 2008-07-12 18:56:22 +02:00
Julien Cristau
34eedc6a98 update changelog 2008-07-12 18:55:55 +02:00
Julien Cristau
8c21c2e07e Merge branch 'mesa_7_0_branch' of git://anongit.freedesktop.org/git/mesa/mesa into debian-unstable 2008-07-12 17:21:50 +02:00
Brian Paul
27425708f5 mesa: return -1, not GL_FALSE if _glapi_add_dispatch() fails name sanity check 2008-07-09 15:06:49 -06:00
Brian Paul
fc07b6cda0 ARB program, GLSL fixes 2008-07-09 08:58:47 -06:00
Brian Paul
562ed27eb5 mesa: remove debug code 2008-07-09 08:52:44 -06:00
Brian Paul
0a0e09078d mesa: implement glGetUniformiv() with new ctx->Driver function
The old implementation could overwrite the caller's param buffer.

cherry-picked from master
2008-07-09 08:51:35 -06:00
Brian Paul
50bc5a75a7 mesa: fix state.clip[n].plane parsing bug (bug 16611) 2008-07-09 08:42:49 -06:00
Brian Paul
6661f53eb3 mesa: check for OpenBSD (bug 15604)
cherry-picked from master
2008-07-09 08:42:28 -06:00
Xiang, Haihao
b8782affc8 i915: fall back to software rendering when shadow comparison is
enabled for 1D texture. fix #12176

Cherry-picked from commit 75e4db1804
2008-07-09 13:44:13 +08:00
Brian Paul
9a9e839b9b added null texObj ptr check (bug 15567) 2008-07-08 15:13:23 -06:00
Julien Cristau
b04ccc9a03 Disable the i915tex driver, it doesn't build against libdrm 2.3.1. 2008-07-08 18:18:56 +02:00
Xiang, Haihao
aa522e14ee i965: official name for GM45 chipset 2008-07-08 14:39:01 +08:00
Julien Cristau
dabd09f5a9 some more debian/rules adjustments
build the software libGL with --disable-gl-osmesa, and try to fix some
rules dependencies
2008-07-06 14:03:58 +02:00
Julien Cristau
46ffb3c0b1 debian/rules cleanup and fixes
* tell configure which dri drivers we want to build, based on the old
  configs/debian-dri-default
* disable direct rendering for the glx libGL on the hurd
* make sure patches are applied before we run autoreconf, and autoreconf
  runs before all builds
2008-07-05 14:03:57 +02:00
Julien Cristau
4b9b01f0a5 Use --with-driver=dri for the dri config
the default is xlib on some architectures and dri on others, so we
need to set that explicitly
2008-07-05 12:59:14 +02:00
Timo Aaltonen
0261355a03 Fix confflags CFLAGS and clean up confflags-dri. 2008-07-04 11:50:09 +03:00
Timo Aaltonen
beb8547c71 Delete two files not available on the tarball.
docs/gears.png
src/glut/os2/src-glut_os2pm.zip
2008-07-04 11:50:08 +03:00
Timo Aaltonen
4aa518a2d7 Add a patch from upstream to set installdir properly.
this also replaces 01_fix-libdir.patch and the need to set --libdir for
every target.
2008-07-04 11:50:08 +03:00
root
08af66d57e Revert "Remove configs/current on clean."
This reverts commit 2380f8bd93.

Conflicts:

	debian/changelog
2008-07-04 11:50:08 +03:00
root
38eb154b39 Use --enable-glx-tls for dri. 2008-07-04 11:50:08 +03:00
Timo Aaltonen
2954e4c3d7 Disable glut for swx11 targets.
It was not built before either and would need new build-deps (xi xmu).
2008-07-04 11:50:08 +03:00
Julien Cristau
213803b4d4 fix libOSMesa versioning, to revert accidental SONAME bump. 2008-07-03 18:30:35 +02:00
Timo Aaltonen
2380f8bd93 Remove configs/current on clean. 2008-07-03 18:37:28 +03:00
Timo Aaltonen
e846ebc1a1 don't chmod configure which does not exist. 2008-07-03 18:14:25 +03:00
Timo Aaltonen
6dedd60350 Further autoconf changes:
add automake & autoconf to build-deps
add some cleanup rules
2008-07-03 15:53:19 +03:00
Timo Aaltonen
063a487fe1 Fix the configure.ac patch somewhat
workaround the problems by setting --libdir for all flavours, otherwise
the path used is /usr/usr/lib.
2008-07-03 13:20:21 +03:00
Timo Aaltonen
99a35fd4e1 01_fix-libdir.patch: libdir handling is broken in configure.ac, fix it. 2008-07-03 09:31:23 +03:00
Timo Aaltonen
cbaac82c2c Further tweaks to the autoconf stuff. Getting closer but still not there 2008-07-03 09:26:46 +03:00
Brian Paul
2c9e332bce mesa: when linking a shader program, make sure all the shaders compiled OK
cherry-picked from master
2008-07-02 17:05:01 -06:00
Brian Paul
e89deed74d mesa: fix error codes in _mesa_shader_source(), _mesa_get_shader_source()
cherry-picked from master
If the 'shader' parameter is wrong, need to either generate GL_INVALID_VALUE
or GL_INVALID_OPERATION.  It depends on whether 'shader' actually names a
'program' or is a totally unknown ID.
There might be other cases to fix...
2008-07-02 17:02:41 -06:00
Brian Paul
5cb6f5515f mesa: regenerated file 2008-07-02 17:02:14 -06:00
Brian Paul
c5024d4a5c mesa: added some missing equal() notEqual() intrinsics
cherry-picked from master
2008-07-02 17:01:26 -06:00
Timo Aaltonen
9d72de1fb2 Run autoreconf before building the various flavours. 2008-07-03 00:20:58 +03:00
Brian Paul
62626467b4 fixes some GLSL bugs 2008-07-02 12:45:16 -06:00
Brian Paul
c55a72ef48 mesa: regenerated files 2008-07-02 12:42:52 -06:00
Brian Paul
8a353c4020 mesa: fix all(bvec2) function typo, add missing bvec2/3/4() constuctors
cherry-picked from master
2008-07-02 12:42:12 -06:00
Brian Paul
8261c40bb9 mesa: init default span fog if fragprog uses fog input register
See bug #16194 for original patch.  Cleaned up a bit here.
2008-07-02 08:58:32 -06:00
Timo Aaltonen
053bf7f5db rules: Replace the old build system with the new autotools-based system. 2008-07-02 17:56:51 +03:00
Timo Aaltonen
e6a5e6512f Add gl.pc to libgl1-mesa-dev 2008-07-02 14:07:23 +03:00
Timo Aaltonen
bc32cd7fc8 Add dri_interface.h to mesa-common-dev. 2008-07-01 18:58:17 +03:00
Timo Aaltonen
24fde3cf34 Drop mesa-swx11-source. 2008-07-01 18:56:38 +03:00
Timo Aaltonen
7ceaa0916a Re-add linux-osmesa-static and linux-osmesa32-static
they were dropped by mistake during the merge.
2008-07-01 18:51:01 +03:00
Timo Aaltonen
4c958fbfb4 Build-depend on x11proto-dri2-dev. 2008-07-01 16:24:46 +03:00
Timo Aaltonen
9795ef4348 Refresh patches, and drop obsolete 00_create-libdir.patch and 01_fix-makefile.patch 2008-07-01 16:07:17 +03:00
Julien Cristau
768d8e0563 update changelog and require libdrm 2.3.1 2008-07-01 13:46:54 +02:00
Julien Cristau
374be37dd9 Merge branch 'master' of git.freedesktop.org:/git/mesa/mesa into debian-experimental
Conflicts:

	.gitignore
	Makefile
	bin/mklib
	configs/.gitignore
	configs/default
	configs/freebsd
	configs/freebsd-dri
	configs/linux-osmesa
	configs/linux-osmesa16
	configs/linux-osmesa16-static
	configs/linux-osmesa32
	docs/download.html
	docs/install.html
	docs/news.html
	docs/relnotes.html
	doxygen/Makefile
	doxygen/doxy.bat
	doxygen/header.html
	doxygen/header_subset.html
	include/GL/internal/dri_interface.h
	progs/demos/.gitignore
	progs/directfb/Makefile
	progs/egl/Makefile
	progs/fbdev/Makefile
	progs/fbdev/glfbdevtest.c
	progs/fp/Makefile
	progs/glsl/.gitignore
	progs/glsl/Makefile
	progs/glsl/bump.c
	progs/glsl/mandelbrot.c
	progs/glsl/noise.c
	progs/glsl/toyball.c
	progs/miniglx/Makefile
	progs/samples/.gitignore
	progs/slang/Makefile
	progs/tests/.gitignore
	progs/tests/Makefile
	progs/tests/arbnpot.c
	progs/tests/cva.c
	progs/tests/dinoshade.c
	progs/tests/drawbuffers.c
	progs/tests/fbotest2.c
	progs/tests/fbotexture.c
	progs/tests/getprocaddress.c
	progs/tests/mipmap_limits.c
	progs/tests/multipal.c
	progs/tests/texline.c
	progs/tools/trace/Makefile
	progs/trivial/Makefile
	progs/trivial/dlist-edgeflag-dangling.c
	progs/trivial/dlist-edgeflag.c
	progs/trivial/point-param.c
	progs/trivial/quad-clip-nearplane.c
	progs/trivial/tri.c
	progs/vp/Makefile
	progs/xdemos/.gitignore
	progs/xdemos/Makefile
	progs/xdemos/glthreads.c
	src/egl/Makefile
	src/egl/drivers/demo/Makefile
	src/egl/drivers/dri/Makefile
	src/egl/main/Makefile
	src/glu/mesa/Makefile
	src/glu/mesa/Makefile.m32
	src/glu/mesa/project.c
	src/glu/mini/project.c
	src/glut/directfb/Makefile
	src/glut/directfb/callback.c
	src/glut/directfb/events.c
	src/glut/directfb/internal.h
	src/glut/directfb/window.c
	src/glut/os2/Makefile
	src/glut/os2/WarpWin.cpp
	src/glut/os2/glutOverlay.cpp
	src/glut/os2/glut_8x13.cpp
	src/glut/os2/glut_9x15.cpp
	src/glut/os2/glut_bitmap.cpp
	src/glut/os2/glut_cindex.cpp
	src/glut/os2/glut_cmap.cpp
	src/glut/os2/glut_cursor.cpp
	src/glut/os2/glut_event.cpp
	src/glut/os2/glut_ext.cpp
	src/glut/os2/glut_fullscrn.cpp
	src/glut/os2/glut_gamemode.cpp
	src/glut/os2/glut_get.cpp
	src/glut/os2/glut_hel10.cpp
	src/glut/os2/glut_hel12.cpp
	src/glut/os2/glut_hel18.cpp
	src/glut/os2/glut_init.cpp
	src/glut/os2/glut_input.cpp
	src/glut/os2/glut_key.cpp
	src/glut/os2/glut_keyctrl.cpp
	src/glut/os2/glut_keyup.cpp
	src/glut/os2/glut_mesa.cpp
	src/glut/os2/glut_modifier.cpp
	src/glut/os2/glut_roman.cpp
	src/glut/os2/glut_shapes.cpp
	src/glut/os2/glut_stroke.cpp
	src/glut/os2/glut_swap.cpp
	src/glut/os2/glut_teapot.cpp
	src/glut/os2/glut_tr24.cpp
	src/glut/os2/glut_util.cpp
	src/glut/os2/glut_vidresize.cpp
	src/glut/os2/glut_warp.cpp
	src/glut/os2/glut_win.cpp
	src/glut/os2/glut_winmisc.cpp
	src/glut/os2/glutbitmap.h
	src/glut/os2/glutstroke.h
	src/glut/os2/layerutil.h
	src/glut/os2/libGlut.DEF
	src/glut/os2/os2_glx.cpp
	src/glut/os2/os2_menu.cpp
	src/glut/os2/os2_winproc.cpp
	src/glw/Makefile
	src/glx/mini/Makefile
	src/glx/mini/miniglx.c
	src/glx/x11/glxext.c
	src/mesa/Makefile
	src/mesa/drivers/allegro/amesa.c
	src/mesa/drivers/allegro/direct.h
	src/mesa/drivers/allegro/generic.h
	src/mesa/drivers/d3d/D3DCAPS.CPP
	src/mesa/drivers/d3d/D3DHAL.H
	src/mesa/drivers/d3d/D3DInit.cpp
	src/mesa/drivers/d3d/D3DMESA.H
	src/mesa/drivers/d3d/D3DRaster.cpp
	src/mesa/drivers/d3d/D3DTEXT.CPP
	src/mesa/drivers/d3d/D3DTextureMgr.cpp
	src/mesa/drivers/d3d/D3DTextureMgr.h
	src/mesa/drivers/d3d/D3DUTILS.CPP
	src/mesa/drivers/d3d/DDrawPROCS.c
	src/mesa/drivers/d3d/DEBUG.C
	src/mesa/drivers/d3d/DEBUG.H
	src/mesa/drivers/d3d/DbgEnv.bat
	src/mesa/drivers/d3d/MAKEFILE
	src/mesa/drivers/d3d/OPENGL32.DEF
	src/mesa/drivers/d3d/WGL.C
	src/mesa/drivers/dri/Makefile.template
	src/mesa/drivers/dri/common/dri_bufmgr.c
	src/mesa/drivers/dri/common/dri_drmpool.c
	src/mesa/drivers/dri/common/dri_util.c
	src/mesa/drivers/dri/common/dri_util.h
	src/mesa/drivers/dri/common/xmlconfig.c
	src/mesa/drivers/dri/glcore/Makefile
	src/mesa/drivers/dri/i915/i915_fragprog.c
	src/mesa/drivers/dri/i915/i915_program.h
	src/mesa/drivers/dri/i915/i915_texprog.c
	src/mesa/drivers/dri/i915/i915_texstate.c
	src/mesa/drivers/dri/i915/i915_vtbl.c
	src/mesa/drivers/dri/i915/intel_context.c
	src/mesa/drivers/dri/i915/intel_context.h
	src/mesa/drivers/dri/i915/intel_pixel.c
	src/mesa/drivers/dri/i915/intel_render.c
	src/mesa/drivers/dri/i915/intel_screen.c
	src/mesa/drivers/dri/i915/intel_state.c
	src/mesa/drivers/dri/i915/intel_tex.c
	src/mesa/drivers/dri/i915/intel_tris.c
	src/mesa/drivers/dri/i915tex/i830_reg.h
	src/mesa/drivers/dri/i915tex/i830_texstate.c
	src/mesa/drivers/dri/i915tex/i830_vtbl.c
	src/mesa/drivers/dri/i915tex/i915_fragprog.c
	src/mesa/drivers/dri/i915tex/i915_metaops.c
	src/mesa/drivers/dri/i915tex/i915_tex_layout.c
	src/mesa/drivers/dri/i915tex/i915_texstate.c
	src/mesa/drivers/dri/i915tex/i915_vtbl.c
	src/mesa/drivers/dri/i915tex/intel_render.c
	src/mesa/drivers/dri/i915tex/intel_screen.c
	src/mesa/drivers/dri/i915tex/intel_tris.c
	src/mesa/drivers/dri/i965/brw_aub.c
	src/mesa/drivers/dri/i965/brw_aub_playback.c
	src/mesa/drivers/dri/i965/brw_cc.c
	src/mesa/drivers/dri/i965/brw_clip.c
	src/mesa/drivers/dri/i965/brw_clip_state.c
	src/mesa/drivers/dri/i965/brw_clip_util.c
	src/mesa/drivers/dri/i965/brw_context.c
	src/mesa/drivers/dri/i965/brw_curbe.c
	src/mesa/drivers/dri/i965/brw_defines.h
	src/mesa/drivers/dri/i965/brw_draw.c
	src/mesa/drivers/dri/i965/brw_draw_upload.c
	src/mesa/drivers/dri/i965/brw_eu.h
	src/mesa/drivers/dri/i965/brw_eu_emit.c
	src/mesa/drivers/dri/i965/brw_gs_state.c
	src/mesa/drivers/dri/i965/brw_misc_state.c
	src/mesa/drivers/dri/i965/brw_sf_emit.c
	src/mesa/drivers/dri/i965/brw_sf_state.c
	src/mesa/drivers/dri/i965/brw_state_cache.c
	src/mesa/drivers/dri/i965/brw_state_pool.c
	src/mesa/drivers/dri/i965/brw_tex.c
	src/mesa/drivers/dri/i965/brw_tex_layout.c
	src/mesa/drivers/dri/i965/brw_vs_state.c
	src/mesa/drivers/dri/i965/brw_vs_tnl.c
	src/mesa/drivers/dri/i965/brw_wm.c
	src/mesa/drivers/dri/i965/brw_wm.h
	src/mesa/drivers/dri/i965/brw_wm_glsl.c
	src/mesa/drivers/dri/i965/brw_wm_sampler_state.c
	src/mesa/drivers/dri/i965/brw_wm_state.c
	src/mesa/drivers/dri/i965/brw_wm_surface_state.c
	src/mesa/drivers/dri/i965/bufmgr_fake.c
	src/mesa/drivers/dri/i965/intel_batchbuffer.c
	src/mesa/drivers/dri/i965/intel_batchbuffer.h
	src/mesa/drivers/dri/i965/intel_blit.c
	src/mesa/drivers/dri/i965/intel_blit.h
	src/mesa/drivers/dri/i965/intel_buffers.c
	src/mesa/drivers/dri/i965/intel_context.c
	src/mesa/drivers/dri/i965/intel_context.h
	src/mesa/drivers/dri/i965/intel_mipmap_tree.c
	src/mesa/drivers/dri/i965/intel_mipmap_tree.h
	src/mesa/drivers/dri/i965/intel_pixel_bitmap.c
	src/mesa/drivers/dri/i965/intel_pixel_copy.c
	src/mesa/drivers/dri/i965/intel_screen.c
	src/mesa/drivers/dri/i965/intel_tex_validate.c
	src/mesa/drivers/dri/i965/server/i830_common.h
	src/mesa/drivers/dri/intel/intel_batchbuffer.c
	src/mesa/drivers/dri/intel/intel_batchbuffer.h
	src/mesa/drivers/dri/intel/intel_blit.c
	src/mesa/drivers/dri/intel/intel_buffers.c
	src/mesa/drivers/dri/intel/intel_context.c
	src/mesa/drivers/dri/intel/intel_context.h
	src/mesa/drivers/dri/intel/intel_mipmap_tree.c
	src/mesa/drivers/dri/intel/intel_mipmap_tree.h
	src/mesa/drivers/dri/intel/intel_screen.h
	src/mesa/drivers/dri/r200/r200_texstate.c
	src/mesa/drivers/dri/r300/r300_cmdbuf.c
	src/mesa/drivers/dri/r300/r300_context.h
	src/mesa/drivers/dri/r300/r300_ioctl.c
	src/mesa/drivers/dri/r300/r300_reg.h
	src/mesa/drivers/dri/r300/r300_state.c
	src/mesa/drivers/dri/r300/r300_tex.h
	src/mesa/drivers/dri/r300/r300_texstate.c
	src/mesa/drivers/dri/radeon/radeon_screen.c
	src/mesa/drivers/windows/gdi/wmesa.c
	src/mesa/drivers/x11/fakeglx.c
	src/mesa/drivers/x11/xm_dd.c
	src/mesa/glapi/Makefile
	src/mesa/glapi/dispatch.h
	src/mesa/glapi/glapioffsets.h
	src/mesa/glapi/glapitable.h
	src/mesa/glapi/glapitemp.h
	src/mesa/glapi/glprocs.h
	src/mesa/main/api_validate.c
	src/mesa/main/attrib.c
	src/mesa/main/config.h
	src/mesa/main/context.c
	src/mesa/main/context.h
	src/mesa/main/dlist.c
	src/mesa/main/drawpix.c
	src/mesa/main/enums.c
	src/mesa/main/fbobject.c
	src/mesa/main/image.c
	src/mesa/main/imports.h
	src/mesa/main/mtypes.h
	src/mesa/main/points.c
	src/mesa/main/state.c
	src/mesa/main/texcompress_fxt1.c
	src/mesa/main/texenvprogram.c
	src/mesa/main/teximage.c
	src/mesa/main/texobj.c
	src/mesa/main/texstate.c
	src/mesa/main/version.h
	src/mesa/shader/prog_execute.c
	src/mesa/shader/program.c
	src/mesa/shader/shader_api.c
	src/mesa/shader/slang/library/slang_core.gc
	src/mesa/shader/slang/library/slang_core_gc.h
	src/mesa/shader/slang/slang_codegen.c
	src/mesa/sources
	src/mesa/sparc/glapi_sparc.S
	src/mesa/swrast/s_aalinetemp.h
	src/mesa/swrast/s_aatriangle.c
	src/mesa/swrast/s_aatritemp.h
	src/mesa/swrast/s_context.c
	src/mesa/swrast/s_copypix.c
	src/mesa/swrast/s_drawpix.c
	src/mesa/swrast/s_fragprog.c
	src/mesa/swrast/s_pointtemp.h
	src/mesa/swrast/s_readpix.c
	src/mesa/swrast/s_span.c
	src/mesa/swrast/s_texfilter.c
	src/mesa/swrast/s_tritemp.h
	src/mesa/swrast/s_zoom.c
	src/mesa/tnl/t_draw.c
	src/mesa/tnl/t_vb_fog.c
	src/mesa/tnl/t_vb_program.c
	src/mesa/tnl/t_vp_build.c
	src/mesa/vbo/vbo_split_copy.c
	src/mesa/x86-64/xform4.S
	src/mesa/x86/common_x86.c
	src/mesa/x86/glapi_x86.S
	windows/VC6/mesa/mesa/mesa.dsp
2008-07-01 13:18:27 +02:00
Xiang, Haihao
9fa552eb0f dri: Take the base image size into account when computing
first level of the mipmap. fix #16421
2008-07-01 11:50:11 +08:00
Brian Paul
5f8ad807be s/GL_INVALID_VALUE/GL_INVALID_OPERATION/ in _mesa_get_uniformfv() 2008-06-28 16:50:07 -06:00
Zou Nan hai
b6e165d661 optimize 965 clip
1. increase clip thread number to 2
  2. do cliptest for -rhw

Cherry-picked from commits b47c9f8c91,
aa88d11e7d.
2008-06-23 15:16:11 +08:00
Roland Scheidegger
afbb645906 r200: fix typo in r200TryDrawPixels parameter validation (bug 16406) 2008-06-21 02:52:18 +02:00
Brice Goglin
2b831e73f5 Prepare changelog for upload 2008-06-18 20:59:24 +02:00
Brice Goglin
6ec170290c Put all configs/ changes into the .diff.gz
Put back our configs/ changes into the .diff.gz since choose-configs
needs them before quilt is invoked. Put 04_cleanup-osmesa-configs.patch
there as well for #485161.
2008-06-18 20:59:09 +02:00
Brice Goglin
7c8ea0899a Revert "Move our configs/ changes from the .diff.gz into our quilt patches"
This reverts commit 03970183fc.

Conflicts:

	debian/changelog
2008-06-18 20:55:42 +02:00
Brice Goglin
f81070dbd5 Pull from mesa_7_0_branch 2008-06-18 20:55:00 +02:00
Brice Goglin
955c2ef48f Merge branch 'mesa_7_0_branch' of git://git.freedesktop.org/git/mesa/mesa into debian-unstable 2008-06-18 20:52:25 +02:00
Xiang, Haihao
2ac4919d24 i965: add support for Intel 4 series chipsets 2008-06-18 15:48:45 +08:00
Xiang, Haihao
3ed89025f3 i915: The pitch passed to intelEmitCopyBlitLocked should be in pixels,
not in bytes. Reported by Christopher Dissauer.
2008-06-18 13:52:04 +08:00
Xiang, Haihao
5b42bbce70 i915: fix data size in intelTryDrawPixels. Reported by Christopher Dissauer 2008-06-18 13:40:22 +08:00
Brian Paul
d2e0a11aab mesa: fix inconsistent use of GL_UNSIGNED_INT vs. GL_UNSIGNED_INT_24_8_EXT for Z unpacking 2008-06-17 16:44:00 -06:00
Brice Goglin
5033e5b36d Prepare changelog for upload 2008-06-17 20:01:01 +02:00
Brice Goglin
6a6a9c1c5a Pull from mesa_7_0_branch 2008-06-17 20:00:37 +02:00
Brice Goglin
3d6aa2e06f Merge branch 'mesa_7_0_branch' of git://git.freedesktop.org/git/mesa/mesa into debian-unstable 2008-06-17 19:54:47 +02:00
Brice Goglin
03970183fc Move our configs/ changes from the .diff.gz into our quilt patches
with 04_cleanup-osmesa-configs.patch renamed into 04_debian-configs.patch
2008-06-17 19:32:21 +02:00
Brian Paul
47d046c93f mesa: make mm.c use unsigned ints for offsets.
If you have a GPU using this code and it has the offsets up in this space,
this fails.

cherry-picked from master
2008-06-17 10:10:53 -06:00
Wilfried Holzke
718724deeb assorted glide driver fixes/updates 2008-06-17 10:03:03 -06:00
Brian Paul
85c325c36c add hyphen to rm command 2008-06-17 10:02:10 -06:00
Brian Paul
7e6d99f5ec glu: silence warnings 2008-06-17 09:01:40 -06:00
Brian Paul
6ce6dc961b bump version to 7.0.4 2008-06-16 10:19:29 -06:00
Brian Paul
186883611e fix glPixelZoom stack over flow on Windows 2008-06-16 10:19:28 -06:00
Brian Paul
48b3c59cb9 mesa: allocate pixel zoom arrays on heap, not stack
Fixes stack overflow on Windows.

cherry-picked from master
2008-06-16 10:19:28 -06:00
Brian Paul
04b9d5bc23 Fix _mesa_new_program() recursive call regression
This was introduced by the "i965 GLSL merge" from master (ce7a9efb09)
2008-06-16 10:19:28 -06:00
Brian Paul
91707e9020 fix GLSL generic vertex attrib linking bug 2008-06-16 10:19:28 -06:00
Xiang, Haihao
82a0e82232 i965: fix intel_batchbuffer_space. (bug#14709) 2008-06-13 13:53:46 +08:00
Brice Goglin
fe4264bf45 Prepare changelog for upload 2008-06-13 06:53:55 +02:00
Brice Goglin
2fa795a213 Pull from mesa_7_0_branch 2008-06-11 18:59:59 +02:00
Brice Goglin
e32aaf5da8 Merge branch 'mesa_7_0_branch' of git://git.freedesktop.org/git/mesa/mesa into debian-unstable 2008-06-11 18:58:59 +02:00
Brian
03447de338 disable ctx->Driver.NewProgram() call in _mesa_new_program()
This was causing infinite recursive calls w/ software drivers.
All vertex/fragment shaders should be allocated by calling
ctx->Driver.NewProgram(), not by calling _mesa_new_program().

(Cherry picked from commit 40133487db,
351a83163a).
2008-06-11 17:03:47 +08:00
Dave Airlie
ee5f4a4caf r300: disable the lowimpact fallbacks by default.
because really we should be able to just fix the driver.
(cherry picked from commit 7013eecf28)

There are actually even better reasons for this, the bottom line being that
enabling these fallbacks makes a lot of apps unusable mostly for no gain
whatsoever.
2008-06-11 10:42:16 +02:00
Xiang, Haihao
c04f3933ab i915: fix fd.o #14966 2008-06-11 11:36:01 +08:00
Xiang, Haihao
8f328c45e5 i915: Keith Whitwell's swizzling TEX patch. fix #8283
Cherry picked from commit 3369cd9a6f
2008-06-11 11:32:12 +08:00
Brice Goglin
9676f0cffc Pull from mesa_7_0_branch 2008-06-10 23:18:28 +02:00
Brice Goglin
2d0ca23319 Merge branch 'mesa_7_0_branch' of git://git.freedesktop.org/git/mesa/mesa into debian-unstable 2008-06-10 22:48:43 +02:00
Xiang, Haihao
6f4c8b5b50 i965: apply commit 6c1a98e97a to glsl
(cherry picked from commit a742bed99a)
2008-06-10 16:46:02 +08:00
Michal Wajdeczko
f8bd9cc30f Add support for ATI_separate_stencil in display lists.
(cherry picked from commit 7f747204ea)
2008-06-10 16:28:06 +08:00
Michal Wajdeczko
d9f9b1cd0b [965] Correctly set read mask for OPCODE_SWZ in pass1.
While OPCODE_SWZ has usually been optimized away in pass0, it may still
exist if a SWZ with dst saturate was emitted in pass_fp.  Fixes an error
in oglconform fpalu.c.
(cherry picked from commit 13a6f73a64)
2008-06-10 16:21:31 +08:00
Michal Wajdeczko
eca283976b [965] Avoid emitting dead code for DPx/math instructions.
The pass1 optimization stage clears out writemasks and registers, but the
instructions themselves are still being processed at this stage, and could
have resulted in them still being emitted.
(cherry picked from commit c60b5dfde8)
2008-06-10 16:18:48 +08:00
Michal Wajdeczko
2176259ca6 [965] Improve pinterp performance by delaying reads of just-written regs.
(cherry picked from commit bb419970ef)
2008-06-10 16:18:09 +08:00
Michal Wajdeczko
8fe6fcb900 [965] Fix negating of unsigned value in emit_wpos_xy.
(cherry picked from commit 6c1a98e97a)
2008-06-10 16:16:52 +08:00
Michal Wajdeczko
76d6edcc38 [965] Add MVP code for position invariant vertex programs.
This fixes the arbvptorus demo.
(cherry picked from commit 5f10438f2d)
2008-06-10 16:13:06 +08:00
Michal Wajdeczko
98d6c671f5 [win32] Use native aligned memory allocation functions.
(cherry picked from commit 31fe7cf5e3)
2008-06-10 16:12:18 +08:00
Andrzej Trznadel
f652811df4 [965] Fix fp temp reg release code to not usually release all temps.
Also, use wrapped ffs() instead of native.
(cherry picked from commit 3105bc1d88)
2008-06-10 15:45:11 +08:00
Andrzej Trznadel
e279f4601d Fix compat implementation of ffs() to return 1-based bit numbers.
(cherry picked from commit e9809a36aa)
2008-06-10 15:44:53 +08:00
Keith Packard
87a30337a1 [i965] short immediate values must be replicated to both halves of the dword
The 32-bit immediate value in the i965 instruction word must contain two
copies of any 16-bit constants. brw_imm_uw and brw_imm_w just needed to
copy the value into both halves of the immediate value instruction field.
(cherry picked from commit ca73488f48)
2008-06-10 15:37:11 +08:00
Eric Anholt
9c2047b275 [965] Don't let the negate flags of src0 affect 1 constants in precalc_dst/lit
This patch is a variant of a submission by Michal Wajdeczko to fix
oglconform fpalu failures.
(cherry picked from commit b4cbf6983e)
2008-06-10 15:32:53 +08:00
Zou Nan hai
1dcb0433a3 [i915] fix fragment.position 2008-06-10 15:28:07 +08:00
Zou Nan hai
5ff27e02b3 [i965] fix wpos height 1 pixel higher
(cherry picked from commit b0f681b458)
2008-06-10 15:25:20 +08:00
Eric Anholt
4beee58e57 [965] Bug #9151: make fragment.position return window coords not screen coords.
(cherry picked from commit 9c8f27ba13)
2008-06-10 15:22:08 +08:00
Eric Anholt
1f9de20719 [915] Fix COS function using same plan as SIN.
The previous COS function failed badly outside of [-pi/2, pi/2].
2008-06-10 14:55:52 +08:00
Eric Anholt
d05a8d9750 [915] Use a quartic term to improve the accuracy of SIN results.
This is described in the link in the comment, and is the same technique that
r300 uses.
2008-06-10 14:46:12 +08:00
Eric Anholt
db5f206c00 [915] Fix fp SIN function, and use a quadratic approximation instead of Taylor.
The Taylor series notably fails at producing sin(pi) == 0, which leads to
discontinuity every 2*pi.  The quadratic gets us sin(pi) == 0 behavior, at the
expense of going from 2.4% THD with working Taylor series to 3.8% THD (easily
seen on comparative graphs of the two).  However, our previous implementation
was producing sin(pi) < -1 and worse, so any reasonable approximation is an
improvement.  This also fixes the repeating behavior, where the previous
implementation would repeat sin(x) for x>pi as sin(x % pi) and the opposite
for x < -pi.
2008-06-10 14:22:36 +08:00
Eric Anholt
9dface8347 [965] Fix potential segfaults from bad realloc.
C has no order of evaluation restrictions on function arguments, so we
attempted to realloc from new-size to new-size.
(cherry picked from commit e747e9a072)
2008-06-10 13:54:01 +08:00
Eric Anholt
32f4940883 [965] Fix inversion of SLT/SGE results in vertex programs.
The WM code had this right, so copy its behavior.  This reverts a flipping
of the arguments to SLT in brw_vs_tnl which came in with the GLSL code that
probably occurred to work around the flipped results, and brings the code back
in line with t_vp_build.c.
(cherry picked from commit 9bae03a583)
2008-06-10 13:44:54 +08:00
Eric Anholt
a7969a9b93 [965] Fix and enable separate stencil.
Note that this does not enable GL_EXT_stencil_two_side, because Mesa's computed
_TestTwoSide ends up respecting only STENCIL_TEST_TWO_SIDE_EXT (defaults to
GL_FALSE), even if the application uses only GL 2.0 / ATI entrypoints.
(cherry picked from commit 9136e1f2c8)
2008-06-10 13:30:25 +08:00
Eric Anholt
ad88130df5 [965] Replace our own depth constants in intel context with GL context ones. 2008-06-10 13:08:09 +08:00
Eric Anholt
d1e71bc08b [965] Remove dead code in upload_wm_surfaces.
(cherry picked from commit 3ecdae82d7)
2008-06-10 11:19:53 +08:00
Roland Scheidegger
fa58fe247c i965: fix OPCODE_TEX when additional ops are needed 2008-06-08 14:04:39 +02:00
Brian Paul
4b71478326 Set the attribute as used.
Cherry-picked from gallium-0.1
2008-06-04 14:42:55 -06:00
Zou Nan hai
0989471fdb [i915] GL_DEPTH_TEXTURE_MODE fix
Cherry picked from commit 7233eabaf0
with manual changes.
2008-06-04 15:57:37 +08:00
Xiang, Haihao
696140bd1d i965: handle source depth to render target for glsl,
(cherry picked from commit d2540e6d4b)
2008-06-04 11:54:25 +08:00
Brian
380d15b7fe replace // comment with /* */ (bug 14916)
(cherry picked from commit eecb3ab7c6)
2008-06-04 11:52:38 +08:00
Xiang, Haihao
41261d64b2 i965: use _Current pointer instead of Current pointer.
Cherry picked from commit de1e9880f8
2008-06-04 11:51:19 +08:00
Zou Nan hai
ce7a9efb09 [i965] Add support for GL shading language in I965 driver.
Cherry picked from commit 6ef27b88e6,
d0ebdca4fa.
2008-06-04 11:47:08 +08:00
Zou Nan hai
8a38ebe328 [i965] This is to fix random crash in some maps of Ut2004 demo.
e.g. bridge of fate.
 	If vs output is big, driver may fall back to use 8 urb entries for vs,
	unfortunally, for some unknown reason, if vs is working at 4x2 mode,
	8 entries is not enough, may lead to gpu hang.

Cherry picked from commmit c9c64a100d
2008-06-03 11:30:41 +08:00
Zou Nan hai
dcc6671b85 [i915] don't use 4x4 filter for 1D shadowmap
Cherry picked from commit d24a5254c2
2008-06-03 11:23:44 +08:00
Zou Nan hai
b53b7581e4 [i965] fix fd.o bug #11471 and #11478
1. Follow EXT_texture_rectangle with YCbCr texture
	2. swap UV component for MESA_FORMAT_YCBCR

Cherry picked from commit 7676980d38.
2008-06-03 11:04:10 +08:00
Zou Nan hai
64a4a03c2a EXT_texture_sRGB support on i965
Cherry picked from commit 6bf81a5edf,
246d1d2522.
2008-06-03 10:09:33 +08:00
Brian Paul
b878c3f518 i915tex: fix fragment fog swizzle (from master) (bug 16195) 2008-06-02 09:29:22 -06:00
Brian Paul
6164163ca8 glDrawElement + VBO bug fix 2008-06-02 09:28:31 -06:00
Zou Nan hai
e92a53cd92 [i965] flip point sprite
Cherry picked from commit 1202c434d9
2008-06-02 17:05:57 +08:00
Zou Nan hai
2467af98b1 ARB sprite point support on i965
Cherry picked from commmit 60179434d1,
505453a04e with manual changes.
2008-06-02 17:01:31 +08:00
Xiang, Haihao
6f851d8875 _generic_read_RGBA_span_BGRA8888_REV_SSE2: It should adjust the source
and target pointers after do the first 2 pixels. fix bug #15850

Cherry-picked from commit 4b7d301c94
2008-06-02 14:28:42 +08:00
Xiang, Haihao
9b99bf89c4 i965: depth offset on glPolygonMode(GL_LINE/GL_POINT)
Cherry picked from 184cf464f4
2008-06-02 14:20:23 +08:00
Xiang, Haihao
7346fca083 965: use RGB565 to render a bitmap if Depth is 16
Cherry-picked from commit 5982d39799.
2008-06-02 14:15:24 +08:00
Xiang, Haihao
7facbb69c6 i965: don't swizzle fogcoord if FogOption is FOG_NONE.
fix #10788 issue on 965.

Cherry picked from commit 83068115e2
2008-06-02 14:08:26 +08:00
Xiang, Haihao
f59267d650 i915: set fogcoord to (f,0,0,1). fix #10788 issue on 915.
Cherry picked from commit 7eef52e975
2008-06-02 14:06:14 +08:00
Xiang, Haihao
71cb014195 mesa: fix a bad cast in put_values_z24.
The values passed to put_values_z24 are GLuint,
not GLubyte. fix #13543

Cherry picked from commit cf46aee14a
2008-06-02 13:59:51 +08:00
Xiang, Haihao
6c0f8db9c2 i965: The jump instruction count is added
to IP pre-increment, and should point to
the first instruction after the do instruction
of the do-while block of code

Cherry picked from commit 46e03d584a
2008-06-02 13:54:45 +08:00
Xiang, Haihao
49f1e2fc4c i965: fix an error in brw_vs_tnl.c
Update the tnl program if the state of TEXMAT is changed.
2008-06-02 13:46:31 +08:00
Eric Anholt
2d26e19535 [965] Clarify a bit of index buffer upload code.
Cherry picked from commit 5a49e84fcd
2008-06-02 13:18:00 +08:00
Xiang, Haihao
5b0c6cd49a i965: align the address of the first element within
the index buffer. (fix#11910)

Cherry picked from ea07a0df9a
2008-06-02 13:16:53 +08:00
Xiang, Haihao
c3ee8e46cc i965: fix projtex_mask
projtex_mask is only an 8bit field, and wm.input_size_masks includes
other attributes' information, therefore right shift is needed.

Cherry picked from 88451b04e9
2008-06-02 13:01:11 +08:00
Xiang, Haihao
46aac24261 i965: fix bad casts in do_blit_bitmap to support WindowPos correctly
Cherry picked from commit e66757c8ba
2008-06-02 11:54:35 +08:00
Xiang, Haihao
e1032ce718 i965: fix DEPTH_TEXTURE_MODE
Cherry picked from commit 6e620162a1 with
manual changes
2008-06-02 11:52:36 +08:00
Brian Paul
ce636f36f2 Fix segfault in _save_OBE_DrawElements() when using VBO and display list (bug 16156)
This was previously fixed in master by commit 982dcb74fd by Haihao Xiang.
2008-05-30 08:46:51 -06:00
Xiang, Haihao
93f2eec6b3 i965: roland's DXTn format texture patch(bug10347)
Cherry picked from commit db928291dc
2008-05-29 15:50:06 +08:00
Eric Anholt
46ef09d787 [965] Replace various alignment code with a shared ALIGN() macro.
In the process, fix some alignment issues:
- Scratch space allocation was aligned into units of 1KB, while the allocation
  wanted units of bytes, so we never allocated enough space for scratch.
- GRF register count was programmed as ALIGN(val - 1, 16) / 16 instead of
  ALIGN(val, 16) / 16 - 1, which overcounted for val != 16n+1.

Cherry picked from commit 77e0523fb7
2008-05-29 15:48:47 +08:00
Xiang, Haihao
7487ec0ff0 i965: align width/height for volume texture
Cherry picked from commit 00b86ecf6f
2008-05-29 15:45:12 +08:00
Xiang, Haihao
a25549866f intel: applying right alignment to compressed texture,
which make small textures(4x4,2x2,1x1) work well.

Cherry picked from commit 8ea66fa2ec
2008-05-29 15:43:31 +08:00
Xiang, Haihao
558cc6e38f i965: set mt->cpp differently with compressed texture
Cherry picked from commit 2cafd749b8
2008-05-29 15:40:44 +08:00
Xiang, Haihao
feb1fa1e83 i965: use BRW_TEXCOORDMODE_CLAMP instead of BRW_TEXCOORDMODE_CLAMP_BORDER
to implement GL_CLAMP

Cherry picked from commit ab99960858. fix #16005
2008-05-28 16:29:17 +08:00
Brian Paul
f32462343d allow GLX_SAMPLES_ARB==0 (bug 16073) 2008-05-27 09:49:44 -06:00
Brian Paul
08ef1b379a added sampler types to sizeof_glsl_type() 2008-05-27 08:50:15 -06:00
Karl Schultz
1e79831b56 dependency fixes (bug 13544) 2008-05-27 08:50:14 -06:00
Tormod Volden
7a29164f70 dri: vblank_mode warning
From what I can see the environment variables LIBGL_THROTTLE_REFRESH
and LIBGL_SYNC_REFRESH were taken out like 3 years ago, but this
warning was never updated.
2008-05-24 18:34:27 +02:00
Brian Paul
f2533e787e AA tri and glMaterial fixes 2008-05-16 15:35:19 -06:00
Brian Paul
b2ccd5c1ae fix memory access error in vbo_bind_vertex_list
Picked from master (commit 8fc1a6808d)
2008-05-16 15:35:19 -06:00
Brian Paul
6f63543dd7 fix an attr/src mix-up when setting-up/binding vertex arrays
This fixes problems with incorrect material coefficients when glMaterial
is called per-vertex.
2008-05-16 15:35:19 -06:00
Brian Paul
c966f1629b fix segfault in AA triangle code when using certain shaders 2008-05-16 15:35:19 -06:00
Xiang, Haihao
709f24adbb intel: Set right cliprects for the current draw region. fix #15057 2008-05-14 15:01:44 +08:00
Brian Paul
52fe7ea3d1 mesa: free shader program data before deleting shader objects.
Picked from master.
Fixes mem corruption seen when glean/api2 test exits.
2008-05-07 16:10:32 +01:00
Xiang, Haihao
44f6a6f9c4 i915: Add E7221 variant to i915.
Cherry picked from commit 39bcbe0921
2008-05-07 14:09:28 +08:00
Brian Paul
ac88b3dd16 Add support for GL_REPLACE_EXT texture env mode.
GL_REPLACE_EXT comes from the ancient GL_EXT_texture extension.  Found an old demo that
actually uses it.
The values of the GL_REPLACE and GL_REPLACE_EXT tokens is different, unfortunately.
2008-04-30 16:08:28 -06:00
Brian Paul
27b6fa5615 mesa: adjust glBitmap coords by a small epsilon
Fixes problem with bitmaps jumping around by one pixel depending on window
size.  The rasterpos is often X.9999 instead of X+1.
Run progs/redbook/drawf and resize window to check.

Cherry picked from gallium-0.1 branch
2008-04-29 18:38:26 -06:00
Brian Paul
68eb76dfb7 Enabled GL_EXT_multi_draw_arrays extension in R200/R300 drivers 2008-04-29 18:38:26 -06:00
Ove Kaaven
392760ee0c r200: fix state submission issue causing bogus textures (bug 15730) 2008-04-29 22:11:23 +02:00
Michel Dänzer
063b60a51f Change default of driconf "allow_large_textures" to announce hardware limits.
The previous default these days served mostly to cause artifical problems with
GLX compositing managers like compiz (see e.g.
http://bugs.freedesktop.org/show_bug.cgi?id=10501).

(cherry picked from commit acba9c1771)
2008-04-29 19:03:44 +02:00
Brian Paul
7b676192e9 enable GL_EXT_multi_draw_arrays (see bug 15670) 2008-04-24 16:31:28 -06:00
Brian Paul
138e0010eb added FreeBSD static config 2008-04-23 08:23:18 -06:00
Anatolij Shkodin
36bad2b478 added freebsd-static 2008-04-23 08:23:18 -06:00
Alan Hourihane
f6d6fc603e revert 2008-04-22 23:08:35 +01:00
Alan Hourihane
5545b46571 small cleanups 2008-04-22 20:29:42 +01:00
Alan Hourihane
06b0a7acce correct the return value 2008-04-22 20:29:00 +01:00
Alan Hourihane
534f30064d Fix error string 2008-04-22 20:28:35 +01:00
Brian Paul
6c9e1b2337 fix GL_ARB_texture_rectangle breakage 2008-04-14 13:44:05 -06:00
Brian Paul
62c67576e0 fixed WIN32 compile problem in libGLU 2008-04-14 13:41:17 -06:00
Brian Paul
91d59e4cb9 check for _WIN32 and __WIN32__ 2008-04-14 13:40:39 -06:00
Brian Paul
8de268bb3c add -Wl case (part of prev DragonFly patch) 2008-04-14 12:58:51 -06:00
Brian Paul
4fd7f6047c define #extension GL_ARB_texture_rectangle 2008-04-14 12:58:51 -06:00
David Flynn
ff3033e190 define #extension GL_ARB_texture_rectangle 2008-04-14 12:58:51 -06:00
Roland Scheidegger
18404076e3 r200: fix XPD vertex program instruction when using temps as inputs
due to the two read ports limit into temp memory may need the MAD_2 instruction
for the second instruction of the decomposed XPD.
While here, also try to avoid MAD_2 for MAD if all 3 inputs are temps but the
temps aren't actually distinct.
2008-04-12 02:40:44 +02:00
Brice Goglin
59c9c40c01 Prepare changelog for upload 2008-04-11 08:42:55 +02:00
Brice Goglin
666e0635da New upstream release 2008-04-11 08:41:32 +02:00
Brice Goglin
f9968a0346 Merge tag 'mesa_7_0_3' into debian-unstable 2008-04-11 08:38:26 +02:00
Hasso Tepper
39dca05d1d New dragonfly configs
A re-do commit, this time with the intended commit message.
2008-04-09 19:05:59 -06:00
Brian Paul
f51b76b670 Revert "Hasso Tepper <hasso@estpak.ee>"
This reverts commit 40ee989db5.
2008-04-09 19:04:36 -06:00
Brian Paul
40ee989db5 Hasso Tepper <hasso@estpak.ee> 2008-04-09 19:02:41 -06:00
Brian Paul
ef76dfc7a0 add link to 7.0.4 relnotes 2008-04-09 19:01:07 -06:00
Brian Paul
02ddc08353 initial 7.0.4 relnotes 2008-04-09 19:00:53 -06:00
Hasso Tepper
4b24d5261a patches for DragonFly OS 2008-04-09 18:59:19 -06:00
Brian
4b96a39c48 added MD5 sums for 7.0.3 2008-04-04 19:24:32 -06:00
Brian
48616e71d2 final prep/changes for 7.0.3 release 2008-04-04 19:06:30 -06:00
Brian
70d227ac62 7.0.3 release candidate 3 2008-04-01 18:04:13 -06:00
Eric Anholt
7f2c4f96f5 Bug #13492: Only call ProgramStringNotify if program parsing succeeded.
Wine intentionally tries some out-of-spec programs to test strictness, and
calling ProgramStringNotify on the results of a failed program parse resulted
in crashes in the 965 driver.
(cherry picked from commit 185320ae13)
2008-04-01 16:27:48 -07:00
Roland Scheidegger
667f0f60fc fix mistakenly set ATIFragmentShader._Enabled bit (bug 15269) 2008-04-01 23:25:04 +02:00
Brian
7592b8cc10 added some missing calls to _mesa_enable_x_y_extensions() 2008-04-01 08:41:24 -06:00
Brian
f55b831859 fix ARB f/v program comment parsing bug 2008-03-31 15:00:18 -06:00
Markus Amsler
217f7f7e5d fix parsing bug involving comments at the end of ARB v/f programs 2008-03-31 15:00:18 -06:00
Julien Cristau
2e5a63f365 Prepare changelog for upload 2008-03-31 16:47:34 +02:00
Julien Cristau
7c614b4666 Fix libgl1-mesa-swx11-i686's dependencies
Change libgl1-mesa-swx11-i686's pre-dependency on libgl1-mesa-swx11 to a
regular versioned dependency, and add ${shlibs:Depends}.
I'm not sure why this used Pre-Depends in the first place, I don't think
that's needed.
2008-03-31 16:47:17 +02:00
Julien Cristau
b23d908829 Update 02_use-ieee-fp-on-s390-and-m68k.patch. 2008-03-31 13:17:24 +02:00
Julien Cristau
5379b84e63 Update changelog and add bug closer 2008-03-31 13:11:59 +02:00
Julien Cristau
32c913308e Merge branch 'mesa_7_0_branch' of git.freedesktop.org:/git/mesa/mesa into debian-unstable 2008-03-31 13:00:20 +02:00
Xiang, Haihao
1e83d70b6d i965: Apply -ve rhw to 965. Fix the regression introduced by
commit da476ff02d. (bug#14940)
2008-03-31 09:37:55 +08:00
Brian
767dfa5b9c fix texture/renderbuffer mix-up in test_attachment_completeness() 2008-03-28 13:25:25 -06:00
Alan Hourihane
7ff5b38126 Fix build problems 2008-03-27 16:36:12 +00:00
Brian
e209f5300d updated glext.h to version 40 2008-03-25 08:11:47 -06:00
Brian
3c4b50c352 updated to version 40 2008-03-25 08:11:36 -06:00
Brian
4e7c2fcf18 add GL_READ_FRAMEBUFFER_BINDING_EXT case, regenerate get.c file 2008-03-24 19:55:46 -06:00
Brian
22534f94f5 fix wrong values for GL_READ/DRAW_FRAMEBUFFER_BINDING_EXT tokens 2008-03-24 19:55:04 -06:00
Brian
1a6928fdbe use ctx->Driver.DeleteProgram() in a few more places 2008-03-22 10:27:08 -06:00
Brian
325dbbac47 delete default programs with ctx->Driver.DeleteProgram() 2008-03-22 09:11:35 -06:00
Brian
39ac6b0481 Fix some PBO breakage.
In _mesa_Bitmap, can't early return if bitmap ptr is NULL, it may be an offset
into a PBO.  Similarly for _mesa_GetTexImage.
2008-03-21 12:32:29 -06:00
Brian
46cc4854e9 fix IEEE_ONE definition for ICC compiler (bug 15134) 2008-03-19 17:25:18 -06:00
Alan Hourihane
f93882512e set outputs_safe to 0 as it's possible for the code generation
to slip over the allocated memory for the vb.

pull in sse fixes from gallium-0.1
2008-03-19 01:03:48 +00:00
Markus Amsler
0dee2a4f6f only set InputsRead bit if input is really used 2008-03-17 08:35:34 -06:00
Brian
3cebc35669 init tmpNode to zeros 2008-03-14 14:16:00 -06:00
Brian Paul
e75a204fb9 mesa: fix emit_clamp() so that we don't use an output register as temporary
IR_CLAMP is decomposed into OPCODE_MIN+OPCODE_MAX.  Allocate a temporary
register for the intermediate value so we don't inadvertantly use an output
register (which are write-only on some GPUs).
2008-03-14 13:57:53 -06:00
Roland Scheidegger
ac06a5c16a fix state.lightprod ambient/specular w value (bug #14983) 2008-03-13 12:43:53 +01:00
Dan Nicholson
ed758fee0c Merge branch '7.0-glx' into mesa_7_0_branch 2008-03-10 16:45:49 -07:00
Jeremy Huddleston
a21c61ee8b Darwin: Fixed small error in darwin config files 2008-03-10 16:02:55 -07:00
Dan Nicholson
24697da20e glapi: Resync generated files with 7.0 branch
The previous commits pulled in the generated files from master. This
regenerates the files from the source on the 7.0 branch.
2008-03-10 15:17:59 -07:00
Jeremy Huddleston
7120c0089d Darwin: Config/source fixes to now build glxdemo apps and OSMesa
Also added darwin-fat-32bit darwin-fat-all configs and deleted old darwin-x86ppc config
2008-03-10 15:13:44 -07:00
Dan Nicholson
88a436a8f7 glapi: Generate xserver glapi sources in the mesa tree
Instead of generating the glapi sources for the xserver and commiting
them to the xserver tree, we can keep them in the mesa tree and change
the xserver build to use the files from the mesa tree.

This makes the xserver glx build more robust as it reduces the chances
for mismatches of the glX API used in the xserver vs. in mesa.
(cherry picked from commit 7688791fc5)
2008-03-10 15:03:13 -07:00
Dan Nicholson
2fdb5a245d glapi: Correct prerequisites for gl_and_glX_API.xml
The indirect_dispatch.h and indirect_table.c source files use
gl_and_glX_API.xml in their generation rather than glX_API.xml, but it
wasn't listed in their prerequisites. In turn, gl_and_glX_API.xml uses
glX_API.xml, but this is already listed in $(COMMON_GLX).
(cherry picked from commit 929b6d2ebf)
2008-03-10 15:03:01 -07:00
Dan Nicholson
8441b53538 glapi: Use make automatic variables to clean up the commands
Make use of the make automatic variables $@ (the target) and $< (first
prerequisite) to clean up the commands for the glapi generation. This
improves readability and guards against typos since words are repeated
less frequently.
(cherry picked from commit fc67d47708)
2008-03-10 15:02:51 -07:00
Dan Nicholson
d336df8b73 glapi: Use variable for indent and flags
Put the path to indent and the flags to call it with in configs/default
rather than in the Makefile. This makes it easier to change the values
globally.
(cherry picked from commit 817af9bec2)
2008-03-10 15:02:36 -07:00
Brian
8aaf805b8a fix parsing of state.texenv.color (bug 14931) 2008-03-10 07:41:31 -06:00
Markus Amsler
8161fd2785 Set normalized flag for GLubyte arrays in _mesa_VertexAttribPointerNV() 2008-03-09 17:53:00 -06:00
Markus Amsler
2f23025dfe init vertex weight attrib to (1,0,0,0) 2008-03-09 17:51:21 -06:00
Brian
1867eac230 fix __builtin_expect() definition test for IBM XLC (sf bug 1909832) 2008-03-09 10:54:50 -06:00
Roland Scheidegger
096e35d05f state.depth.range alpha value should be 1, not 0 (bug #14733) 2008-03-01 02:57:01 +01:00
Xiang, Haihao
8998f52b97 Don't Swap buffer if a DRIDrawable is entirely obscured by another window. 2008-02-28 11:43:54 +01:00
Brian
0fd38dcc83 Replace glut_fbc.c with glut_fcb.c (cb=callback) 2008-02-25 10:57:54 -07:00
Julien Cristau
d89cf0649e Add bug closer for #408679. 2008-02-24 10:23:17 +01:00
Julien Cristau
31e9d9d4f8 Prepare changelog for upload. 2008-02-23 18:18:42 +01:00
Julien Cristau
ea9c6d3d9e 03_optional-progs-and-install.patch: partly applied upstream, fixed up 2008-02-23 16:08:53 +01:00
Brian
ff63cf8068 bump libGL.so version number 2008-02-22 07:59:39 -07:00
Julien Cristau
eaac94c35a Update changelog. 2008-02-22 12:16:27 +01:00
Julien Cristau
9291506af0 Merge branch 'mesa_7_0_branch' of git.freedesktop.org:/git/mesa/mesa into debian-unstable
Conflicts:

	src/glx/mini/Makefile
2008-02-22 12:09:35 +01:00
Brian
4716670de9 prep for 7.0.3 rc-2 2008-02-21 16:59:20 -07:00
Brian
33c5b38034 latest bug fixes 2008-02-20 09:39:59 -07:00
Brian
5737d6c565 Fix point rasterization regression caused by commit 95a2eb9767
Even-sized, non-AA points need 0.5 bias in position to hit the right pixels.
Test program from bug report 11016 retested and is OK.
2008-02-20 09:38:16 -07:00
Brian
08a7f56c6a raise GL_INVALID_OPERATION if glProgramString compilation fails
cherry picked from master.
2008-02-20 09:00:49 -07:00
Brian
7916f2b4aa Fix glBegin-time test for invalid programs/shaders.
Cherry picked from master.
2008-02-20 08:56:20 -07:00
Brian
193d303ac7 Added <size name="Get" mode="get"/> lines for point parameter tokens.
Cherry picked from master
2008-02-19 08:46:39 -07:00
Jeremy Huddleston
e70609b7b8 Apple: Pulled in changes from Apple's patchset to allow mesa to build on darwin again 2008-02-19 00:54:35 -08:00
Xiang, Haihao
da476ff02d i965: new integrated graphics chipset support 2008-02-19 15:59:50 +08:00
Brian
77e3b5d28b Fix potential glDrawPixels(GL_DEPTH_COMPONENT) crashes (bug 13915)
Also, general clean-up of the Xlib-optimized glDraw/CopyPixels code.
2008-02-16 09:56:26 -07:00
Brian
bf97ca448c Fix glBindTexture crash (bug 14514) 2008-02-15 13:42:19 -07:00
Roland Scheidegger
c5f8ff8b32 fix bug with generated fragment programs if vertex shader is active
When generating a fragment program from fixed function, checking
texUnit->_ReallyEnabled is not sufficient, need texUnit->Enabled too
since the former also represents texture enables from an active vertex
shader.
2008-02-15 17:26:58 +01:00
caner
50465766d1 miniglx doc updates 2008-02-14 09:34:08 -07:00
Xiang, Haihao
7d8df58a63 _mesa_swizzle_ubyt_image: Don't use single swizzle_copy call
if components don't match. fix #13508
2008-02-13 07:07:47 -07:00
Andy Skinner
762c074012 added -altopts to allow overriding all other opts 2008-02-07 13:19:55 -07:00
Brian
51f2ee3bfb fix bug 9871 2008-02-06 07:55:26 -07:00
Brian
b5cd34aa21 Fix bug 9871: enable user-defined clip planes for R300
Patch provided by Erkin Bahceci <erkinbah@gmail.com>
2008-02-06 07:54:24 -07:00
Tony DeFeo
ae5c6dcd42 [965] Fix memory leak when deleting buffers with backing store. 2008-02-05 10:49:44 -08:00
Roland Scheidegger
97196d0c8c regenerate glsl library functions 2008-01-31 01:36:23 +01:00
Roland Scheidegger
f6de56b88a fix w component of glsl vec4 asin 2008-01-31 01:35:52 +01:00
Brian
d64ea43b76 fix bugs 13507, 14293 2008-01-30 08:12:06 -07:00
Brian
2deaf93d24 check if fb->Delete is null (bugs 13507,14293) 2008-01-30 08:12:06 -07:00
Alex Deucher
a107ec8300 Add new RV380 pci id
bug 14289
(cherry picked from commit 80efe27560)
2008-01-29 10:15:32 -05:00
Alex Deucher
120a1f9508 Merge branch 'mesa_7_0_branch' of git+ssh://agd5f@git.freedesktop.org/git/mesa/mesa into mesa_7_0_branch 2008-01-29 09:50:26 -05:00
Alex Deucher
bb84007a57 R300: RV410 SE chips have half the pipes of regular RV410
This fixes 3D rendering on x700 SE chips.  Reported
by Kano.
(cherry picked from commit 0b7e0f8159)
2008-01-29 09:46:48 -05:00
Alan Hourihane
86234e55a6 pull some more fixes for pbo access from trunk 2008-01-28 11:23:53 +00:00
Alan Hourihane
61972077cd fix some pbo path problems 2008-01-28 11:15:53 +00:00
Xiang, Haihao
5a7feb8ea2 i965: valid message length includes message header. 2008-01-25 17:23:55 +08:00
Xiang, Haihao
4b4c131cd0 i965: re-define the type of reg.loopcount.
avoid some issues such that 1 + (-2) gets a big
positive value.
2008-01-25 17:23:15 +08:00
Julien Cristau
67617c8f89 Drop -O0 workaround on hppa.
Stop building with -O0 on hppa. Bug #451047 should be fixed in recent gcc
versions.
2008-01-24 22:52:48 +01:00
Brian
0fd23f01c6 Assorted patches for miniglx/linux-solo (Gavin Li <codeview@gmail.com>) 2008-01-23 16:04:02 -07:00
Adam Jackson
557b0d9df7 glxinfo: Fix multisample visual reporting.
strstr() == 0 tests for the string _not_ being present.  Originally
Red Hat bug #351871.
2008-01-22 14:04:39 -07:00
Brian
888f4380cf fix GLX vertex array bug 14197 2008-01-22 08:41:22 -07:00
Brian
3266c5e95a fix pc vs. gc->ps usage (bug 14197) 2008-01-22 08:38:48 -07:00
Brian
834decdaae Don't build yuvrect_client by default
Added 'extra' rule to build optional yuvrect_client, shape, xdemo programs
2008-01-22 07:56:31 -07:00
Brian
18b2d83173 remove unused var 2008-01-22 07:54:37 -07:00
Alexey Sokolov
30c65c3c62 define M_PI if needed 2008-01-22 07:42:40 -07:00
Brian
04fcc4cf1e prep for 7.0.3 release 2008-01-21 16:21:39 -07:00
Julien Cristau
09504dde1f Update changelog; add Vcs-* and Homepage fields in debian/control. 2008-01-17 22:26:48 +01:00
Julien Cristau
c04885f072 Merge branch 'mesa_7_0_branch' of git://anongit.freedesktop.org/git/mesa/mesa into debian-unstable
Conflicts:

	progs/tests/.gitignore
	progs/tests/Makefile
2008-01-14 22:30:03 +01:00
Michel Dänzer
48ae5cf09d i965: Fix byte vs. pixel unit mixup for aligned texture pitch.
I sincerely hope I don't manage to mess this up yet again...

Thanks again to Todd Merrill for pointing out the problem and testing the fix
on IRC.
2008-01-14 16:30:58 +01:00
Michel Dänzer
45cdb6eb45 i965: Fix unresolved symbol intel_miptree_pitch_align.
For some reason, I thought that function was shared with i915tex... The good
news is that i965 gets to keep the lower pitch alignment requirements.

Thanks to Todd Merrill for pointing out the problem on IRC.
2008-01-11 16:32:39 +01:00
Keith Packard
b9f3f732aa i915tex: Centralize mipmap pitch computations.
mipmap pitches must account for the device alignment requirements, which
used to be fairly simple; just align to a 4-byte boundary. However, to allow
textures to be drawn to under TTM, they now need to be aligned to a 64-byte
boundary. Placing all of the alignment constraints in a single function
allows this new constraint to be applied uniformly.

There was some pitch constraining code in intel_miptree_create, but that was
modifying the pitch long after the miptree had been layed out, so it only
served to wreck the mipmap and cause rendering errors.

(cherry picked from commit a183efc132 with manual
changes for mesa_7_0_branch by Michel Dänzer. One side effect of this is that
i965 also aligns the pitch of 2D textures to multiples of 64 bytes, hopefully
that won't cause any issues)
2008-01-08 16:48:13 +01:00
Brian
17006ddd6b fix 3d proxy texture depth bug 2008-01-05 15:44:51 -07:00
Brian
b77a354df3 fix depth/1 typo in glTexImage3D proxy code 2008-01-05 15:44:51 -07:00
Brian
71d46beebf additional stub functions 2008-01-02 07:23:41 -07:00
Brian
454e296eb1 additional GL_COLOR_ATTACHMENTx_EXT cases (bug 13767) 2008-01-02 07:20:08 -07:00
Brian
f9b696be2b fix vbo display list memleak upon context destruction 2008-01-01 10:23:56 -07:00
Brian
c923edbc71 additional GL_COLOR_ATTACHMENTx_EXT cases (bug 13767) 2008-01-01 10:10:18 -07:00
Brian
e20c1d987f fix GLSL uniform/attrib bugs (13753) 2008-01-01 09:59:51 -07:00
Bruce Merry
cd354eb10f Convert to 0/1 when setting boolean uniforms
Also add some extra tests to the shader_api regression tests
2008-01-01 09:59:51 -07:00
Bruce Merry
e9ac27ee23 Make use of count in _mesa_uniform_matrix 2008-01-01 09:59:50 -07:00
Bruce Merry
3f9dc9f5b6 Add a test program to test for assorted bugs in shader_api.c 2008-01-01 09:59:50 -07:00
Bruce Merry
ba709875ae More fixes to shader_api
- return GL_INVALID_OPERATION instead of GL_INVALID_VALUE if location is bad
- correct the type-checking of uniforms from my previous commit
- accept location of -1 in _mesa_uniform_matrix
2008-01-01 09:59:50 -07:00
Bruce Merry
80f8397b35 Fix several bugs relating to uniforms and attributes in GLSL API
- fix sizes for GL_FLOAT_MAT2x3 and GL_FLOAT_MAT4x3 in sizeof_glsl_type
- fix size returns in _mesa_get_active_attrib
- fix out-of-bounds array access to vec_types in _mesa_get_active_attrib
- fix queries of matrix uniforms in _mesa_get_uniformfv
- fix _mesa_get_uniformfv to only return one base, even from an array
- allow location == -1 in _mesa_uniform
- validate types in _mesa_uniform
- allow array overruns in _mesa_uniform
2008-01-01 09:59:50 -07:00
Brian
b45fa27fa1 added 'get' info for framebuffer object tokens 2008-01-01 09:26:30 -07:00
Brian
b59480645d add 'Get' info for MAX_3D_TEXTURE_SIZE (for bug 13811) 2008-01-01 09:04:13 -07:00
Brian
148cb36979 add missing double quote (bug 13878) 2008-01-01 07:59:58 -07:00
Roland Scheidegger
c1eb78f7ff fix GL_LINE_LOOP with drivers using own render pipeline stage (#12410, #13527)
primitive needs to include the begin/end flags (broken since vbo-0.2). Should
fix missing first/last line segment on gamma, i810, i915, mga, r200, radeon,
s3v, savage, unichrome (r300 already correct). Tested on r200, fixes #13527.
2007-12-22 18:49:42 +01:00
Brian
8aa0fd6b20 glGetActiveUniform fix 2007-12-20 09:08:12 -07:00
Brian
a1b3a908f5 return correct size from glGetActiveUniform (bug 13751) 2007-12-20 09:08:12 -07:00
Xiang, Haihao
f9e70d951a i965: allocate GRF registers before building subroutines,
it ensures there are sufficient registers for all subroutines.
2007-12-19 10:44:00 +08:00
Xiang, Haihao
41ed6be1da i965: restore the flag after building the subroutine of the
GS thread. fix #13240
2007-12-19 10:36:56 +08:00
Brian
27de28fc3e Remove -I$(TOP)/src/mesa/transform 2007-12-18 17:07:11 -07:00
Brian
dd2f01c229 simplify update two-side lighting test (follow-on to previous front/back-face changes) 2007-12-18 16:28:36 -07:00
Brian
deb5c56c77 fix NEED_SECONDARY_COLOR for vert/frag progs 2007-12-18 16:28:36 -07:00
Julien Cristau
9fd22f0e3f Prepare changelog for upload. 2007-12-18 19:13:27 +01:00
Julien Cristau
942372dcdf debian/control fixups
* Bump Standards-Version to 3.7.3.
* Move libgl1-mesa-swx11-dbg, mesa-common-dev and libosmesa6-dev to section
  libdevel.
* libgl1-mesa-swx11 conflicts with libgl1-mesa-glx.  Move it and
  libgl1-mesa-swx11-dev to priority extra.
* Fix typo in mesa-common-dev's long description.
2007-12-18 13:57:06 +01:00
Julien Cristau
b7f901088b Update changelog. 2007-12-18 13:32:01 +01:00
Julien Cristau
c02990525c Merge branch 'mesa_7_0_branch' of git.freedesktop.org:/git/mesa/mesa into debian-unstable
Conflicts:

	progs/trivial/quad-clip-nearplane.c
2007-12-18 12:28:29 +01:00
Michel Dänzer
0107acded0 i915tex: Fix issues with glDrawBuffer(GL_NONE).
Don't dereference NULL renderbuffer pointer, and make sure the software
fallback sticks.

Fixes https://bugs.freedesktop.org/show_bug.cgi?id=13694 .
2007-12-17 12:32:26 +01:00
Brian
2ac5e08d1d fix polygon cull regression 2007-12-14 14:36:23 -07:00
Dan Nicholson
1837b8c214 configs: Fix linking with static libGL and --as-needed
Linking of the programs breaks when using a static libGL and the GNU ld
option --as-needed. This is because libXext is needed for the XShm
functions.
(cherry picked from commit 6aaf9bdd41)
2007-12-07 11:51:18 -08:00
Brian
03d2bc1774 fix gl_FrontFacing 2007-12-04 14:07:15 -07:00
Brian
385bddbde0 fix span->facing computation and gl_FrontFacing initialization 2007-12-04 14:07:15 -07:00
Brian
c135426267 Fix gl_FrontFacing compilation problem 2007-12-04 14:07:15 -07:00
Michel Dänzer
4be0c98120 Use -Bsymbolic for linking all shared objects.
Fixes https://bugs.freedesktop.org/show_bug.cgi?id=10132 .

Also remove comment about SONAME, as SONAME only applies to shared libraries.
(cherry picked from commit fc7ddea853)
2007-12-04 18:33:07 +01:00
Brian
e760aebd5a fix two-side lighting bug/crash 2007-12-03 14:13:08 -07:00
Brian
1f6e7d9c29 fix DD_TRI_LIGHT_TWOSIDE bug (#13368) 2007-12-03 14:12:34 -07:00
Dan Nicholson
c6d421af05 Fix the library name in glw.pc
Fix a copy and paste error s/GLU/GLw/ in glw.pc.
(cherry picked from commit 2dc85e8078)
2007-12-03 12:08:03 -08:00
Brian
952df5e493 fix two-sided stencil 2007-12-03 12:00:21 -07:00
Brian
45acb8b058 added missing quote char 2007-12-03 12:00:21 -07:00
Michel Dänzer
e8997c0183 i915tex: Fix up state changes for i8xx.
(cherry picked from commit 2af613e0b8)
2007-12-03 09:38:13 +01:00
Brian
169e62f563 fix-build: remove ctx->_Facing assignment 2007-11-30 15:52:41 -07:00
Brian
1b43babfb1 fix broken two-sided stencil 2007-11-30 13:01:42 -07:00
Brian
43e902f774 better front-plane clip test 2007-11-30 09:09:12 -07:00
Xiang, Haihao
b0a800e249 i965: use uncompressed instruction to ensure only
Pixel Mask Copy is modified as the pixel shader thread
turns off pixels based on kill instructions.
2007-11-30 12:36:07 +08:00
Brian
73d5f232ad New ctx->Driver.Map/UnmapTexture() functions for accessing textures from t_vb_program.c 2007-11-29 08:18:11 -07:00
Brian
f7209541e4 cleanups, comments
Conflicts:

	src/mesa/tnl/t_vb_program.c
2007-11-29 08:18:11 -07:00
Brian
397a32dca7 Move _mesa_load_tracked_matrices() from TNL module to prog_statevars.c 2007-11-29 08:18:11 -07:00
Roland Scheidegger
e0719d7122 make sure state token values are fully initialized 2007-11-29 03:08:48 +01:00
Michel Dänzer
3f18c0a9f2 r200: Fix texture format regression on big endian systems.
See https://bugs.freedesktop.org/show_bug.cgi?id=13324 .

Also use tx_table_be for VALID_FORMAT, in case r200SetTexImages ever gets
called for MESA_FORMAT_RGB888.
(cherry picked from commit dc88a96631)
2007-11-28 10:25:01 +01:00
Delle
b14be61938 use DEFAULT_SOFTWARE_DEPTH_BITS 2007-11-27 18:18:48 -07:00
Brian
440d620308 minor additions to avoid FAQs 2007-11-27 10:32:39 -07:00
Brian
8dd9df0f3e document GLSL float f/F suffix bug 2007-11-27 10:32:39 -07:00
Brian
6b9534eaf5 set fp->UsesKill when emitting OPCODE_KIL 2007-11-27 10:32:39 -07:00
Brian
c91d374ad7 improve 24-bit Z to 32-bit Z conversion 2007-11-27 10:32:39 -07:00
Keith Whitwell
1cab4160bc i915tex: Fix some minor batchbuffer errors. 2007-11-26 17:12:15 +01:00
Keith Whitwell
718d2dfbbd i915tex: Catch cases where not all state is emitted for a new batchbuffer.
This could lead to incorrect rendering or even lockups.
2007-11-26 17:10:26 +01:00
Michel Dänzer
0967e1270d i915tex: Some additional blit fixes and assertions. 2007-11-26 16:59:41 +01:00
Michel Dänzer
a08c02f1a8 i915tex: Actually wait for previous commands to complete for glFinish(). 2007-11-26 16:59:00 +01:00
Brian
bdfd9afead Consolidate texture fetch code and use partial derivatives when possible. 2007-11-23 12:01:39 -07:00
Brian
1c91a590d6 fix a few GLSL bugs 2007-11-23 10:28:33 -07:00
Brian
65bd7968bf Fix parsing of gl_FrontLightModelProduct.sceneColor, don't segfault on variable
array indexes.
2007-11-23 10:26:02 -07:00
Brian
6ccd23b87b need to check border width in sample_linear_2d() - fixes failed assertion in texwrap.c test 2007-11-23 09:14:27 -07:00
Brian
823409b7d0 Bump version numbers to 7.0.3 for next release 2007-11-22 09:36:35 -07:00
Brian
c85d31f4a0 Recompute ctx->Point._Size if GL_POINT_SIZE_MIN/MAX changes.
Note that all the point size clamping stuff has been redone in Mesa/master.
2007-11-22 09:36:35 -07:00
Roland Scheidegger
24af5c44da fix z buffer read/write issue with rv100-like chips and old ddx 2007-11-22 02:55:25 +01:00
Brian
75efacf8eb Initial 7.0.3 relnotes 2007-11-20 08:16:25 -07:00
Brian
825e810247 bring over Fortran fixes from master 2007-11-20 08:15:19 -07:00
Brian
e20723cfc1 Obsolete 2007-11-20 08:13:14 -07:00
Brian
9f39a67c1d Rename glut_fbc.c -> glut_fcb.c (cb=callback) 2007-11-20 08:13:03 -07:00
Brian
2044f3f791 clamp lambda to Min/MaxLod 2007-11-19 13:05:10 -07:00
Brian
30d4e8c422 fix some texture format assertions, etc 2007-11-19 10:37:41 -07:00
Brian
92d552f6a2 fix out-of-bounds array index (ix=-1) 2007-11-19 09:54:41 -07:00
Brian
5adfcbbc4f added gl_dispatch_stub_772() 2007-11-16 10:03:57 -07:00
Roland Scheidegger
69969b3819 fix position invariant vertex programs for sw-tnl
do the same math as for fixed function pipe, including
user clip planes.
(mostly resurrected from the dead t_vb_arbprogram.c code)
2007-11-15 02:06:15 +01:00
Roland Scheidegger
edfee04fcb fix bogus assumption if ddx has set up surface reg for z buffer
this is wrong since even if ddx has not set up a surface reg to cover the z
buffer we should pretend it has on those rv100 chips since they presumably do
not do z buffer tiling if not using hyperz, so we can use linear addressing
just the same. Doesn't seem to fix #13080, but it's wrong anyway and the bug
almost certainly broke newer non-tcl chips.
2007-11-15 01:16:27 +01:00
Brice Goglin
ae0bf74db9 Prepare changelog for upload 2007-11-13 21:44:00 +01:00
Julien Cristau
1bf7ce97c0 * Add build-dep on libxext-dev. Thanks, Timo Aaltonen! 2007-11-13 21:40:49 +01:00
Julien Cristau
4971a009e0 * Workaround gcc ICE on hppa: build libOSMesa with -O0 (see bug#451047). 2007-11-13 20:59:08 +01:00
Julien Cristau
e1613ab80d Don't set -fno-strict-aliasing in configs/debian-default.
Upstream uses that since 7.0.2.
2007-11-13 20:57:58 +01:00
Brian
28c9930888 add pointer to Gallium3D info 2007-11-13 09:51:14 -07:00
Brian
e3a35a123e DRI memory manager info (fixes dangling link) 2007-11-13 09:50:42 -07:00
Brian
412168f2e8 remove dependency on libGLU 2007-11-12 08:21:21 -07:00
Brian
fc0fa0d636 add glw.pc.in to tarball list, remove from DEPEND_FILES 2007-11-12 07:52:20 -07:00
Brice Goglin
caf283329b Prepare changelog for upload 2007-11-11 11:55:05 +01:00
Brice Goglin
5cedd4a43e Remove DESTDIR from INSTALL_DIR in configs/debian-default
... and update 03_optional-progs-and-install.patch accordingly.
2007-11-11 11:49:16 +01:00
Brice Goglin
0595d32d8a Refresh 03_optional-progs-and-install.patch
The default Makefile requires libGLU to be built
while linking progs/xdemos. However, we don't build
libGLU and progs/xdemos at the same time, and
these progs don't actually need libGLU.
2007-11-11 11:48:32 +01:00
Brice Goglin
e339b4e8da New upstream release 2007-11-11 00:34:46 +01:00
Brice Goglin
11c827c588 Merge tag 'mesa_7_0_2' into debian-unstable
Conflicts:

	.gitignore
	progs/demos/.gitignore
	progs/directfb/Makefile
	progs/egl/Makefile
	progs/fbdev/Makefile
	progs/fp/Makefile
	progs/miniglx/Makefile
	progs/samples/.gitignore
	progs/slang/Makefile
	progs/tests/.gitignore
	progs/tests/Makefile
	progs/tools/trace/Makefile
	progs/trivial/Makefile
	progs/vp/Makefile
	progs/xdemos/.gitignore
	src/egl/drivers/demo/Makefile
	src/egl/drivers/dri/Makefile
	src/egl/main/Makefile
	src/glu/mesa/Makefile
	src/glut/directfb/Makefile
	src/glx/mini/Makefile
2007-11-11 00:24:52 +01:00
Brian
8a40b670c3 added md5 checksums 2007-11-10 09:53:00 -07:00
Brian
d9fa5cbfc9 final changes for 7.0.2 relesae 2007-11-10 09:41:52 -07:00
Benno Schulenberg
1c21564292 code clean-ups, reformatting 2007-11-09 08:53:41 -07:00
Benno Schulenberg
6cc96bf156 remove commented-out code 2007-11-09 08:53:15 -07:00
Brian
29afd4bbc4 fix blender/unichrome crash, bug 13142 2007-11-08 07:36:30 -07:00
Benno Schulenberg
4e3db063ec fix Unichrome/Blender crash, bug 13142 2007-11-08 07:36:30 -07:00
Brian
6560744c38 added -fno-strict-aliasing and -fPIC flags 2007-11-08 07:36:30 -07:00
Brian
572ad87881 change filenames for rc2 2007-11-08 07:36:30 -07:00
Michel Dänzer
2ab75d6cfa r200: Fix SetTexOffset format for 16 bit pixmaps/textures.
Use symbolic array indices to clarify.
2007-11-06 18:39:50 +01:00
Chris Rankin
041a8eb5ec r200: Implement SetTexOffset hook.
Implementation guidance by Michel Dänzer, final testing by Timo Aaltonen.
2007-11-06 18:32:33 +01:00
Brian
c1c13bdcfa Check for NULL VB->EdgeFlag array.
There might be a bug elsewhere, but this is a simple work-around for now.
See bug 12614
2007-11-05 14:43:03 -07:00
Brian
403edd34dd fix mmx code (bug 12614) 2007-11-05 14:38:12 -07:00
Brian
f279e48416 fix mmx code (bug 12614) 2007-11-05 14:38:05 -07:00
Brian
bf854d8d27 SSE codegen fixes 2007-11-03 08:45:42 -06:00
Brian
f334121679 Fix mem leak in SSE code generation path (Michel Dänzer) and don't crash if _mesa_exec_malloc() returns NULL. 2007-11-03 08:44:48 -06:00
Dan Nicholson
b88e2be609 Add -fno-strict-aliasing workaround for all GCC targets
Use a GCC option to work around aliasing bugs. See commit 013dbcd for
more details.
(cherry picked from commit 01b18abf93)

Conflicts:

    configs/freebsd
2007-11-01 11:07:02 -07:00
Dan Nicholson
08229c8bb8 configs: Set -fexceptions for GLUT on linux-dri like other targets
Quite a while ago, the GCC option -fexceptions was added for building
libglut. See here:

  http://article.gmane.org/gmane.comp.video.mesa3d.devel/9499

This was missing in the linux-dri targets.
(cherry picked from commit dbcd20f1c2)
2007-11-01 11:02:05 -07:00
Dan Nicholson
c984017f71 configs: Always use -fPIC for shared libraries, never for static
Mesa currently disables -fPIC for DRI on x86, but most Linux distros are
re-enabling -fPIC for all DRI arches. Let's just do that here since
that's normally what's wanted for shared libraries. Some justification:

http://bugs.gentoo.org/show_bug.cgi?id=110840#c9

On the other hand, position-independent code is only necessary when
building shared libraries, so disable it for the static cases.
(cherry picked from commit c3b5adaa9a)
2007-11-01 11:01:10 -07:00
Dan Nicholson
00e7dd8a13 Add -fno-strict-aliasing workaround for Linux GCC targets
Most Linux distros work around aliasing problems in Mesa by compiling
with the GCC option -fno-strict-aliasing. Two examples:

  https://bugs.freedesktop.org/show_bug.cgi?id=6046
  http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=394311

This makes -fno-strict-aliasing the default with a comment that
developers should consider commenting it out. There is a already a note
about these bugs in docs/helpwanted.html.
(cherry picked from commit 013dbcd611)
2007-11-01 10:56:01 -07:00
Brian
d11b375b16 fix typo 2007-10-31 09:43:17 -06:00
Brian
d1afa8146f updated help/to-do list 2007-10-31 09:40:58 -06:00
Brian
31d4ba8a93 glDrawArrays(count=0) bugfix 2007-10-31 09:40:20 -06:00
Brian
1a7640958c check for count==0 in _mesa_validate_DrawArrays() 2007-10-31 09:39:20 -06:00
Brian
2e2a5a450b note G33/Q33/Q35 support 2007-10-31 08:19:14 -06:00
Brian
574fd63ff0 fix GL_ATI_separate_stencil 2007-10-30 10:46:31 -06:00
Brian
1063d47526 Alias glStencilOpSeparateATI with glStencilOpSeparate.
(Cherry-pick from master)
2007-10-30 10:45:47 -06:00
Brian
b59a892d3e Finish up ATI_separate_stencil
Add entrypoints to glapi XML file and regenerate files.
Implement glStencilOpSeparateATI().
Consolidate some code in stencil.c

Conflicts:

	src/mesa/glapi/dispatch.h
	src/mesa/glapi/glapioffsets.h
	src/mesa/glapi/glapitable.h
	src/mesa/glapi/glapitemp.h
	src/mesa/glapi/glprocs.h
	src/mesa/main/enums.c
	src/mesa/main/state.c
	src/mesa/sparc/glapi_sparc.S
	src/mesa/x86-64/glapi_x86-64.S
	src/mesa/x86/glapi_x86.S
2007-10-30 10:34:26 -06:00
Roland Scheidegger
6e5d5d77df add missing _mesa_StencilFuncSeparateATI function 2007-10-30 10:26:56 -06:00
Dan Nicholson
a6319d18cf Build xdemos programs by default on linux-dri
Since libglut is no longer hardcoded, we can build the xdemos programs
so long as a GLX enabled libGL and libGLU have been built.
(cherry picked from commit 06ca14543e)
2007-10-29 12:08:34 -07:00
Dan Nicholson
5103e883fd update APP_LIB_DEPS for static library configs (patch 3/3)
(cherry picked from commit 162914675a)
2007-10-29 12:06:50 -07:00
Dan Nicholson
98c4ea4b24 simplify APP_LIB_DEPS (patch 2/3)
(cherry picked from commit 9ef1d9f03a)
2007-10-29 12:06:23 -07:00
Dan Nicholson
29b8cac7d7 specify app lib dependencies in Makefiles (patch 1/3)
(cherry-picked from commit c05aa5ec4c)

Conflicts: progs/demos/Makefile
           progs/xdemos/Makefile
2007-10-29 12:05:54 -07:00
Dan Nicholson
cdb02d43fe linux-dri-xcb: Fix undefined refs when linking with libGL
GL_LIB_DEPS was missing -lXdamage and -lXfixes, which was causing
linker errors when trying to build the programs.
(cherry picked from commit 3b9e28d507)
2007-10-29 11:44:30 -07:00
Michel Dänzer
50cecddc4a driFenceType: Really return fence type, not flags.
This typo could lead to the i915tex driver waiting for an EXE only fence as RW,
causing it to abort with an error.
2007-10-29 13:27:59 +00:00
Alan Hourihane
177f6398e5 Only set R_MODE with NV_point_sprite 2007-10-28 20:08:15 +00:00
Dan Nicholson
887bd6a46f configs: Fix linux-static to link correctly
The linux-static target was missing necessary libraries and hardcoding
their location to /usr/X11R6/lib. This makes it comparable to the x86
and x86-64 static targets.
(cherry picked from commit 9514209593)
2007-10-26 15:49:00 -07:00
Brian
9af5153410 use grep -q 2007-10-25 14:48:08 -06:00
Dan Nicholson
0e2103689e More ignored programs merged back from master
Some more entries in progs/*/.gitignore that were in master.
2007-10-25 11:59:26 -07:00
Brian
2c496d8e46 simplify/fix the ASM_FLAGS tests (bug 12931) 2007-10-25 11:12:17 -06:00
Brian
8f0ba02e44 Cray Xt3 config 2007-10-25 11:12:07 -06:00
Brian
524c56e417 Fix merge 2007-10-24 16:36:00 -06:00
Brian
773f3a266c added catamount-osmesa-pgi config, fixes for cross-compiling 2007-10-24 16:35:47 -06:00
Brian
882ada0d22 don't build x86, x86-64 dirs if not needed 2007-10-24 16:33:24 -06:00
Brian
6229005f93 properly init dst reg's CondMask/Swizzle fields 2007-10-23 10:55:14 -06:00
Brian
6c63b35ef7 bump up MAX_INSTRUCTIONS and add an assertion to catch emitting too many instructions 2007-10-23 10:25:34 -06:00
Brian
fb85e50e09 add directfb glut sources to tarball 2007-10-23 08:22:11 -06:00
Brian
5e5f908d0c don't apply ColorMask to main gc 2007-10-22 17:54:07 -06:00
Michel Dänzer
c09e2143c7 i915tex: Don't emit 'empty' blit rectangles.
The hardware seems to interpret them differently and produce unexpected
results...
2007-10-17 18:28:46 +02:00
Brian
74ced1e67f fix fog, rescale_normals bugs (from gallium branch) 2007-10-15 18:02:14 -06:00
Andreas Micheler
dd02c1609e faster write_rgba_span_front() 2007-10-15 08:28:06 -06:00
Brian
cdf4880a79 replace 'brick' with correct program name in printfs 2007-10-10 10:57:37 -06:00
Mrc Gran
2ec8e8547d fix force_s3tc_enable option 2007-10-10 09:16:12 -06:00
Dan Nicholson
b7c36d1d33 Ignore more generated files in progs/
Many of the directories in progs/ were missing .gitignore files or
were tracking generated files. This patch is basically the process of
running `make' in each directory and then finding the untracked files
with `git-ls-files -o --exclude-per-directory=.gitignore'. The existing
files were also sorted.

Conflicts:

	progs/demos/.gitignore
	progs/tests/.gitignore
	progs/xdemos/.gitignore
2007-10-10 08:49:59 -06:00
David Nusinow
8913402b74 Revert "* Disable building i915tex."
This reverts commit 76556f8264.
2007-10-06 17:54:29 -04:00
David Nusinow
c00dfefd6f Revert "Don't release just yet."
This reverts commit c3de7b5ade.
2007-10-06 17:54:13 -04:00
David Nusinow
c3de7b5ade Don't release just yet. 2007-10-04 23:10:47 -04:00
David Nusinow
76556f8264 * Disable building i915tex.
It was previously only built on x86 and amd64.  It was never
  production-ready and relies on a kernel interface that never went
  upstream.
2007-10-04 22:49:27 -04:00
Xiang, Haihao
970d18a708 Brian's fix for bug9829 2007-10-04 00:08:18 +02:00
Roland Scheidegger
9456e7f0ff minor fog calc cleanup 2007-10-03 22:34:36 +02:00
Roland Scheidegger
a5db24adc2 fog: fix issues with negative fog coords (may fix #10529)
Rework tnl fog a bit. Make sure we always use ABS(eyez) when fog coord source
is depth, OTOH it does not seem to be necessary to use it (as was done before
in some cases) if fog coord source is fogcoord (just to save some work).
This fixes tests/fog (the first 2 cases) with i915/i915tex.
2007-10-03 22:33:26 +02:00
Roland Scheidegger
17664e2620 make sure optimized fog params get updated 2007-10-03 22:33:03 +02:00
Roland Scheidegger
43a0eb0253 unbreak 3d textures (typo when setting tex layout) 2007-10-03 22:32:33 +02:00
Michel Dänzer
bcdaed2c0a i915tex: Work around texture pitch related performance drops on i915 at least. 2007-10-03 10:48:56 +02:00
Brian
78c6637db5 updated glext.h license info (Khronos), plus other clean-ups 2007-10-01 17:56:48 -06:00
Brian
44214a98fd fix VBO-split infinite loop (bug 12164) 2007-09-29 12:01:47 -06:00
Dan Nicholson
9cc6d2310c add support for LDFLAGS env var 2007-09-28 18:47:11 -06:00
Brian
1a045954be update the DRM/DRI instructions 2007-09-28 18:43:12 -06:00
Dave Airlie
b3fc9a1585 i965: fix vblank on 965gm laptops by bringing in code from i915
jbarnes has better fixes for this in 7.1, but for 7.0.2 this seems like the best
plan, for distros to pick it up.
2007-09-28 12:02:27 +10:00
Xiang, Haihao
2a86a449ca mesa: make sure the gotten value isn't greater than the
max depth buffer value on 64bit system. fix bug #12095
2007-09-27 10:44:45 -06:00
Xiang, Haihao
44f032db61 i965: handle all unfilled mode in clip stage. fix bug #12453 2007-09-27 10:40:22 -06:00
Brian
5a520729ee prep for 7.0.2 release 2007-09-27 10:35:10 -06:00
Brian
36fbe78c60 for Miniglx, use git sources 2007-09-27 10:34:44 -06:00
Brian
029bb17770 bump versions to 7.0.2 2007-09-27 10:30:13 -06:00
Brian
7958bee6be fix blend bug 12164 2007-09-27 10:25:57 -06:00
Brian
0b9bb21ce4 Restore old _TriangleCaps code to fix Blender problem (bug 12164) 2007-09-27 10:25:33 -06:00
Roland Bär
cfcc5b794e [i965] Bug #11812: Fix fwrite return value checks in AUB file code. 2007-09-26 08:00:17 -06:00
Zou Nan hai
925ff408a6 fix fd.o bug #12217, recalcuate urb when clip plane size change 2007-09-26 07:59:41 -06:00
Xiang, Haihao
f40ca444f5 i965: The cube map texture coordinates must be devided by the
component with the largest absolute value before they are
delivered. fix bug #12421
2007-09-26 07:58:57 -06:00
Zou Nan hai
638a5e0382 fix a bug in 965 ARB_occlusion_query,
fd.o bug #12132
2007-09-26 07:58:29 -06:00
Brian
6d777bf055 fix DrawRangeElements error msg 2007-09-23 13:57:36 -06:00
Brian
ae6d4e8bc0 fix -D_BSD_SOURC 2007-09-20 18:42:59 -06:00
Brian
f2728724d3 fix for __IBMC__ 2007-09-20 15:12:42 -06:00
Brian
bc95b34cce added bluegene-xlc-osmesa, fortran fixes 2007-09-20 15:12:21 -06:00
Brian
9eb89616af fixes for bluegene-xlc-osmesa config 2007-09-20 15:10:35 -06:00
Brian
f7713a6d81 Added bluegene-xlc-osmesa config (Alexander Neundorf) 2007-09-20 15:09:54 -06:00
Brian
1cec9b727a fix bug 10604 2007-09-14 13:43:58 -06:00
Brian
18a4730f5b From trunk: mesa: bind VBO_ATTRIB_XXX to correct input array when executing a display list. fix #10604
This also fixes Bill Mitchell's Fortan/plot bug.
2007-09-14 13:43:09 -06:00
Brian
1342aefcdd updated link 2007-09-14 09:57:16 -06:00
Brian
1fd4b1e702 fix glCopyPixel/glPixelZoom bug 12417) 2007-09-14 09:57:08 -06:00
Brian
32dff44c28 fix copypixels overlap test bug (#12417) 2007-09-14 09:56:05 -06:00
Brian
e7c2ae476a fix ARB fp/vp parsing bug 12313 2007-09-13 11:42:48 -06:00
Brian
a66301f83d added program_error2() function for better error reporting 2007-09-13 11:41:44 -06:00
Brian
a5f7d56221 Fix state.texgen parsing error (bug 12313).
Replace *(*inst++) with *(*inst)++ in a few places.
2007-09-13 11:29:51 -06:00
Brian
140080c1ec added .pc.in files to tarballs 2007-09-13 09:27:06 -06:00
Brian
ef43af6d43 added DSTDIR, pkg-config items 2007-09-12 10:12:20 -06:00
Brian
949d0532f0 updated with pkg-config info 2007-09-12 10:12:06 -06:00
Dan Nicholson
96efc76d74 pkg-config support 2007-09-12 10:03:31 -06:00
Dan Nicholson
6ca0d63692 DESTDIR support. 2007-09-12 10:01:06 -06:00
Xiang, Haihao
95fc2485e2 i965: fix bug#11925 2007-09-12 16:58:45 +08:00
Xiang, Haihao
d6ce1e4834 i965: fix #11378 2007-09-12 15:29:11 +08:00
Brian
2cc2b12fc7 fix indirect rendering crash 2007-09-11 10:59:10 -06:00
Brian
2259f81cf7 In _mesa_make_current(), don't unbind FBOs from the old context.
This fixes the X server crash reported by KeithP on Aug 29.
The old context's FBOs will be unreferenced during context destruction so
there's no memleak with this change.
2007-09-11 10:59:10 -06:00
Brian
791f12880f Update depth test state when binding new framebuffer object 2007-09-11 09:25:49 -06:00
Brian
7aa7373a64 fix comment 2007-09-11 09:25:49 -06:00
Xiang, Haihao
2f186a190f i965: take the secondary color into account when drawing
bitmap. fix#10688
2007-09-11 17:03:07 +08:00
Xiang, Haihao
357893a873 i965: limit on LOD Bias, fix#11987 2007-09-11 17:02:15 +08:00
Brian
a17881da5f clean-up (see bug 12317) 2007-09-10 08:36:01 -06:00
Brian
4872ee83a9 updated VC7 project files 2007-09-05 10:05:48 -06:00
Christoph Kubisch
5ec222a832 updated VC7 project files 2007-09-05 10:01:58 -06:00
Brian
40438b3440 Use temporary matrix in __gluInvertMatrixd() to fix aliasing problem (see bugs 12269, 6748) 2007-09-03 16:21:12 -06:00
Xiang, Haihao
e0b80660c8 fix bug#11009 2007-09-01 15:31:49 +08:00
Xiang, Haihao
a2016301f5 i965: Take the upper limitation on LOD into account. 2007-09-01 15:14:58 +08:00
Brian
7ec6729fb6 sync with trunk, fixing bug 12239 2007-08-31 16:36:17 -06:00
Brian
837a2cf72e fix i965 bugs, x86-64 bugs 2007-08-31 16:35:38 -06:00
Roland Scheidegger
0adca14536 fix another occurence of movaps which might not be aligned 2007-08-31 00:06:30 +02:00
Brian
57b0f66c6d s/movaps/movups/ (see bug 12216) 2007-08-30 08:41:43 -06:00
Xiang, Haihao
e47e7a9571 i965: store read drawable info in intel_context. Some OpenGL
operations are based on read drawable. fix bug#10136.
2007-08-30 14:06:26 +08:00
Xiang, Haihao
68ca01560f i965: check NULL pointer. fix bug#12193 2007-08-30 14:06:19 +08:00
Xiang, Haihao
64f1c91fcb i965: samplers group in fours in WM_STATE. fix bug#9415 2007-08-30 14:05:56 +08:00
Xiang, Haihao
7d33f94198 i965: flush batch buffer when getting the maximum. This makes
some 3D programs such as pymol work well.
2007-08-30 14:05:39 +08:00
Julien Cristau
369cda3752 Prepare changelog for upload. 2007-08-28 12:11:47 +02:00
Julien Cristau
846078d06f Delete generated files. 2007-08-28 12:07:45 +02:00
Julien Cristau
b18500d56e * Update to latest git (from mesa_7_0_branch)
+ adds support for some new intel chipsets (i915 and i915_tex dri drivers)
    (closes: #437333)
  + broken inline asm in dri drivers fixed (closes: #423739)
2007-08-28 12:07:25 +02:00
Julien Cristau
7d92c50490 Merge branch 'mesa_7_0_branch' of git.freedesktop.org:/git/mesa/mesa into debian-unstable 2007-08-28 11:06:22 +02:00
Brian
d69a596193 Fixed bugs 6748, 12141 2007-08-27 10:48:31 -06:00
Colin McDonald
8aa4ae638e fixed problem with big glDrawArrays (see bug 12141) 2007-08-27 10:47:49 -06:00
Brian
3069f34841 new __gluInvertMatrix() function (Mesa bug 6748) 2007-08-27 10:36:25 -06:00
Adam Jackson
b3788a0e4f Unbreak Linux builds with -fvisibility=hidden. 2007-08-24 08:49:59 +01:00
Brian
582bc029ab remove CallDepth++/-- accidentally removed in prev commit 2007-08-24 08:45:27 +01:00
Brian
e9e3099433 remove unneeded CallStack array 2007-08-23 08:17:35 +01:00
Brian
4fc561cc7b refactor bounds checking code 2007-08-20 13:12:10 +01:00
Brian
ad3e3a0b99 don't map buffer in _mesa_validate_DrawElements() unless needed 2007-08-20 12:55:26 +01:00
Brian
bfb8c849cb Remove recent texobj refcount debug/logging code. 2007-08-16 09:11:11 +01:00
Michel Dänzer
09dd25b5d1 i915tex: Unreference texture buffers on context destruction.
Not doing this could cause the buffers to leak under some circumstances.
2007-08-16 08:45:16 +02:00
Roland Scheidegger
c48efb1dbe suppress warning about ncon visuals (bug #6689) 2007-08-16 02:43:45 +02:00
Brian
5408acb6b7 log deleting/binding of FBOs 2007-08-15 15:47:28 +01:00
Brian
15481160f9 more debug output (context destroy, fb destroy) 2007-08-15 12:52:00 +01:00
Brian
00ccff03a5 Rewrite quite a bit of the code for glPush/PopAttrib() for texture state.
Remove the Saved1D/2D/etc fields from gl_texture_attrib in mtypes.h
Use a new texture_state struct in attrib.c that has the extra information
for restoring texture object state and saving references to the texture
objects (so they can't accidentally get deleted while referenced by the
attribute stack).  All the texobj refcounting is mutex-protected now.
2007-08-15 11:21:06 +01:00
Brian
21594921b1 copy Target in _mesa_copy_texture_object() 2007-08-15 11:18:38 +01:00
Brian
42c91eebc9 Added _mesa_free_attrib_data() to free anything left in the attribute stack upon context destruction.
Also, a bit more refcount debug info.
2007-08-15 10:10:02 +01:00
Brian
88273e08b4 more tex obj ref count debugging (temporary) 2007-08-15 08:55:03 +01:00
Brian
08f7fb45ef added some temporary texobj ref counting debug output 2007-08-14 19:45:02 +01:00
Brian
75ebda3ce6 Fix a few more problems with freeing FBOs/textures during context destruction.
Free FBOs before textures since the later may be referenced by the former.
Need to bind the context we're destroying if there isn't a current context
so that ctx->DeleteTexture() etc can be used.
2007-08-14 11:57:16 +01:00
Brian
53ff15fcbf fix blending/banding bug 2007-08-13 21:17:04 +01:00
Dan Torop
72adb70ee2 fix spantmp2 READ_RGBA inline asm (#11931) 2007-08-13 21:14:51 +01:00
Brian
960d41fcfe added more i915/945 chipsets 2007-08-13 21:11:17 +01:00
Brian
0c4e35b070 Add PCI IDs for the G33, Q33, and Q35 chipsets.
Conflicts:

	src/mesa/drivers/dri/i915/i915_texstate.c
	src/mesa/drivers/dri/i915/intel_context.c
	src/mesa/drivers/dri/i915/intel_context.h
	src/mesa/drivers/dri/i915/intel_screen.c
	src/mesa/drivers/dri/i915/intel_tex.c
2007-08-13 21:06:33 +01:00
Wang Zhenyu
c53f1cb813 i915tex: Add support for 945GME 2007-08-13 21:00:28 +01:00
Brian
f6696cc15e free any render/framebuffers left in hash tables when freeing shared state 2007-08-13 17:39:05 +01:00
Michel Dänzer
fef9a41fe4 i915tex: Make sure pitch is aligned properly for render-to-texture.
Just always align texture pitch to multiples of 64 bytes for now, pending a
more sophisticated scheme to do it only when really necessary.
2007-08-13 13:22:43 +02:00
Brian
e279a0a076 Implement mutex/locking around texture object reference counting.
Use new _mesa_reference_texobj() function for referencing/unreferencing
textures.  Add new assertions/tests to try to detect invalid usage of
deleted textures.
2007-08-13 11:28:52 +01:00
Brian
88c8aaed96 fix link to 7.0.1 relnotes 2007-08-09 15:59:38 +01:00
Julien Cristau
34beaefe1c Prepare changelog for upload. 2007-08-09 16:00:58 +02:00
Julien Cristau
10b828f193 New upstream release. 2007-08-09 11:56:00 +02:00
Julien Cristau
43e6260ed0 Merge tag 'mesa_7_0_1' into debian-experimental 2007-08-09 11:25:42 +02:00
Brian
62cbbd7226 fix byte swap bug for GLuint stencil indexes (bug 11909) 2007-08-09 08:45:01 +01:00
Brian
f7cbe7fcee move free() after dereference (bug 11878) 2007-08-07 22:06:48 +01:00
Brian
d8e4ff9079 fix potential NULL dereference (bug 11879) 2007-08-07 21:56:39 +01:00
Brian
510ff27eda remove SHELL line, replace -e test with new logic (Daniel Stone) 2007-08-07 21:52:22 +01:00
Brian
5abf055100 fix potential NULL dereference (bug 11880) 2007-08-07 21:46:42 +01:00
Brian
4bb5721f6b fix swizzle error test (bug 11881) 2007-08-07 21:43:46 +01:00
Brian
c41ab70d3a initial 7.0.2 notes 2007-08-07 08:44:35 +01:00
Brian
a05e403bf2 fix bug 9962 (vbo splitting) as in trunk 2007-08-07 08:43:31 +01:00
Brian
2f57e0f71d Merge branch 'mesa_7_0_branch' of git+ssh://brianp@git.freedesktop.org/git/mesa/mesa into mesa_7_0_branch 2007-08-07 08:21:50 +01:00
Brian
95a2eb9767 fix even-sized point positioning (bug 11874) 2007-08-07 08:20:18 +01:00
Brian
55175daed7 added md5 sums 2007-08-03 13:54:55 -06:00
Brian
ae16a51e95 added GLU bug fixes 2007-08-03 13:39:09 -06:00
Brian
4398d67546 update 7.0.1 release info/date 2007-08-03 13:32:47 -06:00
Brian
c93738687c remove -rc2 2007-08-03 13:32:28 -06:00
Brian
799492e606 add OSMESA_LIB_NAME 2007-08-03 10:08:16 -06:00
Brian
f33ff071bb added -lm 2007-08-03 07:24:33 -06:00
Brian
99e854743c added bluegene-osmesa 2007-08-02 14:24:05 -06:00
Brian
6f79062d91 OSmesa on BlueGene (Alexander Neundorf) 2007-08-02 14:22:52 -06:00
Brian
2f682c3995 fix stencil value masking bug 11805, and fix sizeof() bug 2007-08-02 09:08:53 -06:00
Brian
067370e68f fix invalid pointer usage in bezierPatchDeleteList(), bug 11807 2007-08-02 08:40:58 -06:00
Brian
2aa439a6a4 fix double free()s (bug 11808) 2007-08-02 08:38:10 -06:00
Brian
b477182dc3 s/MAX_TEXTURE_LEVELS/SIS_MAX_TEXTURE_LEVELS/ and add assertion (bug 11806) 2007-08-02 08:35:27 -06:00
Michel Dänzer
a8964ca89e i915tex: Better attempt to release miptree when overriding texture image.
The previous approach could lead to crashes in FBO code that dereferences the
miptree struct pointer unconditionally.
2007-08-02 12:14:03 +02:00
Brian
4f0e92d07c Merge branch 'mesa_7_0_branch' of git+ssh://brianp@git.freedesktop.org/git/mesa/mesa into mesa_7_0_branch 2007-08-01 17:03:09 -06:00
Brian
577f4e8a5f Obsolete 2007-08-01 11:45:47 -06:00
Brian
0586d9fe56 fix error code test limit (bug 11795) 2007-08-01 11:27:47 -06:00
Michel Dänzer
1f0d9bf05e i915tex: Missing piece of SetTexOffset hook implementation for I830 generation. 2007-08-01 17:46:32 +02:00
Michel Dänzer
8bcae2a527 i915tex: Implement SetTexOffset hook.
Only build tested for I830 generation.
2007-08-01 17:46:31 +02:00
Michel Dänzer
35ca9aae91 r300: Implement SetTexOffset hook. 2007-08-01 17:46:30 +02:00
Michel Dänzer
6cdd2bf8d7 Add interfaces for overriding texture images with driver specific 'offsets'.
To be used by AIGLX for GLX_EXT_texture_from_pixmap without several
additional data copies.
2007-08-01 17:46:29 +02:00
Brian
ce7d175adb fix mem leak (bug 11793) 2007-08-01 08:42:13 -06:00
Brian
1904fd095f fix mem leak (bug 11791) 2007-08-01 08:42:09 -06:00
Brian
897d0ac5cc fix some FreeBSD issues 2007-07-31 14:57:54 -06:00
Brian
e262d0182f fix failure caused by undeclared variable (bug 11783) 2007-07-31 09:43:40 -06:00
Brian
aa5b748c10 glGetAttribLocation always returned 1 (bug 11774) 2007-07-31 09:29:31 -06:00
Julien Cristau
c6728df4a3 Merge tag 'mesa_7_0_1_rc2' into debian-experimental 2007-07-31 04:00:13 +02:00
Brian
3c182c5bc8 Added sunos5-v9-cc-g++ config (Roland Egger) 2007-07-30 09:00:09 -06:00
Brian
1b5677847b _mesa_pack_bitmap() fix from trunk 2007-07-30 08:13:05 -06:00
Brian
1be59a9dbe dlist polygon stipple fix from trunk 2007-07-30 08:12:29 -06:00
Brian
55c2178ad4 fix bug 11754 2007-07-29 18:28:09 -06:00
Jan Dvorak
3e3d392e1c fix glPointParameteriv bug 11754 2007-07-29 18:26:55 -06:00
Julien Cristau
593de57fa2 Prepare changelog for upload. 2007-07-27 20:18:21 +02:00
Julien Cristau
04b0e43ea6 New upstream release candidate. 2007-07-27 19:59:38 +02:00
Julien Cristau
04eee290c8 Merge branch 'mesa_7_0_branch' of git://anongit.freedesktop.org/git/mesa/mesa into debian-experimental 2007-07-27 19:58:30 +02:00
Brian
756a7a4e4b minor tweaks 2007-07-27 11:44:55 -06:00
Brian
121b4ac220 More Mingw32 fixes from Zhang (zxpmyth@yahoo.com.cn) 2007-07-27 11:12:21 -06:00
Brian
cdbd5db3af release candidate 2 2007-07-27 11:10:00 -06:00
Brian
b2240f6ad4 fix bug 11731 2007-07-26 15:33:39 -06:00
Brian
33814a55f8 Fix function call bug 11731. Also, fix up IR_CALL/IR_FUNC confusion. 2007-07-26 15:32:34 -06:00
Brian
a57c5a417b generate error upon writing to varying var in fragment program (bug 11733) 2007-07-26 11:39:37 -06:00
Brian
ff1a28de17 clamp float colors 2007-07-26 08:19:40 -06:00
Brian
772f57f99b call ctx->Driver.NewProgram() instead of _mesa_new_program() 2007-07-24 09:56:54 -06:00
Brian
dacee32b8b fix logic error, typos 2007-07-24 09:19:44 -06:00
Brian
fa1a3eb06d fix GLX_STEREO bug 2007-07-23 16:54:35 -06:00
Brian
bd4817ca54 fix GLX_STEREO handling (bug 11705) 2007-07-23 16:51:03 -06:00
Julien Cristau
d3a160e217 New upstream release candidate. 2007-07-23 16:39:48 +02:00
Julien Cristau
c5837f2791 Merge branch 'mesa_7_0_branch' of git://anongit.freedesktop.org/git/mesa/mesa into debian-experimental 2007-07-23 16:28:56 +02:00
Julien Cristau
490bd43f18 Merge branch 'debian-unstable' of git+ssh://git.debian.org/git/pkg-xorg/lib/mesa into debian-experimental
Conflicts:

	debian/changelog
2007-07-23 16:28:10 +02:00
Brian
005eea249c Fix a number of MINGW32 issues (Zhang <zxpmyth@yahoo.com.cn>) 2007-07-21 11:27:22 -06:00
Brian
9747de8ec6 drop VC6 and VC7 project files until updated 2007-07-21 10:03:30 -06:00
Brian
849a9799d0 fix bug 11588 2007-07-13 16:37:18 -06:00
Jan Dvorak
e32ae4fe33 fix shader/info string length queries (bug 11588) 2007-07-13 16:35:19 -06:00
Brian
4595389c4c fix width/depth mix-up (bug 11577) 2007-07-12 21:43:39 -06:00
Brian
e8ccc7cc49 Merge branch 'mesa_7_0_branch' of git+ssh://brianp@git.freedesktop.org/git/mesa/mesa into mesa_7_0_branch 2007-07-12 14:49:56 -06:00
Brian
673d21047a fix swizzle-related bug 11534 2007-07-12 14:49:24 -06:00
Julien Cristau
6186261589 Prepare changelog for upload. 2007-07-11 05:51:34 +02:00
Julien Cristau
45310e219c Relax libgl1-mesa-dev dependency on libgl1-mesa-glx.
Change the >= ${source:Version} dependency to >= ${source:Upstream-Version}.
This way libgl1-mesa-dev stays installable after a minor revision bump on
architectures where mesa isn't built yet.
2007-07-11 05:45:30 +02:00
Julien Cristau
250f6b2c88 Replace ${Source-Version} with ${source:Version} in one remaining spot. 2007-07-11 05:34:30 +02:00
Michel Dänzer
fdefc2bbda i915tex: Better procedure for dropping batchbuffer on virtual resolution change.
The previous procedure would often result in a GPU lockup.
2007-07-10 11:02:18 +02:00
Michel Dänzer
2079df8527 i915tex: Only wait for vblank when really necessary.
This avoids superfluous waits for vblank timing out under some circumstances.
2007-07-10 10:54:51 +02:00
Michel Dänzer
b53659452c Clear pointers to freed cliprects.
Not doing this could lead to double frees under rare circumstances.
2007-07-10 10:49:28 +02:00
Michel Dänzer
46f1d6653e Remove dubious compile-time test for pre-2.4 Linux kernels.
LINUX_VERSION_CODE shouldn't be used by userspace code, it can be defined empty
these days.

If anybody still cares about 2.2 kernels, they should reinstate this as a
proper runtime test.
2007-07-10 10:34:10 +02:00
Brian
c1938a60f7 Fix zero-size texture checking in _mesa_test_proxy_teximage(), bug 11309 2007-07-08 10:04:14 -06:00
Brian
d65110f352 Check if 'indices' is NULL, bug 11314 2007-07-08 09:21:21 -06:00
Brian
9fa3bbcb5a check depthScale value for optimized ushort->uint case (fixes bug 11474) 2007-07-08 08:53:09 -06:00
Brice Goglin
19e51ecbe6 libgl1-mesa-dev does not need to depend on libgl1-mesa-dri, libgl1-mesa-glx is enough.
libgl1-mesa-glx was included in libgl1-mesa-dri before 6.4.1-0.1,
so libgl1-mesa-dev had to depend on libgl1-mesa-dri at this point.
Since libgl1-mesa-dri only contains the DRI modules now, it is not
required anymore for libgl1-mesa-dev.
2007-07-07 22:17:35 +02:00
Brian
99d62f2922 fix i915 polygon stipple bug 2007-07-06 16:53:28 -06:00
Brian
284743cafe add GL_QUADS to i915_reduced_primitive_state() to fix redbook/polys demo 2007-07-06 16:52:34 -06:00
Xavier Bachelot
08d7307b2a call glutInit(), bug 11486 2007-07-06 12:54:40 -06:00
Brian
ef6a64abe6 fix a syntax error (missing right-paren) 2007-07-05 16:04:10 -06:00
Brian
18bfa52ef7 fix bug 11475 2007-07-05 09:42:07 -06:00
Brian
d62be2652c Copy from Mesa master. Includes fixes for bugs 11475 and 11448. 2007-07-05 09:40:37 -06:00
Julien Cristau
31f3433635 Prepare changelog for upload. 2007-07-05 00:56:56 +02:00
Samuel Thibault
639eaceee7 Fix build on hurd-i386.
Build libgl1-mesa-glx without direct rendering support on that arch, and
don't build any dri driver.
2007-07-05 00:48:30 +02:00
Eric Anholt
ea53ff80af fix LogicOp/bitmap problem, bug 11133 2007-07-04 07:37:28 -06:00
Brian
feeca1bcbc add fbdev/ to DEMO_FILES 2007-07-03 15:46:48 -06:00
Brian
12e7278c08 document GLSL fixes 2007-07-03 12:21:11 -06:00
Brian
45b5c44eb9 bring over Roland's DOT3_RGBA fix from master 2007-07-03 12:20:52 -06:00
Brian
e3456c1028 added vec2(vec4) constructor, bug 11404 2007-07-03 11:42:03 -06:00
Brian
327fb38573 add code for stpq, rgba writemasks in make_writemask(), bug 11404 2007-07-03 11:41:07 -06:00
Brian
1d25d9e15f Bump version to 7.0.1 2007-07-03 10:04:41 -06:00
Brian
cc7cee3f48 Revert the version of libOSMesa.so to 6.5.3 to avoid linking issues that were caused by bumping to 7.0 2007-07-03 10:03:01 -06:00
Brian
d7062710cd use _mesa_unpack_stencil_span() in draw_stencil_pixels(), bug 11457 2007-07-03 08:58:03 -06:00
Julien Cristau
3e21f52796 Make libgl1-mesa-swx11 depend on libosmesa6
libgl1-mesa-swx11 used to contain libOSMesa.so.6, so programs linked against
it don't necessarily depend on libosmesa6; their dependencies were broken
since mesa 6.5.2-1.
2007-07-03 05:34:07 +02:00
Brian
9bfba734d8 add const to wglSetPixelFormat() to match .h declaration 2007-07-02 10:15:39 -06:00
Julien Cristau
0511d9a9d2 Fix merge and delete symlinks which aren't in the tarball. 2007-07-01 02:55:59 +02:00
Brian
aaebf2f47e regenerated 2007-06-29 07:51:49 -06:00
Brian
23f8d77b38 Add a few missing GL 2.0 entrypoints, regenerate related files.
Specifically:
  glVertexAttrib4bv
  glVertexAttrib4iv
  glVertexAttrib4ubv
  glVertexAttrib4uiv
  glVertexAttrib4usv
2007-06-28 16:38:48 -06:00
Samuel Thibault
498b4dbba4 Fix build on hurd-i386.
Build libgl1-mesa-glx without direct rendering support on that arch, and
don't build any dri driver.
2007-06-28 22:33:05 +01:00
Julien Cristau
ecc42e79ae Merge unreleased changelog entries 2007-06-28 22:01:05 +01:00
Julien Cristau
0bf8ed523d * Add a shlibs file for libgl1-mesa-swx11-i686. 2007-06-28 21:58:42 +01:00
Brian
87d22ee0fe initial 7.0.1 relnotes 2007-06-28 08:11:36 -06:00
zhang
52e25f63d4 a variety of fixes for MingW 2007-06-28 08:10:09 -06:00
Brian
f3fb67972b remove obsolete t_save_api.c 2007-06-28 07:43:32 -06:00
Brian
6400756364 remove obsolete sources 2007-06-28 07:21:59 -06:00
David Nusinow
d71d04bf6f Bite the bullet and add myself to uploaders 2007-06-27 22:54:52 -04:00
David Nusinow
af90259e09 Merge remote branch 'origin/debian-experimental' into debian-experimental
Conflicts:

	debian/changelog
	src/mesa/drivers/dri/r300/radeon_lock.c
2007-06-27 22:53:04 -04:00
David Nusinow
7c9762f698 Changelog bump 2007-06-27 21:32:51 -04:00
David Nusinow
b2e67fdb7c Merge branch 'upstream-experimental' into debian-experimental
Conflicts:

	.gitignore
	progs/miniglx/miniglxtest.c
	src/glx/mini/Makefile
	src/glx/mini/miniglx.c
	src/mesa/drivers/dri/r300/.gitignore
2007-06-27 21:29:16 -04:00
Brian
d59f0314bd md5 sums for 7.0 2007-06-22 16:50:24 -06:00
Brian
131baefac3 fix date for 7.0 release 2007-06-22 16:41:36 -06:00
Brian
a450078b67 update version 2007-06-22 16:40:17 -06:00
Brian
f6b041bf6c bring in Eric's FreeBSD fixes for -pthread 2007-06-22 15:40:46 -06:00
Brian
4f340d181a set tentative 7.0 release date 2007-06-20 19:59:15 -06:00
Julien Cristau
74a11701f3 Shorten the one-line synopsis of various packages.
They're cut off in .changes files if they're too long.
Thanks, Marc 'HE' Brockschmidt!
2007-06-13 19:36:49 +02:00
Brian
b58e38e936 fix TEXTREL problem (bug 7459) 2007-06-12 09:52:05 -06:00
Brian
8713cb48a8 Fix TEXREL issues when using GLX_USE_TLS (see bug 7459). 2007-06-12 09:46:12 -06:00
Brian
277c5e57ed fix GLX_USE_TLS breakage 2007-06-12 08:57:39 -06:00
Brian
b3d62d5af5 disable depthBits check in check_compatible(), see bug 11161 2007-06-08 12:36:00 -06:00
Brian
9c0f0c8d81 remove old comment about DEFAULT_SOFTWARE_DEPTH_BITS 2007-06-08 12:35:37 -06:00
Brian
18a0a2a7ac document bug 11049 fix 2007-05-23 16:50:22 -06:00
Brian
8b99d9e33c restore GL_TEXTURE_LOD_BIAS in _mesa_PopAttrib(), bug 11049 2007-05-23 16:49:19 -06:00
Brian
01e7e153e3 document point attentuation fix 2007-05-23 08:59:02 -06:00
Brian
0ad4ca24d2 Fix point attentuation problem (bug 11042)
ctx->Point._Attentuation was computed in wrong place and the VB->Eye coord Z
array wasn't indexed correctly in run_point_stage().
2007-05-23 08:56:45 -06:00
Brian
724a155552 if light position is local, treat it as a homogeneous coord and divide by W (see bug 11009) 2007-05-21 10:55:15 -06:00
Julien Cristau
e1b0715dd6 Prepare changelog for upload. 2007-05-21 11:35:28 +02:00
Julien Cristau
a5c6598966 Merge remote branch 'origin/debian-unstable' into debian-experimental
Conflicts:

	debian/changelog
2007-05-21 11:33:42 +02:00
Roland Scheidegger
d38b74a316 fix miptree layout (i915) for small compressed mipmaps
This seems to work now. Also fix i945 set_level_info, need to match i915
behaviour for storing mip height, as it's assumed to be the mip width
(in texels) elsewhere and the division by 4 is done later (untested).
2007-05-19 04:43:50 +02:00
Roland Scheidegger
54cab4b47b fix copy & paste bug of previous commit, breaking dxt5 formats 2007-05-19 03:56:06 +02:00
Roland Scheidegger
c093666bc5 fix miptree comparison with compressed textures
TexelBytes is always 0 with compressed textures, thus would never match
mt->cpp. This caused constant blitting around of textures, and it fixes at
least the horrible performance of Q3 if compressed textures are enabled.
2007-05-19 01:39:54 +02:00
Roland Scheidegger
04972f6761 fix small s3tc mipmaps (#10968)
make sure that always whole blocks are uploaded.
(May still not work correctly if the top mip map is not at least a full block,
that is 4 pixels wide - not sure, but probably doesn't happen in real world)
2007-05-19 01:39:16 +02:00
Brian
67f8234622 set version to 7.0 2007-05-18 09:41:34 -06:00
Brian
201d6dbd9c fix STATE_HALF_VECTOR value (bug 10987) 2007-05-18 09:35:18 -06:00
Julien Cristau
1865ef6fd4 Prepare changelog for upload. 2007-05-18 13:36:42 +02:00
Ian Romanick
fbcac5aa83 Refactor determining whether a texture target can use compressed format 2007-05-17 14:45:25 -07:00
Brian
2b72ab8f8f document glXDestroyPbuffer fix 2007-05-17 15:30:39 -06:00
Brian
0ea97b9408 In DestroyPbuffer(), use GetReq() intead of GetReqExtra(). See bug 10983. 2007-05-17 15:26:39 -06:00
Brian
28683ac7c0 version 7.0, not 7.1 2007-05-17 09:07:25 -06:00
Brian
c72e3e210f version should be 7.0 2007-05-17 09:04:19 -06:00
Julien Cristau
a8c856d43c Cherry-pick commmit 65faf023 by Michel Dänzer to fix r300 crash.
r300: Don't crash in radeonUpdatePageFlipping when !radeon->glCtx->DrawBuffer.

This feels like a kludge, maybe there's a better solution.
2007-05-09 15:09:12 +02:00
David Nusinow
1953cfc954 Update changelog 2007-04-30 00:08:11 -04:00
David Nusinow
8e7bac950e Merge branch 'upstream-experimental' into debian-experimental 2007-04-29 23:23:00 -04:00
Julien Cristau
03cdacfb6a Prepare changelog for upload. 2007-04-25 10:37:10 +02:00
Julien Cristau
30f3c3dfad Update changelog. 2007-04-25 08:42:02 +02:00
Julien Cristau
dee1b0d5bb Merge remote branch 'upstream/master' into debian-experimental 2007-04-25 08:40:39 +02:00
Julien Cristau
6f2b0fe463 New upstream release candidate.
Refresh a couple patches.
2007-04-25 01:48:33 +02:00
Julien Cristau
0c69176498 Merge tag 'mesa_6_5_3_rc3' into debian-experimental 2007-04-25 01:41:05 +02:00
Julien Cristau
4e7a0385b5 Merge tag 'mesa_6_5_3_rc2' into debian-experimental 2007-04-25 01:40:50 +02:00
Julien Cristau
4adbd94b10 Only install stuff in mesa-swx11-source if we're building arch:all packages. 2007-04-23 11:00:09 +02:00
Julien Cristau
4a2905b645 Delete obsolete file. 2007-04-22 18:08:58 +02:00
Julien Cristau
0638c6b530 Add generated files from the tarball so they're included in mesa-swx11-source. 2007-04-22 18:08:35 +02:00
Julien Cristau
7dd35ce013 Delete .gitignore files which do more harm than good in a debian package tree. 2007-04-22 18:07:52 +02:00
Julien Cristau
c8629c3178 Resync debian/scripts/install-source.sh. 2007-04-22 00:51:10 +02:00
Julien Cristau
77ccf51cb3 New upstream release candidate. 2007-04-22 00:50:40 +02:00
Julien Cristau
01197f0c77 Merge branch 'upstream-experimental' into debian-experimental 2007-04-22 00:34:30 +02:00
Julien Cristau
69c86ff4fd Remove leftover file. 2007-04-22 00:33:38 +02:00
Julien Cristau
9a42ffad81 Add build-dependencies on libxdamage-dev and libxfixes-dev. 2007-04-21 21:23:21 +02:00
Julien Cristau
0d8633bf8c Delete autogenerated files, and files not included in the tarball. 2007-04-21 21:20:37 +02:00
Julien Cristau
d79e80a3d0 New upstream release candidate.
Drop patches included upstream.
2007-04-21 20:47:01 +02:00
Julien Cristau
d890ebdd25 Merge branch 'upstream-experimental' into debian-experimental
Conflicts:

	doxygen/Makefile
	doxygen/common.doxy
	doxygen/doxy.bat
	doxygen/glapi.doxy
	doxygen/header.html
	doxygen/main.doxy
	doxygen/math.doxy
	doxygen/shader.doxy
	doxygen/swrast.doxy
	doxygen/swrast_setup.doxy
	doxygen/tnl.doxy
	doxygen/tnl_dd.doxy
	progs/tests/Makefile
	progs/tests/fbotest1.c
	progs/tests/fbotest2.c
	progs/tests/fbotexture.c
	progs/tests/mipmap_limits.c
	progs/tests/sharedtex.c
	progs/tools/trace/gltrace_support.cc
	progs/trivial/Makefile
	src/egl/docs/EGL_MESA_screen_surface
	src/egl/main/egllog.c
	src/glx/mini/Makefile
	src/glx/mini/driver.h
	src/mesa/drivers/allegro/amesa.c
	src/mesa/drivers/windows/gldirect/dx7/gld_driver_dx7.c
	src/mesa/drivers/windows/gldirect/dx7/gld_ext_dx7.c
	src/mesa/drivers/windows/gldirect/dx7/gld_primitive_dx7.c
	src/mesa/drivers/windows/gldirect/dx8/gld_driver_dx8.c
	src/mesa/drivers/windows/gldirect/dx8/gld_ext_dx8.c
	src/mesa/drivers/windows/gldirect/dx8/gld_primitive_dx8.c
	src/mesa/drivers/windows/gldirect/dx9/gld_driver_dx9.c
	src/mesa/drivers/windows/gldirect/dx9/gld_ext_dx9.c
	src/mesa/drivers/windows/gldirect/dx9/gld_primitive_dx9.c
	src/mesa/drivers/windows/gldirect/mesasw/gld_wgl_mesasw.c
2007-04-21 20:27:55 +02:00
Brice Goglin
5ee9b3ce72 Fix conflicts for libGLw packages.
libglw1-mesa does not have to conflict with earlier libgl1-mesa-swx11
(libGLw was only shipped as development libs/headers within swx11-dev).

libglw1-mesa-dev needs to conflicts with libglw-dev.
2007-04-21 20:20:03 +02:00
Brice Goglin
031b539a09 Split out libGLw libs and headers from libgl1-mesa-swx11.
Ship both static and shared libraries for libGLw, creating libglw1-mesa and
libglw1-mesa-dev (closes: #374904).
2007-04-21 20:19:38 +02:00
Brice Goglin
47c3c706e8 Add 09_i915_always_enable_pixel_fog.patch 2007-04-21 18:00:12 +02:00
Brice Goglin
0d830a616c Add 08_r300_update_window_state_when_bound_but_stamp_changed.patch 2007-04-20 18:53:47 +02:00
Brice Goglin
e219bf8338 Add 07_call_radeonSetCliprects_from_radeonMakeCurrent.patch 2007-04-20 18:44:59 +02:00
Julien Cristau
6c0fba2480 Prepare changelog for upload. 2007-04-20 05:58:00 +02:00
Julien Cristau
f4cc159f53 Revert " * Split out libGLw libs and headers from libgl1-mesa-swx11 and ship both"
This reverts commit 856ae782c7.

Conflicts:

	debian/changelog
2007-04-20 05:55:04 +02:00
Julien Cristau
04c002abc2 Revert "Fix conflicts for libGLw packages."
This reverts commit 048144074b.
2007-04-20 05:53:59 +02:00
Julien Cristau
78fd17907e Merge branch 'debian-experimental' into debian-unstable 2007-04-20 05:52:20 +02:00
Julien Cristau
47edc83080 Merge branch 'debian-experimental' into debian-unstable
Conflicts:

	configs/debian-osmesa16
	configs/debian-osmesa16-static
	configs/debian-osmesa32
	configs/debian-osmesa32-static
	debian/changelog
	debian/compat
	debian/control
	debian/copyright
	debian/libgl1-mesa-dev.install
	debian/libgl1-mesa-swx11-dev.install
	debian/libgl1-mesa-swx11.shlibs
	debian/libglu1-mesa-dev.install
	debian/mesa-common-dev.docs
	debian/mesa-common-dev.install
	debian/rules
	src/mesa/x86-64/matypes.h
	src/mesa/x86/matypes.h
2007-04-20 05:44:24 +02:00
Julien Cristau
33e34f5bf4 Merge tag 'mesa_6_5_1' into debian-unstable
Conflicts:

	progs/util/README
	progs/util/glstate.c
	progs/util/glstate.h
	progs/util/sampleMakefile
	src/glu/sgi/libnurbs/interface/bezierEval.h
	src/glu/sgi/libnurbs/interface/bezierPatch.cc
	src/glu/sgi/libnurbs/interface/bezierPatch.h
	src/glu/sgi/libnurbs/interface/bezierPatchMesh.cc
	src/glu/sgi/libnurbs/interface/bezierPatchMesh.h
	src/glu/sgi/libnurbs/interface/glcurveval.cc
	src/glu/sgi/libnurbs/interface/glimports.h
	src/glu/sgi/libnurbs/interface/glinterface.cc
	src/glu/sgi/libnurbs/interface/glrenderer.h
	src/glu/sgi/libnurbs/interface/incurveeval.cc
	src/glu/sgi/libnurbs/interface/insurfeval.cc
	src/glu/sgi/libnurbs/interface/mystdio.h
	src/glu/sgi/libnurbs/interface/mystdlib.h
	src/glu/sgi/libnurbs/internals/arc.h
	src/glu/sgi/libnurbs/internals/arcsorter.cc
	src/glu/sgi/libnurbs/internals/arcsorter.h
	src/glu/sgi/libnurbs/internals/arctess.h
	src/glu/sgi/libnurbs/internals/backend.cc
	src/glu/sgi/libnurbs/internals/backend.h
	src/glu/sgi/libnurbs/internals/basiccrveval.h
	src/glu/sgi/libnurbs/internals/basicsurfeval.h
	src/glu/sgi/libnurbs/internals/bezierarc.h
	src/glu/sgi/libnurbs/internals/bin.cc
	src/glu/sgi/libnurbs/internals/bin.h
	src/glu/sgi/libnurbs/internals/bufpool.cc
	src/glu/sgi/libnurbs/internals/bufpool.h
	src/glu/sgi/libnurbs/internals/cachingeval.cc
	src/glu/sgi/libnurbs/internals/cachingeval.h
	src/glu/sgi/libnurbs/internals/ccw.cc
	src/glu/sgi/libnurbs/internals/coveandtiler.h
	src/glu/sgi/libnurbs/internals/curve.cc
	src/glu/sgi/libnurbs/internals/curve.h
	src/glu/sgi/libnurbs/internals/curvelist.cc
	src/glu/sgi/libnurbs/internals/curvelist.h
	src/glu/sgi/libnurbs/internals/curvesub.cc
	src/glu/sgi/libnurbs/internals/dataTransform.cc
	src/glu/sgi/libnurbs/internals/dataTransform.h
	src/glu/sgi/libnurbs/internals/defines.h
	src/glu/sgi/libnurbs/internals/displaylist.cc
	src/glu/sgi/libnurbs/internals/displaylist.h
	src/glu/sgi/libnurbs/internals/displaymode.h
	src/glu/sgi/libnurbs/internals/flist.cc
	src/glu/sgi/libnurbs/internals/flist.h
	src/glu/sgi/libnurbs/internals/flistsorter.cc
	src/glu/sgi/libnurbs/internals/flistsorter.h
	src/glu/sgi/libnurbs/internals/gridline.h
	src/glu/sgi/libnurbs/internals/gridtrimvertex.h
	src/glu/sgi/libnurbs/internals/gridvertex.h
	src/glu/sgi/libnurbs/internals/hull.cc
	src/glu/sgi/libnurbs/internals/hull.h
	src/glu/sgi/libnurbs/internals/intersect.cc
	src/glu/sgi/libnurbs/internals/jarcloc.h
	src/glu/sgi/libnurbs/internals/knotvector.h
	src/glu/sgi/libnurbs/internals/mapdesc.cc
	src/glu/sgi/libnurbs/internals/mapdesc.h
	src/glu/sgi/libnurbs/internals/mapdescv.cc
	src/glu/sgi/libnurbs/internals/maplist.cc
	src/glu/sgi/libnurbs/internals/maplist.h
	src/glu/sgi/libnurbs/internals/mesher.cc
	src/glu/sgi/libnurbs/internals/mesher.h
	src/glu/sgi/libnurbs/internals/monoTriangulationBackend.cc
	src/glu/sgi/libnurbs/internals/monotonizer.cc
	src/glu/sgi/libnurbs/internals/monotonizer.h
	src/glu/sgi/libnurbs/internals/myassert.h
	src/glu/sgi/libnurbs/internals/mycode.cc
	src/glu/sgi/libnurbs/internals/mystring.h
	src/glu/sgi/libnurbs/internals/nurbsconsts.h
	src/glu/sgi/libnurbs/internals/nurbstess.cc
	src/glu/sgi/libnurbs/internals/patch.cc
	src/glu/sgi/libnurbs/internals/patch.h
	src/glu/sgi/libnurbs/internals/patchlist.cc
	src/glu/sgi/libnurbs/internals/patchlist.h
	src/glu/sgi/libnurbs/internals/pwlarc.h
	src/glu/sgi/libnurbs/internals/quilt.cc
	src/glu/sgi/libnurbs/internals/quilt.h
	src/glu/sgi/libnurbs/internals/reader.cc
	src/glu/sgi/libnurbs/internals/reader.h
	src/glu/sgi/libnurbs/internals/renderhints.cc
	src/glu/sgi/libnurbs/internals/renderhints.h
	src/glu/sgi/libnurbs/internals/simplemath.h
	src/glu/sgi/libnurbs/internals/slicer.cc
	src/glu/sgi/libnurbs/internals/slicer.h
	src/glu/sgi/libnurbs/internals/sorter.cc
	src/glu/sgi/libnurbs/internals/sorter.h
	src/glu/sgi/libnurbs/internals/splitarcs.cc
	src/glu/sgi/libnurbs/internals/subdivider.h
	src/glu/sgi/libnurbs/internals/tobezier.cc
	src/glu/sgi/libnurbs/internals/trimline.cc
	src/glu/sgi/libnurbs/internals/trimline.h
	src/glu/sgi/libnurbs/internals/trimregion.cc
	src/glu/sgi/libnurbs/internals/trimregion.h
	src/glu/sgi/libnurbs/internals/trimvertex.h
	src/glu/sgi/libnurbs/internals/trimvertpool.cc
	src/glu/sgi/libnurbs/internals/trimvertpool.h
	src/glu/sgi/libnurbs/internals/types.h
	src/glu/sgi/libnurbs/internals/uarray.cc
	src/glu/sgi/libnurbs/internals/uarray.h
	src/glu/sgi/libnurbs/internals/varray.cc
	src/glu/sgi/libnurbs/internals/varray.h
	src/glu/sgi/libnurbs/nurbtess/definitions.h
	src/glu/sgi/libnurbs/nurbtess/directedLine.h
	src/glu/sgi/libnurbs/nurbtess/glimports.h
	src/glu/sgi/libnurbs/nurbtess/gridWrap.cc
	src/glu/sgi/libnurbs/nurbtess/gridWrap.h
	src/glu/sgi/libnurbs/nurbtess/monoChain.cc
	src/glu/sgi/libnurbs/nurbtess/monoChain.h
	src/glu/sgi/libnurbs/nurbtess/monoTriangulation.cc
	src/glu/sgi/libnurbs/nurbtess/monoTriangulation.h
	src/glu/sgi/libnurbs/nurbtess/mystdio.h
	src/glu/sgi/libnurbs/nurbtess/mystdlib.h
	src/glu/sgi/libnurbs/nurbtess/partitionX.cc
	src/glu/sgi/libnurbs/nurbtess/partitionX.h
	src/glu/sgi/libnurbs/nurbtess/partitionY.cc
	src/glu/sgi/libnurbs/nurbtess/partitionY.h
	src/glu/sgi/libnurbs/nurbtess/polyDBG.h
	src/glu/sgi/libnurbs/nurbtess/polyUtil.cc
	src/glu/sgi/libnurbs/nurbtess/polyUtil.h
	src/glu/sgi/libnurbs/nurbtess/primitiveStream.cc
	src/glu/sgi/libnurbs/nurbtess/primitiveStream.h
	src/glu/sgi/libnurbs/nurbtess/quicksort.cc
	src/glu/sgi/libnurbs/nurbtess/quicksort.h
	src/glu/sgi/libnurbs/nurbtess/rectBlock.cc
	src/glu/sgi/libnurbs/nurbtess/rectBlock.h
	src/glu/sgi/libnurbs/nurbtess/sampleComp.cc
	src/glu/sgi/libnurbs/nurbtess/sampleComp.h
	src/glu/sgi/libnurbs/nurbtess/sampleCompBot.cc
	src/glu/sgi/libnurbs/nurbtess/sampleCompBot.h
	src/glu/sgi/libnurbs/nurbtess/sampleCompRight.cc
	src/glu/sgi/libnurbs/nurbtess/sampleCompRight.h
	src/glu/sgi/libnurbs/nurbtess/sampleCompTop.cc
	src/glu/sgi/libnurbs/nurbtess/sampleCompTop.h
	src/glu/sgi/libnurbs/nurbtess/sampleMonoPoly.cc
	src/glu/sgi/libnurbs/nurbtess/sampleMonoPoly.h
	src/glu/sgi/libnurbs/nurbtess/sampledLine.cc
	src/glu/sgi/libnurbs/nurbtess/sampledLine.h
	src/glu/sgi/libnurbs/nurbtess/searchTree.cc
	src/glu/sgi/libnurbs/nurbtess/searchTree.h
	src/glu/sgi/libnurbs/nurbtess/zlassert.h
	src/glu/sgi/libtess/README
	src/glu/sgi/libtess/alg-outline
	src/glu/sgi/libtess/dict-list.h
	src/glu/sgi/libtess/dict.c
	src/glu/sgi/libtess/dict.h
	src/glu/sgi/libtess/geom.c
	src/glu/sgi/libtess/memalloc.c
	src/glu/sgi/libtess/memalloc.h
	src/glu/sgi/libtess/mesh.c
	src/glu/sgi/libtess/mesh.h
	src/glu/sgi/libtess/normal.h
	src/glu/sgi/libtess/priorityq-heap.c
	src/glu/sgi/libtess/priorityq-heap.h
	src/glu/sgi/libtess/priorityq-sort.h
	src/glu/sgi/libtess/priorityq.c
	src/glu/sgi/libtess/priorityq.h
	src/glu/sgi/libtess/render.c
	src/glu/sgi/libtess/render.h
	src/glu/sgi/libtess/sweep.h
	src/glu/sgi/libtess/tess.h
	src/glu/sgi/libtess/tessmono.c
	src/glu/sgi/libtess/tessmono.h
	src/glu/sgi/libutil/error.c
	src/glu/sgi/libutil/glue.c
	src/glu/sgi/libutil/gluint.h
	src/glu/sgi/libutil/project.c
	src/glu/sgi/libutil/registry.c
	src/glx/x11/glxext.c
	src/mesa/main/imports.h
	src/mesa/tnl/t_vb_cliptmp.h
2007-04-20 05:37:11 +02:00
Brice Goglin
3832ecadae Add 06_fix_texture_data_corruption.patch (closes: #412346) 2007-04-08 18:52:31 +02:00
Brice Goglin
285ed128ab Add a .shlibs file for libglw1-mesa. 2007-04-01 00:44:29 +02:00
Brice Goglin
048144074b Fix conflicts for libGLw packages.
libglw1-mesa does not have to conflict with earlier libgl1-mesa-swx11
(libGLw was only shipped as development libs/headers within swx11-dev).

libglw1-mesa-dev needs to conflicts with libglw-dev.
2007-04-01 00:43:20 +02:00
Brice Goglin
856ae782c7 * Split out libGLw libs and headers from libgl1-mesa-swx11 and ship both
static and shared libraries, creating libglw1-mesa and libglw1-mesa-dev
    (closes: #374904).
2007-03-31 03:28:32 +02:00
Julien Cristau
12e3f97541 Fix explanation about libglide3 in libgl1-mesa-dri's description.
Thanks to Michel Dänzer for his help.
2007-03-30 17:20:02 +02:00
Julien Cristau
30f6fe0710 Have libgl1-mesa-dri suggest libglide3.
Add explanation for this in the package description.  Closes: #387339.
2007-03-30 14:10:24 +02:00
Cyril Brulebois
0aa8f1df3c * Non-maintainer upload.
* Backport a fix from mesa 6.5.2 to mesa 6.5.1 which:
   - fixes braces around the ASSERT macro;
   - fixes a clipping problem, which leads to systematic segfaults of the
     X server (Closes: #405803).
2007-02-23 00:48:40 +01:00
Julien Cristau
d39147a8a1 Fix FTBFS on amd64.
Set LIB_DIR and EXTRA_LIB_PATH in configs/debian-default to override
settings in configs/linux-x86-64. This fixes a FTBFS on amd64, thanks to
Marc 'HE' Brockschmidt for the report (closes: #410118).
2007-02-07 23:13:59 +01:00
Julien Cristau
7991f7e936 * Add myself to Uploaders. 2007-02-04 21:17:18 +01:00
Julien Cristau
10011efcd7 Add bug closer for #409638. 2007-02-04 17:21:57 +01:00
Julien Cristau
0058815c8f Re-add src/glut/mini/ which was deleted by mistake. 2007-02-04 15:21:46 +01:00
Julien Cristau
02048984b7 Delete directories not included in the mesa tarballs. 2007-02-04 15:15:43 +01:00
Julien Cristau
544601e9f4 Fix FTBFS on non-i386 archs.
Build architecture-independant debs in binary-indep, and use the debhelper -s
option for commands in binary-arch, because architectures other than i386
don't have to build libgl1-mesa-swx11-i686.
2007-02-04 14:05:23 +01:00
Julien Cristau
2634f06c20 Merge branch 'upstream-experimental' into debian-experimental
Conflicts:

	progs/util/README
	progs/util/glstate.c
	progs/util/glstate.h
	progs/util/sampleMakefile
	src/glu/sgi/libnurbs/interface/bezierEval.h
	src/glu/sgi/libnurbs/interface/bezierPatch.cc
	src/glu/sgi/libnurbs/interface/bezierPatch.h
	src/glu/sgi/libnurbs/interface/bezierPatchMesh.cc
	src/glu/sgi/libnurbs/interface/bezierPatchMesh.h
	src/glu/sgi/libnurbs/interface/glcurveval.cc
	src/glu/sgi/libnurbs/interface/glimports.h
	src/glu/sgi/libnurbs/interface/glinterface.cc
	src/glu/sgi/libnurbs/interface/glrenderer.h
	src/glu/sgi/libnurbs/interface/incurveeval.cc
	src/glu/sgi/libnurbs/interface/insurfeval.cc
	src/glu/sgi/libnurbs/interface/mystdio.h
	src/glu/sgi/libnurbs/interface/mystdlib.h
	src/glu/sgi/libnurbs/internals/arc.h
	src/glu/sgi/libnurbs/internals/arcsorter.cc
	src/glu/sgi/libnurbs/internals/arcsorter.h
	src/glu/sgi/libnurbs/internals/arctess.h
	src/glu/sgi/libnurbs/internals/backend.cc
	src/glu/sgi/libnurbs/internals/backend.h
	src/glu/sgi/libnurbs/internals/basiccrveval.h
	src/glu/sgi/libnurbs/internals/basicsurfeval.h
	src/glu/sgi/libnurbs/internals/bezierarc.h
	src/glu/sgi/libnurbs/internals/bin.cc
	src/glu/sgi/libnurbs/internals/bin.h
	src/glu/sgi/libnurbs/internals/bufpool.cc
	src/glu/sgi/libnurbs/internals/bufpool.h
	src/glu/sgi/libnurbs/internals/cachingeval.cc
	src/glu/sgi/libnurbs/internals/cachingeval.h
	src/glu/sgi/libnurbs/internals/ccw.cc
	src/glu/sgi/libnurbs/internals/coveandtiler.h
	src/glu/sgi/libnurbs/internals/curve.cc
	src/glu/sgi/libnurbs/internals/curve.h
	src/glu/sgi/libnurbs/internals/curvelist.cc
	src/glu/sgi/libnurbs/internals/curvelist.h
	src/glu/sgi/libnurbs/internals/curvesub.cc
	src/glu/sgi/libnurbs/internals/dataTransform.cc
	src/glu/sgi/libnurbs/internals/dataTransform.h
	src/glu/sgi/libnurbs/internals/defines.h
	src/glu/sgi/libnurbs/internals/displaylist.cc
	src/glu/sgi/libnurbs/internals/displaylist.h
	src/glu/sgi/libnurbs/internals/displaymode.h
	src/glu/sgi/libnurbs/internals/flist.cc
	src/glu/sgi/libnurbs/internals/flist.h
	src/glu/sgi/libnurbs/internals/flistsorter.cc
	src/glu/sgi/libnurbs/internals/flistsorter.h
	src/glu/sgi/libnurbs/internals/gridline.h
	src/glu/sgi/libnurbs/internals/gridtrimvertex.h
	src/glu/sgi/libnurbs/internals/gridvertex.h
	src/glu/sgi/libnurbs/internals/hull.cc
	src/glu/sgi/libnurbs/internals/hull.h
	src/glu/sgi/libnurbs/internals/intersect.cc
	src/glu/sgi/libnurbs/internals/jarcloc.h
	src/glu/sgi/libnurbs/internals/knotvector.h
	src/glu/sgi/libnurbs/internals/mapdesc.cc
	src/glu/sgi/libnurbs/internals/mapdesc.h
	src/glu/sgi/libnurbs/internals/mapdescv.cc
	src/glu/sgi/libnurbs/internals/maplist.cc
	src/glu/sgi/libnurbs/internals/maplist.h
	src/glu/sgi/libnurbs/internals/mesher.cc
	src/glu/sgi/libnurbs/internals/mesher.h
	src/glu/sgi/libnurbs/internals/monoTriangulationBackend.cc
	src/glu/sgi/libnurbs/internals/monotonizer.cc
	src/glu/sgi/libnurbs/internals/monotonizer.h
	src/glu/sgi/libnurbs/internals/myassert.h
	src/glu/sgi/libnurbs/internals/mycode.cc
	src/glu/sgi/libnurbs/internals/mystring.h
	src/glu/sgi/libnurbs/internals/nurbsconsts.h
	src/glu/sgi/libnurbs/internals/nurbstess.cc
	src/glu/sgi/libnurbs/internals/patch.cc
	src/glu/sgi/libnurbs/internals/patch.h
	src/glu/sgi/libnurbs/internals/patchlist.cc
	src/glu/sgi/libnurbs/internals/patchlist.h
	src/glu/sgi/libnurbs/internals/pwlarc.h
	src/glu/sgi/libnurbs/internals/quilt.cc
	src/glu/sgi/libnurbs/internals/quilt.h
	src/glu/sgi/libnurbs/internals/reader.cc
	src/glu/sgi/libnurbs/internals/reader.h
	src/glu/sgi/libnurbs/internals/renderhints.cc
	src/glu/sgi/libnurbs/internals/renderhints.h
	src/glu/sgi/libnurbs/internals/simplemath.h
	src/glu/sgi/libnurbs/internals/slicer.cc
	src/glu/sgi/libnurbs/internals/slicer.h
	src/glu/sgi/libnurbs/internals/sorter.cc
	src/glu/sgi/libnurbs/internals/sorter.h
	src/glu/sgi/libnurbs/internals/splitarcs.cc
	src/glu/sgi/libnurbs/internals/subdivider.h
	src/glu/sgi/libnurbs/internals/tobezier.cc
	src/glu/sgi/libnurbs/internals/trimline.cc
	src/glu/sgi/libnurbs/internals/trimline.h
	src/glu/sgi/libnurbs/internals/trimregion.cc
	src/glu/sgi/libnurbs/internals/trimregion.h
	src/glu/sgi/libnurbs/internals/trimvertex.h
	src/glu/sgi/libnurbs/internals/trimvertpool.cc
	src/glu/sgi/libnurbs/internals/trimvertpool.h
	src/glu/sgi/libnurbs/internals/types.h
	src/glu/sgi/libnurbs/internals/uarray.cc
	src/glu/sgi/libnurbs/internals/uarray.h
	src/glu/sgi/libnurbs/internals/varray.cc
	src/glu/sgi/libnurbs/internals/varray.h
	src/glu/sgi/libnurbs/nurbtess/definitions.h
	src/glu/sgi/libnurbs/nurbtess/directedLine.h
	src/glu/sgi/libnurbs/nurbtess/glimports.h
	src/glu/sgi/libnurbs/nurbtess/gridWrap.cc
	src/glu/sgi/libnurbs/nurbtess/gridWrap.h
	src/glu/sgi/libnurbs/nurbtess/monoChain.cc
	src/glu/sgi/libnurbs/nurbtess/monoChain.h
	src/glu/sgi/libnurbs/nurbtess/monoTriangulation.cc
	src/glu/sgi/libnurbs/nurbtess/monoTriangulation.h
	src/glu/sgi/libnurbs/nurbtess/mystdio.h
	src/glu/sgi/libnurbs/nurbtess/mystdlib.h
	src/glu/sgi/libnurbs/nurbtess/partitionX.cc
	src/glu/sgi/libnurbs/nurbtess/partitionX.h
	src/glu/sgi/libnurbs/nurbtess/partitionY.cc
	src/glu/sgi/libnurbs/nurbtess/partitionY.h
	src/glu/sgi/libnurbs/nurbtess/polyDBG.h
	src/glu/sgi/libnurbs/nurbtess/polyUtil.cc
	src/glu/sgi/libnurbs/nurbtess/polyUtil.h
	src/glu/sgi/libnurbs/nurbtess/primitiveStream.cc
	src/glu/sgi/libnurbs/nurbtess/primitiveStream.h
	src/glu/sgi/libnurbs/nurbtess/quicksort.cc
	src/glu/sgi/libnurbs/nurbtess/quicksort.h
	src/glu/sgi/libnurbs/nurbtess/rectBlock.cc
	src/glu/sgi/libnurbs/nurbtess/rectBlock.h
	src/glu/sgi/libnurbs/nurbtess/sampleComp.cc
	src/glu/sgi/libnurbs/nurbtess/sampleComp.h
	src/glu/sgi/libnurbs/nurbtess/sampleCompBot.cc
	src/glu/sgi/libnurbs/nurbtess/sampleCompBot.h
	src/glu/sgi/libnurbs/nurbtess/sampleCompRight.cc
	src/glu/sgi/libnurbs/nurbtess/sampleCompRight.h
	src/glu/sgi/libnurbs/nurbtess/sampleCompTop.cc
	src/glu/sgi/libnurbs/nurbtess/sampleCompTop.h
	src/glu/sgi/libnurbs/nurbtess/sampleMonoPoly.cc
	src/glu/sgi/libnurbs/nurbtess/sampleMonoPoly.h
	src/glu/sgi/libnurbs/nurbtess/sampledLine.cc
	src/glu/sgi/libnurbs/nurbtess/sampledLine.h
	src/glu/sgi/libnurbs/nurbtess/searchTree.cc
	src/glu/sgi/libnurbs/nurbtess/searchTree.h
	src/glu/sgi/libnurbs/nurbtess/zlassert.h
	src/glu/sgi/libtess/README
	src/glu/sgi/libtess/alg-outline
	src/glu/sgi/libtess/dict-list.h
	src/glu/sgi/libtess/dict.c
	src/glu/sgi/libtess/dict.h
	src/glu/sgi/libtess/geom.c
	src/glu/sgi/libtess/memalloc.c
	src/glu/sgi/libtess/memalloc.h
	src/glu/sgi/libtess/mesh.c
	src/glu/sgi/libtess/mesh.h
	src/glu/sgi/libtess/normal.h
	src/glu/sgi/libtess/priorityq-heap.c
	src/glu/sgi/libtess/priorityq-heap.h
	src/glu/sgi/libtess/priorityq-sort.h
	src/glu/sgi/libtess/priorityq.c
	src/glu/sgi/libtess/priorityq.h
	src/glu/sgi/libtess/render.c
	src/glu/sgi/libtess/render.h
	src/glu/sgi/libtess/sweep.h
	src/glu/sgi/libtess/tess.h
	src/glu/sgi/libtess/tessmono.c
	src/glu/sgi/libtess/tessmono.h
	src/glu/sgi/libutil/error.c
	src/glu/sgi/libutil/glue.c
	src/glu/sgi/libutil/gluint.h
	src/glu/sgi/libutil/project.c
	src/glu/sgi/libutil/registry.c
2007-02-01 11:50:36 +01:00
Julien Cristau
7549426a16 Sync Section and Priority for all packages with the override. 2007-01-28 18:18:38 +01:00
Thierry Reding
6dcb9a3434 Give credit where credit is due. 2007-01-11 15:09:23 +01:00
Thierry Reding
e5a31c00ec libosmesa6{,-dev} replace libgl1-mesa-swx11{,-dev} and mesa-common-dev.
libosmesa6 and libosmesa6-dev are now the only packages to contain OSMesa
libraries and header files so they can be installed independent of which libGL
is installed. They statically link in the software rasterization code.
2007-01-11 15:06:42 +01:00
Thierry Reding
00295242fd mesa-common-dev needs to replace libgl1-mesa-swx11-dev and libgl1-mesa-dev.
The GLX headers were previously shipped in both packages and have been moved
to mesa-common-dev.
2007-01-11 14:56:48 +01:00
Thierry Reding
21b6ed7c29 Build the DRI modules with the default optimization flags. 2007-01-11 14:40:10 +01:00
Thierry Reding
01894cbf10 Revert the previous changes to the libgl1-mesa-{glx,swx11} shlibs. 2007-01-10 15:23:29 +01:00
Thierry Reding
28cad2b9d9 Bump libgl1-mesa-glx, libgl1-mesa-swx11 and libosmesa6 shlibs files. 2007-01-10 13:55:19 +01:00
Thierry Reding
71d7b7dbe7 Drop noop line. 2007-01-08 13:36:25 +01:00
Thierry Reding
4563723db1 Make sure all files in the mesa-swx11-source package have permissions 0644. 2007-01-08 13:36:16 +01:00
Thierry Reding
0bce6a1899 Compile with -O2 optimization instead of -O3 which might lead to problems. 2007-01-08 11:43:25 +01:00
Thierry Reding
e71d6dbd9c Make debugging symbol packages depend on the corresponding binary package and
put them into the libdevel section.
2007-01-08 11:41:02 +01:00
Thierry Reding
132ecd19f3 Do not build any linux*-static configuration with -fPIC. 2007-01-08 10:07:08 +01:00
Thierry Reding
a404143f4c Add patches 04_cleanup-osmesa-configs and 05_static-nonpic.
04_cleanup-osmesa-configs makes the OSMesa configurations behave as expected.
That is respect the OPT_FLAGS, PIC_FLAGS, ARCH_FLAGS and DEFINES variables.
The patch also makes the files more consistent by inheriting from more general
configurations.

05_static-nonpic fixes the linux-static configuration to not use -fPIC for
compiling code because it would violate Debian policy.
2007-01-08 08:35:42 +01:00
Julien Cristau
44467ca45e * Drop obsolete depends on xlibs. 2007-01-05 15:44:51 +01:00
Julien Cristau
f70ea0747d Import changelog entry from the 6.5.1-0.5 NMU. 2007-01-04 21:30:49 +01:00
Thierry Reding
c619abf18a Hijack the package (set XSF as maintainer, add myself to uploaders). \o/ 2007-01-04 16:35:14 +01:00
Julien Cristau
6da1323437 * Non-maintainer upload.
* Build with -fno-strict-aliasing to fix misbuild of i965_dri.so
  (closes: #394311).  Thanks to Michel Dänzer for the fix, and to Ryan
  Richter for the report and testing.
2007-01-03 16:59:06 +01:00
Julien Cristau
1dd29785cf Import changes from the mesa 6.5.1-0.4 NMU. 2007-01-03 13:43:46 +01:00
Julien Cristau
5681987ee4 Import changes from the mesa 6.5.1-0.3 NMU. 2007-01-03 13:41:57 +01:00
Thierry Reding
6eeb18fc68 Build the i915tex DRI module on the i386 and amd64 architectures. 2006-12-05 00:45:42 +00:00
Thierry Reding
01c90575b4 Add missing changelog entry and bug closer. 2006-12-04 07:23:14 +00:00
Thierry Reding
32e9cb0275 Update to new upstream release (6.5.2). 2006-12-02 23:46:07 +00:00
Thierry Reding
017bade93c Update to latest upstream release candidate (6.5.2 RC3). 2006-12-01 00:16:33 +00:00
Thierry Reding
c9c79e7cae Add manpages to the mesa-utils package. 2006-11-29 18:07:26 +00:00
Thierry Reding
777d41dd07 Mark the latest changelog entries as NMUs. 2006-11-26 02:40:01 +00:00
Thierry Reding
6238c30913 Revert maintainer and uploaders fields. Integrate latest NMUs into the
changelog and be a little more verbose in the debian/rules rewrite
changelog entries.
2006-11-26 02:38:31 +00:00
Thierry Reding
db164ab514 Update to latest upstream release candidate. 2006-11-22 19:50:34 +00:00
Thierry Reding
c72ef17731 Add libOSMesa16 and libOSMesa32 entries to libosmesa6.shlibs so packages
linking against those libraries will get the correct dependencies.
2006-11-22 19:47:56 +00:00
Thierry Reding
8dbee7867f Use the new upstream minstall utility to install files and directories. Using
/usr/bin/install would result in a symlink's target being copied instead of
the symlink.
2006-11-18 21:28:07 +00:00
Thierry Reding
f403108f5f Fix typo in changelog. libdrm2-dev is not a package. 2006-11-18 21:22:52 +00:00
Thierry Reding
223a97f92a Bump build-dependency on libdrm-dev (>= 2.2.0). 2006-11-18 21:21:18 +00:00
Thierry Reding
bb44a8ae1f Update to latest upstream release candidate.
Update patches.
2006-11-18 17:59:25 +00:00
Thierry Reding
b5a5062176 Target the mesa package at experimental until etch is released. 2006-11-18 17:50:44 +00:00
Thierry Reding
50faa32ce3 Move the code to choose which configurations to build to a separate script in
order to keep debian/rules cleaner.
2006-11-10 09:00:00 +00:00
Thierry Reding
b6caed527c Also add release notes of version 6.5.1 and the release notes index. 2006-11-10 08:50:35 +00:00
Thierry Reding
d5ef77353b Build Mesa utility programs (glxdemo, glxgears, glxheads, glxinfo) together
with the DRI/GLX-enabled libGL. Don't build the utilities on CPU-optimized
configurations.
2006-11-10 08:40:03 +00:00
Thierry Reding
336beba81b Update Debian changelog. 2006-11-02 21:20:33 +00:00
Thierry Reding
5d23a7905c Add code to provide a mesa-utils package since those utilities are shipped in
the MesaDemos tarball.
2006-11-02 21:05:29 +00:00
Thierry Reding
143dfcc904 Make mesa-common-dev depend on libx11-dev to provide Xlib.h and Xutil.h needed
by the GLX headers.
2006-11-01 07:54:40 +00:00
Thierry Reding
e076cd42f0 Bug #387706 should also be closed because we move libOSMesa to libosmesa6 and
statically link in the software rasterization code.
2006-10-25 00:17:42 +00:00
Thierry Reding
5bed38974e Close 392715 because we now ship the contents of the three Mesa tarballs in
the original source.
2006-10-24 14:45:18 +00:00
Thierry Reding
35bc4b82ff Since the original tarball is repackaged to include the three upstream
tarballs (MesaDemos, MesaGLUT and MesaLib), remove files that are not supposed
to be there.

Note that when importing initially, some files were not even added to the SVN
repository because SVN ignored them. These were configs/diffs~ and
docs/RELNOTES-6.1~. I removed those from the tarball as well.
2006-10-24 14:33:30 +00:00
Thierry Reding
4e5d870f72 Make libosmesa6-dev binNMU-safe again (mesa-common-dev is Architecture: all). 2006-10-24 14:29:11 +00:00
Thierry Reding
83def94db5 Make libgl1-mesa-dev Architecture: all, because all we ship with it is a
symbolic link. Make it binNMU-safe by making it depend on libgl1-mesa-glx and
libgl1-mesa-dri both >= ${Source-Version} instead of exact versions.

Add packages containing debugging symbols for libgl1-mesa-swx11,
libgl1-mesa-glx and libgl1-mesa-dri.
2006-10-24 12:16:16 +00:00
Thierry Reding
9d74c1ef2a -fno-strict-aliasing actually *does* fix #394311 according to the submitter. 2006-10-24 10:31:28 +00:00
Thierry Reding
6023d4bdb5 Build with -fno-strict-aliasing, which should fix bug #394311. 2006-10-24 10:29:21 +00:00
Thierry Reding
5e38f566f2 Provide libgl-dev as alternative to the mesa-common-dev dependency of the
libosmesa6-dev package.
2006-10-23 16:45:00 +00:00
Thierry Reding
b57341a78b Move the glx*.h headers from libgl1-mesa(-swx11)-dev into mesa-common-dev
because both packages provide identical files.
2006-10-23 16:43:41 +00:00
Thierry Reding
910c32c0e9 Install the osmesa.h header in the libosmesa6-dev package where it belongs,
now that all OSMesa libraries have been split off into libosmesa6{,-dev}.

Don't make libosmesa6-dev depend on libgl1-mesa-swx11-dev anymore because it
no longer needs a libGL, only the gl.h header provided by mesa-common-dev.
2006-10-23 16:02:22 +00:00
Thierry Reding
e49456d8d8 Don't force -fPIC everywhere, because it seems only unused on x86 which we
build with assembler optimizations by default, resulting in non-PIC libraries
anyway.
2006-10-23 14:40:10 +00:00
Thierry Reding
c46becc9b3 Move the libOSMesa shlibs entry from libgl1-mesa-swx11 to libosmesa6 because
that's where libOSMesa is now installed.
2006-10-23 08:30:53 +00:00
Thierry Reding
b6e637106f Add the static libGLw and the corresponding headers to the
libgl1-mesa-swx11-dev package again.
2006-10-23 08:23:27 +00:00
Thierry Reding
787cffe3d0 Always force -fPIC. 2006-10-23 08:22:25 +00:00
Thierry Reding
9d914e6809 Make sure the install-source.sh script is executable before trying to run it. 2006-10-20 20:56:41 +00:00
Thierry Reding
4e183c66e9 Add comments to patches and enable the previously disabled patches. 2006-10-20 19:41:00 +00:00
Thierry Reding
b1630fcbe8 Add build-dependency on lesstif2-dev needed to build the GLw libraries. 2006-10-20 19:17:34 +00:00
Thierry Reding
cd44f730cc Enable building the GLw libraries. 2006-10-20 19:07:36 +00:00
Thierry Reding
ce5a39559e Install several documents from the docs subdirectory into the mesa-common-dev
package.
2006-10-20 17:51:36 +00:00
Thierry Reding
ccffaef603 Build architecture-specific static libraries where available. 2006-10-20 12:15:29 +00:00
Thierry Reding
ae41f3a3ee Don't make libgl1-mesa-swx11-dev depend on lesstif2-dev anymore because we
don't ship anything related to LessTif in that package.
2006-10-20 12:06:20 +00:00
Thierry Reding
c7e576d6bf No longer install the default build of libOSMesa in the libgl1-mesa-swx11
package, but in the libosmesa6 package.

Modify the 01_fix-makefile patch to not build libOSMesa on stand-alone builds,
so that it is only created when building OSMesa explicitly.

Build libOSMesa with 8 bits per color channel (the default) in dynamic and
static versions separately from the software rasterization libGL with the
software rasterization code linked in statically so that libOSMesa can run in
parallel with any libGL. This should fix the problem Yann Dirson mentioned a
while ago.

Use the install-source.sh script to install the Mesa sources needed for the
mesa-swx11-source package instead of doing it in the debian/rules file itself.
2006-10-20 07:56:11 +00:00
Thierry Reding
f069b2812e Add a set of files to enable an i686 optimized build of the DRI/GLX-enabled
libGL and the DRI drivers. Disabled for now.
2006-10-20 07:47:37 +00:00
Thierry Reding
f20ff6213e Add a shell script to install the Mesa sources for the mesa-swx11-source
package.
2006-10-20 07:45:39 +00:00
Thierry Reding
24ff74bdcb Add configurations to build static versions of the default OSMesa library.
In all Debian-specific configurations, include the Debian defaults
configuration after the Mesa configurations and drop the 'override' for all
variables because it is no longer needed.
2006-10-20 07:43:50 +00:00
Thierry Reding
230e79916f Merge in the old Debian changelog entries and the old copyright file. 2006-10-17 19:35:35 +00:00
Thierry Reding
9f14b4db35 Use -march in favor of the deprecated -mcpu. 2006-10-17 19:13:27 +00:00
Thierry Reding
ec916398e7 Don't install libOSMesa development files in the libgl1-mesa-swx11 package. 2006-10-16 14:43:43 +00:00
Thierry Reding
6befad112e Actually do rename debian-static to debian-swx11+glu-static. 2006-10-16 13:54:24 +00:00
Thierry Reding
55ce23b8db Beautify IEEE floating point patch. 2006-10-16 13:34:57 +00:00
Thierry Reding
1292ec1ecf Fix typo in the filename of the IEEE FP on s390 and m68k patch. 2006-10-16 13:11:51 +00:00
Thierry Reding
65a324062f Add patches extracted from older Debian diffs but not applied yet because it's
not certain yet that they are needed.
2006-10-16 13:05:42 +00:00
Thierry Reding
c9db617e0b Make the debian-static a subclass of debian-swx11+glu-default, because that's
what it actually is. Rename it accordingly and add it to SWX11_GLU_CONFIGS.

Install the libOSMesa.so symlink and the libOSMesa static library in the
libgl1-mesa-swx11-dev package.

Add .shlibs files for the libgl1-mesa-swx11, libgl1-mesa-glx and libglu1-mesa
packages.
2006-10-16 13:04:29 +00:00
Thierry Reding
b43137d0cc Build libGLU by default for swx11+glu configurations but not in the
configurations targetting specific CPU's because it is unlikely to result in
an increase in performance.
2006-10-16 11:53:06 +00:00
Thierry Reding
eeca642778 Add versioned build-dependency on dpkg-dev (>= 1.13.19) to make sure the
binary:Version and source:Version substitution variables can be used.
2006-10-16 11:49:46 +00:00
Thierry Reding
5cef6ca36a Move the detection of architecture-specific configurations to the debian/rules
file.

Add the configs target to debian/rules for checking whether the correct
configurations will be built.
2006-10-16 10:03:32 +00:00
Thierry Reding
be2b518f7b Also build a static version of libGLU. 2006-10-16 09:53:30 +00:00
Thierry Reding
1b0d29afbc Rename the CPU optimization configurations to make it clear that they only
build swx11 and GLU.

Build architecture-optimized swx11 and GLU where possible.
2006-10-16 09:39:59 +00:00
Thierry Reding
55cf480c0b Drop the libgl1-mesa-swx11-dbg package until there's a decision as to whether
it is really needed.

Allow more than one type of optimization libraries to be built for any given
architecture. Currently optimization configurations are provided for i386
[i686], alpha [ev5], amd64, powerpc [603], ppc64 and sparc [ultrasparc].
However, only i686 and amd64 are enabled for now for safety.

Add the libgl1-mesa-swx11-i686 for i686 optimized libraries.

Drop the debian-common configuration because it is no longer used.

Don't build libGLU in all configurations, only when needed.
2006-10-16 08:58:05 +00:00
Thierry Reding
84db6912f0 Add missing build-dependencies. 2006-10-15 18:02:33 +00:00
Thierry Reding
7495cc28a0 Only build the i810, i915, i965, sis and unichrome DRI drivers on i386 and
amd64.

Only build the ffb DRI driver on sparc.
2006-10-15 16:17:53 +00:00
Thierry Reding
87744f786b Use STAMP_DIR consistently throughout the debian/rules file.
Make the BUILD_STAMPS targets depend on patch so that when they are built
separately the patches will also be applied. Thanks to Michel Dänzer for
catching this.

Make symlinking the source tree idempotent by adding the -f option to cp.
Thanks again Michel Dänzer.
2006-10-15 14:41:12 +00:00
Thierry Reding
5bcfa4c859 Build only optimized versions of the DRI drivers, only using no optimizations
when not supported.

Add configuration to build the DRI drivers on amd64.
2006-10-15 13:30:22 +00:00
Thierry Reding
8ef731bcd1 Add a patch (00_create-libdir) that fixes the upstream build system to make
sure the LIB_DIR is created or bail out.

Update the 01_fix-makefile patch to only install libGL/libOSMesa if they
exist. Don't make installation dependent on which drivers are built.

Build optimized versions of the swx11 libraries in addition to those that
should work on the least-capable supported processor for the given
architecture.

Have most configurations include debian-default instead of debian-common so
that INSTALL_DIR is correctly defined. debian-common can probably be dropped
anyway.
2006-10-15 13:15:56 +00:00
Thierry Reding
8d02f3c68a Add patch to fix upstream build system to correctly install libOSMesa and
variants. This patch also fixes the build system not to install libGL if only
the OSMesa library is built.

Update *.install files to install more files. Pretty much everything except
debugging and optimized libraries is now built and installed.

Enable building static libraries for inclusion in the -dev packages.
2006-10-15 00:49:41 +00:00
Thierry Reding
b1f8b49e8b Add build-dependency on quilt.
Remove shlibs:Depends substitution variable from -dev packages, which doesn't
make sense.
2006-10-15 00:42:25 +00:00
David Nusinow
75733e4237 Commit diff of 6.5.1-0.2 so we've got a record of it here. 2006-10-14 22:42:57 +00:00
Thierry Reding
6e318e2cd1 Base the Debian OSMesa configurations on linux-osmesa* provided upstream.
Add a configuration for building a static version of OSMesa with 32 bits per
color channel.
2006-10-14 17:04:02 +00:00
Thierry Reding
01e6b84b14 Fix some small inconsistencies involving configuration names. 2006-10-14 16:32:25 +00:00
Thierry Reding
69705d22be Rename the debian-dri-common configuration to debian-dri-default, to make it
consistent with the naming scheme of debian-default.
2006-10-14 16:29:32 +00:00
Thierry Reding
b16d1dcff5 Add a default Debian-specific configuration which overrides settings from the
default Mesa configuration.
2006-10-14 16:28:45 +00:00
Thierry Reding
10c5b5d5ba Comment the Debian-specific configurations. 2006-10-14 16:25:30 +00:00
Thierry Reding
d9c5c170f6 Rename the -default configurations to -any, which is a more appropriate name. 2006-10-14 15:44:15 +00:00
Thierry Reding
32c7138d86 Move the debian/debian-dri configurations to debian-default/debian-dri-default
respectively, and use debian/debian-dri to choose an architecture specific
configuration.
2006-10-14 15:42:59 +00:00
Thierry Reding
d29244d872 Add OSMesa configurations and made fixed several issues here and there. 2006-10-14 15:11:31 +00:00
Thierry Reding
0fca6eda1e Initial version of a new build system for Mesa. 2006-10-14 04:33:41 +00:00
Thierry Reding
1ddf606332 Import Mesa 6.5.1 (MesaLib, MesaDemos, MesaGLUT). 2006-10-14 03:46:41 +00:00
David Nusinow
bc8084da74 Fix goofed patch from before 2006-09-26 01:36:37 +00:00
David Nusinow
5eed400862 Prepare changelog for release 2006-09-26 01:21:59 +00:00
David Nusinow
a37a0959ac * Add patch from Cyril Brulebois to allow package to build on HURD, which
lacks DRI and directfb. This includes not using lib-directfb in the
  build-depends for hurd-i386. It also creates a new debian config,
  debian-indirect, which is used when building for HURD. This config is
  invoked in the debian-dri config on hurd-i386. Thanks to Cyril Brulebois
  for the patch, Michael Banck, Michel Dänzer, and Samuel Thibault for
  input on an appropriate fix. (closes: #358065)
2006-09-26 00:46:14 +00:00
David Nusinow
53845c52e5 * Re-add s390 and m68k to the USE_IEEE test in src/mesa/main/imports.h. This
package seriously needs to store patches somewhere that are easy to find
  and re-apply.
2006-09-26 00:32:06 +00:00
David Nusinow
d429f0b14f * Make sure that libGl looks for the dri drivers in the proper location. Do
this by setting the appropriate variables in the debian config
2006-09-25 02:57:24 +00:00
David Nusinow
02339187ad * Stuff not in the upstream tarballs
* Bump libdrm-dev build-dep to >= 2.0.2
* Add libdrm cflags to the debian-dri config. This allows the build system
  to find drm.h
2006-09-24 22:55:41 +00:00
David Nusinow
827f778525 * Stuff not in the upstream tarballs
+ os2 glut stuff
  + docs/gears.png
2006-09-24 21:54:25 +00:00
David Nusinow
d3fc85eea9 Remove os2 glut stuff. It's not in the tarballs 2006-09-24 21:50:01 +00:00
David Nusinow
9a62963129 Add glut 2006-09-24 21:40:02 +00:00
David Nusinow
a0b2543ba1 Add mesa demos 2006-09-24 21:29:21 +00:00
David Nusinow
387acaac69 * New upstream version 2006-09-24 21:21:15 +00:00
David Nusinow
952b775dbe Rename mesa dir 2006-09-24 21:18:17 +00:00
David Nusinow
eadb76b3f8 Bump to latest mesa in Debian 2006-09-24 21:11:46 +00:00
Steve Langasek
b3f7313ae4 Nuke the directory for an obsolete version of mesa -- no reason to merge
it anywhere, it's already superseded
2006-09-18 23:49:49 +00:00
David Nusinow
0c97d48027 * Install the glx sources with the rest in the sources package. This will
allow building of Xgl
2006-04-08 18:28:29 +00:00
David Nusinow
c4a678de9e Update source package install file, change version number to match reality, and note NMU in changelog 2006-04-07 06:36:53 +00:00
David Nusinow
2c834f4d29 * Don't build now non-existant i830 driver in debian dri configs. Fixes
FTBFS.
2006-04-07 03:11:47 +00:00
David Nusinow
b93d290c9f * Remove set_buffer function from idirectfbgl_mesa.c in directfb driver.
Also remove the line that sets SetBuffer to it. Fixes FTBFS.
2006-04-07 02:22:22 +00:00
David Nusinow
32266bb21a * Re-Add s390 and m68k to the USE_IEEE test in src/mesa/main/imports.h.
I need to submit this upstream.
2006-04-07 01:50:23 +00:00
David Nusinow
cab39103b7 * Increment libdrm-dev build-dep to 2.0.1 2006-04-07 00:38:00 +00:00
David Nusinow
5c56a80ac9 Copy over Debian packaging from 6.4.1 2006-04-07 00:35:30 +00:00
David Nusinow
d0bac31721 Copy vendor drop of Mesa 6.5 over to working branch 2006-04-07 00:30:49 +00:00
David Nusinow
9258e54cfa Move incorrect vendor drop of Mesa 6.5 2006-04-07 00:29:08 +00:00
David Nusinow
ccb68495e0 Vendor drop of Mesa 6.5 2006-04-07 00:24:21 +00:00
David Nusinow
db4236fe0b * Add versioned conflict between libgl1-mesa-dri and xlibmesa-dri so that
the xlibmesa-dri transitional upgrade package works
2006-03-07 02:48:44 +00:00
David Nusinow
a4e43427f8 * Move compatibility packages to the xorg source package. The versioning on
these packages will be too low without an epoch and they definitely fit
  with the xorg package anyway.
2006-02-24 05:43:01 +00:00
David Nusinow
829190abdd * Provide compatibility packages for the Xorg 6.9 mesa packages. This
package will be the only source of mesa packages in Debian for the
  present, and these packages will provide for smooth upgrades and
  compatibility.
2006-02-22 03:22:26 +00:00
David Nusinow
99688cd051 Add m68k to previous fix to fix its FTBFS also 2006-02-11 23:00:27 +00:00
David Nusinow
1ba0a92702 * Add s390 to the USE_IEEE test in src/mesa/main/imports.h.
(closes: #349437)
2006-02-09 01:24:52 +00:00
David Nusinow
065d5a8d17 * Remove makedepend from build-depends. Now we'll just build-dep on xutils
to get the app, which will translate over to our own xorg 7.0 plans.
2006-02-01 00:22:24 +00:00
David Nusinow
3b53c0ac19 * Re-add dh_installdirs call to binary-indep target so that we get
arch-specific dirs for the mesa-swx11-source package
2006-01-30 04:02:11 +00:00
David Nusinow
ed56fe4e82 * mesa-swrast-src.install stop looking for the swx11 dir and look for swrast 2006-01-22 19:50:19 +00:00
David Nusinow
1fbbe807ed Make libglu1-mesa default to depending on libgl1-mesa-glx. Thanks Michel Dänzer for catching this one. 2006-01-22 00:07:07 +00:00
David Nusinow
c3dccfa05b Use appropriate version number for an NMU. Thanks Julien for catching this one 2006-01-21 23:40:34 +00:00
David Nusinow
7703d9293f Incorporate other NMU for xlibs-dev transition 2006-01-21 23:32:52 +00:00
David Nusinow
bcf560e4b8 * Change libgl1-mesa to be named libgl1-mesa-glx 2006-01-19 23:45:36 +00:00
David Nusinow
9d944b501a * Change libgl1-mesa-swrast to be named libgl1-mesa-swx11 2006-01-16 22:19:03 +00:00
David Nusinow
cf013a5384 Add more closers 2006-01-11 04:10:39 +00:00
David Nusinow
2f367491c4 Add closer 2006-01-11 04:00:15 +00:00
David Nusinow
e7d93b62ec * Change libgl1-mesa-swrast Depends on libx11-6-dev to libx11-dev.
(closes: #347205)
* Add closer for packaging new upstream
2006-01-11 03:48:31 +00:00
David Nusinow
a5b309c0c9 Document that we'll be NMU'ing this for modular work 2006-01-06 03:09:12 +00:00
David Nusinow
df46b96ab0 Re-add mesa-6.4.1 which was accidentally deleted 2006-01-03 05:15:27 +00:00
David Nusinow
bda1e332ce Update libs to 7.0 release with packaging 2005-12-30 20:12:45 +00:00
David Nusinow
53b2ad5fd0 Rename mesa lib dir to appropriate version 2005-12-16 04:04:38 +00:00
David Nusinow
b44d9c657d Changelog version bump 2005-12-16 04:03:27 +00:00
David Nusinow
92ef7527d1 * New upstream version (6.4.1)
* Merge changes from Ubuntu version 6.4.1-0ubuntu1
  + Add new files required by xorg-server GL build to mesa-swrast-source.
2005-12-14 01:43:13 +00:00
David Nusinow
c37d6b4ca8 Commit Mesa 6.4 sources and packaging 2005-11-09 02:46:07 +00:00
4065 changed files with 1268975 additions and 580258 deletions

1
.gitignore vendored
View File

@@ -4,6 +4,7 @@
*.ilk
*.o
*.obj
*.os
*.pc
*.pdb
*.pyc

228264
ChangeLog Normal file

File diff suppressed because it is too large Load Diff

143
Makefile
View File

@@ -48,7 +48,7 @@ install:
done
.PHONY: default doxygen clean realclean distclean install linux-directfb-install
.PHONY: default doxygen clean realclean distclean install
# If there's no current configuration file
$(TOP)/configs/current:
@@ -80,8 +80,6 @@ catamount-osmesa-pgi \
darwin \
darwin-fat-32bit \
darwin-fat-all \
darwin-static \
darwin-static-x86ppc \
freebsd \
freebsd-dri \
freebsd-dri-amd64 \
@@ -105,12 +103,12 @@ irix6-n32-static \
irix6-o32 \
irix6-o32-static \
linux \
linux-i965 \
linux-alpha \
linux-alpha-static \
linux-cell \
linux-cell-debug \
linux-debug \
linux-directfb \
linux-dri \
linux-dri-debug \
linux-dri-x86 \
@@ -120,12 +118,13 @@ linux-dri-xcb \
linux-egl \
linux-indirect \
linux-fbdev \
linux-glide \
linux-ia64-icc \
linux-ia64-icc-static \
linux-icc \
linux-icc-static \
linux-llvm \
linux-llvm-debug \
linux-opengl-es \
linux-osmesa \
linux-osmesa-static \
linux-osmesa16 \
@@ -134,9 +133,6 @@ linux-osmesa32 \
linux-ppc \
linux-ppc-static \
linux-profile \
linux-solo \
linux-solo-x86 \
linux-solo-ia64 \
linux-sparc \
linux-sparc5 \
linux-static \
@@ -149,7 +145,6 @@ linux-x86-64 \
linux-x86-64-debug \
linux-x86-64-profile \
linux-x86-64-static \
linux-x86-glide \
linux-x86-profile \
linux-x86-static \
netbsd \
@@ -172,17 +167,20 @@ sunos5-v9 \
sunos5-v9-static \
sunos5-v9-cc-g++ \
ultrix-gcc:
@ if test -f configs/current || test -L configs/current ; then \
echo "Please run 'make realclean' before changing configs" ; \
exit 1 ; \
@ if test -f configs/current -o -L configs/current; then \
if ! cmp configs/$@ configs/current > /dev/null; then \
echo "Please run 'make realclean' before changing configs" ; \
exit 1 ; \
fi ; \
else \
cd configs && rm -f current && ln -s $@ current ; \
fi
(cd configs && rm -f current && ln -s $@ current)
$(MAKE) default
# Rules for making release tarballs
VERSION=7.6.1
VERSION=7.8.1
DIRECTORY = Mesa-$(VERSION)
LIB_NAME = MesaLib-$(VERSION)
DEMO_NAME = MesaDemos-$(VERSION)
@@ -207,8 +205,6 @@ MAIN_FILES = \
$(DIRECTORY)/docs/RELNOTES* \
$(DIRECTORY)/docs/*.spec \
$(DIRECTORY)/include/GL/internal/glcore.h \
$(DIRECTORY)/include/GL/dmesa.h \
$(DIRECTORY)/include/GL/ggimesa.h \
$(DIRECTORY)/include/GL/gl.h \
$(DIRECTORY)/include/GL/glext.h \
$(DIRECTORY)/include/GL/gl_mangle.h \
@@ -221,10 +217,16 @@ MAIN_FILES = \
$(DIRECTORY)/include/GL/mesa_wgl.h \
$(DIRECTORY)/include/GL/mglmesa.h \
$(DIRECTORY)/include/GL/osmesa.h \
$(DIRECTORY)/include/GL/svgamesa.h \
$(DIRECTORY)/include/GL/vms_x_fix.h \
$(DIRECTORY)/include/GL/wglext.h \
$(DIRECTORY)/include/GL/wmesa.h \
$(DIRECTORY)/include/VG/*.h \
$(DIRECTORY)/include/KHR/*.h \
$(DIRECTORY)/src/glsl/Makefile \
$(DIRECTORY)/src/glsl/Makefile.template \
$(DIRECTORY)/src/glsl/SConscript \
$(DIRECTORY)/src/glsl/*/Makefile \
$(DIRECTORY)/src/glsl/*/*.[ch] \
$(DIRECTORY)/src/Makefile \
$(DIRECTORY)/src/mesa/Makefile* \
$(DIRECTORY)/src/mesa/sources.mak \
@@ -240,12 +242,9 @@ MAIN_FILES = \
$(DIRECTORY)/src/mesa/shader/*.[chly] \
$(DIRECTORY)/src/mesa/shader/Makefile \
$(DIRECTORY)/src/mesa/shader/descrip.mms \
$(DIRECTORY)/src/mesa/shader/grammar/*.[ch] \
$(DIRECTORY)/src/mesa/shader/slang/*.[ch] \
$(DIRECTORY)/src/mesa/shader/slang/descrip.mms \
$(DIRECTORY)/src/mesa/shader/slang/library/*.[ch] \
$(DIRECTORY)/src/mesa/shader/slang/library/*.gc \
$(DIRECTORY)/src/mesa/shader/slang/library/*.syn \
$(DIRECTORY)/src/mesa/shader/slang/library/Makefile \
$(DIRECTORY)/src/mesa/swrast/*.[ch] \
$(DIRECTORY)/src/mesa/swrast/descrip.mms \
@@ -263,25 +262,13 @@ MAIN_FILES = \
$(DIRECTORY)/src/mesa/drivers/beos/Makefile \
$(DIRECTORY)/src/mesa/drivers/common/*.[ch] \
$(DIRECTORY)/src/mesa/drivers/common/descrip.mms \
$(DIRECTORY)/src/mesa/drivers/directfb/*.[ch] \
$(DIRECTORY)/src/mesa/drivers/directfb/Makefile \
$(DIRECTORY)/src/mesa/drivers/dos/*.[chS] \
$(DIRECTORY)/src/mesa/drivers/fbdev/Makefile \
$(DIRECTORY)/src/mesa/drivers/fbdev/glfbdev.c \
$(DIRECTORY)/src/mesa/drivers/glide/*.[ch] \
$(DIRECTORY)/src/mesa/drivers/ggi/*.[ch] \
$(DIRECTORY)/src/mesa/drivers/ggi/ggimesa.conf.in \
$(DIRECTORY)/src/mesa/drivers/ggi/default/*.c \
$(DIRECTORY)/src/mesa/drivers/ggi/default/genkgi.conf.in \
$(DIRECTORY)/src/mesa/drivers/ggi/display/*.c \
$(DIRECTORY)/src/mesa/drivers/ggi/display/fbdev.conf.in \
$(DIRECTORY)/src/mesa/drivers/ggi/include/ggi/mesa/*.h \
$(DIRECTORY)/src/mesa/drivers/osmesa/Makefile \
$(DIRECTORY)/src/mesa/drivers/osmesa/Makefile.win \
$(DIRECTORY)/src/mesa/drivers/osmesa/descrip.mms \
$(DIRECTORY)/src/mesa/drivers/osmesa/osmesa.def \
$(DIRECTORY)/src/mesa/drivers/osmesa/*.[ch] \
$(DIRECTORY)/src/mesa/drivers/svga/*.[ch] \
$(DIRECTORY)/src/mesa/drivers/windows/*/*.[ch] \
$(DIRECTORY)/src/mesa/drivers/windows/*/*.def \
$(DIRECTORY)/src/mesa/drivers/x11/Makefile \
@@ -303,12 +290,28 @@ MAIN_FILES = \
$(DIRECTORY)/progs/util/sampleMakefile \
$(DIRECTORY)/windows/VC8/
EGL_FILES = \
$(DIRECTORY)/include/EGL/*.h \
ES_FILES = \
$(DIRECTORY)/include/GLES/*.h \
$(DIRECTORY)/include/GLES2/*.h \
$(DIRECTORY)/src/mesa/glapi/gen/*.xml \
$(DIRECTORY)/src/mesa/glapi/gen/*.py \
$(DIRECTORY)/src/mesa/glapi/gen/*.dtd \
$(DIRECTORY)/src/mesa/es/glapi/Makefile \
$(DIRECTORY)/src/mesa/es/glapi/*.xml \
$(DIRECTORY)/src/mesa/es/glapi/*.py \
$(DIRECTORY)/src/mesa/es/state_tracker/*.[ch] \
$(DIRECTORY)/src/mesa/es/main/*.[ch] \
$(DIRECTORY)/src/mesa/es/main/*.xml \
$(DIRECTORY)/src/mesa/es/main/*.py \
$(DIRECTORY)/src/mesa/es/main/*.dtd \
$(DIRECTORY)/src/mesa/es/Makefile \
$(DIRECTORY)/src/mesa/es/sources.mak \
EGL_FILES = \
$(DIRECTORY)/include/EGL/*.h \
$(DIRECTORY)/src/egl/Makefile \
$(DIRECTORY)/src/egl/*/Makefile \
$(DIRECTORY)/src/egl/*/Makefile.template \
$(DIRECTORY)/src/egl/*/*.[ch] \
$(DIRECTORY)/src/egl/*/*/Makefile \
$(DIRECTORY)/src/egl/*/*/*.[ch] \
@@ -321,6 +324,7 @@ GALLIUM_FILES = \
$(DIRECTORY)/src/gallium/*/Makefile \
$(DIRECTORY)/src/gallium/*/SConscript \
$(DIRECTORY)/src/gallium/*/*/Makefile \
$(DIRECTORY)/src/gallium/*/*/Makefile.egl \
$(DIRECTORY)/src/gallium/*/*/Makefile.template \
$(DIRECTORY)/src/gallium/*/*/SConscript \
$(DIRECTORY)/src/gallium/*/*/*.[ch] \
@@ -339,8 +343,8 @@ DRI_FILES = \
$(DIRECTORY)/include/GL/internal/glcore.h \
$(DIRECTORY)/include/GL/internal/sarea.h \
$(DIRECTORY)/src/glx/Makefile \
$(DIRECTORY)/src/glx/x11/Makefile \
$(DIRECTORY)/src/glx/x11/*.[ch] \
$(DIRECTORY)/src/glx/Makefile \
$(DIRECTORY)/src/glx/*.[ch] \
$(DIRECTORY)/src/mesa/drivers/dri/Makefile \
$(DIRECTORY)/src/mesa/drivers/dri/Makefile.template \
$(DIRECTORY)/src/mesa/drivers/dri/dri.pc.in \
@@ -376,15 +380,6 @@ SGI_GLU_FILES = \
$(DIRECTORY)/src/glu/sgi/libtess/*.[ch] \
$(DIRECTORY)/src/glu/sgi/libutil/*.[ch]
MESA_GLU_FILES = \
$(DIRECTORY)/src/glu/mesa/README[12] \
$(DIRECTORY)/src/glu/mesa/Makefile* \
$(DIRECTORY)/src/glu/mesa/descrip.mms \
$(DIRECTORY)/src/glu/mesa/mms_depend \
$(DIRECTORY)/src/glu/mesa/*.def \
$(DIRECTORY)/src/glu/mesa/depend \
$(DIRECTORY)/src/glu/mesa/*.[ch]
GLW_FILES = \
$(DIRECTORY)/src/glw/*.[ch] \
$(DIRECTORY)/src/glw/Makefile* \
@@ -413,8 +408,22 @@ DEMO_FILES = \
$(DIRECTORY)/progs/demos/*.cxx \
$(DIRECTORY)/progs/demos/*.dat \
$(DIRECTORY)/progs/demos/README \
$(DIRECTORY)/progs/egl/Makefile \
$(DIRECTORY)/progs/egl/*.[ch] \
$(DIRECTORY)/progs/es1/*/Makefile \
$(DIRECTORY)/progs/es1/*/*.[ch] \
$(DIRECTORY)/progs/es2/*/Makefile \
$(DIRECTORY)/progs/es2/*/*.[ch] \
$(DIRECTORY)/progs/openvg/*/Makefile \
$(DIRECTORY)/progs/openvg/*/*.[ch] \
$(DIRECTORY)/progs/fbdev/Makefile \
$(DIRECTORY)/progs/fbdev/glfbdevtest.c \
$(DIRECTORY)/progs/objviewer/*.[ch] \
$(DIRECTORY)/progs/objviewer/*.obj \
$(DIRECTORY)/progs/objviewer/*.mtl \
$(DIRECTORY)/progs/objviewer/*.rgb \
$(DIRECTORY)/progs/objviewer/Makefile \
$(DIRECTORY)/progs/objviewer/README.txt \
$(DIRECTORY)/progs/osdemos/Makefile \
$(DIRECTORY)/progs/osdemos/*.c \
$(DIRECTORY)/progs/xdemos/Makefile* \
@@ -429,11 +438,7 @@ DEMO_FILES = \
$(DIRECTORY)/progs/glsl/*.c \
$(DIRECTORY)/progs/glsl/*.frag \
$(DIRECTORY)/progs/glsl/*.vert \
$(DIRECTORY)/progs/glsl/*.shtest \
$(DIRECTORY)/progs/windml/Makefile.ugl \
$(DIRECTORY)/progs/windml/*.c \
$(DIRECTORY)/progs/windml/*.bmp \
$(DIRECTORY)/progs/ggi/*.c
$(DIRECTORY)/progs/glsl/*.shtest
GLUT_FILES = \
$(DIRECTORY)/include/GL/glut.h \
@@ -445,22 +450,11 @@ GLUT_FILES = \
$(DIRECTORY)/src/glut/glx/*.[ch] \
$(DIRECTORY)/src/glut/beos/*.[ch] \
$(DIRECTORY)/src/glut/beos/*.cpp \
$(DIRECTORY)/src/glut/beos/Makefile \
$(DIRECTORY)/src/glut/dos/*.[ch] \
$(DIRECTORY)/src/glut/dos/PC_HW/*.[chS] \
$(DIRECTORY)/src/glut/ggi/*.[ch] \
$(DIRECTORY)/src/glut/ggi/Makefile \
$(DIRECTORY)/src/glut/fbdev/Makefile \
$(DIRECTORY)/src/glut/fbdev/*[ch] \
$(DIRECTORY)/src/glut/mini/*[ch] \
$(DIRECTORY)/src/glut/mini/glut.pc.in \
$(DIRECTORY)/src/glut/directfb/Makefile \
$(DIRECTORY)/src/glut/directfb/NOTES \
$(DIRECTORY)/src/glut/directfb/*[ch]
$(DIRECTORY)/src/glut/beos/Makefile
DEPEND_FILES = \
$(TOP)/src/mesa/depend \
$(TOP)/src/glx/x11/depend \
$(TOP)/src/glx/depend \
$(TOP)/src/glw/depend \
$(TOP)/src/glut/glx/depend \
$(TOP)/src/glu/sgi/depend
@@ -468,6 +462,7 @@ DEPEND_FILES = \
LIB_FILES = \
$(MAIN_FILES) \
$(ES_FILES) \
$(EGL_FILES) \
$(GALLIUM_FILES) \
$(DRI_FILES) \
@@ -496,9 +491,11 @@ rm_depend:
touch $$dep ; \
done
lib_gz:
rm -f configs/current ; \
rm -f configs/autoconf ; \
rm_config:
rm -f configs/current
rm -f configs/autoconf
lib_gz: rm_config
cd .. ; \
tar -cf $(LIB_NAME).tar $(LIB_FILES) ; \
gzip $(LIB_NAME).tar ; \
@@ -516,9 +513,7 @@ glut_gz:
gzip $(GLUT_NAME).tar ; \
mv $(GLUT_NAME).tar.gz $(DIRECTORY)
lib_bz2:
rm -f configs/current ; \
rm -f configs/autoconf ; \
lib_bz2: rm_config
cd .. ; \
tar -cf $(LIB_NAME).tar $(LIB_FILES) ; \
bzip2 $(LIB_NAME).tar ; \
@@ -536,9 +531,7 @@ glut_bz2:
bzip2 $(GLUT_NAME).tar ; \
mv $(GLUT_NAME).tar.bz2 $(DIRECTORY)
lib_zip:
rm -f configs/current ; \
rm -f configs/autoconf ; \
lib_zip: rm_config
rm -f $(LIB_NAME).zip ; \
cd .. ; \
zip -qr $(LIB_NAME).zip $(LIB_FILES) ; \
@@ -567,5 +560,7 @@ md5:
@-md5sum $(GLUT_NAME).tar.bz2
@-md5sum $(GLUT_NAME).zip
.PHONY: tarballs rm_depend lib_gz demo_gz glut_gz lib_bz2 demo_bz2 \
glut_bz2 lib_zip demo_zip glut_zip md5
.PHONY: tarballs rm_depend rm_config md5 \
lib_gz demo_gz glut_gz \
lib_bz2 demo_bz2 glut_bz2 \
lib_zip demo_zip glut_zip

View File

@@ -23,6 +23,7 @@
import os
import os.path
import sys
import SCons.Util
import common
@@ -32,11 +33,14 @@ import common
default_statetrackers = 'mesa'
if common.default_platform in ('linux', 'freebsd', 'darwin'):
default_drivers = 'softpipe,failover,i915simple,trace,identity,llvmpipe'
default_drivers = 'softpipe,failover,svga,i915,i965,trace,identity,llvmpipe'
default_winsys = 'xlib'
elif common.default_platform in ('winddk',):
default_drivers = 'softpipe,i915simple,trace,identity'
default_drivers = 'softpipe,svga,i915,i965,trace,identity'
default_winsys = 'all'
elif common.default_platform in ('embedded',):
default_drivers = 'softpipe,llvmpipe'
default_winsys = 'xlib'
else:
default_drivers = 'all'
default_winsys = 'all'
@@ -46,9 +50,9 @@ common.AddOptions(opts)
opts.Add(ListVariable('statetrackers', 'state trackers to build', default_statetrackers,
['mesa', 'python', 'xorg']))
opts.Add(ListVariable('drivers', 'pipe drivers to build', default_drivers,
['softpipe', 'failover', 'i915simple', 'i965simple', 'cell', 'trace', 'r300', 'identity', 'llvmpipe']))
['softpipe', 'failover', 'svga', 'i915', 'i965', 'trace', 'r300', 'identity', 'llvmpipe']))
opts.Add(ListVariable('winsys', 'winsys drivers to build', default_winsys,
['xlib', 'intel', 'gdi', 'radeon']))
['xlib', 'vmware', 'intel', 'i965', 'gdi', 'radeon']))
opts.Add(EnumVariable('MSVS_VERSION', 'MS Visual C++ version', None, allowed_values=('7.1', '8.0', '9.0')))
@@ -59,19 +63,36 @@ env = Environment(
ENV = os.environ,
)
if os.environ.has_key('CC'):
env['CC'] = os.environ['CC']
if os.environ.has_key('CFLAGS'):
env['CCFLAGS'] += SCons.Util.CLVar(os.environ['CFLAGS'])
if os.environ.has_key('CXX'):
env['CXX'] = os.environ['CXX']
if os.environ.has_key('CXXFLAGS'):
env['CXXFLAGS'] += SCons.Util.CLVar(os.environ['CXXFLAGS'])
if os.environ.has_key('LDFLAGS'):
env['LINKFLAGS'] += SCons.Util.CLVar(os.environ['LDFLAGS'])
Help(opts.GenerateHelpText(env))
# replicate options values in local variables
debug = env['debug']
dri = env['dri']
llvm = env['llvm']
machine = env['machine']
platform = env['platform']
drawllvm = 'llvmpipe' in env['drivers']
# LLVM support in the Draw module
if drawllvm:
env.Tool('llvm')
if not env.has_key('LLVM_VERSION'):
drawllvm = False
# derived options
x86 = machine == 'x86'
ppc = machine == 'ppc'
gcc = platform in ('linux', 'freebsd', 'darwin')
gcc = platform in ('linux', 'freebsd', 'darwin', 'embedded')
msvc = platform in ('windows', 'winddk')
Export([
@@ -79,7 +100,7 @@ Export([
'x86',
'ppc',
'dri',
'llvm',
'drawllvm',
'platform',
'gcc',
'msvc',
@@ -89,6 +110,10 @@ Export([
#######################################################################
# Environment setup
# Always build trace driver
if 'trace' not in env['drivers']:
env['drivers'].append('trace')
# Includes
env.Append(CPPPATH = [
'#/include',
@@ -97,6 +122,25 @@ env.Append(CPPPATH = [
'#/src/gallium/drivers',
])
if env['msvc']:
env.Append(CPPPATH = ['#include/c99'])
# Embedded
if platform == 'embedded':
env.Append(CPPDEFINES = [
'_POSIX_SOURCE',
('_POSIX_C_SOURCE', '199309L'),
'_SVID_SOURCE',
'_BSD_SOURCE',
'_GNU_SOURCE',
'PTHREADS',
])
env.Append(LIBS = [
'm',
'pthread',
'dl',
])
# Posix
if platform in ('posix', 'linux', 'freebsd', 'darwin'):
@@ -110,6 +154,8 @@ if platform in ('posix', 'linux', 'freebsd', 'darwin'):
'PTHREADS',
'HAVE_POSIX_MEMALIGN',
])
if platform == 'darwin':
env.Append(CPPDEFINES = ['_DARWIN_C_SOURCE'])
env.Append(CPPPATH = ['/usr/X11R6/include'])
env.Append(LIBPATH = ['/usr/X11R6/lib'])
env.Append(LIBS = [
@@ -119,7 +165,6 @@ if platform in ('posix', 'linux', 'freebsd', 'darwin'):
'dl',
])
# DRI
if dri:
env.ParseConfig('pkg-config --cflags --libs libdrm')
@@ -130,13 +175,9 @@ if dri:
'GLX_INDIRECT_RENDERING',
])
# LLVM
if llvm:
# See also http://www.scons.org/wiki/UsingPkgConfig
env.ParseConfig('llvm-config --cflags --ldflags --libs backend bitreader engine instrumentation interpreter ipo')
env.Append(CPPDEFINES = ['MESA_LLVM'])
# Force C++ linkage
env['LINK'] = env['CXX']
# LLVM support in the Draw module
if drawllvm:
env.Append(CPPDEFINES = ['DRAW_LLVM'])
# libGL
if platform in ('linux', 'freebsd', 'darwin'):
@@ -160,8 +201,38 @@ Export('env')
# TODO: Build several variants at the same time?
# http://www.scons.org/wiki/SimultaneousVariantBuilds
if env['platform'] != common.default_platform:
# GLSL code has to be built twice -- one for the host OS, another for the target OS...
host_env = Environment(
# options are ignored
# default tool is used
tools = ['default', 'custom'],
toolpath = ['#scons'],
ENV = os.environ,
)
host_env['platform'] = common.default_platform
host_env['machine'] = common.default_machine
host_env['debug'] = env['debug']
SConscript(
'src/glsl/SConscript',
variant_dir = os.path.join(env['build'], 'host'),
duplicate = 0, # http://www.scons.org/doc/0.97/HTML/scons-user/x2261.html
exports={'env':host_env},
)
SConscript(
'src/SConscript',
variant_dir = env['build'],
duplicate = 0 # http://www.scons.org/doc/0.97/HTML/scons-user/x2261.html
)
env.Default('src')
SConscript(
'progs/SConscript',
variant_dir = os.path.join('progs', env['build']),
duplicate = 0 # http://www.scons.org/doc/0.97/HTML/scons-user/x2261.html
)

258
bin/mklib
View File

@@ -25,6 +25,109 @@
# CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
# Clear CDPATH as the 'cd' command will echo stuff
# to stdout if it is set
unset CDPATH
# Given a list of files, look for .a archives and unpack them.
# Return the original list of files minus the .a files plus the unpacked files.
# first param: name of a temp directory (to be deleted when finished)
# remaining params: list of .o and .a files
expand_archives() {
DIR=$1
shift
FILES=$@
NEWFILES=""
ORIG_DIR=`pwd`
mkdir -p "$DIR"
cd "$DIR"
for FILE in $FILES ; do
case $FILE in
*.a)
# extract the .o files from this .a archive
case $FILE in
/*) ;;
*) FILE="$ORIG_DIR/$FILE" ;;
esac
MEMBERS=`ar t $FILE`
ar x $FILE
for MEMBER in $MEMBERS ; do
NEWFILES="$NEWFILES $DIR/$MEMBER"
done
;;
*)
# other file type, just add to list
NEWFILES="$NEWFILES $FILE"
;;
esac
done
cd "$ORIG_DIR"
echo $NEWFILES
}
# Make static library with 'ar'
# params:
# options to ar
# 1 or 0 to indicate if ranlib should be run
# libname to make
# list of object files
# Return name of library we made
# Example: "make_ar_static_lib -ru 1 libfoo.a foo.o bar.o"
make_ar_static_lib() {
OPTS=$1
shift;
RANLIB=$1
shift;
LIBNAME=$1
shift;
OBJECTS=$@
# remove existing lib, if present
rm -f ${LIBNAME}
# make static lib
ar ${OPTS} ${LIBNAME} ${OBJECTS}
# run ranlib
if [ ${RANLIB} = 1 ] ; then
ranlib ${LIBNAME}
fi
echo ${LIBNAME}
}
# Print usage info.
usage() {
echo 'Usage: mklib [options] objects'
echo 'Create a shared library from object files.'
echo ' -o LIBRARY specifies the name of the resulting library, without'
echo ' the leading "lib" or any suffix.'
echo ' (eg: "-o GL" might result in "libGL.so" being made)'
echo ' -major N specifies major version number (default is 1)'
echo ' -minor N specifies minor version number (default is 0)'
echo ' -patch N specifies patch version number (default is 0)'
echo ' -lLIBRARY specifies a dependency on LIBRARY'
echo ' -LDIR search in DIR for library dependencies at build time'
echo ' -RDIR search in DIR for library dependencies at run time'
echo ' -linker L explicity specify the linker program to use (eg: gcc, g++)'
echo ' Not observed on all systems at this time.'
echo ' -ldflags OPT specify any additional linker flags in OPT'
echo ' -cplusplus link with C++ runtime'
echo ' -static make a static library (default is dynamic/shared)'
echo ' -dlopen make a shared library suitable for dynamic loading'
echo ' -install DIR put resulting library file(s) in DIR'
echo ' -arch ARCH override using `uname` to determine host system'
echo ' -archopt OPT specify an extra achitecture-specific option OPT'
echo ' -altopts OPTS alternate options to override all others'
echo " -noprefix don't prefix library name with 'lib' nor add any suffix"
echo ' -exports FILE only export the symbols listed in FILE'
echo ' -id NAME Sets the id of the dylib (Darwin)'
echo ' -h, --help display this information and exit'
}
#
# Option defaults
#
@@ -52,31 +155,7 @@ while true
do
case $1 in
'-h' | '--help')
echo 'Usage: mklib [options] objects'
echo 'Create a shared library from object files.'
echo ' -o LIBRARY specifies the name of the resulting library, without'
echo ' the leading "lib" or any suffix.'
echo ' (eg: "-o GL" might result in "libGL.so" being made)'
echo ' -major N specifies major version number (default is 1)'
echo ' -minor N specifies minor version number (default is 0)'
echo ' -patch N specifies patch version number (default is 0)'
echo ' -lLIBRARY specifies a dependency on LIBRARY'
echo ' -LDIR search in DIR for library dependencies at build time'
echo ' -RDIR search in DIR for library dependencies at run time'
echo ' -linker L explicity specify the linker program to use (eg: gcc, g++)'
echo ' Not observed on all systems at this time.'
echo ' -ldflags OPT specify any additional linker flags in OPT'
echo ' -cplusplus link with C++ runtime'
echo ' -static make a static library (default is dynamic/shared)'
echo ' -dlopen make a shared library suitable for dynamic loading'
echo ' -install DIR put resulting library file(s) in DIR'
echo ' -arch ARCH override using `uname` to determine host system'
echo ' -archopt OPT specify an extra achitecture-specific option OPT'
echo ' -altopts OPTS alternate options to override all others'
echo " -noprefix don't prefix library name with 'lib' nor add any suffix"
echo ' -exports FILE only export the symbols listed in FILE'
echo ' -id NAME Sets the id of the dylib (Darwin)'
echo ' -h, --help display this information and exit'
usage
exit 1
;;
'-o')
@@ -197,11 +276,11 @@ fi
# Error checking
#
if [ "x${LIBNAME}" = "x" ] ; then
echo "mklib: Error: no library name specified"
echo "mklib: Error: no library name specified (-h for help)"
exit 1
fi
if [ "x${OBJECTS}" = "x" ] ; then
echo "mklib: Error: no object files specified"
echo "mklib: Error: no object files specified (-h for help)"
exit 1
fi
@@ -269,45 +348,24 @@ case $ARCH in
# finish up
FINAL_LIBS="${LIBNAME}"
elif [ $STATIC = 1 ] ; then
# make a static .a library
LIBNAME="lib${LIBNAME}.a" # prefix with "lib", suffix with ".a"
echo "mklib: Making" $ARCH "static library: " ${LIBNAME}
LINK="ar"
OPTS="-ru"
if [ "${ALTOPTS}" ] ; then
OPTS=${ALTOPTS}
fi
rm -f ${LIBNAME}
# expand any .a objects into constituent .o files.
NEWOBJECTS=""
DELETIA=""
for OBJ in $OBJECTS ; do
case $OBJ in
*.a)
# extract the .o files from this .a archive
FILES=`ar t $OBJ`
ar x $OBJ
NEWOBJECTS="$NEWOBJECTS $FILES"
# keep track of temporary .o files and delete them below
DELETIA="$DELETIA $FILES"
;;
*)
# ordinary .o file
NEWOBJECTS="$NEWOBJECTS $OBJ"
;;
esac
done
# expand .a into .o files
NEW_OBJECTS=`expand_archives ${LIBNAME}.obj $OBJECTS`
# make lib
${LINK} ${OPTS} ${LIBNAME} ${NEWOBJECTS}
ranlib ${LIBNAME}
# make static lib
FINAL_LIBS=`make_ar_static_lib ${OPTS} 1 ${LIBNAME} ${NEW_OBJECTS}`
# remove temporary extracted .o files
rm -f ${DELETIA}
# finish up
FINAL_LIBS=${LIBNAME}
rm -rf ${LIBNAME}.obj
else
# make dynamic library
LIBNAME="lib${LIBNAME}" # prefix with "lib"
case $ARCH in 'Linux' | 'GNU' | GNU/*)
OPTS="-Xlinker -Bsymbolic -shared -Wl,-soname,${LIBNAME}.so.${MAJOR}"
@@ -368,9 +426,7 @@ case $ARCH in
if [ $STATIC = 1 ] ; then
LIBNAME="lib${LIBNAME}.a"
echo "mklib: Making SunOS static library: " ${LIBNAME}
rm -f ${LIBNAME}
ar -ruv ${LIBNAME} ${OBJECTS}
FINAL_LIBS=${LIBNAME}
FINAL_LIBS=`make_ar_static_lib -ruc 0 ${LIBNAME} ${OBJECTS}`
else
if [ $NOPREFIX = 0 ] ; then
LIBNAME="lib${LIBNAME}.so"
@@ -489,13 +545,19 @@ case $ARCH in
${LINK} ${OPTS} ${LDFLAGS} -o ${LIBNAME} ${OBJECTS} ${DEPS}
FINAL_LIBS=${LIBNAME}
elif [ $STATIC = 1 ] ; then
# make a static .a library
STLIB="lib${LIBNAME}.a"
echo "mklib: Making FreeBSD static library: " ${STLIB}
rm -f ${STLIB}
ar cq ${STLIB} ${OBJECTS}
ranlib ${STLIB}
FINAL_LIBS=${STLIB}
# expand .a into .o files
NEW_OBJECTS=`expand_archives ${STLIB}.obj $OBJECTS`
FINAL_LIBS=`make_ar_static_lib cq 1 ${STLIB} ${NEW_OBJECTS}`
# remove temporary extracted .o files
rm -rf ${STLIB}.obj
else
# make dynamic library
SHLIB="lib${LIBNAME}.so.${MAJOR}"
OPTS="-shared -Wl,-soname,${SHLIB}"
if [ "${ALTOPTS}" ] ; then
@@ -513,10 +575,7 @@ case $ARCH in
if [ $STATIC = 1 ] ; then
LIBNAME="lib${LIBNAME}_pic.a"
echo "mklib: Making NetBSD PIC static library: " ${LIBNAME}
rm -f ${LIBNAME}
ar cq ${LIBNAME} ${OBJECTS}
ranlib ${LIBNAME}
FINAL_LIBS=${LIBNAME}
FINAL_LIBS=`make_ar_static_lib cq 1 ${LIBNAME} ${OBJECTS}`
else
LIBNAME="lib${LIBNAME}.so.${MAJOR}.${MINOR}"
echo "mklib: Making NetBSD PIC shared library: " ${LIBNAME}
@@ -529,9 +588,7 @@ case $ARCH in
'IRIX' | 'IRIX64')
if [ $STATIC = 1 ] ; then
LIBNAME="lib${LIBNAME}.a"
rm -f ${LIBNAME}
ar rc ${LIBNAME} ${OBJECTS}
FINAL_LIBS=${LIBNAME}
FINAL_LIBS=`make_ar_static_lib rc 0 ${LIBNAME} ${OBJECTS}`
else
LIBNAME="lib${LIBNAME}.so" # prefix with "lib", suffix with ".so"
@@ -582,9 +639,7 @@ case $ARCH in
if [ $STATIC = 1 ] ; then
LIBNAME="lib${LIBNAME}.a"
echo "mklib: Making HP-UX static library: " ${LIBNAME}
rm -f ${LIBNAME}
ar -ruv ${LIBNAME} ${OBJECTS}
FINAL_LIBS=${LIBNAME}
FINAL_LIBS=`make_ar_static_lib -ruv 0 ${LIBNAME} ${OBJECTS}`
else
# HP uses a .2 for their current GL/GLU libraries
if [ ${LIBNAME} = "GL" -o ${LIBNAME} = "GLU" ] ; then
@@ -614,8 +669,7 @@ case $ARCH in
if [ $STATIC = 1 ] ; then
LIBNAME="lib${LIBNAME}.a"
echo "mklib: Making AIX static library: " ${LIBNAME}
ar -ruv ${X64} ${LIBNAME} ${OBJECTS}
FINAL_LIBS=${LIBNAME}
FINAL_LIBS=`make_ar_static_lib -ruv 0 ${LIBNAME} ${OBJECTS}`
else
EXPFILE="lib${LIBNAME}.exp"
LIBNAME="lib${LIBNAME}.a" # shared objects are still stored in the .a libraries
@@ -666,9 +720,7 @@ case $ARCH in
if [ $STATIC = 1 ] ; then
LIBNAME="lib${LIBNAME}.a"
echo "mklib: Making OSF/1 static library: " ${LIBNAME}
rm -f ${LIBNAME}
ar -ruv ${LIBNAME} ${OBJECTS}
FINAL_LIBS=${LIBNAME}
FINAL_LIBS=`make_ar_static_lib -ruv 0 ${LIBNAME} ${OBJECTS}`
else
VERSION="${MAJOR}.${MINOR}"
LIBNAME="lib${LIBNAME}.so"
@@ -691,12 +743,20 @@ case $ARCH in
if [ $STATIC = 1 ] ; then
LIBNAME="lib${LIBNAME}.a"
echo "mklib: Making Darwin static library: " ${LIBNAME}
LINK="ar"
OPTS="-ruvs"
if [ "${ALTOPTS}" ] ; then
OPTS=${ALTOPTS}
fi
${LINK} ${OPTS} ${LIBNAME} ${OBJECTS}
# expand .a into .o files
NEW_OBJECTS=`expand_archives ${LIBNAME}.obj $OBJECTS`
# make static lib
FINAL_LIBS=`make_ar_static_lib ${OPTS} 1 ${LIBNAME} ${NEW_OBJECTS}`
# remove temporary extracted .o files
rm -rf ${LIBNAME}.obj
FINAL_LIBS=${LIBNAME}
else
# On Darwin a .bundle is used for a library that you want to dlopen
@@ -755,16 +815,14 @@ case $ARCH in
'LynxOS')
LIBNAME="lib${LIBNAME}.a"
echo "mklib: Making LynxOS static library: " ${LIBNAME}
rm -f ${LIBNAME}
ar ru ${LIBNAME} ${OBJECTS}
FINAL_LIBS=${LIBNAME}
FINAL_LIBS=`make_ar_static_lib -ru 0 ${LIBNAME} ${OBJECTS}`
;;
'BeOS')
if [ $STATIC = 1 ] ; then
LIBNAME="lib${LIBNAME}.a"
echo "mklib: Making BeOS static library: " ${LIBNAME}
ar -cru "${LIBNAME}" ${OBJECTS}
FINAL_LIBS=`make_ar_static_lib -cru 0 ${LIBNAME} ${OBJECTS}`
else
LIBNAME="lib${LIBNAME}.so"
echo "mklib: Making BeOS shared library: " ${LIBNAME}
@@ -843,9 +901,7 @@ case $ARCH in
if [ $STATIC = 1 ] ; then
LIBNAME="lib${LIBNAME}.a"
echo "mklib: Making AIX GCC static library: " ${LIBNAME}
rm -f ${LIBNAME}
ar ru ${LIBNAME} ${OBJECTS}
FINAL_LIBS=${LIBNAME}
FINAL_LIBS=`make_ar_static_lib ru 0 ${LIBNAME} ${OBJECTS}`
else
LIBNAME="lib${LIBNAME}.so" # prefix with "lib", suffix with ".so"
echo "mklib: Making AIX GCC shared library: " ${LIBNAME}
@@ -866,9 +922,7 @@ case $ARCH in
fi
LIBNAME="lib${LIBNAME}.a"
echo "mklib: Making static library for Ultrix: " ${LIBNAME}
rm -f ${LIBNAME}
ar ru ${LIBNAME} ${OBJECTS}
FINAL_LIBS="${LIBNAME}"
FINAL_LIBS=`make_ar_static_lib ru 0 ${LIBNAME} ${OBJECTS}`
;;
CYGWIN*)
@@ -888,17 +942,20 @@ case $ARCH in
LIBNAME="lib${LIBNAME}" # prefix with "lib"
if [ $STATIC = 1 ] ; then
echo "mklib: Making" $ARCH "static library: " ${LIBNAME}.a
LINK="ar"
LIBNAME=${LIBNAME}.a
echo "mklib: Making" $ARCH "static library: " ${LIBNAME}
OPTS="-ru"
if [ "${ALTOPTS}" ] ; then
OPTS=${ALTOPTS}
fi
# make lib
${LINK} ${OPTS} ${LIBNAME}.a ${OBJECTS}
ranlib ${LIBNAME}.a
# finish up
FINAL_LIBS=${LIBNAME}.a
# expand .a into .o files
NEW_OBJECTS=`expand_archives ${LIBNAME}.obj $OBJECTS`
FINAL_LIBS=`make_ar_static_lib ${OPTS} 1 ${LIBNAME} ${NEW_OBJECTS}`
# remove temporary extracted .o files
rm -rf ${LIBNAME}.obj
else
OPTS="-shared -Wl,--enable-auto-image-base -Wl,-export-all -Wl,--out-implib=${LIBNAME}-${MAJOR}.dll.a"
if [ "${ALTOPTS}" ] ; then
@@ -920,6 +977,11 @@ case $ARCH in
# make lib
${LINK} ${OPTS} ${LDFLAGS} -o ${CYGNAME}-${MAJOR}.dll ${OBJECTS} ${DEPS}
# make build fail if link failed
es=$?
if [ "$es" -ne "0" ]; then
exit $es
fi
# make usual symlinks
ln -s ${LIBNAME}-${MAJOR}.dll.a ${LIBNAME}.dll.a
# finish up
@@ -936,9 +998,7 @@ case $ARCH in
if [ $STATIC = 1 ] ; then
LIBNAME="lib${LIBNAME}.a"
echo "mklib: Making static library for example arch: " ${LIBNAME}
rm -f ${LIBNAME}
ar rv ${LIBNAME} ${OBJECTS}
FINAL_LIBS="${LIBNAME}"
FINAL_LIBS=`make_ar_static_lib rv 0 ${LIBNAME} ${OBJECTS}`
else
LIBNAME="lib${LIBNAME}.so" # prefix with "lib", suffix with ".so"
echo "mklib: Making shared library for example arch: " ${LIBNAME}

View File

@@ -1,366 +0,0 @@
#!/usr/bin/env python
##########################################################################
#
# Copyright 2008 Tungsten Graphics, Inc., Cedar Park, Texas.
# All Rights Reserved.
#
# Permission is hereby granted, free of charge, to any person obtaining a
# copy of this software and associated documentation files (the
# "Software"), to deal in the Software without restriction, including
# without limitation the rights to use, copy, modify, merge, publish,
# distribute, sub license, and/or sell copies of the Software, and to
# permit persons to whom the Software is furnished to do so, subject to
# the following conditions:
#
# The above copyright notice and this permission notice (including the
# next paragraph) shall be included in all copies or substantial portions
# of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
# IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR
# ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
# TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
# SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#
##########################################################################
import os.path
import sys
import struct
import Image # http://www.pythonware.com/products/pil/
PIPE_FORMAT_LAYOUT_RGBAZS = 0
PIPE_FORMAT_LAYOUT_YCBCR = 1
PIPE_FORMAT_LAYOUT_DXT = 2
PIPE_FORMAT_LAYOUT_MIXED = 3
PIPE_FORMAT_COMP_R = 0
PIPE_FORMAT_COMP_G = 1
PIPE_FORMAT_COMP_B = 2
PIPE_FORMAT_COMP_A = 3
PIPE_FORMAT_COMP_0 = 4
PIPE_FORMAT_COMP_1 = 5
PIPE_FORMAT_COMP_Z = 6
PIPE_FORMAT_COMP_S = 7
PIPE_FORMAT_TYPE_UNKNOWN = 0
PIPE_FORMAT_TYPE_FLOAT = 1
PIPE_FORMAT_TYPE_UNORM = 2
PIPE_FORMAT_TYPE_SNORM = 3
PIPE_FORMAT_TYPE_USCALED = 4
PIPE_FORMAT_TYPE_SSCALED = 5
PIPE_FORMAT_TYPE_SRGB = 6
PIPE_FORMAT_TYPE_FIXED = 7
def _PIPE_FORMAT_RGBAZS( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, EXP2, TYPE ):
return ((PIPE_FORMAT_LAYOUT_RGBAZS << 0) |\
((SWZ) << 2) |\
((SIZEX) << 14) |\
((SIZEY) << 17) |\
((SIZEZ) << 20) |\
((SIZEW) << 23) |\
((EXP2) << 26) |\
((TYPE) << 29) )
def _PIPE_FORMAT_SWZ( SWZX, SWZY, SWZZ, SWZW ):
return (((SWZX) << 0) | ((SWZY) << 3) | ((SWZZ) << 6) | ((SWZW) << 9))
def _PIPE_FORMAT_RGBAZS_1( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, TYPE ):
return _PIPE_FORMAT_RGBAZS( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, 0, TYPE )
def _PIPE_FORMAT_RGBAZS_2( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, TYPE ):
_PIPE_FORMAT_RGBAZS( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, 1, TYPE )
def _PIPE_FORMAT_RGBAZS_8( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, TYPE ):
return _PIPE_FORMAT_RGBAZS( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, 3, TYPE )
def _PIPE_FORMAT_RGBAZS_64( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, TYPE ):
return _PIPE_FORMAT_RGBAZS( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, 6, TYPE )
def _PIPE_FORMAT_MIXED( SWZ, SIZEX, SIZEY, SIZEZ, SIZEW, SIGNX, SIGNY, SIGNZ, SIGNW, NORMALIZED, SCALE8 ):
return ((PIPE_FORMAT_LAYOUT_MIXED << 0) |\
((SWZ) << 2) |\
((SIZEX) << 14) |\
((SIZEY) << 17) |\
((SIZEZ) << 20) |\
((SIZEW) << 23) |\
((SIGNX) << 26) |\
((SIGNY) << 27) |\
((SIGNZ) << 28) |\
((SIGNW) << 29) |\
((NORMALIZED) << 30) |\
((SCALE8) << 31) )
_PIPE_FORMAT_R001 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_1 )
_PIPE_FORMAT_RG01 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_1 )
_PIPE_FORMAT_RGB1 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_B, PIPE_FORMAT_COMP_1 )
_PIPE_FORMAT_RGBA = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_B, PIPE_FORMAT_COMP_A )
_PIPE_FORMAT_ARGB = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_A, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_B )
_PIPE_FORMAT_ABGR = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_A, PIPE_FORMAT_COMP_B, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_R )
_PIPE_FORMAT_BGRA = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_B, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_A )
_PIPE_FORMAT_1RGB = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_1, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_B )
_PIPE_FORMAT_1BGR = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_1, PIPE_FORMAT_COMP_B, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_R )
_PIPE_FORMAT_BGR1 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_B, PIPE_FORMAT_COMP_G, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_1 )
_PIPE_FORMAT_0000 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0 )
_PIPE_FORMAT_000R = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_R )
_PIPE_FORMAT_RRR1 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_1 )
_PIPE_FORMAT_RRRR = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_R )
_PIPE_FORMAT_RRRG = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_R, PIPE_FORMAT_COMP_G )
_PIPE_FORMAT_Z000 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_Z, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0 )
_PIPE_FORMAT_0Z00 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_Z, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0 )
_PIPE_FORMAT_SZ00 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_S, PIPE_FORMAT_COMP_Z, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0 )
_PIPE_FORMAT_ZS00 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_Z, PIPE_FORMAT_COMP_S, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0 )
_PIPE_FORMAT_S000 = _PIPE_FORMAT_SWZ( PIPE_FORMAT_COMP_S, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0, PIPE_FORMAT_COMP_0 )
def _PIPE_FORMAT_YCBCR( REV ):
return ((PIPE_FORMAT_LAYOUT_YCBCR << 0) |\
((REV) << 2) )
def _PIPE_FORMAT_DXT( LEVEL, RSIZE, GSIZE, BSIZE, ASIZE ):
return ((PIPE_FORMAT_LAYOUT_DXT << 0) | \
((LEVEL) << 2) | \
((RSIZE) << 5) | \
((GSIZE) << 8) | \
((BSIZE) << 11) | \
((ASIZE) << 14) )
PIPE_FORMAT_NONE = _PIPE_FORMAT_RGBAZS_1 ( _PIPE_FORMAT_0000, 0, 0, 0, 0, PIPE_FORMAT_TYPE_UNKNOWN )
PIPE_FORMAT_A8R8G8B8_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_ARGB, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_X8R8G8B8_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_1RGB, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_B8G8R8A8_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_BGRA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_B8G8R8X8_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_BGR1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_A1R5G5B5_UNORM = _PIPE_FORMAT_RGBAZS_1 ( _PIPE_FORMAT_ARGB, 1, 5, 5, 5, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_A4R4G4B4_UNORM = _PIPE_FORMAT_RGBAZS_1 ( _PIPE_FORMAT_ARGB, 4, 4, 4, 4, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_R5G6B5_UNORM = _PIPE_FORMAT_RGBAZS_1 ( _PIPE_FORMAT_RGB1, 5, 6, 5, 0, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_A2B10G10R10_UNORM = _PIPE_FORMAT_RGBAZS_2 ( _PIPE_FORMAT_ABGR, 1, 5, 5, 5, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_L8_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RRR1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_A8_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_000R, 0, 0, 0, 1, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_I8_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RRRR, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_A8L8_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RRRG, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_L16_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RRR1, 2, 2, 2, 0, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_YCBCR = _PIPE_FORMAT_YCBCR( 0 )
PIPE_FORMAT_YCBCR_REV = _PIPE_FORMAT_YCBCR( 1 )
PIPE_FORMAT_Z16_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_Z000, 2, 0, 0, 0, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_Z32_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_Z000, 4, 0, 0, 0, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_Z32_FLOAT = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_Z000, 4, 0, 0, 0, PIPE_FORMAT_TYPE_FLOAT )
PIPE_FORMAT_S8Z24_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_SZ00, 1, 3, 0, 0, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_Z24S8_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_ZS00, 3, 1, 0, 0, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_X8Z24_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_0Z00, 1, 3, 0, 0, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_Z24X8_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_Z000, 3, 1, 0, 0, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_S8_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_S000, 1, 0, 0, 0, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_R64_FLOAT = _PIPE_FORMAT_RGBAZS_64( _PIPE_FORMAT_R001, 1, 0, 0, 0, PIPE_FORMAT_TYPE_FLOAT )
PIPE_FORMAT_R64G64_FLOAT = _PIPE_FORMAT_RGBAZS_64( _PIPE_FORMAT_RG01, 1, 1, 0, 0, PIPE_FORMAT_TYPE_FLOAT )
PIPE_FORMAT_R64G64B64_FLOAT = _PIPE_FORMAT_RGBAZS_64( _PIPE_FORMAT_RGB1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_FLOAT )
PIPE_FORMAT_R64G64B64A64_FLOAT = _PIPE_FORMAT_RGBAZS_64( _PIPE_FORMAT_RGBA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_FLOAT )
PIPE_FORMAT_R32_FLOAT = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 4, 0, 0, 0, PIPE_FORMAT_TYPE_FLOAT )
PIPE_FORMAT_R32G32_FLOAT = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 4, 4, 0, 0, PIPE_FORMAT_TYPE_FLOAT )
PIPE_FORMAT_R32G32B32_FLOAT = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 4, 4, 4, 0, PIPE_FORMAT_TYPE_FLOAT )
PIPE_FORMAT_R32G32B32A32_FLOAT = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 4, 4, 4, 4, PIPE_FORMAT_TYPE_FLOAT )
PIPE_FORMAT_R32_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 4, 0, 0, 0, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_R32G32_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 4, 4, 0, 0, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_R32G32B32_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 4, 4, 4, 0, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_R32G32B32A32_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 4, 4, 4, 4, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_R32_USCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 4, 0, 0, 0, PIPE_FORMAT_TYPE_USCALED )
PIPE_FORMAT_R32G32_USCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 4, 4, 0, 0, PIPE_FORMAT_TYPE_USCALED )
PIPE_FORMAT_R32G32B32_USCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 4, 4, 4, 0, PIPE_FORMAT_TYPE_USCALED )
PIPE_FORMAT_R32G32B32A32_USCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 4, 4, 4, 4, PIPE_FORMAT_TYPE_USCALED )
PIPE_FORMAT_R32_SNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 4, 0, 0, 0, PIPE_FORMAT_TYPE_SNORM )
PIPE_FORMAT_R32G32_SNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 4, 4, 0, 0, PIPE_FORMAT_TYPE_SNORM )
PIPE_FORMAT_R32G32B32_SNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 4, 4, 4, 0, PIPE_FORMAT_TYPE_SNORM )
PIPE_FORMAT_R32G32B32A32_SNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 4, 4, 4, 4, PIPE_FORMAT_TYPE_SNORM )
PIPE_FORMAT_R32_SSCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 4, 0, 0, 0, PIPE_FORMAT_TYPE_SSCALED )
PIPE_FORMAT_R32G32_SSCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 4, 4, 0, 0, PIPE_FORMAT_TYPE_SSCALED )
PIPE_FORMAT_R32G32B32_SSCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 4, 4, 4, 0, PIPE_FORMAT_TYPE_SSCALED )
PIPE_FORMAT_R32G32B32A32_SSCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 4, 4, 4, 4, PIPE_FORMAT_TYPE_SSCALED )
PIPE_FORMAT_R16_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 2, 0, 0, 0, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_R16G16_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 2, 2, 0, 0, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_R16G16B16_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 2, 2, 2, 0, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_R16G16B16A16_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 2, 2, 2, 2, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_R16_USCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 2, 0, 0, 0, PIPE_FORMAT_TYPE_USCALED )
PIPE_FORMAT_R16G16_USCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 2, 2, 0, 0, PIPE_FORMAT_TYPE_USCALED )
PIPE_FORMAT_R16G16B16_USCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 2, 2, 2, 0, PIPE_FORMAT_TYPE_USCALED )
PIPE_FORMAT_R16G16B16A16_USCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 2, 2, 2, 2, PIPE_FORMAT_TYPE_USCALED )
PIPE_FORMAT_R16_SNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 2, 0, 0, 0, PIPE_FORMAT_TYPE_SNORM )
PIPE_FORMAT_R16G16_SNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 2, 2, 0, 0, PIPE_FORMAT_TYPE_SNORM )
PIPE_FORMAT_R16G16B16_SNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 2, 2, 2, 0, PIPE_FORMAT_TYPE_SNORM )
PIPE_FORMAT_R16G16B16A16_SNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 2, 2, 2, 2, PIPE_FORMAT_TYPE_SNORM )
PIPE_FORMAT_R16_SSCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 2, 0, 0, 0, PIPE_FORMAT_TYPE_SSCALED )
PIPE_FORMAT_R16G16_SSCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 2, 2, 0, 0, PIPE_FORMAT_TYPE_SSCALED )
PIPE_FORMAT_R16G16B16_SSCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 2, 2, 2, 0, PIPE_FORMAT_TYPE_SSCALED )
PIPE_FORMAT_R16G16B16A16_SSCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 2, 2, 2, 2, PIPE_FORMAT_TYPE_SSCALED )
PIPE_FORMAT_R8_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 1, 0, 0, 0, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_R8G8_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 1, 1, 0, 0, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_R8G8B8_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_R8G8B8A8_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_R8G8B8X8_UNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_UNORM )
PIPE_FORMAT_R8_USCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 1, 0, 0, 0, PIPE_FORMAT_TYPE_USCALED )
PIPE_FORMAT_R8G8_USCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 1, 1, 0, 0, PIPE_FORMAT_TYPE_USCALED )
PIPE_FORMAT_R8G8B8_USCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_USCALED )
PIPE_FORMAT_R8G8B8A8_USCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_USCALED )
PIPE_FORMAT_R8G8B8X8_USCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_USCALED )
PIPE_FORMAT_R8_SNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 1, 0, 0, 0, PIPE_FORMAT_TYPE_SNORM )
PIPE_FORMAT_R8G8_SNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 1, 1, 0, 0, PIPE_FORMAT_TYPE_SNORM )
PIPE_FORMAT_R8G8B8_SNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_SNORM )
PIPE_FORMAT_R8G8B8A8_SNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SNORM )
PIPE_FORMAT_R8G8B8X8_SNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SNORM )
PIPE_FORMAT_B6G5R5_SNORM = _PIPE_FORMAT_RGBAZS_1 ( _PIPE_FORMAT_BGR1, 6, 5, 5, 0, PIPE_FORMAT_TYPE_SNORM )
PIPE_FORMAT_A8B8G8R8_SNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_BGRA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SNORM )
PIPE_FORMAT_X8B8G8R8_SNORM = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SNORM )
PIPE_FORMAT_R8_SSCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 1, 0, 0, 0, PIPE_FORMAT_TYPE_SSCALED )
PIPE_FORMAT_R8G8_SSCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 1, 1, 0, 0, PIPE_FORMAT_TYPE_SSCALED )
PIPE_FORMAT_R8G8B8_SSCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_SSCALED )
PIPE_FORMAT_R8G8B8A8_SSCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SSCALED )
PIPE_FORMAT_R8G8B8X8_SSCALED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SSCALED )
PIPE_FORMAT_R32_FIXED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_R001, 4, 0, 0, 0, PIPE_FORMAT_TYPE_FIXED )
PIPE_FORMAT_R32G32_FIXED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RG01, 4, 4, 0, 0, PIPE_FORMAT_TYPE_FIXED )
PIPE_FORMAT_R32G32B32_FIXED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 4, 4, 4, 0, PIPE_FORMAT_TYPE_FIXED )
PIPE_FORMAT_R32G32B32A32_FIXED = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 4, 4, 4, 4, PIPE_FORMAT_TYPE_FIXED )
PIPE_FORMAT_L8_SRGB = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RRR1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_SRGB )
PIPE_FORMAT_A8_L8_SRGB = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RRRG, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SRGB )
PIPE_FORMAT_R8G8B8_SRGB = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 0, PIPE_FORMAT_TYPE_SRGB )
PIPE_FORMAT_R8G8B8A8_SRGB = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGBA, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SRGB )
PIPE_FORMAT_R8G8B8X8_SRGB = _PIPE_FORMAT_RGBAZS_8 ( _PIPE_FORMAT_RGB1, 1, 1, 1, 1, PIPE_FORMAT_TYPE_SRGB )
PIPE_FORMAT_X8UB8UG8SR8S_NORM = _PIPE_FORMAT_MIXED( _PIPE_FORMAT_1BGR, 1, 1, 1, 1, 0, 0, 1, 1, 1, 1 )
PIPE_FORMAT_B6UG5SR5S_NORM = _PIPE_FORMAT_MIXED( _PIPE_FORMAT_BGR1, 6, 5, 5, 0, 0, 1, 1, 0, 1, 0 )
PIPE_FORMAT_DXT1_RGB = _PIPE_FORMAT_DXT( 1, 8, 8, 8, 0 )
PIPE_FORMAT_DXT1_RGBA = _PIPE_FORMAT_DXT( 1, 8, 8, 8, 8 )
PIPE_FORMAT_DXT3_RGBA = _PIPE_FORMAT_DXT( 3, 8, 8, 8, 8 )
PIPE_FORMAT_DXT5_RGBA = _PIPE_FORMAT_DXT( 5, 8, 8, 8, 8 )
formats = {}
for name, value in globals().items():
if name.startswith("PIPE_FORMAT_") and isinstance(value, int):
formats[value] = name
def clip(g):
return min(max(g, 0), 255)
def yuv2rgb(y, u, v):
C = y - 16
D = u - 128
E = v - 128
r = clip(( 298 * C + 409 * E + 128) >> 8)
g = clip(( 298 * C - 100 * D - 208 * E + 128) >> 8)
b = clip(( 298 * C + 516 * D + 128) >> 8)
return r, g, b
def translate_r5g6b5(data):
value, = struct.unpack_from("H", data)
r = ((value >> 11) & 0x1f)*0xff/0x1f
g = ((value >> 5) & 0x3f)*0xff/0x3f
b = ((value >> 0) & 0x1f)*0xff/0x1f
a = 255
return [[(r, g, b, a)]]
def translate_a8r8g8b8(data):
b, g, r, a = struct.unpack_from("BBBB", data)
return [[(r, g, b, a)]]
def translate_x8r8g8b8(data):
b, g, r, x = struct.unpack_from("BBBB", data)
a = 255
return [[(r, g, b, a)]]
def translate_r8g8b8a8(data):
r, g, b, a = struct.unpack_from("BBBB", data)
return [[(r, g, b, a)]]
def translate_ycbcr(data):
y1, u, y2, v = struct.unpack_from("BBBB", data)
r1, g1, b1 = yuv2rgb(y1, u, v)
r2, g2, b2 = yuv2rgb(y1, u, v)
return [[(r1, g1, b1, 255), (r2, g2, b2, 255)]]
def translate_ycbcr_rev(data):
v, y2, u, y1 = struct.unpack_from("BBBB", data)
r1, g1, b1 = yuv2rgb(y1, u, v)
r2, g2, b2 = yuv2rgb(y1, u, v)
return [[(r1, g1, b1, 255), (r2, g2, b2, 255)]]
def translate_x8z24(data):
value, = struct.unpack_from("I", data)
r = g = b = (value & 0xffffff)*0xff/0xffffff
a = 255
return [[(r, g, b, a)]]
def translate_s8z24(data):
value, = struct.unpack_from("I", data)
r = (value & 0xffffff)*0xff/0xffffff
g = value >> 24
b = 0
a = 255
return [[(r, g, b, a)]]
translate = {
PIPE_FORMAT_A8R8G8B8_UNORM: (4, 1, 1, translate_a8r8g8b8),
PIPE_FORMAT_X8R8G8B8_UNORM: (4, 1, 1, translate_x8r8g8b8),
PIPE_FORMAT_B8G8R8A8_UNORM: (4, 1, 1, translate_r8g8b8a8),
PIPE_FORMAT_B8G8R8X8_UNORM: (4, 1, 1, translate_r8g8b8a8),
PIPE_FORMAT_A8B8G8R8_SNORM: (4, 1, 1, translate_r8g8b8a8),
PIPE_FORMAT_R5G6B5_UNORM: (2, 1, 1, translate_r5g6b5),
PIPE_FORMAT_YCBCR: (4, 2, 1, translate_ycbcr),
PIPE_FORMAT_YCBCR_REV: (4, 2, 1, translate_ycbcr_rev),
PIPE_FORMAT_S8Z24_UNORM: (4, 1, 1, translate_s8z24),
PIPE_FORMAT_X8Z24_UNORM: (4, 1, 1, translate_x8z24),
}
def read_header(infile):
header_fmt = "IIII"
header = infile.read(struct.calcsize(header_fmt))
return struct.unpack_from(header_fmt, header)
def process(infilename, outfilename):
sys.stderr.write("%s -> %s\n" % (infilename, outfilename))
infile = open(infilename, "rb")
format, cpp, width, height = read_header(infile)
sys.stderr.write(" %ux%ux%ubpp %s\n" % (width, height, cpp*8, formats[format]))
outimage = Image.new(
mode='RGB',
size=(width, height),
color=(0,0,0))
outpixels = outimage.load()
try:
bsize, bwidth, bheight, translate_func = translate[format]
except KeyError:
sys.stderr.write('error: unsupported format %s\n' % formats[format])
return
for y in range(0, height, bheight):
for x in range(0, width, bwidth):
indata = infile.read(bsize)
outdata = translate_func(indata)
for j in range(bheight):
for i in range(bwidth):
r, g, b, a = outdata[j][i]
outpixels[x+i, y+j] = r, g, b
outimage.save(outfilename, "PNG")
def main():
if sys.platform == 'win32':
# wildcard expansion
from glob import glob
args = []
for arg in sys.argv[1:]:
args.extend(glob(arg))
else:
args = sys.argv[1:]
for infilename in args:
root, ext = os.path.splitext(infilename)
outfilename = root + ".png"
process(infilename, outfilename)
if __name__ == '__main__':
main()

View File

@@ -1,309 +0,0 @@
#!/usr/bin/env python
##########################################################################
#
# Copyright 2008 Tungsten Graphics, Inc., Cedar Park, Texas.
# All Rights Reserved.
#
# Permission is hereby granted, free of charge, to any person obtaining a
# copy of this software and associated documentation files (the
# "Software"), to deal in the Software without restriction, including
# without limitation the rights to use, copy, modify, merge, publish,
# distribute, sub license, and/or sell copies of the Software, and to
# permit persons to whom the Software is furnished to do so, subject to
# the following conditions:
#
# The above copyright notice and this permission notice (including the
# next paragraph) shall be included in all copies or substantial portions
# of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
# OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
# IN NO EVENT SHALL TUNGSTEN GRAPHICS AND/OR ITS SUPPLIERS BE LIABLE FOR
# ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
# TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
# SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
#
##########################################################################
import sys
import optparse
import re
import struct
from gprof2dot import Call, Function, Profile
from gprof2dot import CALLS, SAMPLES, TIME, TIME_RATIO, TOTAL_TIME, TOTAL_TIME_RATIO
from gprof2dot import DotWriter, TEMPERATURE_COLORMAP
__version__ = '0.1'
class ParseError(Exception):
pass
class MsvcDemangler:
# http://www.kegel.com/mangle.html
def __init__(self, symbol):
self._symbol = symbol
self._pos = 0
def lookahead(self):
return self._symbol[self._pos]
def consume(self):
ret = self.lookahead()
self._pos += 1
return ret
def match(self, c):
if self.lookahead() != c:
raise ParseError
self.consume()
def parse(self):
self.match('?')
name = self.parse_name()
qualifications = self.parse_qualifications()
return '::'.join(qualifications + [name])
def parse_name(self):
if self.lookahead() == '?':
return self.consume() + self.consume()
else:
name = self.parse_id()
self.match('@')
return name
def parse_qualifications(self):
qualifications = []
while self.lookahead() != '@':
name = self.parse_id()
qualifications.append(name)
self.match('@')
return qualifications
def parse_id(self):
s = ''
while True:
c = self.lookahead()
if c.isalnum() or c in '_':
s += c
self.consume()
else:
break
return s
def demangle(name):
if name.startswith('_'):
name = name[1:]
idx = name.rfind('@')
if idx != -1 and name[idx+1:].isdigit():
name = name[:idx]
return name
if name.startswith('?'):
demangler = MsvcDemangler(name)
return demangler.parse()
return name
class Reader:
def __init__(self):
self.symbols = []
self.symbol_cache = {}
self.base_addr = None
def read_map(self, mapfile):
# See http://msdn.microsoft.com/en-us/library/k7xkk3e2.aspx
last_addr = 0
last_name = 0
for line in file(mapfile, "rt"):
fields = line.split()
try:
section_offset, name, addr, type, lib_object = fields
except ValueError:
continue
if type != 'f':
continue
section, offset = section_offset.split(':')
addr = int(offset, 16)
self.symbols.append((addr, name))
last_addr = addr
last_name = name
# sort symbols
self.symbols.sort(key = lambda (addr, name): addr)
def lookup_addr(self, addr):
try:
return self.symbol_cache[addr]
except KeyError:
pass
tolerance = 4196
s, e = 0, len(self.symbols)
while s != e:
i = (s + e)//2
start_addr, name = self.symbols[i]
try:
end_addr, next_name = self.symbols[i + 1]
except IndexError:
end_addr = start_addr + tolerance
if addr < start_addr:
e = i
continue
if addr == end_addr:
return next_name, addr - start_addr
if addr > end_addr:
s = i
continue
return name, addr - start_addr
raise ValueError
def lookup_symbol(self, name):
for symbol_addr, symbol_name in self.symbols:
if name == symbol_name:
return symbol_addr
return 0
def read_data(self, data):
profile = Profile()
fp = file(data, "rb")
entry_format = "IIII"
entry_size = struct.calcsize(entry_format)
caller = None
caller_stack = []
while True:
entry = fp.read(entry_size)
if len(entry) < entry_size:
break
caller_addr, callee_addr, samples_lo, samples_hi = struct.unpack(entry_format, entry)
if caller_addr == 0 and callee_addr == 0:
continue
if self.base_addr is None:
ref_addr = self.lookup_symbol('___debug_profile_reference@0')
if ref_addr:
self.base_addr = (caller_addr - ref_addr) & ~(options.align - 1)
else:
self.base_addr = 0
sys.stderr.write('Base addr: %08x\n' % self.base_addr)
samples = (samples_hi << 32) | samples_lo
try:
caller_raddr = caller_addr - self.base_addr
caller_sym, caller_ofs = self.lookup_addr(caller_raddr)
try:
caller = profile.functions[caller_sym]
except KeyError:
caller_name = demangle(caller_sym)
caller = Function(caller_sym, caller_name)
profile.add_function(caller)
caller[CALLS] = 0
caller[SAMPLES] = 0
except ValueError:
caller = None
if not callee_addr:
if caller:
caller[SAMPLES] += samples
else:
callee_raddr = callee_addr - self.base_addr
callee_sym, callee_ofs = self.lookup_addr(callee_raddr)
try:
callee = profile.functions[callee_sym]
except KeyError:
callee_name = demangle(callee_sym)
callee = Function(callee_sym, callee_name)
profile.add_function(callee)
callee[CALLS] = samples
callee[SAMPLES] = 0
else:
callee[CALLS] += samples
if caller is not None:
try:
call = caller.calls[callee.id]
except KeyError:
call = Call(callee.id)
call[CALLS] = samples
caller.add_call(call)
else:
call[CALLS] += samples
if options.verbose:
if not callee_addr:
sys.stderr.write('%s+%u: %u\n' % (caller_sym, caller_ofs, samples))
else:
sys.stderr.write('%s+%u -> %s+%u: %u\n' % (caller_sym, caller_ofs, callee_sym, callee_ofs, samples))
# compute derived data
profile.validate()
profile.find_cycles()
profile.aggregate(SAMPLES)
profile.ratio(TIME_RATIO, SAMPLES)
profile.call_ratios(CALLS)
profile.integrate(TOTAL_TIME_RATIO, TIME_RATIO)
return profile
def main():
parser = optparse.OptionParser(
usage="\n\t%prog [options] [file] ...",
version="%%prog %s" % __version__)
parser.add_option(
'-a', '--align', metavar='NUMBER',
type="int", dest="align", default=16,
help="section alignment")
parser.add_option(
'-m', '--map', metavar='FILE',
type="string", dest="map",
help="map file")
parser.add_option(
'-b', '--base', metavar='FILE',
type="string", dest="base",
help="base addr")
parser.add_option(
'-n', '--node-thres', metavar='PERCENTAGE',
type="float", dest="node_thres", default=0.5,
help="eliminate nodes below this threshold [default: %default]")
parser.add_option(
'-e', '--edge-thres', metavar='PERCENTAGE',
type="float", dest="edge_thres", default=0.1,
help="eliminate edges below this threshold [default: %default]")
parser.add_option(
'-v', '--verbose',
action="count",
dest="verbose", default=0,
help="verbose output")
global options
(options, args) = parser.parse_args(sys.argv[1:])
reader = Reader()
if options.base is not None:
reader.base_addr = int(options.base, 16)
if options.map is not None:
reader.read_map(options.map)
for arg in args:
profile = reader.read_data(arg)
profile.prune(options.node_thres/100.0, options.edge_thres/100.0)
output = sys.stdout
dot = DotWriter(output)
colormap = TEMPERATURE_COLORMAP
dot.graph(profile, colormap)
if __name__ == '__main__':
main()

View File

@@ -12,7 +12,7 @@ import platform as _platform
_platform_map = {
'linux2': 'linux',
'win32': 'winddk',
'win32': 'windows',
}
default_platform = sys.platform
@@ -59,9 +59,8 @@ def AddOptions(opts):
opts.Add(EnumOption('machine', 'use machine-specific assembly code', default_machine,
allowed_values=('generic', 'ppc', 'x86', 'x86_64')))
opts.Add(EnumOption('platform', 'target platform', default_platform,
allowed_values=('linux', 'cell', 'windows', 'winddk', 'wince', 'darwin')))
allowed_values=('linux', 'cell', 'windows', 'winddk', 'wince', 'darwin', 'embedded')))
opts.Add(EnumOption('toolchain', 'compiler toolchain', 'default',
allowed_values=('default', 'crossmingw', 'winsdk', 'winddk')))
opts.Add(BoolOption('llvm', 'use LLVM', 'no'))
opts.Add(BoolOption('dri', 'build DRI drivers', default_dri))

View File

@@ -22,6 +22,8 @@ LDFLAGS = @LDFLAGS@
EXTRA_LIB_PATH = @EXTRA_LIB_PATH@
RADEON_CFLAGS = @RADEON_CFLAGS@
RADEON_LDFLAGS = @RADEON_LDFLAGS@
INTEL_LIBS = @INTEL_LIBS@
INTEL_CFLAGS = @INTEL_CFLAGS@
# Assembler
MESA_ASM_SOURCES = @MESA_ASM_SOURCES@
@@ -52,6 +54,7 @@ GLU_LIB_NAME = @GLU_LIB_NAME@
GLUT_LIB_NAME = @GLUT_LIB_NAME@
GLW_LIB_NAME = @GLW_LIB_NAME@
OSMESA_LIB_NAME = @OSMESA_LIB_NAME@
EGL_LIB_NAME = @EGL_LIB_NAME@
# Globs used to install the lib and all symlinks
GL_LIB_GLOB = @GL_LIB_GLOB@
@@ -59,19 +62,20 @@ GLU_LIB_GLOB = @GLU_LIB_GLOB@
GLUT_LIB_GLOB = @GLUT_LIB_GLOB@
GLW_LIB_GLOB = @GLW_LIB_GLOB@
OSMESA_LIB_GLOB = @OSMESA_LIB_GLOB@
EGL_LIB_GLOB = @EGL_LIB_GLOB@
# Directories to build
LIB_DIR = @LIB_DIR@
SRC_DIRS = @SRC_DIRS@
GLU_DIRS = @GLU_DIRS@
DRIVER_DIRS = @DRIVER_DIRS@
EGL_DRIVERS_DIRS = @EGL_DRIVERS_DIRS@
GALLIUM_DIRS = @GALLIUM_DIRS@
GALLIUM_AUXILIARY_DIRS = @GALLIUM_AUXILIARY_DIRS@
GALLIUM_DRIVERS_DIRS = @GALLIUM_DRIVERS_DIRS@
GALLIUM_WINSYS_DIRS = @GALLIUM_WINSYS_DIRS@
GALLIUM_WINSYS_DRM_DIRS = @GALLIUM_WINSYS_DRM_DIRS@
GALLIUM_STATE_TRACKERS_DIRS = @GALLIUM_STATE_TRACKERS_DIRS@
GALLIUM_AUXILIARIES = $(foreach DIR,$(GALLIUM_AUXILIARY_DIRS),$(TOP)/src/gallium/auxiliary/$(DIR)/lib$(DIR).a)
GALLIUM_AUXILIARIES = $(TOP)/src/gallium/auxiliary/libgallium.a
GALLIUM_DRIVERS = $(foreach DIR,$(GALLIUM_DRIVERS_DIRS),$(TOP)/src/gallium/drivers/$(DIR)/lib$(DIR).a)
# Which subdirs under $(TOP)/progs/ to enter:
@@ -80,7 +84,7 @@ PROGRAM_DIRS = @PROGRAM_DIRS@
# Driver specific build vars
DRI_DIRS = @DRI_DIRS@
WINDOW_SYSTEM = @WINDOW_SYSTEM@
USING_EGL = @USING_EGL@
EGL_DISPLAYS = @EGL_DISPLAYS@
# Dependencies
X11_INCLUDES = @X11_INCLUDES@
@@ -126,6 +130,9 @@ DRI_DRIVER_INSTALL_DIR = @DRI_DRIVER_INSTALL_DIR@
# Where libGL will look for DRI hardware drivers
DRI_DRIVER_SEARCH_DIR = @DRI_DRIVER_SEARCH_DIR@
# EGL driver install directory
EGL_DRIVER_INSTALL_DIR = @EGL_DRIVER_INSTALL_DIR@
# Xorg driver install directory (for xorg state-tracker)
XORG_DRIVER_INSTALL_DIR = @XORG_DRIVER_INSTALL_DIR@
@@ -146,3 +153,6 @@ GLW_PC_LIB_PRIV = @GLW_PC_LIB_PRIV@
GLW_PC_CFLAGS = @GLW_PC_CFLAGS@
OSMESA_PC_REQ = @OSMESA_PC_REQ@
OSMESA_PC_LIB_PRIV = @OSMESA_PC_LIB_PRIV@
EGL_DRI2_CFLAGS = @EGL_DRI2_CFLAGS@
EGL_DRI2_LIBS = @EGL_DRI2_LIBS@

View File

@@ -16,7 +16,7 @@ DEFINES = -D_DARWIN_C_SOURCE -DPTHREADS -D_GNU_SOURCE \
-DGLX_ALIAS_UNSUPPORTED -DGLX_INDIRECT_RENDERING
# -D_GNU_SOURCE - for src/mesa/main ...
# -DGLX_DIRECT_RENDERING - pulls in libdrm stuff in glx/x11
# -DGLX_DIRECT_RENDERING - pulls in libdrm stuff in glx
# -DGLX_USE_APPLEGL - supposed to be used with GLX_DIRECT_RENDERING to use AGL rather than DRM, but doesn't compile
# -DIN_DRI_DRIVER
@@ -49,7 +49,7 @@ GLW_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GL_LIB) -L$(INSTALL_DIR)/$(LIB_DIR) -L$(X
APP_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -L$(INSTALL_DIR)/$(LIB_DIR) -L$(X11_DIR)/$(LIB_DIR) -lX11 -lXmu -lXt -lXi -lm
# omit glw lib for now:
SRC_DIRS = glx/x11 mesa glu glut/glx glew
SRC_DIRS = glsl glx mesa gallium glu glut/glx glew
GLU_DIRS = sgi
DRIVER_DIRS = osmesa
#DRIVER_DIRS = dri

View File

@@ -1,33 +0,0 @@
# Configuration for Darwin / MacOS X, making dynamic libs
include $(TOP)/configs/default
CONFIG_NAME = darwin
# Compiler and flags
CC = cc
CXX = cc
CFLAGS = -arch ppc -arch i386 -isysroot /Developer/SDKs/MacOSX10.4u.sdk \
-I/usr/X11R6/include -O3 -fPIC -fno-common -ffast-math -funroll-loops -fexpensive-optimizations -no-cpp-precomp -dynamic -Ddarwin
CXXFLAGS = -arch ppc -arch i386 -isysroot /Developer/SDKs/MacOSX10.4u.sdk \
-I/usr/X11R6/include -O3 -fPIC -fno-common -ffast-math -funroll-loops -fexpensive-optimizations -no-cpp-precomp -dynamic -Ddarwin
MKLIB_OPTIONS = -archopt "-isysroot /Developer/SDKs/MacOSX10.4u.sdk"
# Library names (actual file names)
GL_LIB_NAME = libGL.dylib
GLU_LIB_NAME = libGLU.dylib
GLUT_LIB_NAME = libglut.dylib
GLW_LIB_NAME = libGLw.dylib
OSMESA_LIB_NAME = libOSMesa.dylib
GL_LIB_DEPS = -L/usr/X11R6/lib -lX11 -lXext -lm -lpthread
OSMESA_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -lGL
GLU_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -lGL
GLUT_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -lGL -lGLU -L/usr/X11R6/lib -lX11 -lXmu -lXi -lXext
GLW_LIB_DEPS = -L/usr/X11R6/lib -lX11 -lXt $(TOP)/lib/GL.dylib
APP_LIB_DEPS = -L$(TOP)/lib -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/X11R6/lib -lX11 -lXmu -lXt -lXi -lm
# omit glw lib for now:
SRC_DIRS = gallium mesa glu glut/glx glew

View File

@@ -9,7 +9,7 @@ CONFIG_NAME = default
# Version info
MESA_MAJOR=7
MESA_MINOR=6
MESA_MINOR=8
MESA_TINY=1
MESA_VERSION = $(MESA_MAJOR).$(MESA_MINOR).$(MESA_TINY)
@@ -55,6 +55,7 @@ GLUT_LIB = glut
GLEW_LIB = GLEW
GLW_LIB = GLw
OSMESA_LIB = OSMesa
EGL_LIB = EGL
# Library names (actual file names)
@@ -64,6 +65,7 @@ GLUT_LIB_NAME = lib$(GLUT_LIB).so
GLEW_LIB_NAME = lib$(GLEW_LIB).a
GLW_LIB_NAME = lib$(GLW_LIB).so
OSMESA_LIB_NAME = lib$(OSMESA_LIB).so
EGL_LIB_NAME = lib$(EGL_LIB).so
# globs used to install the lib and all symlinks
GL_LIB_GLOB = $(GL_LIB_NAME)*
@@ -71,6 +73,7 @@ GLU_LIB_GLOB = $(GLU_LIB_NAME)*
GLUT_LIB_GLOB = $(GLUT_LIB_NAME)*
GLW_LIB_GLOB = $(GLW_LIB_NAME)*
OSMESA_LIB_GLOB = $(OSMESA_LIB_NAME)*
EGL_LIB_GLOB = $(EGL_LIB_NAME)*
# Optional assembly language optimization files for libGL
MESA_ASM_SOURCES =
@@ -83,25 +86,26 @@ MOTIF_CFLAGS = -I/usr/include/Motif1.2
# Directories to build
LIB_DIR = lib
SRC_DIRS = mesa gallium egl gallium/winsys glu glut/glx glew glw
SRC_DIRS = glsl mesa gallium egl gallium/winsys glu glut/glx glew glw
GLU_DIRS = sgi
DRIVER_DIRS = x11 osmesa
# Which subdirs under $(TOP)/progs/ to enter:
PROGRAM_DIRS = demos redbook samples glsl xdemos
PROGRAM_DIRS = demos redbook samples glsl objviewer xdemos
# EGL directories
EGL_DRIVERS_DIRS = demo
# EGL drivers to build
EGL_DRIVERS_DIRS = glx
# Gallium directories and
GALLIUM_DIRS = auxiliary drivers state_trackers
GALLIUM_AUXILIARY_DIRS = rbug draw translate cso_cache pipebuffer tgsi sct rtasm util indices
GALLIUM_AUXILIARIES = $(foreach DIR,$(GALLIUM_AUXILIARY_DIRS),$(TOP)/src/gallium/auxiliary/$(DIR)/lib$(DIR).a)
GALLIUM_DRIVERS_DIRS = softpipe i915simple failover trace identity
GALLIUM_AUXILIARIES = $(TOP)/src/gallium/auxiliary/libgallium.a
GALLIUM_DRIVERS_DIRS = softpipe failover svga i915 i965 r300 trace identity
GALLIUM_DRIVERS = $(foreach DIR,$(GALLIUM_DRIVERS_DIRS),$(TOP)/src/gallium/drivers/$(DIR)/lib$(DIR).a)
GALLIUM_WINSYS_DIRS = xlib egl_xlib
GALLIUM_WINSYS_DRM_DIRS =
GALLIUM_STATE_TRACKERS_DIRS = glx
GALLIUM_WINSYS_DIRS = drm xlib
GALLIUM_WINSYS_DRM_DIRS = swrast
GALLIUM_STATE_TRACKERS_DIRS = glx vega
# native displays EGL should support
EGL_DISPLAYS = x11
# Library dependencies
#EXTRA_LIB_PATH ?=
@@ -126,6 +130,9 @@ DRI_DRIVER_INSTALL_DIR = $(INSTALL_LIB_DIR)/dri
# Where libGL will look for DRI hardware drivers
DRI_DRIVER_SEARCH_DIR = $(DRI_DRIVER_INSTALL_DIR)
# EGL driver install directory
EGL_DRIVER_INSTALL_DIR = $(INSTALL_LIB_DIR)/egl
# Xorg driver install directory (for xorg state-tracker)
XORG_DRIVER_INSTALL_DIR = $(INSTALL_LIB_DIR)/xorg/modules/drivers

View File

@@ -41,15 +41,13 @@ GLW_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -L/usr/local/lib -lGL -lXt -lX11
# Directories
SRC_DIRS = glx/x11 gallium mesa glu glut/glx glew glw
SRC_DIRS = glx gallium mesa glu glut/glx glew glw
DRIVER_DIRS = dri
PROGRAM_DIRS =
WINDOW_SYSTEM=dri
DRM_SOURCE_PATH=$(TOP)/../drm
# ffb and gamma are missing because they have not been converted to use the new
# interface.
DRI_DIRS = i810 i915 i965 mach64 mga r128 r200 r300 radeon tdfx \
unichrome savage sis

View File

@@ -23,11 +23,11 @@ DEFINES = -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE \
X11_INCLUDES = -I/usr/X11R6/include
CFLAGS = -Wall -Wmissing-prototypes -Wdeclaration-after-statement \
$(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) \
$(DEFINES) $(ASM_FLAGS) $(X11_INCLUDES) -std=c99 -ffast-math
-Wpointer-arith $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) \
$(DEFINES) $(ASM_FLAGS) $(X11_INCLUDES) -std=c99 -ffast-math
CXXFLAGS = -Wall $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES) \
$(X11_INCLUDES)
CXXFLAGS = -Wall -Wpointer-arith $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) \
$(DEFINES) $(X11_INCLUDES)
# Work around aliasing bugs - developers should comment this out
CFLAGS += -fno-strict-aliasing

View File

@@ -1,6 +1,6 @@
# linux-cell (non-debug build)
include $(TOP)/configs/default
include $(TOP)/configs/linux
CONFIG_NAME = linux-cell
@@ -25,15 +25,19 @@ OPT_FLAGS = -O3
SDK = /opt/cell/sdk/usr
CFLAGS = $(OPT_FLAGS) -Wall -Winline -Wmissing-prototypes \
-fPIC -m32 -std=c99 -mabi=altivec -maltivec \
-I. -I$(SDK)/include \
-DGALLIUM_CELL -DUSE_XSHM -D_BSD_SOURCE -D_SVID_SOURCE
CXXFLAGS = $(CFLAGS)
COMMON_C_CPP_FLAGS = $(OPT_FLAGS) -Wall -Winline \
-fPIC -m32 -mabi=altivec -maltivec \
-I. -I$(SDK)/include \
-DGALLIUM_CELL $(DEFINES)
CFLAGS = $(COMMON_C_CPP_FLAGS) -Wmissing-prototypes -std=c99
CXXFLAGS = $(COMMON_C_CPP_FLAGS)
# Omitting glw here:
SRC_DIRS = gallium mesa gallium/winsys glu glut/glx glew
SRC_DIRS = glsl mesa gallium gallium/winsys glu glut/glx glew
# Build no traditional Mesa drivers:
DRIVER_DIRS =

View File

@@ -4,5 +4,6 @@ include $(TOP)/configs/linux
CONFIG_NAME = linux-debug
OPT_FLAGS = -g -ansi -pedantic
OPT_FLAGS = -g
CFLAGS += -pedantic
DEFINES += -DDEBUG -DDEBUG_MATH

View File

@@ -1,38 +0,0 @@
# Configuration for DirectFB
include $(TOP)/configs/default
CONFIG_NAME = linux-directfb
# Compiler and flags
CC = gcc
CXX = g++
CFLAGS = -Wall -O3 -ffast-math -fPIC -std=c99 -D_GNU_SOURCE -D_POSIX_SOURCE -D_SVID_SOURCE \
-D_POSIX_C_SOURCE=199309L -D_BSD_SOURCE -DPTHREADS
CXXFLAGS = -Wall -O3 -fPIC -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE -D_BSD_SOURCE
# Work around aliasing bugs - developers should comment this out
CFLAGS += -fno-strict-aliasing
CXXFLAGS += -fno-strict-aliasing
HAVE_X86 = $(shell uname -m | grep 'i[3-6]86' >/dev/null && echo yes)
ifeq ($(HAVE_X86), yes)
CFLAGS += -DUSE_X86_ASM -DUSE_MMX_ASM -DUSE_3DNOW_ASM -DUSE_SSE_ASM
CXXFLAGS += -DUSE_X86_ASM -DUSE_MMX_ASM -DUSE_3DNOW_ASM -DUSE_SSE_ASM
MESA_ASM_SOURCES = $(X86_SOURCES)
GLAPI_ASM_SOURCES = $(X86_API)
endif
# Directories
SRC_DIRS = gallium mesa glu glut/directfb glew
GLU_DIRS = sgi
DRIVER_DIRS = directfb
PROGRAM_DIRS = demos directfb
# Library/program dependencies
GL_LIB_DEPS = -lm -lpthread
GLUT_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GL_LIB) -l$(GLU_LIB)
APP_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GL_LIB) -l$(GLU_LIB) -l$(GLUT_LIB)

View File

@@ -51,17 +51,23 @@ GL_LIB_DEPS = $(EXTRA_LIB_PATH) -lX11 -lXext -lXxf86vm -lXdamage -lXfixes \
# Directories
SRC_DIRS := glx/x11 egl $(SRC_DIRS)
SRC_DIRS := glx egl $(SRC_DIRS)
PROGRAM_DIRS := egl $(PROGRAM_DIRS)
# EGL directories
EGL_DRIVERS_DIRS = demo glx
EGL_DRIVERS_DIRS = glx
DRIVER_DIRS = dri
WINDOW_SYSTEM = dri
GALLIUM_WINSYS_DIRS = drm
GALLIUM_WINSYS_DRM_DIRS = intel
GALLIUM_WINSYS_DRM_DIRS = vmware intel i965
GALLIUM_STATE_TRACKERS_DIRS = egl
DRI_DIRS = i810 i915 i965 mach64 mga r128 r200 r300 radeon s3v \
savage sis tdfx trident unichrome ffb swrast
DRI_DIRS = i810 i915 i965 mach64 mga r128 r200 r300 radeon \
savage sis tdfx unichrome swrast
INTEL_LIBS = `pkg-config --libs libdrm_intel`
INTEL_CFLAGS = `pkg-config --cflags libdrm_intel`
RADEON_LIBS = `pkg-config --libs libdrm_radeon`
RADEON_CFLAGS = `pkg-config --cflags libdrm_radeon`

View File

@@ -11,6 +11,6 @@ ARCH_FLAGS = -DDEBUG
#DRI_DIRS = i915tex i915
#DRI_DIRS = i965
#DRI_DIRS = radeon r200 r300
#DRI_DIRS = unichrome sis trident
#DRI_DIRS = unichrome sis
#DRI_DIRS = i810 mga r128 tdfx

View File

@@ -16,7 +16,7 @@ LIB_DIR = lib64
# Library/program dependencies
EXTRA_LIB_PATH=-L/usr/X11R6/lib64
# ffb, gamma, and sis are missing because they have not be converted to use
# sis is missing because it has not been converted to use
# the new interface. i810 are missing because there is no x86-64
# system where they could *ever* be used.
#

View File

@@ -47,26 +47,11 @@ DRI_LIB_DEPS = $(EXTRA_LIB_PATH) -lm -lpthread -lexpat -ldl $(LIBDRM_LIB)
GL_LIB_DEPS = $(EXTRA_LIB_PATH) -lX11 -lXext -lXxf86vm -lm -lpthread -ldl \
$(LIBDRM_LIB) $(shell pkg-config --libs xcb) $(shell pkg-config --libs x11-xcb) $(shell pkg-config --libs xcb-glx)
# This is now 0 by default since it seems to confuse the hell out of people
# and generate a lot of extra noise on bugzilla. If you need to build with
# EGL, do 'make linux-dri USING_EGL=1'
USING_EGL=0
# Directories
ifeq ($(USING_EGL), 1)
SRC_DIRS = egl glx/x11 gallium mesa glu glut/glx glew glw
PROGRAM_DIRS = egl
else
SRC_DIRS = glx/x11 gallium mesa glu glut/glx glew glw
SRC_DIRS = glx gallium mesa glu glut/glx glew glw
PROGRAM_DIRS = xdemos
endif
DRIVER_DIRS = dri
WINDOW_SYSTEM=dri
# gamma are missing because they have not been converted to use the new
# interface.
DRI_DIRS = i810 i915 mach64 mga r128 r200 r300 radeon s3v \
savage sis tdfx trident unichrome ffb
DRI_DIRS = i810 i915 mach64 mga r128 r200 r300 radeon \
savage sis tdfx unichrome

View File

@@ -46,12 +46,6 @@ GL_LIB_DEPS = $(EXTRA_LIB_PATH) -lX11 -lXext -lXxf86vm -lXdamage -lXfixes \
$(LIBDRM_LIB)
# This is now 0 by default since it seems to confuse the hell out of people
# and generate a lot of extra noise on bugzilla. If you need to build with
# EGL, do 'make linux-dri USING_EGL=1'
USING_EGL=0
# Directories
SRC_DIRS = gallium mesa gallium/winsys glu egl
PROGRAM_DIRS = egl
@@ -60,6 +54,4 @@ DRIVER_DIRS = dri
WINDOW_SYSTEM = dri
GALLIUM_WINSYS_DIRS = egl_drm
# gamma are missing because they have not been converted to use the new
# interface.
DRI_DIRS = intel

View File

@@ -1,23 +0,0 @@
# Configuration for generic Linux with 3Dfx Glide driver
include $(TOP)/configs/default
CONFIG_NAME = linux-glide
# Compiler and flags
CC = gcc
CXX = g++
CFLAGS = -O3 -ansi -pedantic -fPIC -ffast-math -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE -D_BSD_SOURCE -DUSE_XSHM -DPTHREADS -I/usr/X11R6/include -DFX -I/usr/include/glide -I/usr/local/glide/include
CXXFLAGS = -O3 -ansi -pedantic -fPIC -ffast-math -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE -D_BSD_SOURCE
GLUT_CFLAGS = -fexceptions
# Work around aliasing bugs - developers should comment this out
CFLAGS += -fno-strict-aliasing
CXXFLAGS += -fno-strict-aliasing
# Library/program dependencies
GL_LIB_DEPS = -L/usr/X11R6/lib -lX11 -lXext -L/usr/local/glide/lib -lglide3x -lm -lpthread
GLUT_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/X11R6/lib -lX11 -lXmu -lXt -lXi -lm
GLW_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GL_LIB) -L/usr/X11R6/lib -lXt -lX11
APP_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/local/glide/lib -lglide3x -lm

8
configs/linux-i965 Normal file
View File

@@ -0,0 +1,8 @@
# Configuration for standalone mode i965 debug
include $(TOP)/configs/linux-debug
CONFIG_NAME = linux-i965
GALLIUM_DRIVER_DIRS = i965
GALLIUM_WINSYS_DIRS = drm/i965/xlib

View File

@@ -47,7 +47,7 @@ GL_LIB_DEPS = $(EXTRA_LIB_PATH) -lX11 -lXext -lXxf86vm -lm -lpthread -ldl
# Directories
SRC_DIRS = glx/x11 glu glut/glx glew glw
SRC_DIRS = glx glu glut/glx glew glw
DRIVER_DIRS =
PROGRAM_DIRS =
WINDOW_SYSTEM=dri

View File

@@ -1,18 +1,18 @@
# -*-makefile-*-
# Configuration for Linux and LLVM with debugging info
# Configuration for Linux and LLVM with optimizations
# Builds the llvmpipe gallium driver
include $(TOP)/configs/linux
CONFIG_NAME = linux-llvm
#GALLIUM_AUXILIARY_DIRS += gallivm
# Add llvmpipe driver
GALLIUM_DRIVERS_DIRS += llvmpipe
OPT_FLAGS = -g -ansi -pedantic
DEFINES += -DDEBUG -DDEBUG_MATH -DGALLIUM_LLVMPIPE -DHAVE_UDIS86
OPT_FLAGS = -O3 -ansi -pedantic
ARCH_FLAGS = -m32 -mmmx -msse -msse2 -mstackrealign
DEFINES += -DNDEBUG -DGALLIUM_LLVMPIPE -DDRAW_LLVM -DHAVE_UDIS86
# override -std=c99
CFLAGS += -std=gnu99
@@ -31,7 +31,7 @@ ifeq ($(MESA_LLVM),1)
# LLVM_CFLAGS=`llvm-config --cflags`
LLVM_CXXFLAGS=`llvm-config --cxxflags backend bitreader engine ipo interpreter instrumentation` -Wno-long-long
LLVM_LDFLAGS = $(shell llvm-config --ldflags backend bitreader engine ipo interpreter instrumentation)
LLVM_LIBS = $(shell llvm-config --libs backend bitreader engine ipo interpreter instrumentation)
LLVM_LIBS = $(shell llvm-config --libs backend bitwriter bitreader engine ipo interpreter instrumentation)
MKLIB_OPTIONS=-cplusplus
else
LLVM_CFLAGS=

12
configs/linux-llvm-debug Normal file
View File

@@ -0,0 +1,12 @@
# -*-makefile-*-
# Configuration for Linux and LLVM with debugging info
# Builds the llvmpipe gallium driver
include $(TOP)/configs/linux-llvm
CONFIG_NAME = linux-llvm-debug
OPT_FLAGS = -g -ansi -pedantic
DEFINES += -DDEBUG -UNDEBUG

28
configs/linux-opengl-es Normal file
View File

@@ -0,0 +1,28 @@
# Configuration for OpenGL ES on Linux
include $(TOP)/configs/linux
CONFIG_NAME = linux-opengl-es
# Directories to build
LIB_DIR = lib
SRC_DIRS = egl glsl mesa/es gallium gallium/winsys
PROGRAM_DIRS = es1/screen es1/xegl es2/xegl
# egl st needs this
DEFINES += -DGLX_DIRECT_RENDERING
# no mesa or egl drivers
DRIVER_DIRS =
EGL_DRIVERS_DIRS =
GALLIUM_DRIVERS_DIRS = softpipe
# build libGLES*.so
GALLIUM_STATE_TRACKERS_DIRS = es
# build egl_x11_{swrast,i915}.so
GALLIUM_DRIVERS_DIRS += trace i915
GALLIUM_STATE_TRACKERS_DIRS += egl
GALLIUM_WINSYS_DIRS += drm
GALLIUM_WINSYS_DRM_DIRS += intel swrast

View File

@@ -1,54 +0,0 @@
# Configuration for linux-solo: Linux DRI hardware drivers for fbdev
include $(TOP)/configs/default
CONFIG_NAME = linux-solo
# Compiler and flags
CC = gcc
CXX = g++
WARN_FLAGS = -Wall -Wundef
OPT_FLAGS = -O3 -g
PIC_FLAGS = -fPIC
# Add '-DGLX_USE_TLS' to ARCH_FLAGS to enable TLS support.
ARCH_FLAGS ?=
# DRM and pciaccess
LIBDRM_CFLAGS = $(shell pkg-config --cflags libdrm)
LIBDRM_LIB = $(shell pkg-config --libs libdrm)
PCIACCESS_CFLAGS = $(shell pkg-config --cflags pciaccess)
PCIACCESS_LIB = $(shell pkg-config --libs pciaccess)
DEFINES = -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE \
-D_BSD_SOURCE -D_GNU_SOURCE -DHAVE_POSIX_MEMALIGN \
-DPTHREADS -DUSE_EXTERNAL_DXTN_LIB=1 -DIN_DRI_DRIVER \
-DHAVE_ALIAS
CFLAGS = $(WARN_FLAGS) $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES) \
$(ASM_FLAGS) -std=c99 -ffast-math
CXXFLAGS = $(WARN_FLAGS) $(OPT_FLAGS) $(PIC_FLAGS) $(ARCH_FLAGS) $(DEFINES)
# Work around aliasing bugs - developers should comment this out
CFLAGS += -fno-strict-aliasing
CXXFLAGS += -fno-strict-aliasing
MESA_ASM_SOURCES =
# Library/program dependencies
DRI_LIB_DEPS = -lm -lpthread -lexpat -ldl -L$(TOP)/$(LIB_DIR) $(PCIACCESS_LIB)
GL_LIB_DEPS = -lm -lpthread -ldl
GLU_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GL_LIB) -lm
GLUT_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) -lm
APP_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -lm -lpthread
# Directories
SRC_DIRS = glx/mini gallium mesa glu glut/mini glew
DRIVER_DIRS = dri
PROGRAM_DIRS = miniglx
#DRI_DIRS = ffb gamma sis savage tdfx unichrome fb
DRI_DIRS = i810 i915tex i915 mach64 mga r128 r200 radeon

View File

@@ -1,7 +0,0 @@
# Configuration for linux-solo-ia64: Linux DRI hardware drivers for fbdev
include $(TOP)/configs/linux-solo
CONFIG_NAME = linux-solo-ia64
DRI_DIRS = fb mach64 mga r128 r200 radeon sis tdfx unichrome

View File

@@ -1,10 +0,0 @@
# -*-makefile-*-
# Configuration for linux-solo-x86: Linux hardware drivers for fbdev for x86
include $(TOP)/configs/linux-solo
CONFIG_NAME = linux-solo-x86
ASM_FLAGS = -DUSE_X86_ASM -DUSE_MMX_ASM -DUSE_3DNOW_ASM -DUSE_SSE_ASM
MESA_ASM_SOURCES = $(X86_SOURCES)
GLAPI_ASM_SOURCES = $(X86_API)

View File

@@ -1,28 +0,0 @@
# Configuration for Linux with 3Dfx Glide driver and x86 optimizations
include $(TOP)/configs/default
CONFIG_NAME = linux-x86-glide
# Compiler and flags
CC = gcc
CXX = g++
CFLAGS = -Wall -O3 -ansi -pedantic -fPIC -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE -D_BSD_SOURCE -DUSE_XSHM -DUSE_X86_ASM -DUSE_MMX_ASM -DUSE_3DNOW_ASM -DUSE_SSE_ASM -DPTHREADS -I/usr/X11R6/include -DFX -I/usr/include/glide -I/usr/local/glide/include
CXXFLAGS = -Wall -O3 -ansi -pedantic -fPIC -D_POSIX_SOURCE -D_POSIX_C_SOURCE=199309L -D_SVID_SOURCE -D_BSD_SOURCE
GLUT_CFLAGS = -fexceptions
# Work around aliasing bugs - developers should comment this out
CFLAGS += -fno-strict-aliasing
CXXFLAGS += -fno-strict-aliasing
MESA_ASM_SOURCES = $(X86_SOURCES)
GLAPI_ASM_SOURCES = $(X86_API)
# Library/program dependencies
GL_LIB_DEPS = -L/usr/X11R6/lib -lX11 -lXext -L/usr/local/glide/lib -lglide3x -lm -lpthread
GLUT_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/X11R6/lib -lX11 -lXmu -lXt -lXi -lm
GLW_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GL_LIB) -L/usr/X11R6/lib -lXt -lX11
APP_LIB_DEPS = -L$(TOP)/$(LIB_DIR) -l$(GLUT_LIB) -l$(GLU_LIB) -l$(GL_LIB) -L/usr/local/glide/lib -lglide3x -lm

View File

@@ -18,9 +18,12 @@ AC_CONFIG_AUX_DIR([bin])
AC_CANONICAL_HOST
dnl Versions for external dependencies
LIBDRM_REQUIRED=2.4.3
LIBDRM_REQUIRED=2.4.15
LIBDRM_RADEON_REQUIRED=2.4.17
DRI2PROTO_REQUIRED=1.99.3
DRI2PROTO_REQUIRED=2.1
GLPROTO_REQUIRED=1.4.11
LIBDRM_XORG_REQUIRED=2.4.17
LIBKMS_XORG_REQUIRED=1.0.0
dnl Check for progs
AC_PROG_CPP
@@ -45,6 +48,28 @@ solaris*)
;;
esac
dnl If we're using GCC, make sure that it is at least version 3.3.0. Older
dnl versions are explictly not supported.
if test "x$GCC" = xyes; then
AC_MSG_CHECKING([whether gcc version is sufficient])
major=0
minor=0
GCC_VERSION=`$CC -dumpversion`
if test $? -eq 0; then
major=`echo $GCC_VERSION | cut -d. -f1`
minor=`echo $GCC_VERSION | cut -d. -f1`
fi
if test $major -lt 3 -o $major -eq 3 -a $minor -lt 3 ; then
AC_MSG_RESULT([no])
AC_MSG_ERROR([If using GCC, version 3.3.0 or later is required.])
else
AC_MSG_RESULT([yes])
fi
fi
MKDEP_OPTIONS=-fdepend
dnl Ask gcc where it's keeping its secret headers
if test "x$GCC" = xyes; then
@@ -91,12 +116,22 @@ linux*|*-gnu*|gnu*)
solaris*)
DEFINES="$DEFINES -DPTHREADS -DSVR4"
;;
cygwin*)
DEFINES="$DEFINES -DPTHREADS"
;;
esac
dnl Add flags for gcc and g++
if test "x$GCC" = xyes; then
CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -std=c99 -ffast-math"
# Enable -fvisibility=hidden if using a gcc that supports it
save_CFLAGS="$CFLAGS"
AC_MSG_CHECKING([whether $CC supports -fvisibility=hidden])
CFLAGS="$CFLAGS -fvisibility=hidden"
AC_LINK_IFELSE([AC_LANG_PROGRAM()], AC_MSG_RESULT([yes]),
[CFLAGS="$save_CFLAGS" ; AC_MSG_RESULT([no])]);
# Work around aliasing bugs - developers should comment this out
CFLAGS="$CFLAGS -fno-strict-aliasing"
fi
@@ -243,24 +278,28 @@ GLU_LIB_NAME='lib$(GLU_LIB).'${LIB_EXTENSION}
GLUT_LIB_NAME='lib$(GLUT_LIB).'${LIB_EXTENSION}
GLW_LIB_NAME='lib$(GLW_LIB).'${LIB_EXTENSION}
OSMESA_LIB_NAME='lib$(OSMESA_LIB).'${LIB_EXTENSION}
EGL_LIB_NAME='lib$(EGL_LIB).'${LIB_EXTENSION}
GL_LIB_GLOB='lib$(GL_LIB).*'${LIB_EXTENSION}'*'
GLU_LIB_GLOB='lib$(GLU_LIB).*'${LIB_EXTENSION}'*'
GLUT_LIB_GLOB='lib$(GLUT_LIB).*'${LIB_EXTENSION}'*'
GLW_LIB_GLOB='lib$(GLW_LIB).*'${LIB_EXTENSION}'*'
OSMESA_LIB_GLOB='lib$(OSMESA_LIB).*'${LIB_EXTENSION}'*'
EGL_LIB_GLOB='lib$(EGL_LIB).*'${LIB_EXTENSION}'*'
AC_SUBST([GL_LIB_NAME])
AC_SUBST([GLU_LIB_NAME])
AC_SUBST([GLUT_LIB_NAME])
AC_SUBST([GLW_LIB_NAME])
AC_SUBST([OSMESA_LIB_NAME])
AC_SUBST([EGL_LIB_NAME])
AC_SUBST([GL_LIB_GLOB])
AC_SUBST([GLU_LIB_GLOB])
AC_SUBST([GLUT_LIB_GLOB])
AC_SUBST([GLW_LIB_GLOB])
AC_SUBST([OSMESA_LIB_GLOB])
AC_SUBST([EGL_LIB_GLOB])
dnl
dnl Arch/platform-specific settings
@@ -380,7 +419,7 @@ fi
dnl
dnl Driver configuration. Options are xlib, dri and osmesa right now.
dnl More later: directfb, fbdev, ...
dnl More later: fbdev, ...
dnl
default_driver="xlib"
@@ -414,13 +453,16 @@ esac
dnl
dnl Driver specific build directories
dnl
SRC_DIRS="mesa glew"
dnl this variable will be prepended to SRC_DIRS and is not exported
CORE_DIRS="glsl mesa"
SRC_DIRS="glew"
GLU_DIRS="sgi"
WINDOW_SYSTEM=""
GALLIUM_DIRS="auxiliary drivers state_trackers"
GALLIUM_WINSYS_DIRS=""
GALLIUM_WINSYS_DRM_DIRS=""
GALLIUM_AUXILIARY_DIRS="rbug draw translate cso_cache pipebuffer tgsi sct rtasm util indices"
GALLIUM_DRIVERS_DIRS="softpipe failover trace identity"
GALLIUM_STATE_TRACKERS_DIRS=""
@@ -430,7 +472,7 @@ xlib)
GALLIUM_WINSYS_DIRS="$GALLIUM_WINSYS_DIRS xlib"
;;
dri)
SRC_DIRS="glx/x11 $SRC_DIRS"
SRC_DIRS="$SRC_DIRS glx"
DRIVER_DIRS="dri"
WINDOW_SYSTEM="dri"
GALLIUM_WINSYS_DIRS="$GALLIUM_WINSYS_DIRS drm"
@@ -447,10 +489,7 @@ AC_SUBST([GALLIUM_DIRS])
AC_SUBST([GALLIUM_WINSYS_DIRS])
AC_SUBST([GALLIUM_WINSYS_DRM_DIRS])
AC_SUBST([GALLIUM_DRIVERS_DIRS])
AC_SUBST([GALLIUM_AUXILIARY_DIRS])
AC_SUBST([GALLIUM_STATE_TRACKERS_DIRS])
AC_SUBST([RADEON_CFLAGS])
AC_SUBST([RADEON_LDFLAGS])
dnl
dnl User supplied program configuration
@@ -575,16 +614,10 @@ dri)
# Check for libdrm
PKG_CHECK_MODULES([LIBDRM], [libdrm >= $LIBDRM_REQUIRED])
PKG_CHECK_MODULES([DRI2PROTO], [dri2proto >= $DRI2PROTO_REQUIRED])
GL_PC_REQ_PRIV="libdrm >= $LIBDRM_REQUIRED dri2proto >= $DRI2PROTO_REQUIRED"
PKG_CHECK_MODULES([GLPROTO], [glproto >= $GLPROTO_REQUIRED])
GL_PC_REQ_PRIV="libdrm >= $LIBDRM_REQUIRED dri2proto >= $DRI2PROTO_REQUIRED glproto >= $GLPROTO_REQUIRED"
DRI_PC_REQ_PRIV="libdrm >= $LIBDRM_REQUIRED"
PKG_CHECK_MODULES([LIBDRM_RADEON], [libdrm_radeon libdrm >= $LIBDRM_RADEON_REQUIRED], HAVE_LIBDRM_RADEON=yes, HAVE_LIBDRM_RADEON=no)
if test "$HAVE_LIBDRM_RADEON" = yes; then
RADEON_CFLAGS="-DHAVE_LIBDRM_RADEON=1 $LIBDRM_RADEON_CFLAGS"
RADEON_LDFLAGS=$LIBDRM_RADEON_LIBS
fi
# find the DRI deps for libGL
if test "$x11_pkgconfig" = yes; then
# add xcb modules if necessary
@@ -693,10 +726,6 @@ yes)
;;
esac
dnl Just default to no EGL for now
USING_EGL=0
AC_SUBST([USING_EGL])
dnl Set DRI_DIRS, DEFINES and LIB_DEPS
if test "$mesa_driver" = dri; then
# Use TLS in GLX?
@@ -704,10 +733,6 @@ if test "$mesa_driver" = dri; then
DEFINES="$DEFINES -DGLX_USE_TLS -DPTHREADS"
fi
if test "x$USING_EGL" = x1; then
PROGRAM_DIRS="egl"
fi
# Platform specific settings and drivers to build
case "$host_os" in
linux*)
@@ -719,10 +744,9 @@ if test "$mesa_driver" = dri; then
case "$host_cpu" in
x86_64)
# ffb, gamma, and sis are missing because they have not be
# converted to use the new interface. i810 are missing
# because there is no x86-64 system where they could *ever*
# be used.
# sis is missing because they have not be converted to use
# the new interface. i810 are missing because there is no
# x86-64 system where they could *ever* be used.
if test "x$DRI_DIRS" = "xyes"; then
DRI_DIRS="i915 i965 mach64 mga r128 r200 r300 r600 radeon \
savage tdfx unichrome swrast"
@@ -738,7 +762,7 @@ if test "$mesa_driver" = dri; then
sparc*)
# Build only the drivers for cards that exist on sparc`
if test "x$DRI_DIRS" = "xyes"; then
DRI_DIRS="mach64 r128 r200 r300 r600 radeon ffb swrast"
DRI_DIRS="mach64 r128 r200 r300 r600 radeon swrast"
fi
;;
esac
@@ -754,8 +778,6 @@ if test "$mesa_driver" = dri; then
CXXFLAGS="$CXXFLAGS -ansi -pedantic"
fi
# ffb and gamma are missing because they have not been converted
# to use the new interface.
if test "x$DRI_DIRS" = "xyes"; then
DRI_DIRS="i810 i915 i965 mach64 mga r128 r200 r300 r600 radeon tdfx \
unichrome savage sis swrast"
@@ -776,8 +798,8 @@ if test "$mesa_driver" = dri; then
# default drivers
if test "x$DRI_DIRS" = "xyes"; then
DRI_DIRS="i810 i915 i965 mach64 mga r128 r200 r300 r600 radeon s3v \
savage sis tdfx trident unichrome ffb swrast"
DRI_DIRS="i810 i915 i965 mach64 mga r128 r200 r300 r600 radeon \
savage sis tdfx unichrome swrast"
fi
DRI_DIRS=`echo "$DRI_DIRS" | $SED 's/ */ /g'`
@@ -804,6 +826,29 @@ AC_SUBST([DRI_DIRS])
AC_SUBST([EXPAT_INCLUDES])
AC_SUBST([DRI_LIB_DEPS])
case $DRI_DIRS in
*i915*|*i965*)
PKG_CHECK_MODULES([INTEL], [libdrm_intel >= 2.4.19])
;;
esac
case $DRI_DIRS in
*radeon*|*r200*|*r300*|*r600*)
PKG_CHECK_MODULES([LIBDRM_RADEON],
[libdrm_radeon libdrm >= $LIBDRM_RADEON_REQUIRED],
HAVE_LIBDRM_RADEON=yes,
HAVE_LIBDRM_RADEON=no)
if test "$HAVE_LIBDRM_RADEON" = yes; then
RADEON_CFLAGS="-DHAVE_LIBDRM_RADEON=1 $LIBDRM_RADEON_CFLAGS"
RADEON_LDFLAGS=$LIBDRM_RADEON_LIBS
fi
;;
esac
AC_SUBST([RADEON_CFLAGS])
AC_SUBST([RADEON_LDFLAGS])
dnl
dnl OSMesa configuration
dnl
@@ -888,17 +933,28 @@ AC_ARG_ENABLE([egl],
[enable_egl=yes])
if test "x$enable_egl" = xyes; then
SRC_DIRS="$SRC_DIRS egl"
EGL_LIB_DEPS="$DLOPEN_LIBS -lpthread"
EGL_DRIVERS_DIRS=""
if test "$enable_static" != yes; then
# build egl_glx when libGL is built
if test "$mesa_driver" != osmesa; then
EGL_DRIVERS_DIRS="glx"
fi
if test "$x11_pkgconfig" = yes; then
PKG_CHECK_MODULES([EGL], [x11])
EGL_LIB_DEPS="$EGL_LIBS"
else
# should check these...
EGL_LIB_DEPS="$X_LIBS -lX11"
# build egl_dri2 when xcb-dri2 is available
PKG_CHECK_MODULES([EGL_DRI2], [x11-xcb xcb-dri2 xcb-xfixes libdrm],
[have_xcb_dri2=yes],[have_xcb_dri2=no])
if test "$have_xcb_dri2" = yes; then
EGL_DRIVERS_DIRS="$EGL_DRIVERS_DIRS dri2"
fi
fi
if test "$with_demos" = yes; then
PROGRAM_DIRS="$PROGRAM_DIRS egl"
fi
EGL_LIB_DEPS="$EGL_LIB_DEPS $DLOPEN_LIBS"
fi
AC_SUBST([EGL_LIB_DEPS])
AC_SUBST([EGL_DRIVERS_DIRS])
dnl
dnl GLU configuration
@@ -1144,7 +1200,14 @@ yes)
GALLIUM_STATE_TRACKERS_DIRS=glx
;;
dri)
test "x$enable_egl" = xyes && GALLIUM_STATE_TRACKERS_DIRS=egl
GALLIUM_STATE_TRACKERS_DIRS="dri"
if test "x$enable_egl" = xyes; then
GALLIUM_STATE_TRACKERS_DIRS="$GALLIUM_STATE_TRACKERS_DIRS egl"
fi
# Have only tested st/xorg on 1.6.0 servers
PKG_CHECK_MODULES(XORG, [xorg-server >= 1.6.0 libdrm >= $LIBDRM_XORG_REQUIRED libkms >= $LIBKMS_XORG_REQUIRED],
HAVE_XORG="yes"; GALLIUM_STATE_TRACKERS_DIRS="$GALLIUM_STATE_TRACKERS_DIRS xorg",
HAVE_XORG="no")
;;
esac
;;
@@ -1155,19 +1218,69 @@ yes)
test -d "$srcdir/src/gallium/state_trackers/$tracker" || \
AC_MSG_ERROR([state tracker '$tracker' doesn't exist])
if test "$tracker" = egl && test "x$enable_egl" != xyes; then
AC_MSG_ERROR([cannot build egl state tracker without EGL library])
fi
if test "$tracker" = xorg; then
PKG_CHECK_MODULES(XEXT, [xextproto >= 7.0.99.1],
HAVE_XEXTPROTO_71="yes"; DEFINES="$DEFINES -DHAVE_XEXTPROTO_71",
HAVE_XEXTPROTO_71="no")
fi
case "$tracker" in
egl)
if test "x$enable_egl" != xyes; then
AC_MSG_ERROR([cannot build egl state tracker without EGL library])
fi
;;
xorg)
PKG_CHECK_MODULES([LIBDRM_XORG], [libdrm >= $LIBDRM_XORG_REQUIRED])
PKG_CHECK_MODULES([LIBKMS_XORG], [libkms >= $LIBKMS_XORG_REQUIRED])
HAVE_XORG="yes"
;;
es)
# mesa/es is required to build es state tracker
CORE_DIRS="$CORE_DIRS mesa/es"
;;
esac
done
GALLIUM_STATE_TRACKERS_DIRS="$state_trackers"
;;
esac
if test "x$HAVE_XORG" = xyes; then
PKG_CHECK_MODULES(XEXT, [xextproto >= 7.0.99.1],
HAVE_XEXTPROTO_71="yes"; DEFINES="$DEFINES -DHAVE_XEXTPROTO_71",
HAVE_XEXTPROTO_71="no")
fi
AC_ARG_WITH([egl-displays],
[AS_HELP_STRING([--with-egl-displays@<:@=DIRS...@:>@],
[comma delimited native displays libEGL supports, e.g.
"x11,kms" @<:@default=auto@:>@])],
[with_egl_displays="$withval"],
[with_egl_displays=yes])
EGL_DISPLAYS=""
case "$with_egl_displays" in
yes)
if test "x$enable_egl" = xyes && test "x$mesa_driver" != xosmesa; then
EGL_DISPLAYS="x11"
fi
;;
*)
if test "x$enable_egl" != xyes; then
AC_MSG_ERROR([cannot build egl state tracker without EGL library])
fi
# verify the requested driver directories exist
egl_displays=`IFS=', '; echo $with_egl_displays`
for dpy in $egl_displays; do
test -d "$srcdir/src/gallium/state_trackers/egl/$dpy" || \
AC_MSG_ERROR([EGL display '$dpy' does't exist])
done
EGL_DISPLAYS="$egl_displays"
;;
esac
AC_SUBST([EGL_DISPLAYS])
AC_ARG_WITH([egl-driver-dir],
[AS_HELP_STRING([--with-egl-driver-dir=DIR],
[directory for EGL drivers [[default=${libdir}/egl]]])],
[EGL_DRIVER_INSTALL_DIR="$withval"],
[EGL_DRIVER_INSTALL_DIR='${libdir}/egl'])
AC_SUBST([EGL_DRIVER_INSTALL_DIR])
AC_ARG_WITH([xorg-driver-dir],
[AS_HELP_STRING([--with-xorg-driver-dir=DIR],
[Default xorg driver directory[[default=${libdir}/xorg/modules/drivers]]])],
@@ -1190,17 +1303,34 @@ AC_ARG_WITH([max-height],
[AC_MSG_WARN([Large framebuffer: see s_tritemp.h comments.])])]
)
dnl
dnl Gallium SVGA configuration
dnl
AC_ARG_ENABLE([gallium-svga],
[AS_HELP_STRING([--enable-gallium-svga],
[build gallium SVGA @<:@default=disabled@:>@])],
[enable_gallium_svga="$enableval"],
[enable_gallium_svga=auto])
if test "x$enable_gallium_svga" = xyes; then
GALLIUM_WINSYS_DRM_DIRS="$GALLIUM_WINSYS_DRM_DIRS vmware"
GALLIUM_DRIVERS_DIRS="$GALLIUM_DRIVERS_DIRS svga"
elif test "x$enable_gallium_svga" = xauto; then
GALLIUM_DRIVERS_DIRS="$GALLIUM_DRIVERS_DIRS svga"
fi
dnl
dnl Gallium Intel configuration
dnl
AC_ARG_ENABLE([gallium-intel],
[AS_HELP_STRING([--disable-gallium-intel],
[build gallium intel @<:@default=enabled@:>@])],
[AS_HELP_STRING([--enable-gallium-intel],
[build gallium intel @<:@default=disabled@:>@])],
[enable_gallium_intel="$enableval"],
[enable_gallium_intel=yes])
[enable_gallium_intel=auto])
if test "x$enable_gallium_intel" = xyes; then
GALLIUM_WINSYS_DRM_DIRS="$GALLIUM_WINSYS_DRM_DIRS intel"
GALLIUM_DRIVERS_DIRS="$GALLIUM_DRIVERS_DIRS i915simple"
GALLIUM_WINSYS_DRM_DIRS="$GALLIUM_WINSYS_DRM_DIRS intel i965"
GALLIUM_DRIVERS_DIRS="$GALLIUM_DRIVERS_DIRS i915 i965"
elif test "x$enable_gallium_intel" = xauto; then
GALLIUM_DRIVERS_DIRS="$GALLIUM_DRIVERS_DIRS i915 i965"
fi
dnl
@@ -1210,10 +1340,12 @@ AC_ARG_ENABLE([gallium-radeon],
[AS_HELP_STRING([--enable-gallium-radeon],
[build gallium radeon @<:@default=disabled@:>@])],
[enable_gallium_radeon="$enableval"],
[enable_gallium_radeon=no])
[enable_gallium_radeon=auto])
if test "x$enable_gallium_radeon" = xyes; then
GALLIUM_WINSYS_DRM_DIRS="$GALLIUM_WINSYS_DRM_DIRS radeon"
GALLIUM_DRIVERS_DIRS="$GALLIUM_DRIVERS_DIRS r300"
elif test "x$enable_gallium_radeon" = xauto; then
GALLIUM_DRIVERS_DIRS="$GALLIUM_DRIVERS_DIRS r300"
fi
dnl
@@ -1226,9 +1358,23 @@ AC_ARG_ENABLE([gallium-nouveau],
[enable_gallium_nouveau=no])
if test "x$enable_gallium_nouveau" = xyes; then
GALLIUM_WINSYS_DRM_DIRS="$GALLIUM_WINSYS_DRM_DIRS nouveau"
GALLIUM_DRIVERS_DIRS="$GALLIUM_DRIVERS_DIRS nouveau nv04 nv10 nv20 nv30 nv40 nv50"
GALLIUM_DRIVERS_DIRS="$GALLIUM_DRIVERS_DIRS nouveau nv30 nv40 nv50"
fi
dnl
dnl Gallium swrast configuration
dnl
AC_ARG_ENABLE([gallium-swrast],
[AS_HELP_STRING([--enable-gallium-swrast],
[build gallium swrast @<:@default=disabled@:>@])],
[enable_gallium_swrast="$enableval"],
[enable_gallium_swrast=auto])
if test "x$enable_gallium_swrast" = xyes; then
GALLIUM_WINSYS_DRM_DIRS="$GALLIUM_WINSYS_DRM_DIRS swrast"
fi
dnl prepend CORE_DIRS to SRC_DIRS
SRC_DIRS="$CORE_DIRS $SRC_DIRS"
dnl Restore LDFLAGS and CPPFLAGS
LDFLAGS="$_SAVE_LDFLAGS"
@@ -1282,7 +1428,6 @@ if echo "$SRC_DIRS" | grep 'gallium' >/dev/null 2>&1; then
echo " Gallium dirs: $GALLIUM_DIRS"
echo " Winsys dirs: $GALLIUM_WINSYS_DIRS"
echo " Winsys drm dirs:$GALLIUM_WINSYS_DRM_DIRS"
echo " Auxiliary dirs: $GALLIUM_AUXILIARY_DIRS"
echo " Driver dirs: $GALLIUM_DRIVERS_DIRS"
echo " Trackers dirs: $GALLIUM_STATE_TRACKERS_DIRS"
else
@@ -1293,7 +1438,11 @@ dnl Libraries
echo ""
echo " Shared libs: $enable_shared"
echo " Static libs: $enable_static"
echo " EGL: $enable_egl"
if test "$enable_egl" = yes; then
echo " EGL: $EGL_DRIVERS_DIRS"
else
echo " EGL: no"
fi
echo " GLU: $enable_glu"
echo " GLw: $enable_glw (Motif: $enable_motif)"
echo " glut: $enable_glut"

39
debian/README.source vendored Normal file
View File

@@ -0,0 +1,39 @@
------------------------------------------------------
Quick Guide To Patching This Package For The Impatient
------------------------------------------------------
1. Make sure you have quilt installed
2. Unpack the package as usual with "dpkg-source -x"
3. Run the "patch" target in debian/rules
4. Create a new patch with "quilt new" (see quilt(1))
5. Edit all the files you want to include in the patch with "quilt edit"
(see quilt(1)).
6. Write the patch with "quilt refresh" (see quilt(1))
7. Run the "clean" target in debian/rules
Alternatively, instead of using quilt directly, you can drop the patch in to
debian/patches and add the name of the patch to debian/patches/series.
The X Strike Force team maintains X packages in git repositories on
git.debian.org in the pkg-xorg subdirectory. Most upstream packages
are actually maintained in git repositories as well, so they often
just need to be pulled into git.debian.org in a "upstream-*" branch.
The .orig.tar.gz upstream source file could be generated this
"upstream-*" branch in the Debian git repository but it is actually
generated from upstream tarballs directly.
Upstream ships Mesa as 3 different tarballs (MesaLib, MesaGLUT and
MesaDemos) which are re-bundled together into a single .orig.tar.gz.
The Debian packaging is added by creating the "debian-*" git branch
which contains the aforementioned "upstream-*" branch plus the debian/
repository files.
When a patch has to be applied to the Debian package, two solutions
are involved:
* If the patch is available in one of the upstream branches, it
may be git'cherry-picked into the Debian repository. In this
case, it appears directly in the .diff.gz.
* Otherwise, the patch is added to debian/patches/ which is managed
with quilt as documented in /usr/share/doc/quilt/README.source.
Thus, the patching system requires a build dependency on quilt.

1559
debian/changelog vendored Normal file

File diff suppressed because it is too large Load Diff

1
debian/compat vendored Normal file
View File

@@ -0,0 +1 @@
5

355
debian/control vendored Normal file
View File

@@ -0,0 +1,355 @@
Source: mesa
Section: graphics
Priority: optional
Maintainer: Debian X Strike Force <debian-x@lists.debian.org>
Uploaders: David Nusinow <dnusinow@debian.org>, Brice Goglin <bgoglin@debian.org>
Standards-Version: 3.8.4
Build-Depends: debhelper (>= 6.0.7), quilt (>= 0.40), pkg-config,
libdrm-dev (>= 2.4.19) [!hurd-i386], libx11-dev, xutils-dev,
x11proto-gl-dev (>= 1.4.11), libxxf86vm-dev,
libexpat1-dev, lesstif2-dev, dpkg-dev (>= 1.13.19), libxfixes-dev,
libxdamage-dev, libxext-dev, autoconf, automake, x11proto-dri2-dev (>= 2.1),
linux-libc-dev (>= 2.6.31) [!hurd-i386 !kfreebsd-amd64 !kfreebsd-i386]
Vcs-Git: git://git.debian.org/git/pkg-xorg/lib/mesa
Vcs-Browser: http://git.debian.org/?p=pkg-xorg/lib/mesa.git
Homepage: http://mesa3d.sourceforge.net/
Package: libgl1-mesa-swx11
Section: libs
Priority: extra
Architecture: any
Depends: ${shlibs:Depends}, libosmesa6 (>= 6.5.2-1)
Conflicts: mesag3-glide, mesag3-glide2, mesag3+ggi, libgl1, nvidia-glx, mesag3, libgl1-mesa-swrast
Provides: libgl1, mesag3, libgl1-mesa-swrast
Replaces: libgl1, mesag3, libgl1-mesa-swrast
Description: A free implementation of the OpenGL API -- runtime
Mesa is a 3-D graphics library with an API which is very similar to
that of OpenGL. To the extent that Mesa utilizes the OpenGL command
syntax or state machine, it is being used with authorization from
Silicon Graphics, Inc. However, the author makes no claim that Mesa
is in any way a compatible replacement for OpenGL or associated with
Silicon Graphics, Inc.
.
This library provides a pure software rasteriser; it does not provide
a direct rendering-capable library, or one which uses GLX. For that,
please see libgl1-mesa-glx.
.
On Linux, this library is also known as libGL or libGL.so.1.
Package: libgl1-mesa-swx11-dbg
Section: debug
Priority: extra
Architecture: any
Depends: libgl1-mesa-swx11 (= ${binary:Version})
Conflicts: libgl1-mesa-swrast-dbg
Provides: libgl1-mesa-swrast-dbg
Replaces: libgl1-mesa-swrast-dbg
Description: A free implementation of the OpenGL API -- debugging symbols
Mesa is a 3-D graphics library with an API which is very similar to
that of OpenGL. To the extent that Mesa utilizes the OpenGL command
syntax or state machine, it is being used with authorization from
Silicon Graphics, Inc. However, the author makes no claim that Mesa
is in any way a compatible replacement for OpenGL or associated with
Silicon Graphics, Inc.
.
This library provides a pure software rasteriser; it does not provide
a direct rendering-capable library, or one which uses GLX. For that,
please see libgl1-mesa-glx.
.
On Linux, this library is also known as libGL or libGL.so.1.
.
This package contains debugging symbols for the software rasterization GL
library.
Package: libgl1-mesa-swx11-i686
Section: libs
Priority: extra
Architecture: i386 kfreebsd-i386 hurd-i386
Depends: libgl1-mesa-swx11 (= ${binary:Version}), ${shlibs:Depends}
Description: Mesa OpenGL runtime [i686 optimized]
Mesa is a 3-D graphics library with an API which is very similar to
that of OpenGL. To the extent that Mesa utilizes the OpenGL command
syntax or state machine, it is being used with authorization from
Silicon Graphics, Inc. However, the author makes no claim that Mesa
is in any way a compatible replacement for OpenGL or associated with
Silicon Graphics, Inc.
.
This library provides a pure software rasteriser; it does not provide
a direct rendering-capable library, or one which uses GLX. For that,
please see libgl1-mesa-glx.
.
On Linux, this library is also known as libGL or libGL.so.1.
.
This set of libraries is optimized for i686 machines and will only be used if
you are running a 2.6 kernel on an i686 class CPU. This includes Pentium Pro,
Pentium II/II/IV, Celeron CPU's and similar class CPU's (including clones
such as AMD Athlon/Opteron, VIA C3 Nehemiah, but not VIA C3 Ezla).
Package: libgl1-mesa-swx11-dev
Section: libdevel
Priority: extra
Architecture: any
Depends: libgl1-mesa-swx11 (= ${binary:Version}), libc6-dev, libx11-dev, libxext6, mesa-common-dev (= ${binary:Version})
Provides: libgl-dev, mesag-dev, libgl1-mesa-swrast-dev
Conflicts: mesa-dev, libgl-dev, mesag3 (<< 3.1-1), nvidia-glx-dev, mesag-dev, libgl1-mesa-swrast-dev
Replaces: libgl-dev, mesag-dev, libgl1-mesa-swrast-dev
Description: A free implementation of the OpenGL API -- development files
This package provides the development environment required for
compiling programs with Mesa. For a complete description of Mesa,
please look at the libgl1-mesa-swx11 package.
.
This library provides a pure software rasteriser; it does not provide
a direct rendering-capable library, or one which uses GLX. For that,
please see libgl1-mesa-dev.
Package: libgl1-mesa-glx
Section: libs
Architecture: any
Depends: ${shlibs:Depends}
Recommends: libgl1-mesa-dri (>= 7.2)
Conflicts: libgl1, libgl1-mesa-dri (<< 6.4.0)
Replaces: libgl1, libgl1-mesa-dri (<< 6.4.0)
Provides: libgl1
Description: A free implementation of the OpenGL API -- GLX runtime
This version of Mesa provides GLX and DRI capabilities: it is capable of
both direct and indirect rendering. For direct rendering, it can use DRI
modules from the libgl1-mesa-dri package to accelerate drawing.
.
This package does not include the modules themselves: these can be found
in the libgl1-mesa-dri package.
.
For a complete description of Mesa, please look at the
libgl1-mesa-swx11 package.
Package: libgl1-mesa-glx-dbg
Section: debug
Priority: extra
Architecture: any
Depends: libgl1-mesa-glx (= ${binary:Version})
Description: Debugging symbols for the Mesa GLX runtime
This version of Mesa provides GLX and DRI capabilities: it is capable of
both direct and indirect rendering. For direct rendering, it can use DRI
modules from the libgl1-mesa-dri package to accelerate drawing.
.
This package does not include the modules themselves: these can be found
in the libgl1-mesa-dri package.
.
For a complete description of Mesa, please look at the
libgl1-mesa-swx11 package.
.
This package contains debugging symbols for the GL library with GLX and DRI
capabilities.
#Package: libgl1-mesa-glx-i686
#Section: libs
#Priority: extra
#Architecture: i386 kfreebsd-i386 hurd-i386
#Pre-Depends: libgl1-mesa-glx
#Description: A free implementation of the OpenGL API -- GLX runtime [i686 optimized]
# This version of Mesa provides GLX and DRI capabilities: it is capable of
# both direct and indirect rendering. For direct rendering, it can use DRI
# modules from the libgl1-mesa-dri package to accelerate drawing.
# .
# This package does not include the modules themselves: these can be found
# in the libgl1-mesa-dri package.
# .
# For a complete description of Mesa, please look at the
# libgl1-mesa-swx11 package.
# .
# This set of libraries is optimized for i686 machines and will only be used if
# you are running a 2.6 kernel on an i686 class CPU. This includes Pentium Pro,
# Pentium II/II/IV, Celeron CPU's and similar class CPU's (including clones
# such as AMD Athlon/Opteron, VIA C3 Nehemiah, but not VIA C3 Ezla).
Package: libgl1-mesa-dri
Section: libs
Priority: optional
Architecture: any
Depends: ${shlibs:Depends}
Suggests: libglide3
Conflicts: xlibmesa-dri (<< 1:7.0.0)
Replaces: xlibmesa-dri (<< 1:7.0.0)
Breaks: xserver-xorg-core (<< 2:1.5), libgl1-mesa-glx (<< 7.2)
Description: A free implementation of the OpenGL API -- DRI modules
This version of Mesa provides GLX and DRI capabilities: it is capable of
both direct and indirect rendering. For direct rendering, it can use DRI
modules from the libgl1-mesa-dri package to accelerate drawing.
.
This package does not include the OpenGL library itself, only the DRI
modules for accelerating direct rendering.
.
For a complete description of Mesa, please look at the
libgl1-mesa-swx11 package.
.
The tdfx DRI module needs libglide3 to enable direct rendering.
Package: libgl1-mesa-dri-dbg
Section: debug
Priority: extra
Architecture: any
Depends: libgl1-mesa-dri (= ${binary:Version})
Description: Debugging symbols for the Mesa DRI modules
This version of Mesa provides GLX and DRI capabilities: it is capable of
both direct and indirect rendering. For direct rendering, it can use DRI
modules from the libgl1-mesa-dri package to accelerate drawing.
.
This package does not include the OpenGL library itself, only the DRI
modules for accelerating direct rendering.
.
For a complete description of Mesa, please look at the
libgl1-mesa-swx11 package.
.
This package contains debugging symbols for the DRI modules.
#Package: libgl1-mesa-dri-i686
#Section: libs
#Priority: extra
#Architecture: i386 kfreebsd-i386 hurd-i386
#Pre-Depends: libgl1-mesa-dri
#Description: A free implementation of the OpenGL API -- DRI modules [i686 optimized]
# This version of Mesa provides GLX and DRI capabilities: it is capable of
# both direct and indirect rendering. For direct rendering, it can use DRI
# modules from the libgl1-mesa-dri package to accelerate drawing.
# .
# This package does not include the OpenGL library itself, only the DRI
# modules for accelerating direct rendering.
# .
# For a complete description of Mesa, please look at the
# libgl1-mesa-swx11 package.
# .
# This set of libraries is optimized for i686 machines and will only be used if
# you are running a 2.6 kernel on an i686 class CPU. This includes Pentium Pro,
# Pentium II/II/IV, Celeron CPU's and similar class CPU's (including clones
# such as AMD Athlon/Opteron, VIA C3 Nehemiah, but not VIA C3 Ezla).
Package: libgl1-mesa-dev
Section: libdevel
Architecture: any
Depends: libc6-dev, mesa-common-dev (= ${binary:Version}), libgl1-mesa-glx (= ${binary:Version})
Conflicts: libgl-dev, libgl1-mesa-dri-dev
Replaces: libgl-dev, libgl1-mesa-dri-dev
Provides: libgl-dev, libgl1-mesa-dri-dev
Description: A free implementation of the OpenGL API -- GLX development files
This version of Mesa provides GLX and DRI capabilities: it is capable of
both direct and indirect rendering. For direct rendering, it can use DRI
modules from the libgl1-mesa-dri package to accelerate drawing.
.
This package includes headers and static libraries for compiling
programs with Mesa.
.
For a complete description of Mesa, please look at the libgl1-mesa-swx11
package.
Package: mesa-common-dev
Section: libdevel
Architecture: any
Replaces: xlibmesa-gl-dev (<< 1:7), xlibosmesa-dev, libgl1-mesa-swx11-dev (<< 6.5.2), libgl1-mesa-dev (<< 7.5~rc4-2)
Depends: libx11-dev
Description: Developer documentation for Mesa
This package includes the specifications for the Mesa-specific OpenGL
extensions, the complete set of release notes and the development header
files common to all Mesa packages.
Package: libosmesa6
Section: libs
Architecture: any
Depends: ${shlibs:Depends}
Replaces: libgl1-mesa-swx11 (<< 6.5.2)
Description: Mesa Off-screen rendering extension
OSmesa is a Mesa extension that allows programs to render to an
off-screen buffer using the OpenGL API without having to create a
rendering context on an X Server. It uses a pure software renderer.
.
This package provides both 16-bit and 32-bit versions of the off-screen
renderer which do not require external libraries to work.
Package: libosmesa6-dev
Section: libdevel
Architecture: any
Depends: libosmesa6 (= ${binary:Version}), mesa-common-dev (= ${binary:Version}) | libgl-dev
Conflicts: xlibosmesa-dev, libosmesa4-dev, libosmesa-dev
Replaces: xlibosmesa-dev, libosmesa-dev, libgl1-mesa-swx11-dev (<< 6.5.2), mesa-common-dev (<< 6.5.2)
Provides: xlibosmesa-dev, libosmesa-dev
Description: Mesa Off-screen rendering extension -- development files
This package provides the required environment for developing programs
that use the off-screen rendering extension of Mesa.
.
For more information on OSmesa see the libosmesa6 package.
Package: libglu1-mesa
Section: libs
Architecture: any
Depends: ${shlibs:Depends}, libgl1-mesa-glx | libgl1
Provides: libglu1
Conflicts: mesag3 (<< 5.0.0-1), xlibmesa3, libglu1
Replaces: libglu1
Description: The OpenGL utility library (GLU)
GLU offers simple interfaces for building mipmaps; checking for the
presence of extensions in the OpenGL (or other libraries which follow
the same conventions for advertising extensions); drawing
piecewise-linear curves, NURBS, quadrics and other primitives
(including, but not limited to, teapots); tesselating surfaces; setting
up projection matrices and unprojecting screen coordinates to world
coordinates.
.
On Linux, this library is also known as libGLU or libGLU.so.1.
.
This package provides the SGI implementation of GLU shipped with the
Mesa package (ergo the "-mesa" suffix).
Package: libglu1-mesa-dev
Section: libdevel
Architecture: any
Depends: libglu1-mesa (= ${binary:Version}), libgl1-mesa-dev | libgl-dev
Provides: libglu-dev, xlibmesa-glu-dev
Conflicts: mesag-dev (<< 5.0.0-1), mesa-glide2-dev (<< 5.0.0-1), mesag3+ggi-dev (<< 5.0.0-1), xlibmesa-dev
Replaces: libglu-dev
Description: The OpenGL utility library -- development files
Includes headers and static libraries for compiling programs with GLU.
.
For a complete description of GLU, please look at the libglu1-mesa
package.
Package: libglw1-mesa
Section: libs
Architecture: any
Depends: ${shlibs:Depends}
Provides: libglw1
Description: A free implementation of the OpenGL API -- runtime
Mesa is a 3-D graphics library with an API which is very similar to
that of OpenGL. To the extent that Mesa utilizes the OpenGL command
syntax or state machine, it is being used with authorization from
Silicon Graphics, Inc. However, the author makes no claim that Mesa
is in any way a compatible replacement for OpenGL or associated with
Silicon Graphics, Inc.
.
This package provides a simple widgets library, libGLw, which
allows Motif-based applications to embed an OpenGL drawing context.
.
On Linux, this library is also known as libGLw or libGLw.so.1.
Package: libglw1-mesa-dev
Section: libdevel
Architecture: any
Depends: libglw1-mesa (= ${binary:Version}), libc6-dev, libx11-dev, libxext6, mesa-common-dev (= ${binary:Version})
Provides: mesag3-widgets, mesag-widgets-dev, libglw-dev
Conflicts: libglw-dev, libgl1-mesa-swx11-dev (<< 6.5.2-4)
Replaces: libglw-dev
Description: A free implementation of the OpenGL API -- development files
This package provides the development environment required for
compiling programs with the Mesa widgets library, libGLw, which
allows Motif-based applications to embed an OpenGL drawing context.
The headers and static libraries for compiling programs that use this
library are included.
Package: mesa-utils
Section: x11
Priority: optional
Architecture: any
Depends: ${shlibs:Depends}
Replaces: xbase-clients (<< 6.8.2-38)
Description: Miscellaneous Mesa GL utilities
This package provides several basic GL utilities built by Mesa, including
glxinfo and glxgears.
# vim: tw=0

193
debian/copyright vendored Normal file
View File

@@ -0,0 +1,193 @@
This package was debianized by James A. Treacy treacy@debian.org on Thu,
6 Jan 2000 01:11:34 -0500. It was newly debianized by Marcelo E.
Magallon <mmagallo@debian.org> on Sat, 25 Dec 2004 14:50:02 -0600. It was
again debianized by Thierry Reding <thierry@gilfi.de> on Sat, 14 Oct 2006
02:01:12 +0200.
It was downloaded from http://www.mesa3d.org/download.html
For more information see:
http://www.mesa3d.org/
Copyright:
Upstream Author: Brian Paul <brian.paul@tungstengraphics.com>
License:
License / Copyright Information
The Mesa distribution consists of several components. Different
copyrights and licenses apply to different components. For
example, GLUT is copyrighted by Mark Kilgard, some demo programs
are copyrighted by SGI, some of the Mesa device drivers are
copyrighted by their authors. See below for a list of Mesa's
components and the copyright/license for each.
The core Mesa library is licensed according to the terms of the
XFree86 copyright (an MIT-style license). This allows integration
with the XFree86/DRI project. Unless otherwise stated, the Mesa
source code and documentation is licensed as follows:
Copyright (C) 1999-2003 Brian Paul All Rights Reserved.
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
BRIAN PAUL BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
Attention, Contributors
When contributing to the Mesa project you must agree to relinquish
your work to the holder of the copyright for the particular
component you're contributing to. That is, you can't put your own
copyright on the code, unless it's a modular piece that can be
omitted from Mesa (like a new device driver). If for example, you
contribute a bug fix to Mesa's texture mapping code, your code
will become a part of the body of work which is copyrighted by
Brian Paul and licensed by the above terms.
----------------------------------------------------------------------
Some files, as listed below, are made available under the SGI Free B
license. This license is as follows:
SGI FREE SOFTWARE LICENSE B (Version 2.0, Sept. 18, 2008)
Copyright (C) [dates of first publication] Silicon Graphics, Inc. All Rights
Reserved.
Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
The above copyright notice including the dates of first publication and either
this permission notice or a reference to http://oss.sgi.com/projects/FreeB/
shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES
OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
NONINFRINGEMENT. IN NO EVENT SHALL SILICON GRAPHICS, INC. BE
LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN
ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
IN THE SOFTWARE.
Except as contained in this notice, the name of Silicon Graphics, Inc. shall
not be used in advertising or otherwise to promote the sale, use or other
dealings in this Software without prior written authorization from Silicon
Graphics, Inc.
--------------------------------------------------------------------------
Some other files listed below are made available from Silicon Graphics,
Inc. under a more liberal, MIT-style license, as follows:
Permission to use, copy, modify, and distribute this software for
any purpose and without fee is hereby granted, provided that the above
copyright notice appear in all copies and that both the copyright notice
and this permission notice appear in supporting documentation, and that
the name of Silicon Graphics, Inc. not be used in advertising
or publicity pertaining to distribution of the software without specific,
written prior permission.
THE MATERIAL EMBODIED ON THIS SOFTWARE IS PROVIDED TO YOU "AS-IS"
AND WITHOUT WARRANTY OF ANY KIND, EXPRESS, IMPLIED OR OTHERWISE
INCLUDING WITHOUT LIMITATION, ANY WARRANTY OF MERCHANTABILITY OR
FITNESS FOR A PARTICULAR PURPOSE. IN NO EVENT SHALL SILICON
GRAPHICS, INC. BE LIABLE TO YOU OR ANYONE ELSE FOR ANY DIRECT,
SPECIAL, INCIDENTAL, INDIRECT OR CONSEQUENTIAL DAMAGES OF ANY
KIND, OR ANY DAMAGES WHATSOEVER, INCLUDING WITHOUT LIMITATION,
LOSS OF PROFIT, LOSS OF USE, SAVINGS OR REVENUE, OR THE CLAIMS OF
THIRD PARTIES, WHETHER OR NOT SILICON GRAPHICS, INC. HAS BEEN
ADVISED OF THE POSSIBILITY OF SUCH LOSS, HOWEVER CAUSED AND ON
ANY THEORY OF LIABILITY, ARISING OUT OF OR IN CONNECTION WITH THE
POSSESSION, USE OR PERFORMANCE OF THIS SOFTWARE.
US Government Users Restricted Rights
Use, duplication, or disclosure by the Government is subject to
restrictions set forth in FAR 52.227.19(c)(2) or subparagraph
(c)(1)(ii) of the Rights in Technical Data and Computer Software
clause at DFARS 252.227-7013 and/or in similar or successor
clauses in the FAR or the DOD or NASA FAR Supplement.
Unpublished-- rights reserved under the copyright laws of the
United States. Contractor/manufacturer is Silicon Graphics,
Inc., 2011 N. Shoreline Blvd., Mountain View, CA 94039-7311.
--------------------------------------------------------------------------
Mesa Component Licenses:
Component Files Primary Author License
----------------------------------------------------------------------------
core Mesa code src/*.[ch] Brian Paul Mesa
include/GL/gl.h
GLX driver src/X/* Brian Paul Mesa
include/GL/glx.h
include/GL/xmesa.h
OS/Mesa driver src/OSmesa/* Brian Paul Mesa
include/GL/osmesa.h
3Dfx driver src/FX/* David Bucciarelli Mesa
include/GL/fxmesa.h
BeOS R4 driver mesa/drivers/beos/ Brian Paul Mesa
MGL driver include/GL/mglmesa.h SciTech, Inc GNU LGPL
Windows driver mesa/drivers/windows/ Li Wei GNU LGPL
include/GL/wmesa.h
SVGA driver mesa/drivers/svga/ Brian Paul GNU LGPL
include/GL/svgamesa.h
DOS driver mesa/drivers/dos/ Charlie Wallace GNU LGPL
include/GL/dosmesa.h
GGI driver mesa/drivers/ggi/ Uwe Maurer GNU LGPL
include/GL/ggimesa.h
GLUT src/glut/* Mark Kilgard Mark's copyright
include/GL/*glut*.h
GLU library src/glu/* Brian Paul GNU LGPL
SGI GLU library src/glu/sgi/* SGI SGI Free B
include/GL/glu.h
Ext registry include/GL/glext.h SGI SGI Free B
include/GL/glxext.h
demo programs progs/demos/* various see source files
X demos progs/xdemos/* Brian Paul see source files
SGI demos progs/samples/* SGI SGI MIT-style
RedBook demos progs/redbook/* SGI SGI MIT-style
On Debian systems the full text of the GNU LGPL license is found in
/usr/share/common-licenses/LGPL.
------------------------------------------------------------------------------
The Debian packaging is (C) 2006, Thierry Reding <thierry@gilfi.de> and
is licensed under the GPL, see `/usr/share/common-licenses/GPL'.

15
debian/glxdemo.1 vendored Normal file
View File

@@ -0,0 +1,15 @@
.TH glxdemo 1 "2006-11-29"
.SH NAME
glxdemo \- a demonstration of the GLX functions
.SH SYNOPSIS
.B glxdemo
.SH DESCRIPTION
The \fIglxdemo\fP program shows how to use the GLX functions in order to
create an OpenGL program running on top of an X server. This program is most
useful when studied in its source code form.
.SH AUTHOR
glxdemo was written by Brian Paul <brian.paul@tungstengraphics.com>.
.PP
This manual page was written by Thierry Reding <thierry@gilfi.de>, for the
Debian project (but may be used by others).

29
debian/glxgears.1 vendored Normal file
View File

@@ -0,0 +1,29 @@
.TH glxgears 1 "2006-11-29"
.SH NAME
glxgears \- ``gears'' demo for GLX
.SH SYNOPSIS
.B glxgears
.RI [ options ]
.SH DESCRIPTION
The \fIglxgears\fP program is a port of the ``gears'' demo to GLX. It displays
a set of rotating gears and prints out the frame rate at regular intervals. It
has become quite popular as basic benchmarking tool.
.SH OPTIONS
.TP 8
.B \-display \fIdisplay\fP
Specify which X display to run on.
.TP 8
.B \-info
Display OpenGL renderer information.
.TP 8
.B \-stereo
Use a stereo enabled GLX visual.
.TP 8
.B \-fullscreen
Run in fullscreen mode.
.SH AUTHOR
glxgears was written by Brian Paul <brian.paul@tungstengraphics.com>.
.PP
This manual page was written by Thierry Reding <thierry@gilfi.de>, for the
Debian project (but may be used by others).

30
debian/glxheads.1 vendored Normal file
View File

@@ -0,0 +1,30 @@
.TH glxheads 1 "2006-11-29"
.SH NAME
glxheads \- exercise multiple GLX connections
.SH SYNOPSIS
.B glxheads
[\fIdisplay\fP ...]
.SH DESCRIPTION
The \fIglxheads\fP program will try to open GLX connections on multiple X
displays as specified on the command-line. If a connection can be made it will
try to create a direct GLX context (and fallback to using indirect contexts if
that fails) and open a window displaying a spinning green triangle.
.PP
If no display names are specified, \fIglxheads\fP will default to opening a
single local connection on display 0.
.SH EXAMPLE
To open a local connection on display 0 and two remote connections to the
hosts \fImars\fP (display 0) and \fIvenus\fP (display 1), run glxheads with
the following command-line:
.PP
.RS 3n
.nf
$ glxheads :0 mars:0 venus:1
.fi
.RE
.SH AUTHOR
glxheads was written by Brian Paul <brian.paul@tungstengraphics.com>.
.PP
This manual page was written by Thierry Reding <thierry@gilfi.de> for the
Debian project (but may be used by others).

41
debian/glxinfo.1 vendored Normal file
View File

@@ -0,0 +1,41 @@
.TH glxinfo 1 "2006-11-29"
.SH NAME
glxinfo \- show information about the GLX implementation
.SH SYNOPSIS
.B glxinfo
.RI [ options ]
.SH DESCRIPTION
The \fIglxinfo\fP program shows information about the OpenGL and GLX
implementations running on a given X display.
.PP
The information includes details about the server- and client-side GLX
implementation, the OpenGL and GLU implementations as well as a list
of available GLX visuals.
.SH OPTIONS
.TP 8
.B \-v
Print visuals info in verbose form.
.TP 8
.B \-t
Print verbose table.
.TP 8
.B \-display \fIdisplay\fP
Specify the X display to interrogate.
.TP 8
.B \-h
Print usage information.
.TP 8
.B \-i
Force an indirect rendering context.
.TP 8
.B \-b
Find the "best" visual and print its number.
.TP 8
.B \-l
Print interesting OpenGL limits.
.SH AUTHOR
glxinfo was written by Brian Paul <brian.paul@tungstengraphics.com>.
.PP
This manual page was written by Thierry Reding <thierry@gilfi.de>, for the
Debian project (but may be used by others).

2
debian/libgl1-mesa-dev.install vendored Normal file
View File

@@ -0,0 +1,2 @@
usr/lib/libGL.so
usr/lib/pkgconfig/gl.pc

1
debian/libgl1-mesa-dri-i686.install vendored Normal file
View File

@@ -0,0 +1 @@
usr/lib/dri/i686/cmov/*.so

1
debian/libgl1-mesa-dri.install vendored Normal file
View File

@@ -0,0 +1 @@
usr/lib/dri/*.so

1
debian/libgl1-mesa-glx-i686.install vendored Normal file
View File

@@ -0,0 +1 @@
usr/lib/glx/i686/cmov/libGL.so.* usr/lib/i686/cmov

1
debian/libgl1-mesa-glx.install vendored Normal file
View File

@@ -0,0 +1 @@
usr/lib/glx/libGL.so.* usr/lib

View File

@@ -0,0 +1 @@
package-name-doesnt-match-sonames libGL1

1
debian/libgl1-mesa-glx.shlibs vendored Normal file
View File

@@ -0,0 +1 @@
libGL 1 libgl1-mesa-glx | libgl1

2
debian/libgl1-mesa-swx11-dev.install vendored Normal file
View File

@@ -0,0 +1,2 @@
usr/lib/libGL.a
usr/lib/libGL.so

1
debian/libgl1-mesa-swx11-i686.install vendored Normal file
View File

@@ -0,0 +1 @@
usr/lib/i686/cmov/libGL.so.*

1
debian/libgl1-mesa-swx11-i686.shlibs vendored Normal file
View File

@@ -0,0 +1 @@
libGL 1 libgl1-mesa-glx | libgl1

1
debian/libgl1-mesa-swx11.install vendored Normal file
View File

@@ -0,0 +1 @@
usr/lib/libGL.so.*

View File

@@ -0,0 +1 @@
package-name-doesnt-match-sonames libGL1

1
debian/libgl1-mesa-swx11.shlibs vendored Normal file
View File

@@ -0,0 +1 @@
libGL 1 libgl1-mesa-glx | libgl1

5
debian/libglu1-mesa-dev.install vendored Normal file
View File

@@ -0,0 +1,5 @@
usr/include/GL/glu.h
usr/include/GL/glu_mangle.h
usr/lib/libGLU.a
usr/lib/libGLU.so
usr/lib/pkgconfig/glu.pc

1
debian/libglu1-mesa.install vendored Normal file
View File

@@ -0,0 +1 @@
usr/lib/libGLU.so.*

1
debian/libglu1-mesa.lintian-overrides vendored Normal file
View File

@@ -0,0 +1 @@
package-name-doesnt-match-sonames libGLU1

1
debian/libglu1-mesa.shlibs vendored Normal file
View File

@@ -0,0 +1 @@
libGLU 1 libglu1-mesa | libglu1

4
debian/libglw1-mesa-dev.install vendored Normal file
View File

@@ -0,0 +1,4 @@
usr/include/GL/GLw*A.h
usr/lib/libGLw.a
usr/lib/libGLw.so
usr/lib/pkgconfig/glw.pc

1
debian/libglw1-mesa.install vendored Normal file
View File

@@ -0,0 +1 @@
usr/lib/libGLw.so.*

1
debian/libglw1-mesa.lintian-overrides vendored Normal file
View File

@@ -0,0 +1 @@
package-name-doesnt-match-sonames libGLw1

1
debian/libglw1-mesa.shlibs vendored Normal file
View File

@@ -0,0 +1 @@
libGLw 1 libglw1-mesa | libglw1

8
debian/libosmesa6-dev.install vendored Normal file
View File

@@ -0,0 +1,8 @@
usr/include/GL/osmesa.h
usr/lib/libOSMesa.a
usr/lib/libOSMesa.so
usr/lib/libOSMesa16.a
usr/lib/libOSMesa16.so
usr/lib/libOSMesa32.a
usr/lib/libOSMesa32.so
usr/lib/pkgconfig/osmesa.pc

3
debian/libosmesa6.install vendored Normal file
View File

@@ -0,0 +1,3 @@
usr/lib/libOSMesa.so.*
usr/lib/libOSMesa16.so.*
usr/lib/libOSMesa32.so.*

3
debian/libosmesa6.shlibs vendored Normal file
View File

@@ -0,0 +1,3 @@
libOSMesa 6 libosmesa6 (>= 6.5.2-1) | libgl1-mesa-glide3
libOSMesa16 6 libosmesa6 (>= 6.5.2-1)
libOSMesa32 6 libosmesa6 (>= 6.5.2-1)

8
debian/mesa-common-dev.docs vendored Normal file
View File

@@ -0,0 +1,8 @@
docs/bugs.html
docs/debugging.html
docs/envvars.html
docs/faq.html
docs/osmesa.html
docs/RELNOTES-*
docs/relnotes*
docs/*.spec

8
debian/mesa-common-dev.install vendored Normal file
View File

@@ -0,0 +1,8 @@
usr/include/GL/gl.h
usr/include/GL/glext.h
usr/include/GL/gl_mangle.h
usr/include/GL/glx.h
usr/include/GL/glxext.h
usr/include/GL/glx_mangle.h
usr/include/GL/internal/dri_interface.h
usr/lib/glx/pkgconfig/dri.pc usr/lib/pkgconfig/

4
debian/mesa-utils.install vendored Normal file
View File

@@ -0,0 +1,4 @@
usr/bin/glxdemo
usr/bin/glxgears
usr/bin/glxheads
usr/bin/glxinfo

4
debian/mesa-utils.manpages vendored Normal file
View File

@@ -0,0 +1,4 @@
debian/glxdemo.1
debian/glxgears.1
debian/glxheads.1
debian/glxinfo.1

View File

@@ -0,0 +1,21 @@
Patch that fixes Debian bug #349437.
This patch by David Nusinow.
---
src/mesa/main/compiler.h | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
--- a/src/mesa/main/compiler.h
+++ b/src/mesa/main/compiler.h
@@ -353,8 +353,9 @@ static INLINE GLuint CPU_TO_LE32(GLuint
* USE_IEEE: Determine if we're using IEEE floating point
*/
#if defined(__i386__) || defined(__386__) || defined(__sparc__) || \
- defined(__s390x__) || defined(__powerpc__) || \
+ defined(__s390__) || defined(__s390x__) || defined(__powerpc__) || \
defined(__x86_64__) || \
+ defined(__m68k__) || \
defined(ia64) || defined(__ia64__) || \
defined(__hppa__) || defined(hpux) || \
defined(__mips) || defined(_MIPS_ARCH) || \

View File

@@ -0,0 +1,56 @@
Allow the programs that are to be built to be defined in the build
configuration.
Provide an install target for installing the programs in $(INSTALL_DIR)/bin.
This patch by Thierry Reding.
Not submitted to Mesa.
--
Also remove references to GLU library since it is not required
and we don't actually build it at this point.
---
progs/Makefile | 6 +++++-
progs/xdemos/Makefile | 7 ++++++-
2 files changed, 11 insertions(+), 2 deletions(-)
--- a/progs/xdemos/Makefile
+++ b/progs/xdemos/Makefile
@@ -13,7 +13,7 @@ APP_LIB_DEPS += -lX11 -lpthread
LIBS = -L$(TOP)/$(LIB_DIR) -l$(GL_LIB) -L$(libdir) $(APP_LIB_DEPS)
-PROGS = \
+PROGS ?= \
corender \
glsync \
glthreads \
@@ -68,6 +68,11 @@ default: $(PROGS)
extra: $(EXTRA_PROGS)
+install: $(PROGS)
+ $(INSTALL) -d $(DESTDIR)$(INSTALL_DIR)/bin
+ $(INSTALL) -m 755 $(PROGS) $(DESTDIR)$(INSTALL_DIR)/bin
+
+
clean:
-rm -f $(PROGS) $(EXTRA_PROGS)
-rm -f *.o *~
--- a/progs/Makefile
+++ b/progs/Makefile
@@ -21,8 +21,12 @@ subdirs:
fi \
done
-# Dummy install target
install:
+ @for dir in $(SUBDIRS) ; do \
+ if [ -d $$dir ] ; then \
+ (cd $$dir ; $(MAKE) install) ; \
+ fi \
+ done
clean:
@list='$(SUBDIRS)'; for dir in $$list tests ; do \

15
debian/patches/04_osmesa_version.diff vendored Normal file
View File

@@ -0,0 +1,15 @@
---
src/mesa/drivers/osmesa/Makefile | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/src/mesa/drivers/osmesa/Makefile
+++ b/src/mesa/drivers/osmesa/Makefile
@@ -43,7 +43,7 @@ default: $(TOP)/$(LIB_DIR)/$(OSMESA_LIB_
# -DCHAN_BITS=16/32.
$(TOP)/$(LIB_DIR)/$(OSMESA_LIB_NAME): $(OBJECTS) $(CORE_MESA)
$(MKLIB) -o $(OSMESA_LIB) -linker '$(CC)' -ldflags '$(LDFLAGS)' \
- -major $(MESA_MAJOR) -minor $(MESA_MINOR) -patch $(MESA_TINY) \
+ -major 6 -minor 5 -patch 3 \
-install $(TOP)/$(LIB_DIR) $(MKLIB_OPTIONS) \
-id $(INSTALL_LIB_DIR)/lib$(OSMESA_LIB).$(MESA_MAJOR).dylib \
$(OSMESA_LIB_DEPS) $(OBJECTS) $(CORE_MESA)

57
debian/patches/05_hurd-ftbfs.diff vendored Normal file
View File

@@ -0,0 +1,57 @@
From: Samuel Thibault <samuel.thibault@ens-lyon.org>
Subject: Fix build on GNU/Hurd
---
configure.ac | 27 +++++++++++++++------------
1 file changed, 15 insertions(+), 12 deletions(-)
--- a/configure.ac
+++ b/configure.ac
@@ -578,6 +578,13 @@ else
enable_xcb=no
fi
+dnl Direct rendering or just indirect rendering
+AC_ARG_ENABLE([driglx-direct],
+ [AS_HELP_STRING([--disable-driglx-direct],
+ [enable direct rendering in GLX for DRI @<:@default=enabled@:>@])],
+ [driglx_direct="$enableval"],
+ [driglx_direct="yes"])
+
dnl
dnl libGL configuration per driver
dnl
@@ -611,12 +618,14 @@ dri)
AC_MSG_ERROR([Can't use static libraries for DRI drivers])
fi
- # Check for libdrm
- PKG_CHECK_MODULES([LIBDRM], [libdrm >= $LIBDRM_REQUIRED])
- PKG_CHECK_MODULES([DRI2PROTO], [dri2proto >= $DRI2PROTO_REQUIRED])
- PKG_CHECK_MODULES([GLPROTO], [glproto >= $GLPROTO_REQUIRED])
- GL_PC_REQ_PRIV="libdrm >= $LIBDRM_REQUIRED dri2proto >= $DRI2PROTO_REQUIRED glproto >= $GLPROTO_REQUIRED"
- DRI_PC_REQ_PRIV="libdrm >= $LIBDRM_REQUIRED"
+ if test x"$driglx_direct" = xyes; then
+ # Check for libdrm
+ PKG_CHECK_MODULES([LIBDRM], [libdrm >= $LIBDRM_REQUIRED])
+ PKG_CHECK_MODULES([DRI2PROTO], [dri2proto >= $DRI2PROTO_REQUIRED])
+ PKG_CHECK_MODULES([GLPROTO], [glproto >= $GLPROTO_REQUIRED])
+ GL_PC_REQ_PRIV="libdrm >= $LIBDRM_REQUIRED dri2proto >= $DRI2PROTO_REQUIRED glproto >= $GLPROTO_REQUIRED"
+ DRI_PC_REQ_PRIV="libdrm >= $LIBDRM_REQUIRED"
+ fi
# find the DRI deps for libGL
if test "$x11_pkgconfig" = yes; then
@@ -690,12 +699,6 @@ AC_ARG_WITH([dri-searchpath],
[DRI_DRIVER_SEARCH_DIR="$withval"],
[DRI_DRIVER_SEARCH_DIR='${DRI_DRIVER_INSTALL_DIR}'])
AC_SUBST([DRI_DRIVER_SEARCH_DIR])
-dnl Direct rendering or just indirect rendering
-AC_ARG_ENABLE([driglx-direct],
- [AS_HELP_STRING([--disable-driglx-direct],
- [enable direct rendering in GLX for DRI @<:@default=enabled@:>@])],
- [driglx_direct="$enableval"],
- [driglx_direct="yes"])
dnl Which drivers to build - default is chosen by platform
AC_ARG_WITH([dri-drivers],
[AS_HELP_STRING([--with-dri-drivers@<:@=DIRS...@:>@],

21
debian/patches/06_kfreebsd-ftbfs.diff vendored Normal file
View File

@@ -0,0 +1,21 @@
From: Aurelien Jarno <aurel32@debian.org>
mesa fails to build on GNU/kFreeBSD, since some parts are not enabled.
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=524690
---
configure.ac | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/configure.ac
+++ b/configure.ac
@@ -770,7 +770,7 @@ if test "$mesa_driver" = dri; then
;;
esac
;;
- freebsd* | dragonfly*)
+ freebsd* | dragonfly* | kfreebsd*-gnu*)
DEFINES="$DEFINES -DPTHREADS -DUSE_EXTERNAL_DXTN_LIB=1"
DEFINES="$DEFINES -DIN_DRI_DRIVER -DHAVE_ALIAS"
DEFINES="$DEFINES -DGLX_INDIRECT_RENDERING"

5
debian/patches/series vendored Normal file
View File

@@ -0,0 +1,5 @@
02_use-ieee-fp-on-s390-and-m68k.patch
03_optional-progs-and-install.patch
04_osmesa_version.diff
05_hurd-ftbfs.diff
06_kfreebsd-ftbfs.diff

247
debian/rules vendored Executable file
View File

@@ -0,0 +1,247 @@
#!/usr/bin/make -f
# debian/rules for the Debian mesa package
# Copyright © 2006 Thierry Reding <thierry@gilfi.de>
# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1
CFLAGS = -Wall -g
ifneq (,$(filter noopt,$(DEB_BUILD_OPTIONS)))
CFLAGS += -O0
else
CFLAGS += -O2
endif
ifneq (,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
NUMJOBS = $(patsubst parallel=%,%,$(filter parallel=%,$(DEB_BUILD_OPTIONS)))
MAKEFLAGS += -j$(NUMJOBS)
endif
DEB_BUILD_ARCH ?= $(shell dpkg-architecture -qDEB_BUILD_ARCH)
DEB_HOST_ARCH ?= $(shell dpkg-architecture -qDEB_HOST_ARCH)
DEB_HOST_ARCH_OS ?= $(shell dpkg-architecture -qDEB_HOST_ARCH_OS)
DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
DEB_HOST_GNU_CPU ?= $(shell dpkg-architecture -qDEB_HOST_GNU_CPU)
DEB_BUILD_DIR ?= $(CURDIR)/build
ifeq ($(DEB_BUILD_GNU_TYPE), $(DEB_HOST_GNU_TYPE))
confflags += --build=$(DEB_HOST_GNU_TYPE)
else
confflags += --build=$(DEB_BUILD_GNU_TYPE) --host=$(DEB_HOST_GNU_TYPE)
endif
# choose which configurations to build
include debian/scripts/choose-configs
# build the following configurations by default
CONFIGS = $(SWX11_GLU_CONFIGS) \
dri \
osmesa \
osmesa-static \
osmesa16 \
osmesa16-static \
osmesa32 \
osmesa32-static
STAMP_DIR = debian/stamp
STAMP = $(STAMP_DIR)/$(DEB_BUILD_GNU_TYPE)
BUILD_STAMPS = $(addprefix $(STAMP)-build-, $(CONFIGS))
QUILT_STAMPFN = $(STAMP_DIR)/patch
include /usr/share/quilt/quilt.make
# temporary until we figure out what to build
confflags += --disable-gallium
confflags-common = \
--disable-egl \
--disable-glu \
--disable-glut \
--disable-glw \
CFLAGS="$(CFLAGS)"
DRI_DRIVERS = swrast
# hurd doesn't do direct rendering
ifeq ($(DEB_HOST_ARCH_OS), hurd)
DIRECT_RENDERING = --disable-driglx-direct
else
DIRECT_RENDERING = --enable-driglx-direct
ifeq ($(DEB_HOST_ARCH), lpia)
DRI_DRIVERS += i915 i965
else ifneq ($(DEB_HOST_ARCH), s390)
DRI_DRIVERS += mach64 mga r128 r200 r300 r600 radeon savage tdfx
ifeq ($(DEB_HOST_GNU_CPU), i486)
DRI_DRIVERS += i810 i915 i965 sis unichrome
else ifeq ($(DEB_HOST_GNU_CPU), x86_64)
DRI_DRIVERS += i915 i965 sis unichrome
else ifeq ($(DEB_HOST_ARCH), sparc)
DRI_DRIVERS += ffb
else ifeq ($(DEB_HOST_ARCH), sparc64)
DRI_DRIVERS += ffb
endif
endif
endif
confflags-dri = \
--with-driver=dri \
--with-dri-drivers="$(DRI_DRIVERS)" \
--with-demos=xdemos \
--libdir=/usr/lib/glx \
--with-dri-driverdir=/usr/lib/dri \
--enable-glx-tls \
$(DIRECT_RENDERING) \
$(confflags-common)
confflags-osmesa = \
--with-driver=osmesa \
--with-demos= \
$(confflags-common)
confflags-osmesa-static = \
--with-driver=osmesa \
--enable-static \
--with-demos= \
$(confflags-common)
confflags-osmesa16 = \
--with-driver=osmesa \
--with-osmesa-bits=16 \
--with-demos= \
$(confflags-common)
confflags-osmesa16-static = \
--with-driver=osmesa \
--with-osmesa-bits=16 \
--enable-static \
--with-demos= \
$(confflags-common)
confflags-osmesa32 = \
--with-driver=osmesa \
--with-osmesa-bits=32 \
--with-demos= \
$(confflags-common)
confflags-osmesa32-static = \
--with-driver=osmesa \
--with-osmesa-bits=32 \
--enable-static \
--with-demos= \
$(confflags-common)
confflags-swx11+glu = \
--with-driver=xlib \
--disable-gl-osmesa \
--with-demos= \
--disable-egl \
--disable-glut \
--enable-motif \
CFLAGS="$(CFLAGS)"
confflags-swx11+glu-static = \
--with-driver=xlib \
--disable-gl-osmesa \
--enable-static \
--with-demos= \
--disable-egl \
--disable-glut \
--enable-motif \
CFLAGS="$(CFLAGS)"
confflags-swx11+glu-i386-i686 = \
--with-driver=xlib \
--disable-gl-osmesa \
--with-demos= \
--disable-glut \
--disable-egl \
--enable-motif \
--libdir=/usr/lib/i686/cmov \
CFLAGS="$(CFLAGS) -march=i686"
configure: $(QUILT_STAMPFN) configure.ac
autoreconf -vfi
# list the configurations that will built
configs:
@echo Building the following configurations: $(CONFIGS)
$(STAMP_DIR)/stamp:
dh_testdir
mkdir -p $(STAMP_DIR)
>$@
$(QUILT_STAMPFN): $(STAMP_DIR)/stamp
build: $(BUILD_STAMPS)
$(STAMP)-build-%: configure
dh_testdir
mkdir -p $(DEB_BUILD_DIR)/$*
find $(CURDIR)/* -maxdepth 0 -not -path '$(DEB_BUILD_DIR)*' | \
xargs cp -rlf -t $(DEB_BUILD_DIR)/$*
cd $(DEB_BUILD_DIR)/$* && \
../../configure --prefix=/usr --mandir=\$${prefix}/share/man \
--infodir=\$${prefix}/share/info --sysconfdir=/etc \
--localstatedir=/var $(confflags) $(confflags-$*)
cd $(DEB_BUILD_DIR)/$* && $(MAKE)
touch $@
install: build
# Add here commands to install the package into debian/tmp
dh_testdir
dh_testroot
dh_clean -k
dh_installdirs
set -e; for config in $(CONFIGS); do \
$(MAKE) -C $(DEB_BUILD_DIR)/$$config DESTDIR=$(CURDIR)/debian/tmp install; \
done
clean: unpatch
dh_testdir
dh_testroot
rm -rf .pc
rm -f config.cache config.log config.status
rm -f */config.cache */config.log */config.status
rm -f conftest* */conftest*
rm -rf autom4te.cache */autom4te.cache
rm -rf build
rm -rf configure config.guess config.sub config.h.in
rm -rf $$(find -name Makefile.in)
rm -rf aclocal.m4 missing depcomp install-sh ltmain.sh
rm -rf $(STAMP_DIR)
dh_clean
# Build architecture-independent files here.
binary-indep: install
# Build architecture-dependent files here.
binary-arch: install
dh_testdir
dh_testroot
dh_installchangelogs -s
dh_installchangelogs -pmesa-common-dev ChangeLog
dh_installdocs -s
dh_installexamples -s
dh_install -s --sourcedir=debian/tmp --list-missing
dh_installman -s
dh_lintian -s
dh_link -s
dh_strip -plibgl1-mesa-swx11 --dbg-package=libgl1-mesa-swx11-dbg
dh_strip -plibgl1-mesa-glx --dbg-package=libgl1-mesa-glx-dbg
dh_strip -plibgl1-mesa-dri --dbg-package=libgl1-mesa-dri-dbg
dh_strip -s
dh_compress -s
dh_fixperms -s
dh_makeshlibs -s
dh_installdeb -s
dh_shlibdeps -s
dh_gencontrol -s
dh_md5sums -s
dh_builddeb -s
binary: binary-indep binary-arch
.PHONY: configs build clean binary-indep binary-arch binary install

58
debian/scripts/choose-configs vendored Normal file
View File

@@ -0,0 +1,58 @@
# Script to choose which configurations are to be built depending on the value
# of the DEB_BUILD_ARCH variable.
#
# Copyright © 2006 Thierry Reding <thierry@gilfi.de>
##############################################################################
## architecture-specific configurations ######################################
# choose an architecture-specific build of swx11 and GLU if a matching
# configuration exists
#ifneq ($(wildcard configs/debian-swx11+glu-$(DEB_BUILD_ARCH)),)
# SWX11_GLU_CONFIGS := debian-swx11+glu-$(DEB_BUILD_ARCH)
#else
# SWX11_GLU_CONFIGS := debian-swx11+glu-any
#endif
# same for static builds
#ifneq ($(wildcard configs/debian-swx11+glu-static-$(DEB_BUILD_ARCH)),)
# SWX11_GLU_CONFIGS += debian-swx11+glu-static-$(DEB_BUILD_ARCH)
#else
# SWX11_GLU_CONFIGS += debian-swx11+glu-static-any
#endif
SWX11_GLU_CONFIGS := swx11+glu swx11+glu-static
# and for the GLX/DRI-enabled libGL
ifneq ($(wildcard configs/debian-indirect-$(DEB_BUILD_ARCH)),)
DRI_CONFIGS := debian-indirect-$(DEB_BUILD_ARCH)
else
ifneq ($(wildcard configs/debian-dri-$(DEB_BUILD_ARCH)),)
DRI_CONFIGS := debian-dri-$(DEB_BUILD_ARCH)
else
DRI_CONFIGS := debian-dri-any
endif
endif
##############################################################################
## CPU-optimized configurations ##############################################
ifneq (,$(filter $(DEB_BUILD_ARCH), i386 kfreebsd-i386 hurd-i386))
SWX11_GLU_CONFIGS += swx11+glu-i386-i686
# DRI_CONFIGS += debian-dri-i386-i686
endif
#ifeq ($(DEB_BUILD_ARCH), alpha)
# SWX11_GLU_CONFIGS += debian-swx11+glu-alpha-ev5
#endif
#ifeq ($(DEB_BUILD_ARCH), powerpc)
# SWX11_GLU_CONFIGS += debian-swx11+glu-powerpc-603
#endif
#ifeq ($(DEB_BUILD_ARCH), sparc)
# SWX11_GLU_CONFIGS += debian-swx11+glu-sparc-ultrasparc
#endif
# vim: ft=make

6
debian/watch vendored Normal file
View File

@@ -0,0 +1,6 @@
version=3
opts="uversionmangle=s/-rc/~rc/" \
http://sf.net/mesa3d/MesaLib-(.*)\.tar\.gz
opts="uversionmangle=s/-rc/~rc/" \
ftp://freedesktop.org/pub/mesa/([\d\.]*)/ MesaLib-(.*)\.tar\.gz

69
docs/GL3.txt Normal file
View File

@@ -0,0 +1,69 @@
Status of OpenGL 3.x features in Mesa
Note: when an item is marked as "DONE" it means all the core Mesa
infrastructure is complete but it may be the case that few (if any) drivers
implement the features.
Feature Status
----------------------------------------------------- ------------------------
GL 3.0:
GLSL changes (GL_EXT_gpu_shader4, etc) not started
Conditional rendering (GL_NV_conditional_render) DONE (swrast & softpipe)
Map buffer subranges (GL_APPLE_flush_buffer_range) not started
Float textures, renderbuffers some infrastructure done
Framebuffer objects (GL_EXT_framebuffer_object) DONE
Half-float some infrastructure done
Multisample blit DONE
Non-normalized Integer texture/framebuffer formats not started
1D/2D Texture arrays core Mesa, swrast done
Packed depth/stencil formats DONE
Per-buffer blend and masks (GL_EXT_draw_buffers2) DONE
GL_EXT_texture_compression_rgtc not started
Red and red/green texture formats Ian?
Transform feedback (GL_EXT_transform_feedback) not started
Vertex array objects (GL_APPLE_vertex_array_object) DONE
sRGB framebuffer format (GL_EXT_framebuffer_sRGB) not started
glClearBuffer commands DONE, except for dispatch
glGetStringi command DONE, except for dispatch
glTexParameterI, glGetTexParameterI commands DONE, except for dispatch
glVertexAttribI commands not started
glBindFragDataLocation, glGetFragDataLocation cmds not started
glBindBufferRange, glBindBufferBase commands not started
GL 3.1:
GLSL 1.30 and 1.40 not started
Instanced drawing (GL_ARB_draw_instanced) not started
Buffer copying (GL_ARB_copy_buffer) DONE
Primitive restart (GL_NV_primitive_restart) not started
16 vertex texture image units not started
Texture buffer objs (GL_ARB_textur_buffer_object) not started
Rectangular textures (GL_ARB_texture_rectangle) DONE
Uniform buffer objs (GL_ARB_uniform_buffer_object) not started
Signed normalized texture formats not started
GL 3.2:
Core/compatibility profiles not started
GLSL 1.50 not started
Geometry shaders (GL_ARB_geometry_shader4) partially done (Zack)
BGRA vertex order (GL_ARB_vertex_array_bgra) DONE
Base vertex offset(GL_ARB_draw_elements_base_vertex) DONE
Frag shader coord (GL_ARB_fragment_coord_conventions) not started
Provoking vertex (GL_ARB_provoking_vertex) DONE
Seamless cubemaps (GL_ARB_seamless_cube_map) DONE, mostly?
Multisample textures (GL_ARB_texture_multisample) not started
Frag depth clamp (GL_ARB_depth_clamp) DONE
Fence objects (GL_ARB_sync) DONE
More info about these features and the work involved can be found at
http://dri.freedesktop.org/wiki/MissingFunctionality

View File

@@ -43,7 +43,7 @@ Issues
New Procedures and Functions
int glXSwapIntervalMESA(int interval)
int glXSwapIntervalMESA(unsigned int interval)
int glXGetSwapIntervalMESA(void)
New Tokens
@@ -103,11 +103,8 @@ Additions to the GLX 1.3 Specification
Errors
glXSwapIntervalMESA returns GLX_BAD_VALUE if parameter <interval> is
less than zero.
glXSwapIntervalMESA returns GLX_BAD_CONTEXT if there is no current
GLXContext.
GLXContext or if the current context is not a direct rendering context.
GLX Protocol

View File

@@ -1,534 +0,0 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<title>Mini GLX Specification</title>
</head>
<body>
<h1>
<center>Mini GLX Specification</center>
</h1>
<h2>
<center>Tungsten Graphics, Inc.<br>
<br>
January 20, 2003<br>
<br>
</center>
</h2>
<p> Copyright &copy; 2002-2003 by Tungsten Graphics, Inc., Cedar Park,
Texas. All Rights Reserved. <br>
<br>
Permission is granted to make and distribute verbatim copies of this
document provided the copyright notice and this permission notice are
preserved on all copies.<br>
<br>
</p>
<h1>1. Introduction</h1>
<p>The Mini GLX interface facilitates OpenGL rendering on embedded
devices. The interface is a subset of the GLX interface, plus a minimal
set of Xlib-like functions.</p>
<p>Programs written to the Mini GLX specification should run unchanged
on systems with the X Window System and the GLX extension. The intention
is to allow flexibility for prototyping and testing.</p>
<p>This document serves as both the reference guide and programming
guide for Mini GLX.<br>
<br>
</p>
<h1>2. Mini GLX Concepts</h1>
<p>The OpenGL specification does not describe how OpenGL rendering
contexts and drawing surfaces (i.e. the frame buffer) are created and
managed. Rather, this is handled by an OpenGL window system interface,
such as Mini GLX.</p>
<p>There are three main datatypes or resources managed by Mini GLX. The
resources and their corresponding GLX or Xlib data types are:</p>
<table cellspacing="10" align="center">
<tbody>
<tr>
<td><u>Resource</u></td>
<td><u>Data type</u></td>
</tr>
<tr>
<td>pixel formats</td>
<td>X Visual and XVisualInfo</td>
</tr>
<tr>
<td>drawing surfaces</td>
<td>X Window or GLXDrawable</td>
</tr>
<tr>
<td>rendering contexts</td>
<td>GLXContext</td>
</tr>
</tbody>
</table>
<p>Pixel formats or X Visuals describe the per-pixel attributes of the
frame buffer. For example, bits per color component, Z buffer size,
stencil size, TrueColor vs PseudoColor, etc.</p>
<p>Drawing surfaces or X Windows typically describe a spatial
allocation of the frame buffer (i.e. the position and size of a
rectangular region of pixels). Since MiniGLX doesn't really support a
window system, the window is effectively the entire frame buffer.</p>
<p>A rendering context represents the current OpenGL state such as
current drawing color, line width, blending mode, texture parameters,
etc. Several rendering contexts can be created but only one can be in
use at any given time.</p>
<p>The Mini GLX interface provides all the functions needed for
choosing pixel formats, create drawing surfaces, creating rendering
contexts and binding rendering contexts to drawing surfaces.<br>
<br>
</p>
<h1>3. Using Mini GLX</h1>
<p>To use the Mini GLX interface in your application, include the
GL/miniglx.h header file at compile time:</p>
<blockquote><code> #include &lt;GL/miniglx.h&gt;<br>
</code></blockquote>
<code></code>Applications should link with libGL.so (i.e. <code>gcc
myprogram.o -lGL -o myprogram</code>). &nbsp;libGL.so implements the
MiniGLX API functions and, in turn, loads a hardware-specific device
driver (such as <code>radeon_dri.so</code>) at runtime. &nbsp;The
environment variable <code>LIBGL_DRIVERS_PATH</code> should name the
directory where these modules are located.<br>
<br>
The remainder of this section describes the MiniGLX API functions.<br>
<br>
<h2>3.1 Initialization</h2>
<p>The XOpenDisplay function is used to initialize the graphics system:</p>
<blockquote>
<pre>Display *XOpenDisplay(const char *displayname)<br></pre>
</blockquote>
<p>The <code>displayName</code> parameter is currently ignored in Mini
GLX. It is recommended that <code>NULL</code> be passed as the<code>displayName</code>
parameter.</p>
<p>If XOpenDisplay is able to initialize the graphics system a pointer
to a Display will be returned. Otherwise, NULL will be returned.</p>
<h2>3.2 Choosing a Visual</h2>
<p>A visual (i.e. pixel format) must be chosen before a drawing surface
or rendering context can be created. This is done with the
glXChooseVisual function:</p>
<blockquote>
<pre>XVisualInfo *glXChooseVisual(Display *dpy, int screen, const int *attribList)<br></pre>
</blockquote>
<p><code>dpy</code> is a pointer to the display returned by
XOpenDisplay. </p>
<p><code>screen</code> is currently ignored by Mini GLX and should be
zero. </p>
<p><code>attribList</code> is a list of GLX attributes which describe
the desired pixel format. It is terminated by the token <code>None</code>.
The attributes are as follows:</p>
<blockquote>
<dl>
<dt><code>GLX_USE_GL</code></dt>
<dd>This attribute should always be present in order to maintain
compatibility with GLX.</dd>
<dt><code>GLX_RGBA</code></dt>
<dd>If present, only RGBA pixel formats will be considered.
Otherwise, only color index formats are considered.</dd>
<dt><code>GLX_DOUBLEBUFFER</code></dt>
<dd>if present, only double-buffered pixel formats will be chosen.</dd>
<dt><code>GLX_RED_SIZE n</code></dt>
<dd>Must be followed by a non-negative integer indicating the
minimum number of bits per red pixel component that is acceptable.</dd>
<dt><code>GLX_GREEN_SIZE n</code></dt>
<dd>Must be followed by a non-negative integer indicating the
minimum number of bits per green pixel component that is acceptable.</dd>
<dt><code>GLX_BLUE_SIZE n</code></dt>
<dd>Must be followed by a non-negative integer indicating the
minimum number of bits per blue pixel component that is acceptable.</dd>
<dt><code>GLX_ALPHA_SIZE n</code></dt>
<dd>Must be followed by a non-negative integer indicating the
minimum number of bits per alpha pixel component that is acceptable.</dd>
<dt><code>GLX_STENCIL_SIZE n</code></dt>
<dd>Must be followed by a non-negative integer indicating the
minimum number of bits per stencil value that is acceptable.</dd>
<dt><code>None</code></dt>
<dd>This token is used to terminate the attribute list.</dd>
</dl>
</blockquote>
<p>glXChooseVisual will return a pointer to an XVisualInfo object which
most closely matches the requirements of the attribute list. If there
is no visual which matches the request, NULL will be returned.</p>
<p>Note that visuals with accumulation buffers and depth buffers are
not available.<br>
<br>
</p>
<h2>3.3 Creating a Drawing Surface</h2>
<p>Drawing surfaces are created as X windows. &nbsp;For Mini GLX,
windows are <i>full-screen</i>; they cover the entire frame buffer.
&nbsp;Also, Mini GLX imposes a limit of one window. A second window
cannot be created until the first one is destroyed.</p>
<h3>3.3.1 Window Creation</h3>
<p>The XCreateWindow function is used to create a drawing surface:</p>
<blockquote>
<pre>Window XCreateWindow( Display *display,<br> Window parent,<br> int x, int y,<br> unsigned int width, unsigned int height,<br> unsigned int borderWidth,<br> int depth,<br> unsigned int class,<br> Visual *visual,<br> unsigned long valuemask,<br> XSetWindowAttributes *attributes )<br></pre>
</blockquote>
<p>The parameters are as follows:</p>
<blockquote>
<dl>
<dt><code>display</code></dt>
<dd>A Display pointer, as returned by XOpenDisplay.</dd>
<dt><code>parent</code></dt>
<dd>The parent window for the new window. For Mini GLX, this
should be<code>RootWindow(dpy, 0)</code>.</dd>
<dt><code>x, y</code></dt>
<dd>The position of the window. For Mini GLX, both values should
be zero.</dd>
<dt><code>width, height</code></dt>
<dd>The size of the window. For Mini GLX, this specifies the
desired screen size such as 1024, 768 or 1280, 1024.</dd>
<dt><code>borderWidth</code></dt>
<dd>This parameter should be zero.</dd>
<dt><code>depth</code></dt>
<dd>The pixel depth for the window. For Mini GLX this should be
the depth found in the XVisualInfo object returned by <code>glxChooseVisual</code>.</dd>
<dt><code>class</code></dt>
<dd>The window class. For Mini GLX this value should be <code>InputOutput</code>.</dd>
<dt><code>visual</code></dt>
<dd>This parameter should be the <code>visual</code> field of the <code>XVisualInfo</code>
object returned by <code>glxChooseVisual</code>.</dd>
<dt><code>valuemask</code></dt>
<dd>This parameter indicates which fields of the <code>XSetWindowAttributes</code>
are to be used. For Mini GLX this is typically the bitmask<code>CWBackPixel
| CWBorderPixel | CWColormap</code>.</dd>
<dt><code>attributes</code></dt>
<dd>Initial window attributes. Of the fields in the <code>XSetWindowAttributes</code>
structure, the<code>background_pixel</code>, <code>border_pixel</code>
and <code>colormap</code> fields should be set. &nbsp;See the discussion
below regarding colormaps.</dd>
</dl>
</blockquote>
<p><code>XCreateWindow</code> will return a window handle if it succeeds
or zero if it fails.</p>
<h3>3.3.2 Window Mapping</h3>
<p>To display the window the XMapWindow function must be called:</p>
<blockquote>
<pre>void XMapWindow(Display *dpy, Window w)</pre>
</blockquote>
<p>This function does nothing in Mini GLX but is required for Xlib/GLX
compatibility</p>
<h3>3.3.3 Colormaps<br>
</h3>
<p>Xlib requires specification of a colormap when creating a window.
&nbsp;For purposes of interoperability, Mini GLX requires this as well,
though the colormap is not actually used. &nbsp;The XCreateColormap
function is used to create a colormap:</p>
<blockquote><code>Colormap XCreateColormap(Display *dpy, Window window,
Visual *visual, int alloc)</code><br>
<code></code></blockquote>
<p>The parameters are as follows:<br>
</p>
<blockquote>
<dl>
<dt><code>dpy</code></dt>
<dd>The display handle as returned by XOpenDisplay.</dd>
<dt><code>window</code></dt>
<dd> This parameter is ignored by Mini GLX but should be the value
returned by the <code>RootWindow(dpy, 0)</code> macro.<br>
</dd>
<dt><code>visual</code></dt>
<dd>This parameter is ignored by Mini GLX but should be the visual
field of the XVisualInfo object returned by glXChooseVisual. </dd>
<dt><code>alloc</code></dt>
<dd>This parameter is ignored by Mini GLX but should be set to <code>AllocNone</code>.</dd>
</dl>
</blockquote>
<br>
<h2>3.4 Creating a Rendering Context</h2>
<p>An OpenGL rendering context is created with the <code>glXCreateContext</code>
function:</p>
<blockquote>
<pre>GLXContext glXCreateContext(Display *dpy, XVisualInfo *visInfo, GLXContext shareList, Bool direct)<br></pre>
</blockquote>
<p>The parameters are as follows:</p>
<blockquote>
<dl>
<dt><code>dpy</code></dt>
<dd>The display handle as returned by XOpenDisplay.</dd>
<dt><code>visInfo</code></dt>
<dd>The visual as returned by glXChooseVisual.</dd>
<dt><code>shareList</code></dt>
<dd>If non-zero, texture objects and display lists are shared with
the named rendering context. If zero, texture objects and display lists
will (initially) be private to this context. They may be shared when a
subsequent context is created.</dd>
<dt><code>direct</code></dt>
<dd>Specifies whether direct or indirect rendering is desired. For
Mini GLX this value is ignored but it should be set to <code>True</code>.</dd>
</dl>
</blockquote>
<p><code>glXCreateContext</code> will return a GLXContext handle if it
succeeds or zero if it fails due to invalid parameter or insufficient
resources.<br>
<br>
</p>
<h2>3.5 Binding a Rendering Context</h2>
<p>The final step before beginning OpenGL rendering is to bind (i.e.
activate) a rendering context and drawing surface with the
glXMakeCurrent function:</p>
<blockquote>
<pre>Bool glXMakeCurrent(Display *dpy, GLXDrawable drawable, GLXContext ctx)<br></pre>
</blockquote>
<p>The parameters are as follows:</p>
<blockquote>
<dl>
<dt><code>dpy</code></dt>
<dd>The display handle, as returned by XOpenDisplay.</dd>
<dt><code>drawable</code></dt>
<dd>The window or drawable to bind to the rendering context. This
should be the value returned by XCreateWindow.</dd>
<dt><code>ctx</code></dt>
<dd>The rendering context to bind, as returned by glXCreateContext.</dd>
</dl>
</blockquote>
<p>If glXMakeCurrent succeeds True is returned. Otherwise False is
returned to indicate an invalid display, window or context parameter.</p>
<p>After the rendering context has been bound to the drawing surface
OpenGL rendering can begin.</p>
<p>The current rendering context may be unbound by calling
glXMakeCurrent with the window and context parameters set to zero.</p>
<p>An application may create any number of rendering contexts and bind
them as needed. Note that binding a rendering context is generally not a
light-weight operation. &nbsp;Most simple OpenGL applications create
only one rendering context.<br>
<br>
</p>
<h2>3.6 Color Buffer Swapping</h2>
<p>A double buffered window has two color buffers: a front buffer and a
back buffer. Normally, rendering is directed to the back buffer while
the front buffer is displayed. When rendering of a frame is finished
the front and back buffers are swapped to provide the illusion of
instanteous screen updates.</p>
<p>The color buffers for a particular window (i.e. drawable) may be
swapped with the glXSwapBuffers command:</p>
<blockquote>
<pre>void glXSwapBuffers(Display *dpy, GLXDrawable drawable)<br></pre>
</blockquote>
Any pending rendering commands will be completed before the buffer swap
takes place.<br>
<br>
Calling glXSwapBuffers on a window which is single-buffered has no
effect.<br>
<br>
<h2>3.7 Releasing Resources</h2>
<h3>3.7.1 Releasing Rendering Contexts</h3>
<p>A rendering context may be destroyed by calling glXDestroyContext:</p>
<blockquote>
<pre>void glXDestroyContext(Display *dpy, GLXContext ctx)<br></pre>
</blockquote>
<h3>3.7.2 Releasing Windows</h3>
<p>A window may be destroyed by calling XDestroyWindow:</p>
<blockquote>
<pre>void XDestroyWindow(Display *dpy, Window window)<br></pre>
</blockquote>
<h3>3.7.3 Releasing Visuals</h3>
<p>An XVisualInfo object may be freed by calling XFree:</p>
<blockquote>
<pre>void XFree(void *data)<br></pre>
</blockquote>
<h3>3.7.4 Releasing Colormaps</h3>
<p>A colormap may be freed by calling XFreeColormap:</p>
<blockquote>
<pre>void XFreeColormap(Display *dpy, Colormap colormap)<br></pre>
</blockquote>
<h3>3.7.4 Releasing Display Resources</h3>
<p>When the application is about to exit, the resources associated with
the graphics system can be released by calling XCloseDisplay:</p>
<blockquote>
<pre>void XCloseDisplay(Display *dpy)<br></pre>
</blockquote>
<p>The display handle becomes invalid at this point.<br>
<br>
</p>
<h2>3.8 Query Functions</h2>
<h3>3.8.1 Querying Available Visuals</h3>
A list of all available visuals can be obtained with the XGetVisualInfo
function:<br>
<br>
<div style="margin-left: 40px;"><code>XVisualInfo
*XGetVisualInfo(Display *dpy, long vinfo_mask, XVisualInfo
*vinfo_template, int *nitems_return)<br>
</code></div>
<br>
The parameters are as follows:<br>
<blockquote>
<dl>
<dt><code>dpy</code></dt>
<dd>The display handle, as returned by XOpenDisplay.</dd>
<dt><code>vinfo_mask</code></dt>
<dd>A bitmask indicating which fields of the vinfo_template are to
be matched. &nbsp;The value must be VisualScreenMask.</dd>
<dt><code>vinfo_template</code></dt>
<dd>A template whose fields indicate which visual attributes must
be matched by the results. &nbsp;The screen field of this structure must
be zero.</dd>
<dt><code>nitems_return</code></dt>
<dd>Returns the number of visuals returned. </dd>
</dl>
</blockquote>
The return value is the address of an array of all available visuals.<br>
<br>
An example of using XGetVisualInfo to get all available visuals follows:<br>
<br>
<div style="margin-left: 40px;"><code>XVisualInfo visTemplate, *results;</code><br>
<code>int numVisuals;</code><br>
<code>Display *dpy = XOpenDisplay(NULL);</code><br>
<code>visTemplate.screen = 0;</code><br>
<code>results = XGetVisualInfo(dpy, VisualScreenMask, &amp;visTemplate,
&amp;numVisuals);</code><br>
<code></code></div>
<br>
<h3>3.8.2 Querying Visual Attributes</h3>
<p>The GLX attributes of an X visual may be queried with the
glXGetConfig function:</p>
<blockquote>
<pre>int glXGetConfig(Display *dpy, XVisualInfo *vis, int attribute, int *value)<br></pre>
</blockquote>
<p>The parameters are as follows:</p>
<blockquote>
<dl>
<dt><code>dpy</code></dt>
<dd>The display handle, as returned by XOpenDisplay.</dd>
<dt><code>vis</code></dt>
<dd>The visual, as returned by glXChooseVisual.</dd>
<dt><code>attribute</code></dt>
<dd>The attribute to query. The attributes are listed below.</dd>
<dt><code>value</code></dt>
<dd>Pointer to an integer in which the result of the query will be
stored. </dd>
</dl>
</blockquote>
<p>The return value will be zero if no error occurs.<code>
&nbsp;GLX_INVALID_ATTRIBUTE</code> will be returned if the attribute
parameter is invalid.<code> &nbsp;GLX_BAD_VISUAL</code> will be returned
if the XVisualInfo parameter is invalid.</p>
<p>The following attributes may be queried:</p>
<blockquote>
<dl>
<dt><code>GLX_USE_GL</code></dt>
<dd>The result will be <code>True</code> or <code>False</code> to
indicate if OpenGL rendering is supported with the visual. Mini GLX
always return <code>True</code>.</dd>
<dt><code>GLX_RGBA</code></dt>
<dd>The result will be <code>True</code> for RGBA visuals or <code>False</code>
for color index visuals.</dd>
<dt><code>GLX_DOUBLEBUFFER</code></dt>
<dd>The result will be <code>True</code> if the visual has two
color buffers or <code>False</code> if the visual has one color buffer.</dd>
<dt><code>GLX_RED_SIZE</code></dt>
<dd>The result will be the number of red bits per pixel.</dd>
<dt><code>GLX_GREEN_SIZE</code></dt>
<dd>The result will be the number of green bits per pixel.</dd>
<dt><code>GLX_BLUE_SIZE</code></dt>
<dd>The result will be the number of blue bits per pixel.</dd>
<dt><code>GLX_ALPHA_SIZE</code></dt>
<dd>The result will be the number of alpha bits per pixel.</dd>
<dt><code>GLX_DEPTH_SIZE</code></dt>
<dd>The result will be the number of bits per Z value.</dd>
<dt><code>GLX_STENCIL_SIZE</code></dt>
<dd>The result will be the number of bits per stencil value.<br>
<br>
</dd>
</dl>
</blockquote>
<h3>3.8.3 Querying the Current Rendering Context</h3>
<p>The current rendering context can be queried with
glXGetCurrentContext: </p>
<blockquote>
<pre>GLXContext glXGetCurrentContext(void)<br></pre>
</blockquote>
<p>Zero will be returned if no context is currently bound.<br>
<br>
</p>
<h3>3.8.4 Querying the Current Drawable</h3>
<p>The current drawable (i.e. window or drawing surface) can be queried
with glXGetCurrentDrawable:</p>
<blockquote>
<pre>GLXDrawable glXGetCurrentDrawable(void)<br></pre>
</blockquote>
<p>Zero will be returned if no drawable is currently bound.<br>
<br>
</p>
<h3>3.8.5 Function Address Queries</h3>
<p>The glXGetProcAddress function will return the address of any
available OpenGL or Mini GLX function:</p>
<blockquote>
<pre>void *glXGetProcAddress(const GLubyte *procName)<br></pre>
</blockquote>
<p>If <code>procName</code> is a valid function name, a pointer to that
function will be returned. &nbsp;Otherwise, NULL will be returned.</p>
<p>The purpose of glXGetProcAddress is to facilitate using future
extensions to OpenGL or Mini GLX. If a future version of the library
adds new extension functions they'll be accessible via
glXGetProcAddress. The alternative is to hard-code calls to the new
functions in the application but doing so will prevent linking the
application with older versions of the library.<br>
<br>
</p>
<h2>3.9 Versioning</h2>
The Mini GLX version can be queried at run time with glXQueryVersion:
<blockquote>
<pre>Bool glXQueryVersion(Display *dpy, int *major, int *minor)<br></pre>
</blockquote>
<p><code>major</code> will be set to the major version number and<code>minor</code>
will be set to the minor version number.<code>True</code> will be
returned if the function succeeds. <code>False</code> will be returned
if the function fails due to invalid parameters. The <code>dpy</code>
argument is currently ignored, but should be the value returned by
XOpenDisplay.</p>
<p>At compile time, the Mini GLX interface version can be tested with
the MINI_GLX_VERSION_1_<i>x</i> preprocessor tokens. For example, if
version 1.0 of Mini GLX is supported, then<code> MINI_GLX_VERSION_1_0</code>
will be defined. If version 1.1 of Mini GLX is supported, then<code>
MINI_GLX_VERSION_1_1</code> will be defined.</p>
<p>At the time of writing the current Mini GLX version is 1.0.<br>
<br>
</p>
<h1>4.0 Interoperability with GLX and Xlib</h1>
While Mini GLX strives to be compatible with GLX and Xlib there are
some unavoidable differences which must be taken into consideration.<br>
<h2>4.1 Public vs Private Structures</h2>
The structure of many X data types is public. &nbsp;For example, the <code>Display</code>
data type is defined as a structure in /usr/include/X11/Xlib.h and
programmers may access any fields of that structure at will. &nbsp;Mini
GLX also defines a Display data type but its fields are hidden and not
visiblein <code>miniglx.h</code>. &nbsp;Duplicating the Xlib
declaration for the <code>Display</code> data type in minigl.h would
require defining a large number of other superfluous Xlib datatypes.<br>
<br>
Mini GLX users are discouraged from directly accessing the fields of
Xlib data types to maximize portability - though this is unavoidable to
some extent. &nbsp;For example, the <code>XVisualInfo</code> and <code>XSetWindowAtttributes</code>
data types must be completely public.
<h2>4.2 Macros</h2>
In some cases, Xlib defines macros which are meant to be used instead
of direct structure accesses. &nbsp;For example, the <code>RootWindow(dpy,
screen)</code> macro returns the root window for a given screen on a
given display. &nbsp;Unfortunately, macros do nothing to aid in ABI
compatibility since they are resolved at compile time instead of at
link/run time.<br>
<br>
Mini GLX also defines a <code>RootWindow</code> macro since it's
essential for creating windows. &nbsp;But the implementation of this
macro by Xlib and Mini GLX is completely different.<br>
<h2>4.3 Summary</h2>
Because Xlib and Mini GLX define data types and macros differently,
Mini GLX applications must be recompiled when retargeting Mini GLX or
native Xlib/GLX. &nbsp;That is, applications can't simply be re-linked
because of ABI incompatibilities.<br>
<br>
Nevertheless, the fact that Mini GLX programs can be recompiled for
Xlib and GLX increases portability and flexibility for testing and
prototyping.<br>
<br>
<h1>5.0 Example Program</h1>
<p>This section shows an example program which uses the Mini GLX
interface. The program simply draws several frames of a rotating square.<br>
</p>
<p>The program may be compiled for use with Xlib/GLX or Mini GLX by
setting the <code>USE_MINIGLX</code> token to 0 or 1, respectively.
&nbsp;Note that the only difference is the header files which are
included.<br>
</p>
<p> </p>
<pre><code><br></code>#define USE_MINIGLX 1 /* 1 = use Mini GLX, 0 = use Xlib/GLX */<br><br>#include &lt;stdio.h&gt;<br>#include &lt;stdlib.h&gt;<br>#include &lt;GL/gl.h&gt;<br><br>#if USE_MINIGLX<br>#include &lt;GL/miniglx.h&gt;<br>#else<br>#include &lt;GL/glx.h&gt;<br>#include &lt;X11/Xlib.h&gt;<br>#endif<br><br><code>/*<br> * Create a simple double-buffered RGBA window.<br> */<br>static Window<br>MakeWindow(Display * dpy, unsigned int width, unsigned int height)<br>{<br> int visAttributes[] = {<br> GLX_RGBA,<br> GLX_RED_SIZE, 1,<br> GLX_GREEN_SIZE, 1,<br> GLX_BLUE_SIZE, 1,<br> GLX_DOUBLEBUFFER,<br> None<br> };<br> XSetWindowAttributes attr;<br> unsigned long attrMask;<br> Window root;<br> Window win;<br> GLXContext ctx;<br> XVisualInfo *visinfo;<br><br> root = RootWindow(dpy, 0);<br><br> /* Choose GLX visual / pixel format */<br> visinfo = glXChooseVisual(dpy, 0, visAttributes);<br> if (!visinfo) {<br> printf("Error: couldn't get an RGB, Double-buffered visual\n");<br> exit(1);<br> }<br><br> /* Create the window */<br> attr.background_pixel = 0;<br> attr.border_pixel = 0;<br> attr.colormap = XCreateColormap(dpy, root, visinfo-&gt;visual, AllocNone);<br> attrMask = CWBackPixel | CWBorderPixel | CWColormap;<br> win = XCreateWindow(dpy, root, 0, 0, width, height,<br> 0, visinfo-&gt;depth, InputOutput,<br> visinfo-&gt;visual, attrMask, &amp;attr);<br> if (!win) {<br> printf("Error: XCreateWindow failed\n");<br> exit(1);<br> }<br><br> /* Display the window */<br> XMapWindow(dpy, win);<br><br> /* Create GLX rendering context */<br> ctx = glXCreateContext(dpy, visinfo, NULL, True);<br> if (!ctx) {<br> printf("Error: glXCreateContext failed\n");<br> exit(1);<br> }<br><br> /* Bind the rendering context and window */<br> glXMakeCurrent(dpy, win, ctx);<br><br> return win;<br>}<br><br><br>/*<br> * Draw a few frames of a rotating square.<br> */<br>static void<br>DrawFrames(Display * dpy, Window win)<br>{<br> int angle;<br> glShadeModel(GL_FLAT);<br> glClearColor(0.5, 0.5, 0.5, 1.0);<br> for (angle = 0; angle &lt; 360; angle += 10) {<br> glClear(GL_COLOR_BUFFER_BIT);<br> glColor3f(1.0, 1.0, 0.0);<br> glPushMatrix();<br> glRotatef(angle, 0, 0, 1);<br> glRectf(-0.8, -0.8, 0.8, 0.8);<br> glPopMatrix();<br> glXSwapBuffers(dpy, win);<br> }<br>}<br><br><br>int<br>main(int argc, char *argv[])<br>{<br> Display *dpy;<br> Window win;<br><br> dpy = XOpenDisplay(NULL);<br> if (!dpy) {<br> printf("Error: XOpenDisplay failed\n");<br> return 1;<br> }<br><br> win = MakeWindow(dpy, 300, 300);<br><br> DrawFrames(dpy, win);<br><br> return 0;<br>}<br></code></pre>
<br>
</body>
</html>

View File

@@ -1,230 +0,0 @@
Name
MESA_packed_depth_stencil
Name Strings
GL_MESA_packed_depth_stencil
Contact
Keith Whitwell, VA Linux Systems Inc. (keithw 'at' valinux.com)
Brian Paul, VA Linux Systems Inc. (brianp 'at' valinux.com)
Status
Obsolete.
Version
Number
???
Dependencies
EXT_abgr affects the definition of this extension
SGIS_texture4D affects the definition of this extension
EXT_cmyka affects the definition of this extension
ARB_packed_pixels affects the definition of this extension
Overview
Provides a mechanism for DrawPixels and ReadPixels to efficiently
transfer depth and stencil image data. Specifically, we defined new
packed pixel formats and types which pack both stencil and depth
into one value.
Issues:
1. Is this the right way to distinguish between 24/8 and 8/24
pixel formats? Should we instead provide both:
GL_DEPTH_STENCIL_MESA
GL_STENCIL_DEPTH_MESA
And perhaps just use GL_UNSIGNED_INT, GL_UNSIGNED_SHORT ?
2. If not, is it correct to use _REV to indicate that stencil
preceeds depth in the 1_15 and 8_24 formats?
3. Do we really want the GL_UNSIGNED_SHORT formats?
New Procedures and Functions
None.
New Tokens
Accepted by the <format> parameter of ReadPixels and DrawPixels:
GL_DEPTH_STENCIL_MESA 0x8750
Accepted by the <type> parameter of ReadPixels and DrawPixels:
GL_UNSIGNED_INT_24_8_MESA 0x8751
GL_UNSIGNED_INT_8_24_REV_MESA 0x8752
GL_UNSIGNED_SHORT_15_1_MESA 0x8753
GL_UNSIGNED_SHORT_1_15_REV_MESA 0x8754
Additions to Chapter 2 of the 1.1 Specification (OpenGL Operation)
None
Additions to Chapter 3 of the 1.1 Specification (Rasterization)
One entry is added to table 3.5 (DrawPixels and ReadPixels formats).
The new table is:
Target
Format Name Buffer Element Meaning and Order
----------- ------ -------------------------
COLOR_INDEX Color Color index
STENCIL_INDEX Stencil Stencil index
DEPTH_COMPONENT Depth Depth component
RED Color R component
GREEN Color G component
BLUE Color B component
ALPHA Color A component
RGB Color R, G, B components
RGBA Color R, G, B, A components
BGRA Color B, G, R, A components
ABGR_EXT Color A, B, G, R components
CMYK_EXT Color Cyan, Magenta, Yellow, Black components
CMYKA_EXT Color Cyan, Magenta, Yellow, Black, A components
LUMINANCE Color Luminance component
LUMINANCE_ALPHA Color Luminance, A components
DEPTH_STENCIL Depth, Depth component, stencil index.
Stencil
Table 3.5: DrawPixels and ReadPixels formats. The third column
gives a description of and the number and order of elements in a
group.
Add to the description of packed pixel formats:
<type> Parameter Data of Matching
Token Name Type Elements Pixel Formats
---------------- ---- -------- -------------
UNSIGNED_BYTE_3_3_2 ubyte 3 RGB
UNSIGNED_BYTE_2_3_3_REV ubyte 3 RGB
UNSIGNED_SHORT_5_6_5 ushort 3 RGB
UNSIGNED_SHORT_5_6_5_REV ushort 3 RGB
UNSIGNED_SHORT_4_4_4_4 ushort 4 RGBA,BGRA,ABGR_EXT,CMYK_EXT
UNSIGNED_SHORT_4_4_4_4_REV ushort 4 RGBA,BGRA
UNSIGNED_SHORT_5_5_5_1 ushort 4 RGBA,BGRA,ABGR_EXT,CMYK_EXT
UNSIGNED_SHORT_1_5_5_5_REV ushort 4 RGBA,BGRA
UNSIGNED_INT_8_8_8_8 uint 4 RGBA,BGRA,ABGR_EXT,CMYK_EXT
UNSIGNED_INT_8_8_8_8_REV uint 4 RGBA,BGRA
UNSIGNED_INT_10_10_10_2 uint 4 RGBA,BGRA,ABGR_EXT,CMYK_EXT
UNSIGNED_INT_2_10_10_10_REV uint 4 RGBA,BGRA
UNSIGNED_SHORT_15_1_MESA ushort 2 DEPTH_STENCIL_MESA
UNSIGNED_SHORT_1_15_REV_MESA ushort 2 DEPTH_STENCIL_MESA
UNSIGNED_SHORT_24_8_MESA ushort 2 DEPTH_STENCIL_MESA
UNSIGNED_SHORT_8_24_REV_MESA ushort 2 DEPTH_STENCIL_MESA
UNSIGNED_INT_8_24:
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
+-----------------------+-----------------------------------------------------------------------+
| | |
+-----------------------+-----------------------------------------------------------------------+
first second
element element
UNSIGNED_INT_24_8:
31 30 29 28 27 26 25 24 23 22 21 20 19 18 17 16 15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
+----------------------------------------------------------------------+------------------------+
| | |
+----------------------------------------------------------------------+------------------------+
first second
element element
UNSIGNED_SHORT_15_1:
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
+-----------------------------------------------------------+---+
| | |
+-----------------------------------------------------------+---+
first second
element element
UNSIGNED_SHORT_1_15_REV:
15 14 13 12 11 10 9 8 7 6 5 4 3 2 1 0
+---+-----------------------------------------------------------+
| | |
+---+-----------------------------------------------------------+
second first
element element
The assignment of elements to fields in the packed pixel is as
described in the table below:
First Second Third Fourth
Format Element Element Element Element
------ ------- ------- ------- -------
RGB red green blue
RGBA red green blue alpha
BGRA blue green red alpha
ABGR_EXT alpha blue green red
CMYK_EXT cyan magenta yellow black
DEPTH_STENCIL_MESA depth stencil
Additions to Chapter 4 of the 1.1 Specification (Per-Fragment Operations
and the Frame Buffer)
The new format is added to the discussion of Obtaining Pixels from the
Framebuffer. It should read " If the <format> is one of RED, GREEN,
BLUE, ALPHA, RGB, RGBA, ABGR_EXT, LUMINANCE, or LUMINANCE_ALPHA, and
the GL is in color index mode, then the color index is obtained."
The new format is added to the discussion of Index Lookup. It should
read "If <format> is one of RED, GREEN, BLUE, ALPHA, RGB, RGBA,
ABGR_EXT, LUMINANCE, or LUMINANCE_ALPHA, then the index is used to
reference 4 tables of color components: PIXEL_MAP_I_TO_R,
PIXEL_MAP_I_TO_G, PIXEL_MAP_I_TO_B, and PIXEL_MAP_I_TO_A."
Additions to Chapter 5 of the 1.1 Specification (Special Functions)
None
Additions to Chapter 6 of the 1.1 Specification (State and State Requests)
None
Additions to the GLX Specification
None
GLX Protocol
TBD
Errors
None
New State
None
Revision History
Version 1.0 - 23 Sep 2000
Keith's original version.
Version 1.1 - 3 Nov 2000
Brian's edits, assigned values to new enums.

View File

@@ -1,356 +0,0 @@
Name
MESA_program_debug
Name Strings
GL_MESA_program_debug
Contact
Brian Paul (brian.paul 'at' tungstengraphics.com)
Status
XXX - Not complete yet!!!
Version
Last Modified Date: July 20, 2003
Author Revision: 1.0
Number
TBD
Dependencies
OpenGL 1.4 is required
The extension is written against the OpenGL 1.4 specification.
ARB_vertex_program or ARB_fragment_program or NV_vertex_program
or NV_fragment_program is required.
Overview
The extension provides facilities for implementing debuggers for
vertex and fragment programs.
The concept is that vertex and fragment program debuggers will be
implemented outside of the GL as a utility package. This extension
only provides the minimal hooks required to implement a debugger.
There are facilities to do the following:
1. Have the GL call a user-specified function prior to executing
each vertex or fragment instruction.
2. Query the current program string's execution position.
3. Query the current values of intermediate program values.
The main feature is the ProgramCallbackMESA function. It allows the
user to register a callback function with the GL. The callback will
be called prior to executing each vertex or fragment program instruction.
From within the callback, the user may issue Get* commands to
query current GL state. The GetProgramRegisterfvMESA function allows
current program values to be queried (such as temporaries, input
attributes, and result registers).
There are flags for enabling/disabling the program callbacks.
The current execution position (as an offset from the start of the
program string) can be queried with
GetIntegerv(GL_FRAGMENT_PROGRAM_POSITION_MESA, &pos) or
GetIntegerv(GL_VERTEX_PROGRAM_POSITION_MESA, &pos).
IP Status
None
Issues
1. Is this the right model for a debugger?
It seems prudent to minimize the scope of this extension and leave
it up to the developer (or developer community) to write debuggers
that layer on top of this extension.
If the debugger were fully implemented within the GL it's not
clear how terminal and GUI-based interfaces would work, for
example.
2. There aren't any other extensions that register callbacks with
the GL. Isn't there another solution?
If we want to be able to single-step through vertex/fragment
programs I don't see another way to do it.
3. How do we prevent the user from doing something crazy in the
callback function, like trying to call glBegin (leading to
recursion)?
The rule is that the callback function can only issue glGet*()
functions and no other GL commands. It could be difficult to
enforce this, however. Therefore, calling any non-get GL
command from within the callback will result in undefined
results.
4. Is this extension amenable to hardware implementation?
Hopefully, but if not, the GL implementation will have to fall
back to a software path when debugging. This may be acceptable
for debugging.
5. What's the <data> parameter to ProgramCallbackMESA for?
It's a common programming practice to associate a user-supplied
value with callback functions.
6. Debuggers often allow one to modify intermediate program values,
then continue. Does this extension support that?
No.
New Procedures and Functions (and datatypes)
typedef void (*programcallbackMESA)(enum target, void *data)
void ProgramCallbackMESA(enum target, programcallbackMESA callback,
void *data)
void GetProgramRegisterfvMESA(enum target, sizei len,
const ubyte *registerName, float *v)
New Tokens
Accepted by the <cap> parameter of Enable, Disable, IsEnabled,
GetBooleanv, GetDoublev, GetFloatv and GetIntegerv:
FRAGMENT_PROGRAM_CALLBACK_MESA 0x8bb1
VERTEX_PROGRAM_CALLBACK_MESA 0x8bb4
Accepted by the <pname> parameter GetBooleanv, GetDoublev,
GetFloatv and GetIntegerv:
FRAGMENT_PROGRAM_POSITION_MESA 0x8bb0
VERTEX_PROGRAM_POSITION_MESA 0x8bb4
Accepted by the <pname> parameter of GetPointerv:
FRAGMENT_PROGRAM_CALLBACK_FUNC_MESA 0x8bb2
FRAGMENT_PROGRAM_CALLBACK_DATA_MESA 0x8bb3
VERTEX_PROGRAM_CALLBACK_FUNC_MESA 0x8bb6
VERTEX_PROGRAM_CALLBACK_DATA_MESA 0x8bb7
Additions to Chapter 2 of the OpenGL 1.4 Specification (OpenGL Operation)
None.
Additions to Chapter 3 of the OpenGL 1.4 Specification (Rasterization)
None.
Additions to Chapter 4 of the OpenGL 1.4 Specification (Per-Fragment
Operations and the Frame Buffer)
None.
Additions to Chapter 5 of the OpenGL 1.4 Specification (Special Functions)
In section 5.4 "Display Lists", page 202, add the following command
to the list of those that are not compiled into display lists:
ProgramCallbackMESA.
Add a new section 5.7 "Callback Functions"
The function
void ProgramCallbackMESA(enum target, programcallbackMESA callback,
void *data)
registers a user-defined callback function with the GL. <target>
may be FRAGMENT_PROGRAM_ARB or VERTEX_PROGRAM_ARB. The enabled
callback functions registered with these targets will be called
prior to executing each instruction in the current fragment or
vertex program, respectively. The callbacks are enabled and
disabled by calling Enable or Disable with <cap>
FRAGMENT_PROGRAM_ARB or VERTEX_PROGRAM_ARB.
The callback function's signature must match the typedef
typedef void (*programcallbackMESA)(enum target, void *data)
When the callback function is called, <target> will either be
FRAGMENT_PROGRAM_ARB or VERTEX_PROGRAM_ARB to indicate which
program is currently executing and <data> will be the value
specified when ProgramCallbackMESA was called.
From within the callback function, only the following GL commands
may be called:
GetBooleanv
GetDoublev
GetFloatv
GetIntegerv
GetProgramLocalParameter
GetProgramEnvParameter
GetProgramRegisterfvMESA
GetProgramivARB
GetProgramStringARB
GetError
Calling any other command from within the callback results in
undefined behaviour.
Additions to Chapter 6 of the OpenGL 1.4 Specification (State and
State Requests)
Add a new section 6.1.3 "Program Value Queries":
The command
void GetProgramRegisterfvMESA(enum target, sizei len,
const ubyte *registerName,
float *v)
Is used to query the value of program variables and registers
during program execution. GetProgramRegisterfvMESA may only be
called from within a callback function registered with
ProgramCallbackMESA.
<registerName> and <len> specify the name a variable, input
attribute, temporary, or result register in the program string.
The current value of the named variable is returned as four
values in <v>. If <name> doesn't exist in the program string,
the error INVALID_OPERATION is generated.
Additions to Appendix A of the OpenGL 1.4 Specification (Invariance)
None.
Additions to the AGL/GLX/WGL Specifications
None.
GLX Protocol
XXX TBD
Dependencies on NV_vertex_program and NV_fragment_program
If NV_vertex_program and/or NV_fragment_program are supported,
vertex and/or fragment programs defined by those extensions may
be debugged as well. Register queries will use the syntax used
by those extensions (i.e. "v[X]" to query vertex attributes,
"o[X]" for vertex outputs, etc.)
Errors
INVALID_OPERATION is generated if ProgramCallbackMESA is called
between Begin and End.
INVALID_ENUM is generated by ProgramCallbackMESA if <target> is not
a supported vertex or fragment program type.
Note: INVALID_OPERAION IS NOT generated by GetProgramRegisterfvMESA,
GetBooleanv, GetDoublev, GetFloatv, or GetIntegerv if called between
Begin and End when a vertex or fragment program is currently executing.
INVALID_ENUM is generated by ProgramCallbackMESA,
GetProgramRegisterfvMESA if <target> is not a program target supported
by ARB_vertex_program, ARB_fragment_program (or NV_vertex_program or
NV_fragment_program).
INVALID_VALUE is generated by GetProgramRegisterfvMESA if <registerName>
does not name a known program register or variable.
INVALID_OPERATION is generated by GetProgramRegisterfvMESA when a
register query is attempted for a program target that's not currently
being executed.
New State
XXX finish
(table 6.N, p. ###)
Initial
Get Value Type Get Command Value Description Sec. Attribute
--------- ---- ----------- ----- ----------- ---- ---------
FRAGMENT_PROGRAM_CALLBACK_MESA B IsEnabled FALSE XXX XXX enable
VERTEX_PROGRAM_CALLBACK_MESA B IsEnabled FALSE XXX XXX enable
FRAGMENT_PROGRAM_POSITION_MESA Z+ GetIntegerv -1 XXX XXX -
VERTEX_PROGRAM_POSITION_MESA Z+ GetIntegerv -1 XXX XXX -
FRAGMENT_PROGRAM_CALLBACK_FUNC_MESA P GetPointerv NULL XXX XXX -
VERTEX_PROGRAM_CALLBACK_FUNC_MESA P GetPointerv NULL XXX XXX -
FRAGMENT_PROGRAM_CALLBACK_DATA_MESA P GetPointerv NULL XXX XXX -
VERTEX_PROGRAM_CALLBACK_DATA_MESA P GetPointerv NULL XXX XXX -
XXX more?
New Implementation Dependent State
None.
Revision History
8 July 2003
Initial draft. (Brian Paul)
11 July 2003
Second draft. (Brian Paul)
20 July 2003
Third draft. Lots of fundamental changes. (Brian Paul)
23 July 2003
Added chapter 5 and 6 spec language. (Brian Paul)
Example Usage
The following is a very simple example of how this extension may
be used to print the values of R0, R1, R2 and R3 while executing
vertex programs.
/* This is called by the GL when the vertex program is executing.
* We can only make glGet* calls from within this function!
*/
void DebugCallback(GLenum target, GLvoid *data)
{
GLint pos;
GLuint i;
/* Get PC and current instruction string */
glGetIntegerv(GL_VERTEX_PROGRAM_POSITION_ARB, &pos);
printf("Current position: %d\n", pos);
printf("Current temporary registers:\n");
for (i = 0; i < 4; i++) {
GLfloat v[4];
char s[10];
sprintf(s, "R%d", i);
glGetProgramRegisterfvMESA(GL_VERTEX_PROGRAM_ARB, strlen(s), s, v);
printf("R%d = %g, %g, %g, %g\n", i, v[0], v[1], v[2], v[3]);
}
}
/*
* elsewhere...
*/
/* Register our debugger callback function */
glProgramCallbackMESA(GL_VERTEX_PROGRAM_ARB, DebugCallback, NULL);
glEnable(GL_VERTEX_PROGRAM_CALLBACK_MESA);
/* define/bind a vertex program */
glEnable(GL_VERTEX_PROGRAM);
/* render something */
glBegin(GL_POINTS);
glVertex2f(0, 0);
glEnd();

View File

@@ -1,190 +0,0 @@
Name
MESA_sprite_point
Name Strings
GL_MESA_sprite_point
Contact
Brian Paul, VA Linux Systems Inc. (brianp 'at' valinux.com)
Status
Obsolete - see GL_ARB_point_sprite.
Version
Number
???
Dependencies
GL_EXT_point_parameters effects the definition of this extension
GL_ARB_multitexture effects the definition of this extension
Overview
This extension modifies the way in which points are rendered,
specifically when they're textured. When SPRITE_POINT_MESA is enabled
a point is rendered as if it were a quadrilateral with unique texture
coordinates at each vertex. This extension effectively turns points
into sprites which may be rendered more easily and quickly than using
conventional textured quadrilaterals.
When using point size > 1 or attenuated points this extension is an
effective way to render many small sprite images for particle systems
or other effects.
Issues:
1. How are the texture coordinates computed?
The lower-left corner has texture coordinate (0,0,r,q).
The lower-right, (1,0,r,q). The upper-right, (1,1,r,q).
The upper-left, (0,1,r,q).
2. What about texgen and texture matrices?
Texgen and the texture matrix have no effect on the point's s and t
texture coordinates. The r and q coordinates may have been computed
by texgen or the texture matrix. Note that with a 3D texture and/or
texgen that the r coordinate could be used to select a slice in the
3D texture.
3. What about point smoothing?
When point smoothing is enabled, a triangle fan could be rendered
to approximate a circular point. This could be problematic to
define and implement so POINT_SMOOTH is ignored when drawing sprite
points.
Smoothed points can be approximated by using an appropriate texture
images, alpha testing and blending.
POLYGON_SMOOTH does effect the rendering of the quadrilateral, however.
4. What about sprite rotation?
There is none. Sprite points are always rendered as window-aligned
squares. One could define rotated texture images if desired. A 3D
texture and appropriate texture r coordinates could be used to
effectively specify image rotation per point.
5. What about POLYGON_MODE?
POLYGON_MODE does not effect the rasterization of the quadrilateral.
6. What about POLYGON_CULL?
TBD. Polygon culling is normally specified and implemented in the
transformation stage of OpenGL. However, some rasterization hardware
implements it later during triangle setup.
Polygon culling wouldn't be useful for sprite points since the
quadrilaterals are always defined in counter-clockwise order in
window space. For that reason, polygon culling should probably be
ignored.
7. Should sprite points be alpha-attenuated if their size is below the
point parameter's threshold size?
8. Should there be an advertisized maximum sprite point size?
No. Since we're rendering the point as a quadrilateral there's no
need to limit the size.
New Procedures and Functions
None.
New Tokens
Accepted by the <pname> parameter of Enable, Disable, IsEnabled,
GetIntegerv, GetBooleanv, GetFloatv and GetDoublev:
SPRITE_POINT_MESA 0x????
MAX_SPRITE_POINT_SIZE_MESA 0x???? (need this?)
Additions to Chapter 2 of the 1.1 Specification (OpenGL Operation)
None
Additions to Chapter 3 of the 1.1 Specification (Rasterization)
Section ???.
When SPRITE_POINT_MESA is enabled points are rasterized as screen-
aligned quadrilaterals. If the four vertices of the quadrilateral
are labeled A, B, C, and D, starting at the lower-left corner and moving
counter-clockwise around the quadrilateral, then the vertex and
texture coordinates are computed as follows:
vertex window coordinate texture coordinate
A (x-r, y-r, z, w) (0, 0, r, q)
B (x+r, y-r, z, w) (1, 0, r, q)
C (x+r, y+r, z, w) (1, 1, r, q)
D (x-r, y+r, z, w) (0, 1, r, q)
where x, y, z, w are the point's window coordinates, r and q are the
point's 3rd and 4th texture coordinates and r is half the point's
size. The other vertex attributes (such as the color and fog coordinate)
are simply duplicated from the original point vertex.
Point size may either be specified with PointSize or computed
according to the EXT_point_parameters extension.
The new texture coordinates are not effected by texgen or the texture
matrix. Note, however, that the texture r and q coordinates are passed
unchanged and may have been computed with texgen and/or the texture
matrix.
If multiple texture units are present the same texture coordinate is
used for all texture units.
The point is then rendered as if it were a quadrilateral using the
normal point sampling rules. POLYGON_MODE does not effect the
rasterization of the quadrilateral but POLYGON_SMOOTH does.
POINT_SMOOTH has no effect when SPRITE_POINT_MESA is enabled.
Additions to Chapter 4 of the 1.1 Specification (Per-Fragment Operations
and the Frame Buffer)
None.
Additions to Chapter 5 of the 1.1 Specification (Special Functions)
None
Additions to Chapter 6 of the 1.1 Specification (State and State Requests)
None
Additions to the GLX Specification
None
GLX Protocol
TBD
Errors
None
New State
Add boolean variable SPRITE_POINT_MESA to the point attribute group.
Revision History
Version 1.0 - 4 Dec 2000
Original draft.

View File

@@ -1,359 +0,0 @@
Name
MESA_trace
Name Strings
GL_MESA_trace
Contact
Bernd Kreimeier, Loki Entertainment, bk 'at' lokigames.com
Brian Paul, VA Linux Systems, Inc., brianp 'at' valinux.com
Status
Obsolete.
Version
Number
none yet
Dependencies
OpenGL 1.2 is required.
The extension is written against the OpenGL 1.2 Specification
Overview
Provides the application with means to enable and disable logging
of GL calls including parameters as readable text. The verbosity
of the generated log can be controlled. The resulting logs are
valid (but possibly incomplete) C code and can be compiled and
linked for standalone test programs. The set of calls and the
amount of static data that is logged can be controlled at runtime.
The application can add comments and enable or disable tracing of GL
operations at any time. The data flow from the application to GL
and back is unaffected except for timing.
Application-side implementation of these features raises namespace
and linkage issues. In the driver dispatch table a simple
"chain of responsibility" pattern (aka "composable piepline")
can be added.
IP Status
The extension spec is in the public domain. The current implementation
in Mesa is covered by Mesa's XFree86-style copyright by the authors above.
This extension is partially inspired by the Quake2 QGL wrapper.
Issues
(1) Is this Extension obsolete because it can
be implemented as a wrapper DLL?
RESOLVED: No. While certain operating systems (Win32) provide linkers
that facilitate this kind of solution, other operating systems
(Linux) do not support hierarchical linking, so a wrapper solution
would result in symbol collisions.
Further, IHV's might have builtin support for tracing GL execution
that enjoys privileged access, or that they do not wish to separate
the tracing code from their driver code base.
(2) Should the Trace API explicitely support the notion of "frames?
This would require hooking into glXSwapBuffers calls as well.
RESOLVED: No. The application can use NewTraceMESA/EndTraceMESA
and TraceComment along with external parsing tools to split the
trace into frames, in whatever way considered adequate.
(2a) Should GLX calls be traced?
PBuffers and other render-to-texture solutions demonstrate that
context level commands beyond SwapBuffers might have to be
traced. The GL DLL exports the entry points, so this would not
be out of the question.
(3) Should the specification mandate the actual output format?
RESOLVED: No. It is sufficient to guarantee that all data and commands
will be traced as requested by Enable/DisableTraceMESA, in the order
encountered. Whether the resulting trace is available as a readable
text file, binary metafile, compilable source code, much less which
indentation and formatting has been used, is up to the implementation.
For the same reason this specification does not enforce or prohibit
additional information added to the trace (statistics, profiling/timing,
warnings on possible error conditions).
(4) Should the comment strings associated with names and pointer (ranges)
be considered persistent state?
RESOLVED: No. The implementation is not forced to use this information
on subsequent occurences of name/pointer, and is free to consider it
transient state.
(5) Should comment commands be prohibited between Begin/End?
RESOLVED: Yes, with the exception of TraceCommentMESA. TraceCommentMESA
is transient, the other commands might cause storage of persistent
data in the context. There is no need to have the ability mark names
or pointers between Begin and End.
New Procedures and Functions
void NewTraceMESA( bitfield mask, const ubyte * traceName )
void EndTraceMESA( void )
void EnableTraceMESA( bitfield mask )
void DisableTraceMESA( bitfield mask )
void TraceAssertAttribMESA( bitfield attribMask )
void TraceCommentMESA( const ubyte* comment )
void TraceTextureMESA( uint name, const ubyte* comment )
void TraceListMESA( uint name, const ubyte* comment )
void TracePointerMESA( void* pointer, const ubyte* comment )
void TracePointerRangeMESA( const void* first,
const void* last,
const ubyte* comment )
New Tokens
Accepted by the <mask> parameter of EnableTrace and DisableTrace:
TRACE_ALL_BITS_MESA 0xFFFF
TRACE_OPERATIONS_BIT_MESA 0x0001
TRACE_PRIMITIVES_BIT_MESA 0x0002
TRACE_ARRAYS_BIT_MESA 0x0004
TRACE_TEXTURES_BIT_MESA 0x0008
TRACE_PIXELS_BIT_MESA 0x0010
TRACE_ERRORS_BIT_MESA 0x0020
Accepted by the <pname> parameter of GetIntegerv, GetBooleanv,
GetFloatv, and GetDoublev:
TRACE_MASK_MESA 0x8755
Accepted by the <pname> parameter to GetString:
TRACE_NAME_MESA 0x8756
Additions to Chapter 2 of the OpenGL 1.2.1 Specification (OpenGL Operation)
None.
Additions to Chapter 3 of the OpenGL 1.2.1 Specification (OpenGL Operation)
None.
Additions to Chapter 4 of the OpenGL 1.2.1 Specification (OpenGL Operation)
None.
Additions to Chapter 5 of the OpenGL 1.2.1 Specification (Special Functions)
Add a new section:
5.7 Tracing
The tracing facility is used to record the execution of a GL program
to a human-readable log. The log appears as a sequence of GL commands
using C syntax. The primary intention of tracing is to aid in program
debugging.
A trace is started with the command
void NewTraceMESA( bitfield mask, const GLubyte * traceName )
<mask> may be any value accepted by PushAttrib and specifies a set of
attribute groups. The state values included in those attribute groups
is written to the trace as a sequence of GL commands.
<traceName> specifies a name or label for the trace. It is expected
that <traceName> will be interpreted as a filename in most implementations.
A trace is ended by calling the command
void EndTraceMESA( void )
It is illegal to call NewTraceMESA or EndTraceMESA between Begin and End.
The commands
void EnableTraceMESA( bitfield mask )
void DisableTraceMESA( bitfield mask )
enable or disable tracing of different classes of GL commands.
<mask> may be the union of any of TRACE_OPERATIONS_BIT_MESA,
TRACE_PRIMITIVES_BIT_MESA, TRACE_ARRAYS_BIT_MESA, TRACE_TEXTURES_BIT_MESA,
and TRACE_PIXELS_BIT_MESA. The special token TRACE_ALL_BITS_MESA
indicates all classes of commands are to be logged.
TRACE_OPERATIONS_BIT_MESA controls logging of all commands outside of
Begin/End, including Begin/End.
TRACE_PRIMITIVES_BIT_MESA controls logging of all commands inside of
Begin/End, including Begin/End.
TRACE_ARRAYS_BIT_MESA controls logging of VertexPointer, NormalPointer,
ColorPointer, IndexPointer, TexCoordPointer and EdgeFlagPointer commands.
TRACE_TEXTURES_BIT_MESA controls logging of texture data dereferenced by
TexImage1D, TexImage2D, TexImage3D, TexSubImage1D, TexSubImage2D, and
TexSubImage3D commands.
TRACE_PIXELS_BIT_MESA controls logging of image data dereferenced by
Bitmap and DrawPixels commands.
TRACE_ERRORS_BIT_MESA controls logging of all errors. If this bit is
set, GetError will be executed whereever applicable, and the result will
be added to the trace as a comment. The error returns are cached and
returned to the application on its GetError calls. If the user does not
wish the additional GetError calls to be performed, this bit should not
be set.
The command
void TraceCommentMESA( const ubyte* comment )
immediately adds the <comment> string to the trace output, surrounded
by C-style comment delimiters.
The commands
void TraceTextureMESA( uint name, const ubyte* comment )
void TraceListMESA( uint name, const ubyte* comment )
associates <comment> with the texture object or display list specified
by <name>. Logged commands which reference the named texture object or
display list will be annotated with <comment>. If IsTexture(name) or
IsList(name) fail (respectively) the command is quietly ignored.
The commands
void TracePointerMESA( void* pointer, const ubyte* comment )
void TracePointerRangeMESA( const void* first,
const void* last,
const ubyte* comment )
associate <comment> with the address specified by <pointer> or with
a range of addresses specified by <first> through <last>.
Any logged commands which reference <pointer> or an address between
<first> and <last> will be annotated with <comment>.
The command
void TraceAssertAttribMESA( bitfield attribMask )
will add GL state queries and assertion statements to the log to
confirm that the current state at the time TraceAssertAttrib is
executed matches the current state when the trace log is executed
in the future.
<attribMask> is any value accepted by PushAttrib and specifies
the groups of state variables which are to be asserted.
The commands NewTraceMESA, EndTraceMESA, EnableTraceMESA, DisableTraceMESA,
TraceAssertAttribMESA, TraceCommentMESA, TraceTextureMESA, TraceListMESA,
TracePointerMESA and TracePointerRangeMESA are not compiled into display lists.
Examples:
The command NewTraceMESA(DEPTH_BUFFER_BIT, "log") will query the state
variables DEPTH_TEST, DEPTH_FUNC, DEPTH_WRITEMASK, and DEPTH_CLEAR_VALUE
to get the values <test>, <func>, <mask>, and <clear> respectively.
Statements equivalent to the following will then be logged:
glEnable(GL_DEPTH_TEST); (if <test> is true)
glDisable(GL_DEPTH_TEST); (if <test> is false)
glDepthFunc(<func>);
glDepthMask(<mask>);
glClearDepth(<clear>);
The command TraceAssertAttribMESA(DEPTH_BUFFER_BIT) will query the state
variables DEPTH_TEST, DEPTH_FUNC, DEPTH_WRITEMASK, and DEPTH_CLEAR_VALUE
to get the values <test>, <func>, <mask>, and <clear> respectively.
The resulting trace might then look will like this:
{
GLboolean b;
GLint i;
GLfloat f;
b = glIsEnabled(GL_DEPTH_TEST);
assert(b == <test>);
glGetIntegerv(GL_DEPTH_FUNC, &i);
assert(i == <func>);
glGetIntegerv(GL_DEPTH_MASK, &i);
assert(i == <mask>);
glGetFloatv(GL_DEPTH_CLEAR_VALUE, &f);
assert(f == <clear>);
}
Additions to Chapter 6 of the OpenGL 1.2.1 Specification
(State and State Requests)
Querying TRACE_MASK_MESA with GetIntegerv, GetFloatv, GetBooleanv or
GetDoublev returns the current command class trace mask.
Querying TRACE_NAME_MESA with GetString returns the current trace name.
Additions to Appendix A of the OpenGL 1.2.1 Specification (Invariance)
The MESA_trace extension can be used in a way that does not affect data
flow from application to OpenGL, as well as data flow from OpenGL to
application, except for timing, possible print I/O. TRACE_ERRORS_BIT_MESA
will add additional GetError queries. Setting a trace mask with NewTraceMESA
as well as use of TraceAssertAttribMESA might cause additional state queries.
With the possible exception of performance, OpenGL rendering should not be
affected at all by a properly chosen logging operation.
Additions to the AGL/GLX/WGL Specifications
None.
GLX Protocol
None. The logging operation is carried out client-side, by exporting
entry points to the wrapper functions that execute the logging operation.
Errors
INVALID_OPERATION is generated if any trace command except TraceCommentMESA
is called between Begin and End.
New State
The current trace name and current command class mask are stored
per-context.
New Implementation Dependent State
None.
Revision History
* Revision 0.1 - Initial draft from template (bk000415)
* Revision 0.2 - Draft (bk000906)
* Revision 0.3 - Draft (bk000913)
* Revision 0.4 - Reworked text, fixed typos (bp000914)
* Revision 0.5 - Assigned final GLenum values (bp001103)
* Revision 0.6 - TRACE_ERRORS_BIT_MESA (bk000916)
* Revision 0.7 - Added MESA postfix (bk010126)

View File

@@ -644,7 +644,7 @@ Hints and Special Features:
- The Voodoo driver supports the GL_EXT_paletted_texture. it works
only with GL_COLOR_INDEX8_EXT, GL_RGBA palettes and the alpha value
is ignored because this is a limitation of the the current Glide
is ignored because this is a limitation of the current Glide
version and of the Voodoo hardware. See Mesa-3.1/3Dfx/demos/paltex.c for
a demo of this extension.

View File

@@ -1,124 +0,0 @@
DirectX 6 Driver for Mesa 3.0
This software is distributed under the terms of the GNU Library
General Public License, see the LICENSE file for details.
What do you need ?
------------------
- A PC with a DirectX 6 video driver installed.
- Mesa 3.0
- The 3Dfx Glide library 2.3 or later for your OS (the 2.4 works fine).
The Voodoo2 requires the Glide library 2.51. The Glide 3.0 is not
compatible with the Glide 2.x so it doesn't work with the current
version of the driver;
- Visual C++ 5.0 is only compiler test but others should be ok with
changes to the makefiles (CFLAGS/LFLAGS).
- DirectX 6 SDK (was a MS download but not sure if still available).
- SoftIce or another debugger that will get DPF's is nice.
Tested on:
----------
Windows 95
Windows 98
Windows NT 5.0 (beta 2)
What is able to do ?
--------------------
- the driver will try and use DirectX to rasterize the OpenGL primitives
that are sent to the driver. The driver will fall back to SW if the rendering
context is too big. The fallback to SW still uses DirectDraw. If the driver
fails to support and operation (accum, stencil, etc) then it will try and get
Mesa to render it in SW. DirectX 6 features that are unsupported by the
installed DirectX 6 driver will be mapped to some other best fit feature.
How to compile:
---------------
These instructions assume you have Visual C++ installed.
You might need to increase you enviroment space. You can do this by
adding the following statement to you config.sys.
shell=C:\COMMAND.COM C:\ /p /e:8198
Next setup you compiler enviroment by running vcvars32.bat in the Visual C++
'bin' directoy.
c:\DevStudio\VC\bin\vcvars32.bat
Modify the D3D makefile to point at your SDK install. Example has the SDK
installed on my 'f' drive in the root.
file: \Mesa-3.0\src\makefile.d3d
SDKROOT=f:\mssdk
Now you can simply make the project. If you look in the makefile you can see
I have some different targets like 'install'.
nmake /f makefile.d3d
FAQ:
----
1) I don't think the driver is using my DirectX driver.
This maybe true as the current version will only select the Primary D3D driver
installed. If you 3D card is the secondary (3dfx) then your out of luck for this
release.
2) The driver seems like its not HW accelerated.
If you have a video card with limited memory then you might want to try and
change your destop resolution to a low setting (640x480x16) so that the 3D part
of the card has more resources. Remeber the driver can't make the card better...
3) Nothing works.
Make sure you have a DirectX '6' driver installed. Check you driver docs for this
info or use the SDK info utilities.
The final 'dll' is named opengl32.dll and is either in the same directory as the
OpenGL program or in your system directory (x:\windows\system or x:\winnt\system32).
Check your destop resolution. Most DirectX 6 drivers will only support 16bit and
32bit color depth. To find out for sure you can check the DirectX Info Viewer in
the SDK.
4) Rendering doesn't look right.
Sometimes this is because the card doesn't support a feature that that is required.
This is usually due to unsupported alpha functions (test/blend) or texture mapping.
Some cards suffer from too small of an alpha channel. The driver does its best to
fallback on unsupported features. This is not to say the driver may not have a bug(s).
5) Textures look bad.
No mipmapping in this release.
Thanks to:
----------
Brian Paul
Leigh McRae (leigh@altsoftware.com)
February 9, 1999

View File

@@ -1,29 +0,0 @@
Mesa DirectFB Information
Requirements
============
To build Mesa with DirectFB (DirectFBGL) support you need:
- DirectFB at least 1.0.0 (http://directfb.org)
- pkg-config at least 0.9 (http://pkgconfig.sf.net)
Installation
============
Run
make linux-directfb
to build Mesa and DirectFBGL module,
make install
to install OpenGL libraries and
cd src/mesa/drivers/directfb ; make install
to install DirectFBGL module in the proper location.
Actually, that last command may not be needed. Please provide feedback.

View File

@@ -52,9 +52,12 @@ a:visited {
<b>User Topics</b>
<ul>
<li><a href="shading.html" target="MainFrame">Shading Language</a>
<li><a href="egl.html" target="MainFrame">EGL</a>
<li><a href="opengles.html" target="MainFrame">OpenGL ES</a>
<li><a href="openvg.html" target="MainFrame">OpenVG / Vega</a>
<LI><A HREF="envvars.html" target="MainFrame">Environment Variables</A>
<LI><A HREF="osmesa.html" target="MainFrame">Off-Screen Rendering</A>
<LI><A HREF="pbuffers.html" target="MainFrame">Pbuffer Rendering</A>
<LI><A HREF="debugging.html" target="MainFrame">Debugging Tips</A>
<LI><A HREF="perf.html" target="MainFrame">Performance Tips</A>
<LI><A HREF="extensions.html" target="MainFrame">Mesa Extensions</A>
@@ -65,8 +68,8 @@ a:visited {
<ul>
<li><a href="http://sourceforge.net/projects/mesa3d" target="_parent">SourceForge homepage</a>
<li><a href="repository.html" target="MainFrame">Source Code Repository</a>
<li><a href="sourcetree.html" target="MainFrame">Source Code Tree</a>
<li><a href="memory.html" target="MainFrame">DRI Memory Management</a>
<li><a href="shading.html" target="MainFrame">Shading Language</a>
<li><a href="glu.html" target="MainFrame">SGI's GLU</a>
<li><a href="utilities.html" target="MainFrame">Utilities</a>
<li><a href="helpwanted.html" target="MainFrame">Help Wanted</a>
@@ -89,7 +92,6 @@ a:visited {
<li><a href="modelers.html" target="MainFrame">Modeling and Rendering</a>
<li><a href="science.html" target="MainFrame">Science and Technical</a>
<li><a href="utility.html" target="MainFrame">Utilities</a>
<li><a href="demos.html" target="MainFrame">Demos / other</a>
</ul>
<b>Hosted by:</b>

View File

@@ -1,18 +0,0 @@
<HTML>
<TITLE>Demos</TITLE>
<link rel="stylesheet" type="text/css" href="mesa.css"></head>
<BODY>
<H1>Demos</H1>
<ul>
<li><a href="http://www.geocities.com/shobhand/homepage.html">Shobhan Dutta's Geartrain and Walkthrough Demos</a>
</li></ul>
</body>
</html>

View File

@@ -107,7 +107,7 @@ Global variables are not allowed.
Function name examples:
</p>
<pre>
glFooBar() - a public GL entry point (in dispatch.c)
glFooBar() - a public GL entry point (in glapi_dispatch.c)
_mesa_FooBar() - the internal immediate mode function
save_FooBar() - retained mode (display list) function in dlist.c
foo_bar() - a static (private) function

View File

@@ -199,7 +199,7 @@ few preprocessor defines.</p>
<li>If <tt>GLX_USE_TLS</tt> is defined, method #4 is used.</li>
<li>If <tt>PTHREADS</tt> is defined, method #3 is used.</li>
<li>If any of <tt>PTHREADS</tt>,
<tt>SOLARIS_THREADS</tt>, <tt>WIN32_THREADS</tt>, or <tt>BEOS_THREADS</tt>
<tt>WIN32_THREADS</tt>, or <tt>BEOS_THREADS</tt>
is defined, method #2 is used.</li>
<li>If none of the preceeding are defined, method #1 is used.</li>
</ul>
@@ -244,8 +244,8 @@ isn't a significant problem.</p>
system. There are two steps to this. The file must first be added to
<tt>src/mesa/sources</tt>. That gets the file built and linked. The second
step is to add the correct <tt>#ifdef</tt> magic to
<tt>src/mesa/main/dispatch.c</tt> to prevent the C version of the dispatch
functions from being built.</p>
<tt>src/mesa/glapi/glapi_dispatch.c</tt> to prevent the C version of the
dispatch functions from being built.</p>
<A NAME="fixedsize"/>
<H3>3.4. Fixed-Length Dispatch Stubs</H3>

324
docs/egl.html Normal file
View File

@@ -0,0 +1,324 @@
<html>
<title>Mesa EGL</title>
<head><link rel="stylesheet" type="text/css" href="mesa.css"></head>
<body>
<h1>Mesa EGL</h1>
<p>The current version of EGL in Mesa implements EGL 1.4. More information
about EGL can be found at
<a href="http://www.khronos.org/egl/" target="_parent">
http://www.khronos.org/egl/</a>.</p>
<p>The Mesa's implementation of EGL uses a driver architecture. The main
library (<code>libEGL</code>) is window system neutral. It provides the EGL
API entry points and helper functions for use by the drivers. Drivers are
dynamically loaded by the main library and most of the EGL API calls are
directly dispatched to the drivers.</p>
<p>The driver in use decides the window system to support. For drivers that
support hardware rendering, there are usually multiple drivers supporting the
same window system. Each one of of them supports a certain range of graphics
cards.</p>
<h2>Build EGL</h2>
<ol>
<li>
<p>Run <code>configure</code> with the desired state trackers and enable
the Gallium driver for your hardware. For example</p>
<pre>
$ ./configure --with-state-trackers=egl,es,vega --enable-gallium-{swrast,intel}
</pre>
<p>The main library will be enabled by default. The <code>egl</code> state
tracker is needed by a number of EGL drivers. EGL drivers will be covered
later. The <a href="opengles.html">es state tracker</a> provides OpenGL ES 1.x
and 2.x and the <a href="openvg.html">vega state tracker</a> provides OpenVG
1.x.</p>
</li>
<li>Build and install Mesa as usual.</li>
</ol>
<p>In the given example, it will build and install <code>libEGL</code>,
<code>libGLESv1_CM</code>, <code>libGLESv2</code>, <code>libOpenVG</code>, and
one or more EGL drivers.</p>
<h3>Configure Options</h3>
<p>There are several options that control the build of EGL at configuration
time</p>
<ul>
<li><code>--enable-egl</code>
<p>By default, EGL is enabled. When disabled, the main library and the drivers
will not be built.</p>
</li>
<li><code>--with-egl-driver-dir</code>
<p>The directory EGL drivers should be installed to. If not specified, EGL
drivers will be installed to <code>${libdir}/egl</code>.</p>
</li>
<li><code>--with-egl-displays</code>
<p>List the window system(s) to support. It is by default <code>x11</code>,
which supports the X Window System. Its argument is a comma separated string
like, for example, <code>--with-egl-displays=x11,kms</code>. Because an EGL
driver decides which window system to support, this example will enable two
(sets of) EGL drivers. One supports the X window system and the other supports
bare KMS (kernel modesetting).</p>
</li>
<li><code>--with-state-trackers</code>
<p>The argument is a comma separated string. It is usually used to specify the
rendering APIs, like OpenGL ES or OpenVG, to build. But it should be noted
that a number of EGL drivers depend on the <code>egl</code> state tracker.
They will <em>not</em> be built without the <code>egl</code> state tracker.</p>
</li>
<li><code>--enable-gallium-swrast</code>
<p>This option is not specific to EGL. But if there is no driver for your
hardware, or you are experiencing problems with the hardware driver, you can
enable the swrast DRM driver. It is a dummy driver and EGL will fallback to
software rendering automatically.</p>
</li>
</ul>
<h3>OpenGL</h3>
<p>The OpenGL state tracker is not built in the above example. It should be
noted that the classic <code>libGL</code> is not a state tracker and cannot be
used with EGL (unless the EGL driver in use is <code>egl_glx</code>). To build
the OpenGL state tracker, one may append <code>glx</code> to
<code>--with-state-trackers</code> and manually build
<code>src/gallium/winsys/xlib/</code>.</p>
<h2>Use EGL</h2>
<p> The demos for OpenGL ES and OpenVG can be found in <code>progs/es1/</code>,
<code>progs/es2/</code> and <code>progs/openvg/</code>. You can use them to
test your build. For example,</p>
<pre>
$ cd progs/es1/xegl
$ make
$ ./torus
</pre>
<h3>Environment Variables</h3>
<p>There are several environment variables that control the behavior of EGL at
runtime</p>
<ul>
<li><code>EGL_DRIVERS_PATH</code>
<p>By default, the main library will look for drivers in the directory where
the drivers are installed to. This variable specifies a list of
colon-separated directories where the main library will look for drivers, in
addition to the default directory. This variable is ignored for setuid/setgid
binaries.</p>
</li>
<li><code>EGL_DRIVER</code>
<p>This variable specifies a full path to an EGL driver and it forces the
specified EGL driver to be loaded. It comes in handy when one wants to test a
specific driver. This variable is ignored for setuid/setgid binaries.</p>
</li>
<li><code>EGL_DISPLAY</code>
<p>When <code>EGL_DRIVER</code> is not set, the main library loads <em>all</em>
EGL drivers that support a certain window system. <code>EGL_DISPLAY</code> can
be used to specify the window system and the valid values are, for example,
<code>x11</code> or <code>kms</code>. When the variable is not set, the main
library defaults the value to the first window system listed in
<code>--with-egl-displays</code> at configuration time.
</li>
<li><code>EGL_LOG_LEVEL</code>
<p>This changes the log level of the main library and the drivers. The valid
values are: <code>debug</code>, <code>info</code>, <code>warning</code>, and
<code>fatal</code>.</p>
</li>
<li><code>EGL_SOFTWARE</code>
<p>For drivers that support both hardware and software rendering, setting this
variable to true forces the use of software rendering.</p>
</li>
</ul>
<h2>EGL Drivers</h2>
<p>There are two categories of EGL drivers: Gallium and classic.</p>
<p>Gallium EGL drivers supports all rendering APIs specified in EGL 1.4. The
support for optional EGL functions and EGL extensions is usually more complete
than the classic ones. These drivers depend on the <code>egl</code> state
tracker to build. The available drivers are</p>
<ul>
<li><code>egl_&lt;dpy&gt;_i915</code></li>
<li><code>egl_&lt;dpy&gt;_i965</code></li>
<li><code>egl_&lt;dpy&gt;_radeon</code></li>
<li><code>egl_&lt;dpy&gt;_nouveau</code></li>
<li><code>egl_&lt;dpy&gt;_swrast</code></li>
<li><code>egl_&lt;dpy&gt;_vmwgfx</code></li>
</ul>
<p><code>&lt;dpy&gt;</code> is given by <code>--with-egl-displays</code> at
configuration time. There will be one EGL driver for each combination of the
displays listed and the hardware drivers enabled.</p>
<p>Classic EGL drivers, on the other hand, supports only OpenGL as its
rendering API. They can be found under <code>src/egl/drivers/</code>. There
are 3 of them</p>
<ul>
<li><code>egl_glx</code>
<p>This driver provides a wrapper to GLX. It uses exclusively GLX to implement
the EGL API. It supports both direct and indirect rendering when the GLX does.
It is accelerated when the GLX is. As such, it cannot provide functions that
is not available in GLX or GLX extensions.</p>
</li>
<li><code>egl_dri2</code>
<p>This driver supports the X Window System as its window system. It functions
as a DRI2 driver loader. Unlike <code>egl_glx</code>, it has no dependency on
<code>libGL</code>. It talks to the X server directly using DRI2 protocol.</p>
</li>
<li><code>egl_dri</code>
<p>This driver lacks maintenance and does <em>not</em> build. It is similiar
to <code>egl_dri2</code> in that it functions as a DRI(1) driver loader. But
unlike <code>egl_dri2</code>, it supports Linux framebuffer devices as its
window system and supports EGL_MESA_screen_surface extension. As DRI1 drivers
are phasing out, it might eventually be replaced by <code>egl_dri2</code>.</p>
</li>
</ul>
<p>To use the classic drivers, one must manually set <code>EGL_DRIVER</code> at
runtime.</p>
<h2>Developers</h2>
<p>The sources of the main library and the classic drivers can be found at
<code>src/egl/</code>. The sources of the <code>egl</code> state tracker can
be found at <code>src/gallium/state_trackers/egl/</code>.</p>
<p>The suggested way to learn to write a EGL driver is to see how other drivers
are written. <code>egl_glx</code> should be a good reference. It works in any
environment that has GLX support, and it is simpler than most drivers.</p>
<h3>Lifetime of Display Resources</h3>
<p>Contexts and surfaces are examples of display resources. They might live
longer than the display that creates them.</p>
<p>In EGL, when a display is terminated through <code>eglTerminate</code>, all
display resources should be destroyed. Similarly, when a thread is released
throught <code>eglReleaseThread</code>, all current display resources should be
released. Another way to destory or release resources is through functions
such as <code>eglDestroySurface</code> or <code>eglMakeCurrent</code>.</p>
<p>When a resource that is current to some thread is destroyed, the resource
should not be destroyed immediately. EGL requires the resource to live until
it is no longer current. A driver usually calls
<code>eglIs&lt;Resource&gt;Bound</code> to check if a resource is bound
(current) to any thread in the destroy callbacks. If it is still bound, the
resource is not destroyed.</p>
<p>The main library will mark destroyed current resources as unlinked. In a
driver's <code>MakeCurrent</code> callback,
<code>eglIs&lt;Resource&gt;Linked</code> can then be called to check if a newly
released resource is linked to a display. If it is not, the last reference to
the resource is removed and the driver should destroy the resource. But it
should be careful here because <code>MakeCurrent</code> might be called with an
uninitialized display.</p>
<p>This is the only mechanism provided by the main library to help manage the
resources. The drivers are responsible to the correct behavior as defined by
EGL.</p>
<h3><code>EGL_RENDER_BUFFER</code></h3>
<p>In EGL, the color buffer a context should try to render to is decided by the
binding surface. It should try to render to the front buffer if the binding
surface has <code>EGL_RENDER_BUFFER</code> set to
<code>EGL_SINGLE_BUFFER</code>; If the same context is later bound to a
surface with <code>EGL_RENDER_BUFFER</code> set to
<code>EGL_BACK_BUFFER</code>, the context should try to render to the back
buffer. However, the context is allowed to make the final decision as to which
color buffer it wants to or is able to render to.</p>
<p>For pbuffer surfaces, the render buffer is always
<code>EGL_BACK_BUFFER</code>. And for pixmap surfaces, the render buffer is
always <code>EGL_SINGLE_BUFFER</code>. Unlike window surfaces, EGL spec
requires their <code>EGL_RENDER_BUFFER</code> values to be honored. As a
result, a driver should never set <code>EGL_PIXMAP_BIT</code> or
<code>EGL_PBUFFER_BIT</code> bits of a config if the contexts created with the
config won't be able to honor the <code>EGL_RENDER_BUFFER</code> of pixmap or
pbuffer surfaces.</p>
<p>It should also be noted that pixmap and pbuffer surfaces are assumed to be
single-buffered, in that <code>eglSwapBuffers</code> has no effect on them. It
is desirable that a driver allocates a private color buffer for each pbuffer
surface created. If the window system the driver supports has native pbuffers,
or if the native pixmaps have more than one color buffers, the driver should
carefully attach the native color buffers to the EGL surfaces, re-route them if
required.</p>
<p>There is no defined behavior as to, for example, how
<code>glDrawBuffer</code> interacts with <code>EGL_RENDER_BUFFER</code>. Right
now, it is desired that the draw buffer in a client API be fixed for pixmap and
pbuffer surfaces. Therefore, the driver is responsible to guarantee that the
client API renders to the specified render buffer for pixmap and pbuffer
surfaces.</p>
<h3><code>EGLDisplay</code> Mutex</h3>
The <code>EGLDisplay</code> will be locked before calling any of the dispatch
functions (well, except for GetProcAddress which does not take an
<code>EGLDisplay</code>). This guarantees that the same dispatch function will
not be called with the sample display at the same time. If a driver has access
to an <code>EGLDisplay</code> without going through the EGL APIs, the driver
should as well lock the display before using it.
<h3>TODOs</h3>
<ul>
<li>Pass the conformance tests</li>
<li>Better automatic driver selection: <code>EGL_DISPLAY</code> loads all
drivers and might eat too much memory.</li>
</ul>
</body>
</html>

View File

@@ -28,6 +28,7 @@ Setting this variable automatically sets the MESA_TEX_PROG variable as well.
<li>MESA_EXTENSION_OVERRIDE - can be used to enable/disable extensions.
A value such as "GL_EXT_foo -GL_EXT_bar" will enable the GL_EXT_foo extension
and disable the GL_EXT_bar extension.
<li>MESA_GLSL - <a href="shading.html#envvars">shading language options</a>
</ul>
<p>
@@ -50,5 +51,28 @@ See the <A HREF="xlibdriver.html">Xlib software driver page</A> for details.
</ul>
<p>
These environment variables are for the Intel i945/i965 drivers:
</p>
<ul>
<li>INTEL_STRICT_CONFORMANCE - if set to 1, enable sw fallbacks to improve
OpenGL conformance. If set to 2, always use software rendering.
<li>INTEL_NO_BLIT - if set, disable hardware-accelerated glBitmap,
glCopyPixels, glDrawPixels.
</ul>
<p>
These environment variables are for the Radeon R300 driver:
</p>
<ul>
<li>R300_NO_TCL - if set, disable hardware-accelerated Transform/Clip/Lighting.
</ul>
<p>
Mesa EGL supports different sets of environment variables. See the
<a href="egl.html">Mesa EGL</a> page for the details.
</p>
</BODY>
</HTML>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.6 KiB

View File

@@ -35,14 +35,14 @@
<h3>1.1 Prerequisites for DRI and hardware acceleration</h3>
<p>
The following are required for DRI-based hardware acceleration with Mesa 7.3:
The following are required for DRI-based hardware acceleration with Mesa:
</p>
<ul>
<li><a href="http://xorg.freedesktop.org/releases/individual/proto/">dri2proto</a> version 1.99.3 or later
<li>Linux 2.6.28
<li><a href="http://dri.freedesktop.org/libdrm/" target="_parent">libDRM</a>
version 2.4.3 or later
version 2.4.15 or later
<li>Xorg server version 1.5 or later
</ul>
</p>
@@ -351,20 +351,11 @@ example linux or windows, <i>machine</i> is x86 or x86_64, optionally followed
by -debug for debug builds.
</p>
<p>
The sample programs are built seperately. To build them do
<pre>
scons -C progs
</pre>
And the build output will be placed in progs/build/...
</p>
<p>
To build Mesa with SCons for Windows on Linux using the MinGW crosscompiler toolchain do
</p>
<pre>
scons platform=windows toolchain=crossmingw machine=x86 statetrackers=mesa drivers=softpipe,trace winsys=gdi
scons -C progs platform=windows toolchain=crossmingw machine=x86 -k
</pre>
<p>
This will create:

197
docs/libGL.txt Normal file
View File

@@ -0,0 +1,197 @@
Introduction
------------
This document describes the implementation of the XFree86 4.0 libGL.so
library defined by the Linux/OpenGL Base specification found at
http://reality.sgi.com/opengl/linux/linuxbase.html.
The documentation is divided into two sections:
User's Guide
Driver Developer's Guide
Author: Brian Paul (brian@precisioninsight.com)
Date: February 2000
User's Guide
------------
Using libGL.so
The libGL.so library defines the gl- and glX-prefixed functions needed to
run OpenGL programs. OpenGL client applications should link with the
-lGL option to use it.
libGL.so serves two primary functions: GLX protocol generation for indirect
rendering and loading/management of hardware drivers for direct rendering.
When libGL.so initializes itself it uses the DRI to determine the
appropriate hardware driver for each screen on the local X display.
The hardware drivers are expected to be in the /usr/X11R6/lib/modules/dri/
directory. Drivers are named with the convention <name>_dri.so where
<name> is a driver such as "tdfx", "i810", "gamma", etc.
The LIBGL_DRIVERS_DIR environment variable may be used to specify a
different DRI modules directory, overriding /usr/X11R6/lib/modules/dri/.
This environment variable is ignored in setuid programs for security
reasons.
When libGL.so is unable to locate appropriate hardware drivers it will
fall back to using indirect GLX rendering.
To aid in solving problems, libGL.so will print diagnostic messages to
stderr if the LIBGL_DEBUG environment variable is defined.
libGL.so is thread safe. The overhead of thread safety for common,
single-thread clients is negligible. However, the overhead of thread
safety for multi-threaded clients is significant. Each GL API call
requires two calls to pthread_get_specific() which can noticably
impact performance. Warning: libGL.so is thread safe but individual
DRI drivers may not be. Please consult the documentation for a driver
to learn if it is thread safe.
Indirect Rendering
You can force indirect rendering mode by setting the LIBGL_ALWAYS_INDIRECT
environment variable. Hardware acceleration will not be used.
libGL.so Extensibility
libGL.so is designed to be extended without upgrading. That is,
drivers may install new OpenGL extension functions into libGL.so
without requiring libGL.so to be replaced. Clients of libGL.so should
use the glXGetProcAddressEXT() function to obtain the address of
functions by name. For more details of GLX_ARB_get_proc_address see
http://oss.sgi.com/projects/ogl-sample/registry/ARB/get_proc_address.spec
libGL.so is also designed with flexibility such that it may be used
with many generations of hardware drivers to come.
Driver Developer's Guide
------------------------
This section describes the requirements to make an XFree86 4.0
libGL.so-compatible hardware driver. It is not intended for end
users of libGL.so.
XFree86 source files
libGL.so is built inside XFree86 with sources found in xc/lib/GL/.
Specifically, libGL.so is built from:
xc/lib/GL/glx/*.c
xc/lib/dri/XF86dri.c
xc/lib/dri/dri_glx.c
xc/lib/GL/mesa/src/glapi.c
xc/lib/GL/mesa/src/glapitemp.h
xc/lib/GL/mesa/src/glapitable.h
xc/lib/GL/mesa/src/glapioffsets.h
xc/lib/GL/mesa/src/glapinoop.c
xc/lib/GL/mesa/src/glheader.h
xc/lib/GL/mesa/src/glthread.c
xc/lib/GL/mesa/src/glthread.h
xc/lib/GL/mesa/src/X86/glapi_x86.S
xc/lib/GL/mesa/src/X86/assyntax.h
Understand that the mesa/src/gl*.[ch] files are not tied to Mesa. They
have no dependencies on the rest of Mesa and are designed to be reusable
in a number of projects.
The glapi_x86.X and assyntax.h files implement x86-optimized dispatch
of GL functions. They are not required; C-based dispatch can be used
instead, with a slight performance penalty.
Driver loading and binding
When libGL.so initializes itself (via the __glXInitialize function) a
call is made to driCreateDisplay(). This function uses DRI facilities
to determine the driver file appropriate for each screen on the local
display. Each screen's driver is then opened with dlopen() and asked
for its __driCreateScreen() function. The pointers to the __driCreateScreen()
functions are kept in an array, indexed by screen number, in the
__DRIdisplayRec struct.
When a driver's __driCreateScreen() function is called, it must initialize
a __DRIscreenRec struct. This struct acts as the root of a tree of
function pointers which are called to create and destroy contexts and
drawables and perform all the operations needed by the GLX interface.
See the xc/lib/GL/glx/glxclient.h file for details.
Dynamic Extension Function Registration
In order to provide forward compatibility with future drivers, libGL.so
allows drivers to register new OpenGL extension functions which weren't
known when libGL.so was built.
The register_extensions() function in xc/lib/GL/dri/dri_glx.c is called
as soon as libGL.so is loaded. This is done with gcc's constructor
attribute. This mechanism will likely have to be changed for other compilers.
register_extensions() loops over all local displays and screens, determines
the DRI driver for each, and calls the driver's __driRegisterExtensions()
function, if present.
The __driRegisterExtensions() function can add new entrypoints to libGL
by calling:
GLboolean _glapi_add_entrypoint(const char *funcName, GLuint offset)
The parameters are the name of the function (such as "glFoobarEXT") and the
offset of the dispatch slot in the API dispatch table. The return value
indicates success (GL_TRUE) or failure (GL_FALSE).
_glapi_add_entrypoint() will synthesize entrypoint code in assembly
language. Assembly languages is required since parameter passing
can't be handled correctly using a C-based solution.
The address of the new entrypoint is obtained by calling the
glXGetProcAddressARB() function.
The dispatch offset number MUST be a number allocated by SGI in the same
manner in which new GL_* constants are allocated. Using an arbitrary
offset number will result in many problems.
Dispatch Management
When a GL context is made current, the driver must install its dispatch
table as the current dispatch table. This is done by calling
void _glapi_set_dispatch(struct _glapi_table *dispatch);
This will install the named dispatch table for the calling thread.
The current dispatch table for a thread can be obtained by calling
struct _glapi_table *_glapi_get_dispatch(void);
For higher performance in the common single-thread case, the global
variable _glapi_Dispatch will point to the current dispatch table.
This variable will be NULL when in multi-thread mode.
Context Management
libGL.so uses the XFree86 xthreads package to manage a thread-specific
current context pointer. See __glXGet/SetCurrentContext() in glext.c
Drivers may use the _glapi_set/get_context() functions to maintain
a private thread-specific context pointer.

View File

@@ -13,36 +13,41 @@
</p>
<ul>
<li><a href="https://lists.sourceforge.net/lists/listinfo/mesa3d-announce"
target="_parent">mesa3d-announce</a> - announcements of new Mesa
versions are sent to this list.
</li>
<br>
<li><a href="https://lists.sourceforge.net/lists/listinfo/mesa3d-users"
target="_parent">mesa3d-users</a> - intended for users of the Mesa and DRI.
Newbie questions are appropriate, but please try the general OpenGL
<li><a href="http://lists.freedesktop.org/mailman/listinfo/mesa-users"
target="_parent">mesa-users</a> - intended for end-users of Mesa and DRI
drivers. Newbie questions are OK, but please try the general OpenGL
resources and Mesa/DRI documentation first.
</li>
<br>
<li><a href="https://lists.sourceforge.net/lists/listinfo/mesa3d-dev"
target="_parent">mesa3d-dev</a> - for discussion of Mesa and Direct Rendering
Infrastructure development. Not for beginners.
<li><a href="http://lists.freedesktop.org/mailman/listinfo/mesa-dev"
target="_parent">mesa-dev</a> - for Mesa, Gallium and DRI development
discussion. Not for beginners.
</li>
<br>
<li><a href="http://lists.freedesktop.org/mailman/listinfo/mesa-commit"
target="_parent">mesa-commit</a> - relays git check-in messages
(for developers).
In general, people should not post to this list.
</li>
<br>
Note: the old mesa3d-cvs list is no longer in use.
<li><a href="http://lists.freedesktop.org/mailman/listinfo/mesa-announce"
target="_parent">mesa-announce</a> - announcements of new Mesa
versions are sent to this list. Very low traffic.
</li>
</ul>
<p>
Follow the links above for list archives.
</p>
<p>For mailing lists about Direct Rendering Modules (drm) in Linux/BSD
kernels, see <a href="http://dri.freedesktop.org/wiki/MailingLists">wiki</a>.
kernels, see the
<a href="http://dri.freedesktop.org/wiki/MailingLists" target="_parent">
DRI wiki</a>.
</p>
<p>
<b>Notice</b>: non-member posts to any of these lists will be automatically
rejected.
<b>Notice</b>: You must subscribe to these lists in order to post to them.
</p>

View File

@@ -10,11 +10,36 @@
<H1>News</H1>
<h2>November XX, 2009</h2>
<h2>April 5, 2010</h2>
<p>
<a href="relnotes-7.8.1.html">Mesa 7.8.1</a> is released. This is a bug-fix
release for a few critical issues in the 7.8 release.
</p>
<h2>March 28, 2010</h2>
<p>
<a href="relnotes-7.7.1.html">Mesa 7.7.1</a> is released. This is a bug-fix
release fixing issues found in the 7.7 release.
</p>
<p>
Also, <a href="relnotes-7.8.html">Mesa 7.8</a> is released. This is a new
development release.
</p>
<h2>December 21, 2009</h2>
<p>
<a href="relnotes-7.6.1.html">Mesa 7.6.1</a> is released. This is a bug-fix
release fixing issues found in the 7.6 release.
</p>
<p>
Also, <a href="relnotes-7.7.html">Mesa 7.7</a> is released. This is a new
development release.
</p>
<h2>September 28, 2009</h2>

Some files were not shown because too many files have changed in this diff Show More