mesa.git
14 years agor300g: refuse to create a texture with size 0
Marek Olšák [Mon, 3 May 2010 17:14:31 +0000 (19:14 +0200)]
r300g: refuse to create a texture with size 0

14 years agor300g: improve texture debug output, split into TEX and TEXALLOC flags
Marek Olšák [Mon, 3 May 2010 17:05:03 +0000 (19:05 +0200)]
r300g: improve texture debug output, split into TEX and TEXALLOC flags

14 years agoReorder LLVM passes, running mem2reg earlier.
Török Edwin [Mon, 3 May 2010 14:43:03 +0000 (07:43 -0700)]
Reorder LLVM passes, running mem2reg earlier.

This gives a ~30% shader optimization time improvement on blender.
Tested by comparing the dumped LLVM modules.
Current ordering:
time ~/llvm-git/obj/Release-Asserts/bin/opt l.bc  -constprop -instcombine
-mem2reg -gvn  -simplifycfg
real    0m1.126s
user    0m1.108s
sys     0m0.012s

With this patch:
time ~/llvm-git/obj/Release-Asserts/bin/opt l.bc -mem2reg -constprop -instcombine   -gvn  -simplifycfg
real    0m0.885s
user    0m0.880s
sys     0m0.000s

The overall improvement in blender is ~15%.
Blender without the patch takes 1m13s:
edwin     5934 87.6 11.5 729440 458296 pts/5   SLl+ 17:35   1:13 blender

Blender with the patch takes 1m3s:
edwin     5726 94.2 11.2 716424 446168 pts/5   SLl+ 17:32   1:03 blender

It is still slow with the patch, but better (most of the optimization time is
taken up by GVN, see LLVM PR7023).

Signed-off-by: Török Edwin <edwintorok@gmail.com>
Signed-off-by: José Fonseca <jfonseca@vmware.com>
14 years agosvga: Silent warning.
José Fonseca [Mon, 3 May 2010 15:23:44 +0000 (16:23 +0100)]
svga: Silent warning.

14 years agoGenerate es glapi files when es1 or es2 is enabled
Kristian Høgsberg [Mon, 3 May 2010 12:32:56 +0000 (08:32 -0400)]
Generate es glapi files when es1 or es2 is enabled

14 years agogallivm: Display message instead of crashing when sampler generator was not supplied...
José Fonseca [Mon, 3 May 2010 12:16:09 +0000 (13:16 +0100)]
gallivm: Display message instead of crashing when sampler generator was not supplied for tgsi translation.

14 years agodriswrast: Fix more context creation breakage
Kristian Høgsberg [Mon, 3 May 2010 12:00:10 +0000 (08:00 -0400)]
driswrast: Fix more context creation breakage

Pointed out by Colin Harrison.

14 years agotranslate: Make translate_generic truly generic.
José Fonseca [Mon, 3 May 2010 11:18:55 +0000 (12:18 +0100)]
translate: Make translate_generic truly generic.

PIPE_FORMAT_R10G10B10X2_USCALED, half floats, were not supported, so
just rely on u_format for (almost) universal format support.

14 years agodraw: Remove draw_pt_fetch_prepare call from llvm middle end.
José Fonseca [Mon, 3 May 2010 11:15:32 +0000 (12:15 +0100)]
draw: Remove draw_pt_fetch_prepare call from llvm middle end.

Unneeded since we code generate the vertex fecthes.

14 years agotgsi: Parse and dump predicates.
José Fonseca [Mon, 3 May 2010 11:13:54 +0000 (12:13 +0100)]
tgsi: Parse and dump predicates.

14 years agogallium: Remove loop register file.
José Fonseca [Mon, 3 May 2010 09:53:32 +0000 (10:53 +0100)]
gallium: Remove loop register file.

It was only used for D3D's REP/END/BGNFOR/ENDFOR. D3D's aL register is
just like another address register now.

14 years agogallivm: Replace predicate assertion failure with warning message.
José Fonseca [Mon, 3 May 2010 08:54:01 +0000 (09:54 +0100)]
gallivm: Replace predicate assertion failure with warning message.

14 years agodraw: Disable rtasm compilation when using LLVM.
José Fonseca [Mon, 3 May 2010 08:53:12 +0000 (09:53 +0100)]
draw: Disable rtasm compilation when using LLVM.

Saves time and trouble.

14 years agonouveau: fix nouveau_create_context decleration
Dave Airlie [Mon, 3 May 2010 07:09:17 +0000 (17:09 +1000)]
nouveau: fix nouveau_create_context decleration

14 years agosoftpipe: invalidate cache view when swizzles are different.
Dave Airlie [Sun, 2 May 2010 07:37:18 +0000 (17:37 +1000)]
softpipe: invalidate cache view when swizzles are different.

Current code only invalidated if the texture was different, however we
store swizzled values in the cache, so we need to invalidate in that case
also.

Signed-off-by: Dave Airlie <airlied@redhat.com>
14 years agoglx: fix regression with GLX_USE_GL
Dave Airlie [Sun, 2 May 2010 09:35:34 +0000 (19:35 +1000)]
glx: fix regression with GLX_USE_GL

update for fbconfig_style_tags

14 years agogallivm: fix nested break and continue statements
Zack Rusin [Mon, 3 May 2010 01:40:30 +0000 (21:40 -0400)]
gallivm: fix nested break and continue statements

we were resetting the mask on each new break/continue statement within
the same scope. we always need to and the current execution mask
with the current break/continue mask to get the correct result (the
masks are always ~1 initially)

14 years agoidentity: Move sampler view create and destroy to id_objects.c
Jakob Bornecrantz [Sat, 1 May 2010 11:38:25 +0000 (12:38 +0100)]
identity: Move sampler view create and destroy to id_objects.c

14 years agoidentity: s/texture/resource/
Jakob Bornecrantz [Sat, 1 May 2010 11:02:26 +0000 (12:02 +0100)]
identity: s/texture/resource/

14 years agoidentity: Whitespace & Style
Jakob Bornecrantz [Sat, 1 May 2010 10:50:36 +0000 (11:50 +0100)]
identity: Whitespace & Style

14 years agoswrast: Correct include for mtypes.h
Jakob Bornecrantz [Sun, 2 May 2010 23:25:12 +0000 (00:25 +0100)]
swrast: Correct include for mtypes.h

14 years agogallium/util: print \n after DXTn printf
Luca Barbieri [Sun, 2 May 2010 23:12:50 +0000 (16:12 -0700)]
gallium/util: print \n after DXTn printf

Re-add commit 2d65a7caf97684aa654088c76a74b632fbd685fa

Signed-off-by: Xavier Chantry <chantry.xavier@gmail.com>
Signed-off-by: José Fonseca <jfonseca@vmware.com>
14 years agollvmpipe: add lp_test_* to .gitignore
Xavier Chantry [Sun, 2 May 2010 22:57:25 +0000 (15:57 -0700)]
llvmpipe: add lp_test_* to .gitignore

Signed-off-by: Xavier Chantry <chantry.xavier@gmail.com>
Signed-off-by: José Fonseca <jfonseca@vmware.com>
14 years agosvga: Remove the screen private context.
José Fonseca [Sun, 2 May 2010 22:54:42 +0000 (23:54 +0100)]
svga: Remove the screen private context.

All affected operations have already been moved to context.

More cleanup work can be done, in particular with the buffer transfers.

14 years agosvga: Remove empty file.
José Fonseca [Sun, 2 May 2010 21:35:53 +0000 (22:35 +0100)]
svga: Remove empty file.

14 years agosvga: Update flags documentation.
José Fonseca [Sun, 2 May 2010 21:33:43 +0000 (22:33 +0100)]
svga: Update flags documentation.

14 years agosoftpipe: Fix alpha blending for formats without alpha channel.
José Fonseca [Sun, 2 May 2010 20:37:24 +0000 (21:37 +0100)]
softpipe: Fix alpha blending for formats without alpha channel.

Don't use the dst alpha channel from the tile cache when it does not
exist in the true format.

14 years agollvmpipe: Fix alpha blending for formats without alpha channel.
José Fonseca [Sun, 2 May 2010 20:36:12 +0000 (21:36 +0100)]
llvmpipe: Fix alpha blending for formats without alpha channel.

Don't use the dst alpha channel from the swizzled tile when it does not
exist in the true format.

14 years agoUpdate drisw state tracker to use new API aware context create
Xavier Chantry [Sun, 2 May 2010 21:25:43 +0000 (23:25 +0200)]
Update drisw state tracker to use new API aware context create

Even though swrast defines its own __DriverAPIRec it still shares the
driCreateNewContext() implementation from dri_util.c.  So the CreateContext
prototypes have to match in the two __DriverAPIRecs.

Reviewed-by: Jakob Bornecrantz <jakob@vmware.com>
Signed-off-by: Xavier Chantry <chantry.xavier@gmail.com>
14 years agosvga: Include svga_surface.h in svga_screen.c.
Vinson Lee [Sun, 2 May 2010 20:34:50 +0000 (13:34 -0700)]
svga: Include svga_surface.h in svga_screen.c.

Fixes svga_screen_init_surface_functions implicit declaration warning.

14 years agor300g: Remove unnecessary header.
Vinson Lee [Sun, 2 May 2010 20:30:40 +0000 (13:30 -0700)]
r300g: Remove unnecessary header.

14 years agoUpdate dri state tracker to use new API aware context create
Xavier Chantry [Sun, 2 May 2010 20:27:25 +0000 (16:27 -0400)]
Update dri state tracker to use new API aware context create

14 years agomesa: Include api_exec.h in dlist.c.
Vinson Lee [Sun, 2 May 2010 20:21:42 +0000 (13:21 -0700)]
mesa: Include api_exec.h in dlist.c.

Fixes _mesa_alloc_dispatch_table implicit declaration warning.

14 years agor300g: do not validate buffers in check_cs
Marek Olšák [Sun, 2 May 2010 15:31:06 +0000 (17:31 +0200)]
r300g: do not validate buffers in check_cs

It's already done in r300_emit_buffer_validate.
This also fixes Total Annihilation 3D on debug builds at least.

14 years agor300g: fix surface_copy for compressed formats
Marek Olšák [Sun, 2 May 2010 15:19:03 +0000 (17:19 +0200)]
r300g: fix surface_copy for compressed formats

No accelerated blitting for these, it's too messy.

14 years agoconfigure.ac: Fix test for whether to build src/gles
Kristian Høgsberg [Sun, 2 May 2010 18:52:39 +0000 (14:52 -0400)]
configure.ac: Fix test for whether to build src/gles

14 years agomesa: Include mfeatures.h before testing feature macros
Kristian Høgsberg [Sun, 2 May 2010 18:19:54 +0000 (14:19 -0400)]
mesa: Include mfeatures.h before testing feature macros

14 years agomesa: Only compile ES files when ES1 or ES2 are selected
Kristian Høgsberg [Sun, 2 May 2010 18:09:52 +0000 (14:09 -0400)]
mesa: Only compile ES files when ES1 or ES2 are selected

This still requieres manual generation of the es1 and es2 glapis and is
disabled by default.

14 years agomesa: #ifdef out more remap_table related code when disabled.
José Fonseca [Sun, 2 May 2010 15:10:40 +0000 (16:10 +0100)]
mesa: #ifdef out more remap_table related code when disabled.

Seems to get everything building again here.

14 years agoretrace: Add sampler_view_destroy
José Fonseca [Sun, 2 May 2010 12:04:08 +0000 (13:04 +0100)]
retrace: Add sampler_view_destroy

14 years agotrace: Fix typo in method name.
José Fonseca [Sun, 2 May 2010 12:03:37 +0000 (13:03 +0100)]
trace: Fix typo in method name.

14 years agoMerge branch 'gles2-2'
Kristian Høgsberg [Sun, 2 May 2010 14:17:07 +0000 (10:17 -0400)]
Merge branch 'gles2-2'

Conflicts:
src/mesa/drivers/dri/common/dri_util.h

14 years agoHook in install rules for es1 and es2
Kristian Høgsberg [Sun, 2 May 2010 14:14:53 +0000 (10:14 -0400)]
Hook in install rules for es1 and es2

14 years agoAdd glesv2.pc and glesv1_cm.pc pkg-config files for ES 1 and 2
Kristian Høgsberg [Sun, 2 May 2010 13:51:13 +0000 (09:51 -0400)]
Add glesv2.pc and glesv1_cm.pc pkg-config files for ES 1 and 2

14 years agost/mesa: Create context for API_OPENGL as first priority
Kristian Høgsberg [Sun, 2 May 2010 13:27:51 +0000 (09:27 -0400)]
st/mesa: Create context for API_OPENGL as first priority

14 years agor300g: always set the pitch of the first miplevel in the tiling flags
Marek Olšák [Sun, 2 May 2010 11:27:57 +0000 (13:27 +0200)]
r300g: always set the pitch of the first miplevel in the tiling flags

This further reduces the number of DRM calls and flushes.

14 years agoRevert "r300g: disable point sprites (again)"
Marek Olšák [Sun, 2 May 2010 05:06:35 +0000 (07:06 +0200)]
Revert "r300g: disable point sprites (again)"

This reverts commit 3e0f1719d411b34f77fd2a053ecf83b43bb836ca.

14 years agor300g: merge VS output mapping state (VAP) to rasterizer block state (RS)
Marek Olšák [Sun, 2 May 2010 04:24:55 +0000 (06:24 +0200)]
r300g: merge VS output mapping state (VAP) to rasterizer block state (RS)

These two should be tied together because what's set in VAP or stuffed in GA
should be rasterized in RS. Not doing so causes a hardlock.

The reason for the merge is that if stuffed texture coordinates (e.g. point
sprite texgen) happen to occupy the texcoord slot dedicated to fog or wpos,
the two must be relocated to other free slots, which needs remapping the vertex
shader outputs.

The rasterizer code is now literally a sequence read-rasterize-write.

14 years agor300g: inline update_derived_shader_state
Marek Olšák [Sun, 2 May 2010 02:21:21 +0000 (04:21 +0200)]
r300g: inline update_derived_shader_state

14 years agor300g: fix segfault when resizing a DRI2 framebuffer
Marek Olšák [Sat, 1 May 2010 23:55:44 +0000 (01:55 +0200)]
r300g: fix segfault when resizing a DRI2 framebuffer

Resetting tiling flags might happen after a texture is destroyed...
Looking at the kernel sources, we don't actually need to reset the tiling
flags.

14 years agor300g: cache tiling flags to reduce the number of DRM calls
Marek Olšák [Sat, 1 May 2010 23:48:57 +0000 (01:48 +0200)]
r300g: cache tiling flags to reduce the number of DRM calls

14 years agomesa: s/sprintf/_mesa_snprintf/
Vinson Lee [Sun, 2 May 2010 08:03:59 +0000 (01:03 -0700)]
mesa: s/sprintf/_mesa_snprintf/

14 years agoi965g: s/sprintf/util_snprintf/
Vinson Lee [Sun, 2 May 2010 07:21:04 +0000 (00:21 -0700)]
i965g: s/sprintf/util_snprintf/

14 years agoglsl: s/sprintf/_mesa_snprintf/
Vinson Lee [Sun, 2 May 2010 05:01:28 +0000 (22:01 -0700)]
glsl: s/sprintf/_mesa_snprintf/

14 years agoglapi: s/strcpy/strncpy/
Vinson Lee [Sat, 1 May 2010 22:34:47 +0000 (15:34 -0700)]
glapi: s/strcpy/strncpy/

14 years agollvmpipe: Remove unused variable.
Vinson Lee [Sat, 1 May 2010 22:12:45 +0000 (15:12 -0700)]
llvmpipe: Remove unused variable.

14 years agoprogs/tests: Remove meaningless const qualifiers.
Vinson Lee [Sat, 1 May 2010 22:07:45 +0000 (15:07 -0700)]
progs/tests: Remove meaningless const qualifiers.

14 years agoswrastg: Use trace
Jakob Bornecrantz [Sat, 1 May 2010 10:29:20 +0000 (11:29 +0100)]
swrastg: Use trace

14 years agoprogs/demos: Remove meaningless const qualifier in vao_demo.c.
Vinson Lee [Sat, 1 May 2010 08:28:06 +0000 (01:28 -0700)]
progs/demos: Remove meaningless const qualifier in vao_demo.c.

14 years agonv50: raise constant buffers size to maximum
Christoph Bumiller [Fri, 30 Apr 2010 20:57:23 +0000 (22:57 +0200)]
nv50: raise constant buffers size to maximum

Removed the param heaps, haven't been using them for a long
time now.

14 years agonv50: relax restriction on surface_copy format equality a bit
Christoph Bumiller [Thu, 29 Apr 2010 21:15:05 +0000 (23:15 +0200)]
nv50: relax restriction on surface_copy format equality a bit

14 years agonv50: don't segfault on OPCODE_END for empty programs
Christoph Bumiller [Thu, 29 Apr 2010 20:48:00 +0000 (22:48 +0200)]
nv50: don't segfault on OPCODE_END for empty programs

14 years agollvmpipe: fix out-of-bounds texture sampling
Brian Paul [Fri, 30 Apr 2010 19:54:31 +0000 (13:54 -0600)]
llvmpipe: fix out-of-bounds texture sampling

If we're using a wrap mode in which border color sampling is possible
it means that texcoords may be outside of the texture image bounds.
Fetching the texel may result in a segfault.

Use the 'use_border' variable to catch such texcoords and replace
the texel offset with zero (which will be in bounds).

Fixes segfault in Lightsmark demo, fd.o bug 27877.

14 years agollvmpipe: added lp_build_sample_nop() for debugging
Brian Paul [Fri, 30 Apr 2010 19:53:54 +0000 (13:53 -0600)]
llvmpipe: added lp_build_sample_nop() for debugging

14 years agogles: Build libGLESv1_CM.so and libGLESv2.so from glapi files
Kristian Høgsberg [Sat, 6 Mar 2010 00:01:43 +0000 (19:01 -0500)]
gles: Build libGLESv1_CM.so and libGLESv2.so from glapi files

14 years agointel: Only register ES2 extensions for ES2 contexts
Kristian Høgsberg [Tue, 27 Apr 2010 18:57:51 +0000 (14:57 -0400)]
intel: Only register ES2 extensions for ES2 contexts

14 years agoconfigure.ac: Add options to enable GLES1/2 API support
Kristian Høgsberg [Tue, 27 Apr 2010 17:42:33 +0000 (13:42 -0400)]
configure.ac: Add options to enable GLES1/2 API support

14 years agointel: Advertise GLES1/2 for i915+ when enabled
Kristian Høgsberg [Wed, 28 Apr 2010 01:43:40 +0000 (21:43 -0400)]
intel: Advertise GLES1/2 for i915+ when enabled

14 years agodri: Add DRI entrypoints to create a context for a given API
Kristian Høgsberg [Tue, 27 Apr 2010 15:04:51 +0000 (11:04 -0400)]
dri: Add DRI entrypoints to create a context for a given API

14 years agoegl_dri2: Use new DRI API to create a GLES1/2 context when asked to
Kristian Høgsberg [Tue, 27 Apr 2010 15:38:46 +0000 (11:38 -0400)]
egl_dri2: Use new DRI API to create a GLES1/2 context when asked to

14 years agodri: Add DRI entrypoints to create a context for a given API
Kristian Høgsberg [Tue, 27 Apr 2010 15:04:51 +0000 (11:04 -0400)]
dri: Add DRI entrypoints to create a context for a given API

14 years agost/mesa: Move st_cb_drawtex.c to the mesa state tracker
Kristian Høgsberg [Tue, 27 Apr 2010 14:52:23 +0000 (10:52 -0400)]
st/mesa: Move st_cb_drawtex.c to the mesa state tracker

14 years agoes: Drop es specific enums.c
Kristian Høgsberg [Tue, 27 Apr 2010 13:00:31 +0000 (09:00 -0400)]
es: Drop es specific enums.c

14 years agoglapi: Regenerate enums.c for all APIs
Kristian Høgsberg [Tue, 27 Apr 2010 13:00:17 +0000 (09:00 -0400)]
glapi: Regenerate enums.c for all APIs

14 years agoglapi: Update gl_enum.py to generate enum tables for multiple APIs
Kristian Høgsberg [Tue, 27 Apr 2010 12:57:56 +0000 (08:57 -0400)]
glapi: Update gl_enum.py to generate enum tables for multiple APIs

14 years agomesa: Drop unused _mesa_init_drawtex_dispatch()
Kristian Høgsberg [Mon, 26 Apr 2010 13:55:41 +0000 (09:55 -0400)]
mesa: Drop unused _mesa_init_drawtex_dispatch()

14 years agomesa: Move drawtex functionality to main/
Kristian Høgsberg [Mon, 26 Apr 2010 13:53:23 +0000 (09:53 -0400)]
mesa: Move drawtex functionality to main/

14 years agomesa: Move glQueryMatrixxOES() implementation to core mesa
Kristian Høgsberg [Sun, 25 Apr 2010 00:36:49 +0000 (20:36 -0400)]
mesa: Move glQueryMatrixxOES() implementation to core mesa

14 years agomesa: Move GLES1 texgen functions to texgen.c
Kristian Høgsberg [Sat, 24 Apr 2010 23:56:42 +0000 (19:56 -0400)]
mesa: Move GLES1 texgen functions to texgen.c

14 years agomesa: Move support for paletted textures to main/teximage.c
Kristian Høgsberg [Sat, 24 Apr 2010 23:34:57 +0000 (19:34 -0400)]
mesa: Move support for paletted textures to main/teximage.c

14 years agomesa: Handle GL_TEXTURE_GEN_STR_OES in _mesa_Enable()
Kristian Høgsberg [Sat, 24 Apr 2010 23:18:35 +0000 (19:18 -0400)]
mesa: Handle GL_TEXTURE_GEN_STR_OES in _mesa_Enable()

14 years agomesa: Move get_es*.c to main/
Kristian Høgsberg [Sat, 24 Apr 2010 23:17:54 +0000 (19:17 -0400)]
mesa: Move get_es*.c to main/

14 years agoes: Prefix the get* functions with _es1/2 so they don't conflict
Kristian Høgsberg [Sat, 24 Apr 2010 20:22:02 +0000 (16:22 -0400)]
es: Prefix the get* functions with _es1/2 so they don't conflict

14 years agomesa: Move GL_RGB565 workaround into fbobject.c
Kristian Høgsberg [Fri, 23 Apr 2010 01:11:56 +0000 (21:11 -0400)]
mesa: Move GL_RGB565 workaround into fbobject.c

14 years agomesa: Move GLES1/2 vbo entrypoints to vbo_exec_api.c
Kristian Høgsberg [Fri, 23 Apr 2010 00:52:21 +0000 (20:52 -0400)]
mesa: Move GLES1/2 vbo entrypoints to vbo_exec_api.c

This let's us drop stubs.c.

14 years agomesa: Move GLES2 shader stubs to main/shaders.c
Kristian Høgsberg [Fri, 23 Apr 2010 00:34:33 +0000 (20:34 -0400)]
mesa: Move GLES2 shader stubs to main/shaders.c

14 years agomesa: Move api_exec_es*.c into mesa/main
Kristian Høgsberg [Fri, 23 Apr 2010 00:26:51 +0000 (20:26 -0400)]
mesa: Move api_exec_es*.c into mesa/main

This requires renaming a few functions to have unique names so that
they can all live within the same driver.

14 years agomesa: Move references to main/remap_helper.h to api_exec.c
Kristian Høgsberg [Thu, 22 Apr 2010 17:30:03 +0000 (13:30 -0400)]
mesa: Move references to main/remap_helper.h to api_exec.c

14 years agomesa: Move struct _glapi_table allocation out of context.c
Kristian Høgsberg [Thu, 22 Apr 2010 16:40:47 +0000 (12:40 -0400)]
mesa: Move struct _glapi_table allocation out of context.c

We now allocate the table from api_exec.c and dlist.c where we fill out
the table.  This way, context.c doesn't need to know the actual contents
of struct _glapi_table.

14 years agomesa: Compute extension string according to API
Kristian Høgsberg [Thu, 22 Apr 2010 15:41:41 +0000 (11:41 -0400)]
mesa: Compute extension string according to API

We can now stop special casing glGetString() and drop specials_es*.c.

14 years agoes2: Move over es2 code to compute extensions
Kristian Høgsberg [Thu, 22 Apr 2010 12:27:51 +0000 (08:27 -0400)]
es2: Move over es2 code to compute extensions

14 years agomain: Report GL_SHADING_LANGUAGE_VERSION according to API
Kristian Høgsberg [Thu, 22 Apr 2010 12:34:42 +0000 (08:34 -0400)]
main: Report GL_SHADING_LANGUAGE_VERSION according to API

14 years agomesa: Compute GL version according to API
Kristian Høgsberg [Wed, 21 Apr 2010 20:14:18 +0000 (16:14 -0400)]
mesa: Compute GL version according to API

14 years agomesa: Move API specific context intialization into context.c
Kristian Høgsberg [Thu, 22 Apr 2010 15:07:45 +0000 (11:07 -0400)]
mesa: Move API specific context intialization into context.c

14 years agost/mesa: Use API-aware context constructor
Kristian Høgsberg [Thu, 22 Apr 2010 13:32:11 +0000 (09:32 -0400)]
st/mesa: Use API-aware context constructor

The mesa state tracker is currently the only place where we create a
context and expect it to implement GLES1/2.  Use the API-aware constructor
to communicate this to core mesa.

14 years agomesa: Track the OpenGL API we're implementing in the context
Kristian Høgsberg [Thu, 22 Apr 2010 13:25:51 +0000 (09:25 -0400)]
mesa: Track the OpenGL API we're implementing in the context

This introduces a new way to create or initialize a context:

  _mesa_create_context_for_api and
  _mesa_initialize_context_for_api

which in addition to the current arguments take an api enum to indicate
which OpenGL API the context should implement.  At this point the
API field in GLcontext isn't used anywhere, but later commits will
key certain functionality off of it.

The _mesa_create_context and _mesa_initialize_context functions are
kept in place as wrappers around the *_for_api versions, passing in
API_OPENGL to get the same behavior as before.

14 years agogallivm: Remove unused variable.
Vinson Lee [Thu, 22 Apr 2010 07:45:27 +0000 (00:45 -0700)]
gallivm: Remove unused variable.

14 years agor300g: fix vertex unit setup
Alex Deucher [Thu, 22 Apr 2010 06:37:34 +0000 (02:37 -0400)]
r300g: fix vertex unit setup

RV3xx is 2, RV560,RV570 is 8

Noticed by Tormod Volden.

14 years agogallium/util: Fix deviation calculation in u_cache.
Vinson Lee [Thu, 22 Apr 2010 01:45:44 +0000 (18:45 -0700)]
gallium/util: Fix deviation calculation in u_cache.

The approximate deviation calculation was using the entire cache's total
instead of each cache entry's total.

14 years agogallium/tests: Add test case for u_cache.
Vinson Lee [Thu, 22 Apr 2010 01:31:01 +0000 (18:31 -0700)]
gallium/tests: Add test case for u_cache.