platform/upstream/mesa.git
15 years agoswrast: fix cube face selection
Brian Paul [Mon, 21 Sep 2009 14:32:43 +0000 (08:32 -0600)]
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.

15 years agor600: fix typo in the last commit
Alex Deucher [Mon, 21 Sep 2009 20:48:55 +0000 (16:48 -0400)]
r600: fix typo in the last commit

128 gprs, 256 reg-based consts

15 years agor600: various cleanups
Alex Deucher [Mon, 21 Sep 2009 20:30:14 +0000 (16:30 -0400)]
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>
15 years agomesa: Ensure TGSI tokens are freed with gallium's free.
José Fonseca [Mon, 21 Sep 2009 18:57:57 +0000 (19:57 +0100)]
mesa: Ensure TGSI tokens are freed with gallium's free.

To avoid breaking the gallium's builtin malloc debugging.

15 years agoprogs/perf: added fill-rate test
Brian Paul [Mon, 21 Sep 2009 18:17:49 +0000 (12:17 -0600)]
progs/perf: added fill-rate test

Many more fill modes could be tested, but this hits the basics including
blending, texturing and shaders.

15 years agoprogs/perf: added helpers for creating simple textures and shader programs
Brian Paul [Mon, 21 Sep 2009 17:58:03 +0000 (11:58 -0600)]
progs/perf: added helpers for creating simple textures and shader programs

15 years agoprogs/perf: offsetof() should be defined in stddef.h, include it
Brian Paul [Mon, 21 Sep 2009 17:09:00 +0000 (11:09 -0600)]
progs/perf: offsetof() should be defined in stddef.h, include it

If this breaks mingw, feel free to revert this.

15 years agor300g: Fix bad formatting parameters in calls to debug_printf
Nicolai Hähnle [Mon, 21 Sep 2009 15:35:10 +0000 (17:35 +0200)]
r300g: Fix bad formatting parameters in calls to debug_printf

Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
15 years agogallium debug: Add gcc printf hint to debug_printf
Nicolai Hähnle [Mon, 21 Sep 2009 15:28:37 +0000 (17:28 +0200)]
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>
15 years agoprogs/perf: a few more vbo upload modes
Keith Whitwell [Mon, 21 Sep 2009 14:56:17 +0000 (15:56 +0100)]
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.

15 years agoprogs/perf: human-readable drawoverhead output
Keith Whitwell [Mon, 21 Sep 2009 14:54:28 +0000 (15:54 +0100)]
progs/perf: human-readable drawoverhead output

15 years agoprogs/perf: human-format vertexrate output
Keith Whitwell [Mon, 21 Sep 2009 14:52:17 +0000 (15:52 +0100)]
progs/perf: human-format vertexrate output

15 years agoprogs/perf: add human-readable float formatter
Keith Whitwell [Mon, 21 Sep 2009 14:51:26 +0000 (15:51 +0100)]
progs/perf: add human-readable float formatter

15 years agoprogs/glsl: Include local headers before installed headers during compilation.
Vinson Lee [Mon, 21 Sep 2009 14:44:53 +0000 (08:44 -0600)]
progs/glsl: Include local headers before installed headers during compilation.

Fixes compilation errors on platforms with insufficient older installed
GL headers.

15 years agor600: fix some issues with LIT instruction
Andre Maasikas [Mon, 21 Sep 2009 14:14:25 +0000 (10:14 -0400)]
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

15 years agoMerge branch 'mesa_7_6_branch'
Nicolai Hähnle [Mon, 21 Sep 2009 11:08:34 +0000 (13:08 +0200)]
Merge branch 'mesa_7_6_branch'

15 years agor300: Zero-initialize register for NV_vertex_program
Nicolai Hähnle [Mon, 21 Sep 2009 10:50:33 +0000 (12:50 +0200)]
r300: Zero-initialize register for NV_vertex_program

Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
15 years agor300: Fix handling of NV_vertex_program parameters
Nicolai Hähnle [Wed, 9 Sep 2009 17:56:57 +0000 (19:56 +0200)]
r300: Fix handling of NV_vertex_program parameters

The handling is a bit inefficient, unfortunately, but I don't want to make
any intrusive changes for Mesa 7.6.

Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
15 years agoMerge branch 'mesa_7_6_branch'
Michel Dänzer [Mon, 21 Sep 2009 08:48:32 +0000 (10:48 +0200)]
Merge branch 'mesa_7_6_branch'

15 years agoMerge branch 'mesa_7_5_branch' into mesa_7_6_branch
Michel Dänzer [Mon, 21 Sep 2009 08:39:20 +0000 (10:39 +0200)]
Merge branch 'mesa_7_5_branch' into mesa_7_6_branch

15 years agointel: Fix crash in intel_flush().
Michel Dänzer [Mon, 21 Sep 2009 08:08:11 +0000 (10:08 +0200)]
intel: Fix crash in intel_flush().

Since commit 2921a2555d0a76fa649b23c31e3264bbc78b2ff5 ('intel: Deassociated
drawables from private context struct in intelUnbindContext'),
intel->driDrawable may be NULL in intel_flush().

15 years agonouveau: allow building modesetting_drv.so
Ben Skeggs [Mon, 21 Sep 2009 04:51:25 +0000 (14:51 +1000)]
nouveau: allow building modesetting_drv.so

15 years agonouveau: drm_api create_screen()'s 'arg' argument can be NULL
Ben Skeggs [Mon, 21 Sep 2009 04:46:50 +0000 (14:46 +1000)]
nouveau: drm_api create_screen()'s 'arg' argument can be NULL

15 years agowindows: call _mesa_meta_init/free()
Brian Paul [Mon, 21 Sep 2009 04:19:28 +0000 (22:19 -0600)]
windows: call _mesa_meta_init/free()

15 years agoxlib: always call _mesa_meta_init/free()
Brian Paul [Mon, 21 Sep 2009 04:19:06 +0000 (22:19 -0600)]
xlib: always call _mesa_meta_init/free()

15 years agodri/swrast: call _mesa_meta_init/free()
Brian Paul [Mon, 21 Sep 2009 04:13:28 +0000 (22:13 -0600)]
dri/swrast: call _mesa_meta_init/free()

15 years agoosmesa: call _mesa_meta_init/free()
Brian Paul [Mon, 21 Sep 2009 04:13:09 +0000 (22:13 -0600)]
osmesa: call _mesa_meta_init/free()

15 years agoRevert "st/mesa: Compile in meta.c."
Brian Paul [Mon, 21 Sep 2009 04:08:30 +0000 (22:08 -0600)]
Revert "st/mesa: Compile in meta.c."

This reverts commit 6c5726cd39ab12b86fae391d075fa74bc24b615c.

15 years agoRevert "scons: add meta.c to sources"
Brian Paul [Mon, 21 Sep 2009 04:08:21 +0000 (22:08 -0600)]
Revert "scons: add meta.c to sources"

This reverts commit 41fefe88c50376a57876b498c8619c8c9f535de6.

15 years agoRevert "mesa: move _mesa_meta_init/free() calls to core Mesa"
Brian Paul [Mon, 21 Sep 2009 04:06:03 +0000 (22:06 -0600)]
Revert "mesa: move _mesa_meta_init/free() calls to core Mesa"

This reverts commit 651cffd626a82d9bf539437ca4bdf8ea4b396fab.

The commit inadvertantly introduced a new gallium dependency on the meta code.

15 years agoscons: add meta.c to sources
Brian Paul [Mon, 21 Sep 2009 03:31:38 +0000 (21:31 -0600)]
scons: add meta.c to sources

15 years agost/mesa: Compile in meta.c.
Chia-I Wu [Mon, 21 Sep 2009 02:57:14 +0000 (10:57 +0800)]
st/mesa: Compile in meta.c.

meta was moved to core Mesa since
651cffd626a82d9bf539437ca4bdf8ea4b396fab.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
15 years agointel: meta clear has a new name.
Chia-I Wu [Mon, 21 Sep 2009 02:52:07 +0000 (10:52 +0800)]
intel: meta clear has a new name.

It was renamed to _mesa_meta_Clear.

Signed-off-by: Chia-I Wu <olvaffe@gmail.com>
15 years agoxorg/st: fixup builds against later dpms headers.
Dave Airlie [Mon, 21 Sep 2009 03:26:48 +0000 (13:26 +1000)]
xorg/st: fixup builds against later dpms headers.

15 years agoradeon: Fix legacy bo not to reuse dma buffers before refcount is 1.
Pauli Nieminen [Sun, 20 Sep 2009 19:24:35 +0000 (22:24 +0300)]
radeon: Fix legacy bo not to reuse dma buffers before refcount is 1.

This should help detecting possible memory leaks with dma buffers and prevent
possible visual corruption if data would be overwriten too early.

15 years agor300/compiler: Fix trig instructions in R300 fp
Nicolai Hähnle [Sun, 20 Sep 2009 18:40:03 +0000 (20:40 +0200)]
r300/compiler: Fix trig instructions in R300 fp

Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
15 years agoradeon: Fix typo in variable name.
Pauli Nieminen [Sun, 20 Sep 2009 18:08:42 +0000 (21:08 +0300)]
radeon: Fix typo in variable name.

15 years agoradeon: Improve WARN_ONCE macro to appear as single statement.
Pauli Nieminen [Sun, 20 Sep 2009 17:07:35 +0000 (20:07 +0300)]
radeon: Improve WARN_ONCE macro to appear as single statement.

Do-while makes macro safe to be used with if and for constructions.

Also remove __LINE__ macro from variable name because scope is local to macro anyway.

15 years agoscons: Drop gprof support for profile builds; tweak optimization flags instead.
José Fonseca [Sun, 20 Sep 2009 17:07:16 +0000 (18:07 +0100)]
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.

15 years agollvmpipe: Fix lp_get_cached_tile.
José Fonseca [Sun, 20 Sep 2009 17:04:00 +0000 (18:04 +0100)]
llvmpipe: Fix lp_get_cached_tile.

Align coordinates to tile boundaries.

15 years agollvmpipe: Update tile status on flush.
José Fonseca [Sun, 20 Sep 2009 11:28:07 +0000 (12:28 +0100)]
llvmpipe: Update tile status on flush.

15 years agoradeon: Fix "verts" debugging enable
Nicolai Hähnle [Sun, 20 Sep 2009 16:45:32 +0000 (18:45 +0200)]
radeon: Fix "verts" debugging enable

Copy'n'paste apparently prevented the RADEON_VERTS flag from being enabled.

Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
15 years agoMerge branch 'mesa_7_6_branch'
Brian Paul [Sun, 20 Sep 2009 16:36:45 +0000 (10:36 -0600)]
Merge branch 'mesa_7_6_branch'

Conflicts:
src/mesa/drivers/dri/intel/intel_clear.c

15 years agoMerge branch 'mesa_7_5_branch' into mesa_7_6_branch
Nicolai Hähnle [Sun, 20 Sep 2009 14:59:03 +0000 (16:59 +0200)]
Merge branch 'mesa_7_5_branch' into mesa_7_6_branch

15 years agomesa/st: Create front renderbuffer on the fly when supplied with a surface
Nicolai Hähnle [Sat, 12 Sep 2009 14:49:31 +0000 (16:49 +0200)]
mesa/st: Create front renderbuffer on the fly when supplied with a surface

Normally, the mesa/st would create a fake front buffer out of a
client-allocated surface.

In the DRI setting, however, st/dri provides a front buffer surface which is
created and maintained by the X server. Prefer to use this surface instead,
so that front buffer rendering and reading works correctly.

Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
15 years agomesa/st: Initialize format bits of framebuffer renderbuffers
Nicolai Hähnle [Sat, 12 Sep 2009 10:13:35 +0000 (12:13 +0200)]
mesa/st: Initialize format bits of framebuffer renderbuffers

Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
15 years agodocs: Document new features in radeon/r200/r300 drivers
Nicolai Hähnle [Sun, 20 Sep 2009 14:46:58 +0000 (16:46 +0200)]
docs: Document new features in radeon/r200/r300 drivers

Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
15 years agor300/compiler: Fix R300 fragment program regression introduced by 0723cd1...
Nicolai Hähnle [Sun, 20 Sep 2009 14:33:59 +0000 (16:33 +0200)]
r300/compiler: Fix R300 fragment program regression introduced by 0723cd1...

We obviously need to move the code addr register backwards because their may
be overlap.

This bug affected in particular the Compiz water plugin.

Signed-off-by: Nicolai Hähnle <nhaehnle@gmail.com>
15 years agomesa: remove redundant readbuffer check
Brian Paul [Sat, 19 Sep 2009 23:26:14 +0000 (17:26 -0600)]
mesa: remove redundant readbuffer check

15 years agomesa: rename functions to be more consistant with rest of mesa
Brian Paul [Sat, 19 Sep 2009 23:06:15 +0000 (17:06 -0600)]
mesa: rename functions to be more consistant with rest of mesa

15 years agoswrast: remove obsolete s_imaging.c file
Brian Paul [Sat, 19 Sep 2009 22:42:36 +0000 (16:42 -0600)]
swrast: remove obsolete s_imaging.c file

15 years agoswrast: remove prototypes for obsolete functions
Brian Paul [Sat, 19 Sep 2009 22:41:37 +0000 (16:41 -0600)]
swrast: remove prototypes for obsolete functions

15 years agomesa: remove s_imaging.c from build
Brian Paul [Sat, 19 Sep 2009 22:40:09 +0000 (16:40 -0600)]
mesa: remove s_imaging.c from build

15 years agowindows: replace old ColorTable, Convolution functions with new
Brian Paul [Sat, 19 Sep 2009 22:36:15 +0000 (16:36 -0600)]
windows: replace old ColorTable, Convolution functions with new

15 years agomesa: use new meta functions
Brian Paul [Sat, 19 Sep 2009 22:33:09 +0000 (16:33 -0600)]
mesa: use new meta functions

15 years agomesa: meta functions for glCopyColorTable, glCopyConvolutionFilter, etc
Brian Paul [Sat, 19 Sep 2009 22:32:42 +0000 (16:32 -0600)]
mesa: meta functions for glCopyColorTable, glCopyConvolutionFilter, etc

15 years agomesa: move readbuffer tests
Brian Paul [Sat, 19 Sep 2009 22:27:59 +0000 (16:27 -0600)]
mesa: move readbuffer tests

15 years agomesa: use _mesa_get_current_tex_unit() helper
Brian Paul [Sat, 19 Sep 2009 22:16:48 +0000 (16:16 -0600)]
mesa: use _mesa_get_current_tex_unit() helper

15 years agomesa: use _mesa_get_current_tex_unit() helper
Brian Paul [Sat, 19 Sep 2009 22:13:01 +0000 (16:13 -0600)]
mesa: use _mesa_get_current_tex_unit() helper

15 years agomesa: fix some glCopyTex[Sub]Image regressions related to convolution
Brian Paul [Sat, 19 Sep 2009 19:37:28 +0000 (13:37 -0600)]
mesa: fix some glCopyTex[Sub]Image regressions related to convolution

15 years agomesa: move _mesa_meta_init/free() calls to core Mesa
Brian Paul [Sat, 19 Sep 2009 18:58:55 +0000 (12:58 -0600)]
mesa: move _mesa_meta_init/free() calls to core Mesa

15 years agor600: fix point sizes
Alex Deucher [Sat, 19 Sep 2009 19:18:42 +0000 (15:18 -0400)]
r600: fix point sizes

registers takes radius

15 years agor600: fix polygon offset
Alex Deucher [Sat, 19 Sep 2009 18:46:06 +0000 (14:46 -0400)]
r600: fix polygon offset

15 years agoswrast: remove obsolete s_texstore.c
Brian Paul [Sat, 19 Sep 2009 17:09:25 +0000 (11:09 -0600)]
swrast: remove obsolete s_texstore.c

Replaced by new, simpler meta functions.

15 years agoswrast: remove prototypes for obsolete functions
Brian Paul [Sat, 19 Sep 2009 17:08:49 +0000 (11:08 -0600)]
swrast: remove prototypes for obsolete functions

15 years agomesa: remove s_texstore.c from makefile/project files
Brian Paul [Sat, 19 Sep 2009 17:08:20 +0000 (11:08 -0600)]
mesa: remove s_texstore.c from makefile/project files

15 years agoglapi: replace old TexCopy functions w/ new
Brian Paul [Sat, 19 Sep 2009 17:05:54 +0000 (11:05 -0600)]
glapi: replace old TexCopy functions w/ new

15 years agowindows: replace old TexCopy functions w/ new
Brian Paul [Sat, 19 Sep 2009 17:03:33 +0000 (11:03 -0600)]
windows: replace old TexCopy functions w/ new

15 years agogldirect: remove refs to soon-to-be-obsolete functions
Brian Paul [Sat, 19 Sep 2009 17:01:07 +0000 (11:01 -0600)]
gldirect: remove refs to soon-to-be-obsolete functions

I don't know if this driver is anywhere near build-able, but anyway.

15 years agomesa: use new _mesa_meta_CopyTex[Sub]Image() functions
Brian Paul [Sat, 19 Sep 2009 16:55:09 +0000 (10:55 -0600)]
mesa: use new _mesa_meta_CopyTex[Sub]Image() functions

15 years agointel: use new _mesa_meta_CopyTex[Sub]Image() functions
Brian Paul [Sat, 19 Sep 2009 16:58:07 +0000 (10:58 -0600)]
intel: use new _mesa_meta_CopyTex[Sub]Image() functions

15 years agoglapi: regenerated files
Brian Paul [Sat, 19 Sep 2009 16:00:55 +0000 (10:00 -0600)]
glapi: regenerated files

15 years agoglapi: added tokens, function for GL_ARB_provoking_vertex
Brian Paul [Sat, 19 Sep 2009 16:00:19 +0000 (10:00 -0600)]
glapi: added tokens, function for GL_ARB_provoking_vertex

15 years agollvmpipe: Respect input interpolators for the shader.
Michal Krol [Thu, 17 Sep 2009 15:05:08 +0000 (16:05 +0100)]
llvmpipe: Respect input interpolators for the shader.

Cherry-picked from fb2c7b6743ba6e89f24843890fb7fcd6a09c3dbb

15 years agomesa: Allow BlitFramebuffer from a texture.
José Fonseca [Sat, 19 Sep 2009 13:33:35 +0000 (14:33 +0100)]
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.

15 years agosoftpipe: Fix cube face selection.
Michal Krol [Fri, 18 Sep 2009 13:36:59 +0000 (14:36 +0100)]
softpipe: Fix cube face selection.

If arx and ary are equal, we still want to choose from one of them,
and not arz.

15 years ago[i965] add a missing header file
Zou Nan hai [Fri, 18 Sep 2009 08:04:41 +0000 (16:04 +0800)]
[i965] add a missing header file

15 years ago [i965] use intel_batchbuffer_flush to flush the clear
Zou Nan hai [Fri, 18 Sep 2009 05:29:28 +0000 (13:29 +0800)]
 [i965] use intel_batchbuffer_flush to flush the clear

15 years agosoftpipe: Respect input interpolators for the shader.
Michal Krol [Thu, 17 Sep 2009 15:05:08 +0000 (16:05 +0100)]
softpipe: Respect input interpolators for the shader.

15 years agotgsi: Scan input interpolators, too.
Michal Krol [Thu, 17 Sep 2009 15:04:35 +0000 (16:04 +0100)]
tgsi: Scan input interpolators, too.

15 years agoprogs/perf: convert some DOS line-endings
Keith Whitwell [Thu, 17 Sep 2009 11:09:16 +0000 (12:09 +0100)]
progs/perf: convert some DOS line-endings

It seems like some of these files were committed with CRLF initially.

15 years agoprogs/perf: add scons support, get working under mingw
Keith Whitwell [Thu, 17 Sep 2009 11:08:04 +0000 (12:08 +0100)]
progs/perf: add scons support, get working under mingw

15 years agomesa: begin some texstore code refactoring
Brian Paul [Thu, 17 Sep 2009 03:49:55 +0000 (21:49 -0600)]
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.

15 years agomesa: fix clip plane, fog issues
Brian Paul [Thu, 17 Sep 2009 03:21:42 +0000 (21:21 -0600)]
mesa: fix clip plane, fog issues

15 years agomesa: meta driver functions for glCopyTex[Sub]Image()
Brian Paul [Thu, 17 Sep 2009 02:09:05 +0000 (20:09 -0600)]
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.

15 years agoprogs/perf: initial set of simple performance test programs
Brian Paul [Thu, 17 Sep 2009 01:33:01 +0000 (19:33 -0600)]
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.

15 years agoprogs/glsl: minor Makefile clean-ups
Brian Paul [Wed, 16 Sep 2009 21:49:33 +0000 (15:49 -0600)]
progs/glsl: minor Makefile clean-ups

15 years agoswrast: remove mipmap generation checks (done in core Mesa now)
Brian Paul [Wed, 16 Sep 2009 21:48:52 +0000 (15:48 -0600)]
swrast: remove mipmap generation checks (done in core Mesa now)

15 years agos3v: remove unneeded initializations
Brian Paul [Wed, 16 Sep 2009 01:53:50 +0000 (19:53 -0600)]
s3v: remove unneeded initializations

15 years agoffb: remove disabled code
Brian Paul [Wed, 16 Sep 2009 01:47:06 +0000 (19:47 -0600)]
ffb: remove disabled code

15 years agoglx: Use initstate_r / random_r instead of corrupting global random number state
Ian Romanick [Wed, 16 Sep 2009 23:43:50 +0000 (16:43 -0700)]
glx: Use initstate_r / random_r instead of corrupting global random number state

Previously srandom and random were used.  This cause the global random
number generator state to be modified.  This caused problems for
applications that called srandom before calling into GLX.  By using
local state the global state is left unmodified.

This should fix bug #23774.

15 years agollvmpipe: Don't assert due to unsupported texture wrap modes.
José Fonseca [Wed, 16 Sep 2009 15:12:22 +0000 (16:12 +0100)]
llvmpipe: Don't assert due to unsupported texture wrap modes.

Issue a warning and fallback to clamping.

15 years agost/mesa: fix some incorrect branching/clean-up code in TexImage functions
Brian Paul [Wed, 16 Sep 2009 19:07:12 +0000 (13:07 -0600)]
st/mesa: fix some incorrect branching/clean-up code in TexImage functions

We need to be sure to call the _mesa_unmap_teximage_pbo() function if we
called _mesa_validate_pbo_teximage().

15 years agost/mesa: fix texture memory allocation bug
Brian Paul [Wed, 16 Sep 2009 18:57:26 +0000 (12:57 -0600)]
st/mesa: fix texture memory allocation bug

The following example caused an incorrect GL_OUT_OF_MEMORY error to be
raised in glTexSubImage2D:

   glTexImage2D(level=0, width=32, height=32, pixels=NULL);
   glTexImage2D(level=0, width=64, height=64, pixels=NULL);
   glTexSubImage2D(level=0, pixels!=NULL);

The second glTexImage2D() call needs to cause the first image to be
deallocated then reallocated at the new size.  This was not happening
because we were testing for pixels==NULL too early.

15 years agoMerge branch 'mesa_7_6_branch'
Ian Romanick [Wed, 16 Sep 2009 15:05:36 +0000 (08:05 -0700)]
Merge branch 'mesa_7_6_branch'

15 years agogallium: remove incorrect 'return' stmt
Brian Paul [Wed, 16 Sep 2009 14:59:32 +0000 (08:59 -0600)]
gallium: remove incorrect 'return' stmt

15 years agoMerge branch 'mesa_7_5_branch' into mesa_7_6_branch
Ian Romanick [Wed, 16 Sep 2009 14:57:19 +0000 (07:57 -0700)]
Merge branch 'mesa_7_5_branch' into mesa_7_6_branch

Conflicts:
src/mesa/main/dlist.c

15 years agointel: Deassociated drawables from private context struct in intelUnbindContext
Ian Romanick [Wed, 16 Sep 2009 14:39:58 +0000 (07:39 -0700)]
intel: Deassociated drawables from private context struct in intelUnbindContext

The generic DRI infrastructure makes sure that __DRIcontextRec::driDrawablePriv
and __DRIcontextRec::driReadablePriv are set to NULL after unbinding a
context.  However, the intel_context structure keeps cached copies of
these pointers.  If these cached pointers are not NULLed and the
drawable is actually destroyed after unbinding the context (typically
by way of glXDestroyWindow), freed memory will be dereferenced in
intelDestroyContext.

This should fix bug #23418.

15 years agogallium: Deprecate PIPE_CAP_S3TC.
José Fonseca [Wed, 16 Sep 2009 13:31:14 +0000 (14:31 +0100)]
gallium: Deprecate PIPE_CAP_S3TC.

No longer used. S3TC support is queried via
pipe_screen::is_format_supported.

15 years agosoftpipe: Do not advertise Z32_UNORM as a supported format.
Michal Krol [Wed, 16 Sep 2009 12:56:58 +0000 (13:56 +0100)]
softpipe: Do not advertise Z32_UNORM as a supported format.