summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* mesa: Fix ugly indentation left from previous commitIan Romanick2011-03-292-39/+36
| | | | | Reviewed-by: Eric Anholt <[email protected]> Reviewed-by: Chad Versace <[email protected]>
* glsl: Calcluate Mesa state slots in front-end instead of back-endIan Romanick2011-03-296-73/+117
| | | | | | | | | | | | This should be the last bit of infrastructure changes before generating GLSL IR for assembly shaders. This commit leaves some odd code formatting in ir_to_mesa and brw_fs. This was done to minimize whitespace changes / reindentation in some loops. The following commit will restore formatting sanity. Reviewed-by: Eric Anholt <[email protected]> Reviewed-by: Chad Versace <[email protected]>
* glsl: Move _mesa_builtin_uniform_desc from uniforms.c to ir_variable.cppIan Romanick2011-03-292-248/+253
| | | | | | | | This array is going to be used in the main compiler soon. Leaving them uniforms.c caused problems for building the stand-alone compiler. Reviewed-by: Eric Anholt <[email protected]> Reviewed-by: Chad Versace <[email protected]>
* r300g: add support for all render targets with one and two channelsMarek Olšák2011-03-291-30/+130
| | | | | | | | | | | | | | | The hardware should be set according to this table: FORMAT -> R300 COLORFORMAT ------------------------- X16 -> UV88 X16Y16 -> ARGB8888 X32 -> ARGB8888 X32Y32 -> ARGB16161616 US_OUT_FMT must contain the real format. I wasn't able to make B3G3R2 and L4A4 work, but those aren't important.
* intel: fix buildMarek Olšák2011-03-292-2/+2
| | | | | broken with e5c6a92a12b5cd7db205d72039f58d302b0be9d5 (mesa: implement clamping controls (ARB_color_buffer_float))
* intel: Protect intel_clear_with_blit from failed buffer allocationsChris Wilson2011-03-291-10/+11
| | | | | Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=34419 Signed-off-by: Chris Wilson <[email protected]>
* i965: Avoid name clash of loop counter and memberChris Wilson2011-03-291-5/+5
| | | | | | src/mesa/drivers/dri/i965/brw_fs.cpp:565 warning: name lookup of ‘c’ changed Signed-off-by: Chris Wilson <[email protected]>
* i915: Detect allocation failure of batch bufferChris Wilson2011-03-291-0/+4
| | | | Signed-off-by: Chris Wilson <[email protected]>
* r300g: finish up signed normalized textures and render targetsMarek Olšák2011-03-292-28/+46
|
* r300g: enable clamping controlsMarek Olšák2011-03-294-6/+14
|
* gallium: remove PIPE_CAP_VERTEX_COLOR_CLAMP_CONTROLMarek Olšák2011-03-292-5/+26
| | | | | | | | | | | | | | The vertex color clamp control is a property of an API, a lot like gl_rasterization_rules. The state should be set according to the API being implemented, for example: OpenGL Compatibility: enabled by default OpenGL Core: disabled by default D3D11: always disabled This patch also changes the way ARB_color_buffer_float is advertised. If no SNORM or FLOAT render target is supported, fragment color clamping is not required.
* mesa: clamp texture border color if ARB_texture_float is unsupportedMarek Olšák2011-03-291-4/+12
| | | | | ARB_texture_float disables clamping of the texture border color, ARB_color_buffer_float only modifies clamping of the glGet query.
* st/mesa: choose an appropriate texture format for DrawPixelsMarek Olšák2011-03-291-3/+49
|
* gallium: add EXT_texture_snorm supportMarek Olšák2011-03-294-2/+253
|
* mesa: implement texstore and texfetch hooks for signed normalized formatsMarek Olšák2011-03-293-118/+514
| | | | | | The snorm texstore functions were all broken. swrast support done except for mipmap generation, but I leave it disabled.
* mesa: initial EXT_texture_snorm supportMarek Olšák2011-03-2910-37/+233
| | | | | The component ordering of some formats has been been reversed to match Gallium types.
* gallium: implement clamping controls (ARB_color_buffer_float)Luca Barbieri2011-03-2910-7/+52
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | BTW this changes the gallium interface. Some rather cosmetic changes by Marek. Squashed commit of the following: commit 513b37d484f0318311e84bb86ed4c93cdff71f13 Author: Luca Barbieri <[email protected]> Date: Thu Aug 26 18:17:54 2010 +0200 mesa/st: respect fragment clamping in st_DrawPixels commit 546a31e42cad459d7a7a10ebf77fc5ffcf89e9b8 Author: Luca Barbieri <[email protected]> Date: Thu Aug 26 18:17:28 2010 +0200 mesa/st: support fragment and vertex color clamping commit c406514a1fbee6891da4cf9ac3eebe4e4407ec13 Author: Luca Barbieri <[email protected]> Date: Tue Aug 24 21:56:37 2010 +0200 mesa/st: expose ARB_color_buffer_float if unclamping is supported commit d0c5ea11b6f75f3da2f4ca989115f150ebc7cf8d Author: Luca Barbieri <[email protected]> Date: Thu Aug 26 17:53:41 2010 +0200 mesa/st: use unclamped colors This assumes that Gallium is to be interpreted as given drivers the responsibility to clamp these colors if necessary. commit aef5c3c6be6edd076e955e37c80905bc447f8a82 Author: Luca Barbieri <[email protected]> Date: Thu Aug 26 18:12:34 2010 +0200 mesa, mesa/st: handle read color clamping properly We set IMAGE_CLAMP_BIT in the caller based on _ClampReadColor, where the operation mandates it. (see the removed XXX comment. -Marek) TODO: did I get the set of operations mandating it right? commit 76bdfcfe3ff4145a1818e6cb6e227b730a5f12d8 Author: Luca Barbieri <[email protected]> Date: Thu Aug 26 18:18:25 2010 +0200 gallium: add color clamping to the interface
* mesa: implement clamping controls (ARB_color_buffer_float)Marek Olšák2011-03-2926-70/+290
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Squashed commit of the following: Author: Marek Olšák <[email protected]> mesa: fix getteximage so that it doesn't clamp values mesa: update the compute_version function mesa: add display list support for ARB_color_buffer_float mesa: fix glGet query with GL_ALPHA_TEST_REF and ARB_color_buffer_float commit b2f6ddf907935b2594d2831ddab38cf57a1729ce Author: Luca Barbieri <[email protected]> Date: Tue Aug 31 16:50:57 2010 +0200 mesa: document known possible deviations from ARB_color_buffer_float commit 5458935be800c1b19d1c9d1569dc4fa30a97e8b8 Author: Luca Barbieri <[email protected]> Date: Tue Aug 24 21:54:56 2010 +0200 mesa: expose GL_ARB_color_buffer_float commit aef5c3c6be6edd076e955e37c80905bc447f8a82 Author: Luca Barbieri <[email protected]> Date: Thu Aug 26 18:12:34 2010 +0200 mesa, mesa/st: handle read color clamping properly (I'll squash the st/mesa part to a separate commit. -Marek) We set IMAGE_CLAMP_BIT in the caller based on _ClampReadColor, where the operation mandates it. TODO: did I get the set of operations mandating it right? commit 3a9cb5e59b676b6148c50907ce6eef5441677e36 Author: Luca Barbieri <[email protected]> Date: Thu Aug 26 18:09:41 2010 +0200 mesa: respect color clamping in texenv programs (v2) Changes in v2: - Fix attributes other than vertex color sometimes getting clamped commit de26f9e47e886e176aab6e5a2c3d4481efb64362 Author: Luca Barbieri <[email protected]> Date: Thu Aug 26 18:05:53 2010 +0200 mesa: restore color clamps on glPopAttrib commit a55ac3c300c189616627c05d924c40a8b55bfafa Author: Luca Barbieri <[email protected]> Date: Thu Aug 26 18:04:26 2010 +0200 mesa: clamp color queries if and only if fragment clamping is enabled commit 9940a3e31c2fb76cc3d28b15ea78dde369825107 Author: Luca Barbieri <[email protected]> Date: Wed Aug 25 00:00:16 2010 +0200 mesa: introduce derived _ClampXxxColor state resolving FIXED_ONLY To do this, we make ClampColor call FLUSH_VERTICES with the appropriate _NEW flag. We introduce _NEW_FRAG_CLAMP since fragment clamping has wide-ranging effects, despite being in the Color attrib group. This may be easily changed by s/_NEW_FRAG_CLAMP/_NEW_COLOR/g commit 6244c446e3beed5473b4e811d10787e4019f59d6 Author: Luca Barbieri <[email protected]> Date: Thu Aug 26 17:58:24 2010 +0200 mesa: add unclamped color parameters
* mesa: regenerate glapi filesMarek Olšák2011-03-2913-8626/+8736
|
* i965: Resolve implied moves in brw_dp_READ_4_vs_relative.Kenneth Graunke2011-03-291-1/+3
| | | | | | | | | Fixes piglit test glsl-vs-arrays-3 on Sandybridge, as well as garbage rendering in 3DMarkMobileES 2.0's Taiji demo and GLBenchmark 2.0's Egypt and PRO demos. NOTE: This a candidate for stable release branches. It depends on commit 9a21bc640188e4078075b9f8e6701853a4f0bbe4.
* i965: Refactor Sandybridge implied move handling.Kenneth Graunke2011-03-291-36/+32
| | | | | | | | | This was open-coded in three different places, and more are necessary. Extract this into a function so it can be reused. Unfortunately, not all variations were the same: in particular, one set compression control and checked that the source register was not ARF_NULL. This seemed like a good idea, so all cases now do so.
* mesa: Add missing parentheses in glBlitFramebufferEXT error strings.Vinson Lee2011-03-281-5/+5
|
* intel: Don't leak the tex object miptree when replacing itIan Romanick2011-03-281-1/+3
| | | | | | | | | | | Eventually the miptree refcounting interface should be cleaned up. The assymmetry dramatically increases the probability of bugs like this. It should be made to like like libdrm refcounting or the refcounting style used in other parts of Mesa. Fixes https://bugs.freedesktop.org/show_bug.cgi?id=33046 Reviewed-by: Eric Anholt <[email protected]>
* gallivm: Fix build with llvm-2.9.Vinson Lee2011-03-281-2/+2
| | | | | The build fix of commit 40ae214067673edbda79371969d1730b6194d83e does not apply to llvm-2.9 but rather to llvm-3.0svn.
* i915g: Fix build.Vinson Lee2011-03-281-3/+6
| | | | | | Fix build failures introduced with commit 0fbb64a52931ba5871aa2c5eb01b81d391f678d1. Reviewed-by: Jakob Bornecrantz <[email protected]>
* i915g: use drm ioctl to get pci devidDaniel Vetter2011-03-281-18/+8
| | | | Signed-off-by: Daniel Vetter <[email protected]>
* gallivm: Fix build with llvm-2.9Tobias Droste2011-03-281-3/+9
| | | | | | In llvm-2.9 Target->createMCInstPrinter() takes different arguments Signed-off-by: Tobias Droste <[email protected]>
* st/mesa: Validate state before doing blits.Henri Verbeet2011-03-271-0/+3
| | | | | | | Specifically, this ensures things like the front buffer actually exist. This fixes piglt fbo/fbo-sys-blit and fd.o bug 35483. Signed-off-by: Henri Verbeet <[email protected]>
* r600g: Handle texture fetch instructions with relative addressingFabian Bieler2011-03-271-0/+1
| | | | Signed-off-by: Henri Verbeet <[email protected]>
* r600g: Handle texture fetch instructions with neg or abs on source registerFabian Bieler2011-03-271-3/+5
| | | | Signed-off-by: Henri Verbeet <[email protected]>
* r600g: Handle texture fetch instructions with swizzle on source registerFabian Bieler2011-03-271-10/+20
| | | | Signed-off-by: Henri Verbeet <[email protected]>
* glsl: Accept precision qualifiers on sampler types, but only in ES.Kenneth Graunke2011-03-261-2/+9
| | | | | | | | | | GLSL 1.30 states clearly that only float and int are allowed, while the GLSL ES specification's issues section states that sampler types may take precision qualifiers. Fixes compilation failures in 3DMarkMobileES 2.0 and GLBenchmark 2.0. NOTE: This is a candidate for stable release branches.
* i965/fs: Fix linear gl_Color interpolation on pre-gen6 hardware.Kenneth Graunke2011-03-261-3/+5
| | | | | | | | | | | | | Civilization 4's shaders make heavy use of gl_Color and don't use perspective interpolation. This resulted in rivers, units, trees, and so on being rendered almost entirely white. This is a regression compared to the old fragment shader backend. Found by inspection (comparing the old and new FS backend code). References: https://bugs.freedesktop.org/show_bug.cgi?id=32949 NOTE: This is a candidate for the 7.10 branch.
* egl/wayland-drm: Fix include pathBenjamin Franzke2011-03-261-1/+2
| | | | | | src/egl/main/egltypedefs.h needs the path for EGL/egl.h Reported by jlind on irc.
* egl_dri2: We don't actually support KHR_gl_texture_2D_imageKristian Høgsberg2011-03-261-1/+0
|
* egl_dri2: Enable image extensions in one placeKristian Høgsberg2011-03-264-13/+7
| | | | | We know what we can support in egl_dri2.c so just enable the extensions there.
* glsl: Generate readable unique names at print time.Kenneth Graunke2011-03-252-11/+63
| | | | | | | | | | | | | | | | | | | | Since GLSL IR allows multiple ir_variables to share the same name, we need to generate unique names when printing the IR. Previously, we always used %s@%p, appending the ir_variable's memory address. While this worked, it had two drawbacks: - When there aren't duplicates, the extra "@0x669a3e88" is useless and makes the code harder to read. - Real duplicates were hard to tell apart: channel_expressions@0x6699e3c8 vs. channel_expressions@0x6699ddd8 We now append @2, @3, @4, and so on, but only where necessary to distinguish duplicates. Since we only do this at print time, any performance impact is irrelevant. Signed-off-by: Kenneth Graunke <[email protected]> Reviewed-by: Eric Anholt <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* gallivm: Fix build with llvm-2.9.Vinson Lee2011-03-251-0/+5
| | | | | In llvm-2.9, the header file llvm/System/Host.h has been moved to llvm/Support/Host.h.
* glsl: Make add_variable, add_uniform, et. al. have similar signaturesIan Romanick2011-03-251-106/+109
| | | | | | While making some other changes in this area I was finding it annoying each of these functions took mostly the same set of parameters in differing orders.
* i965/fs: Use different name for inner loop counterIan Romanick2011-03-251-2/+2
| | | | | | 'i' is already used for the outer loop. This caused some problems while doing other work in this area. No bug exists here... until you want to use the outer loop counter in the inner loop.
* glsl: Fix off-by-one error setting max_array_access for non-constant indexingIan Romanick2011-03-251-1/+1
| | | | NOTE: This is a candidate for the stable branches.
* glsl: Add array access bounds checking to ir_validateIan Romanick2011-03-251-0/+15
|
* mesa: add void to save_TextureBarrierNV()Brian Paul2011-03-251-1/+1
|
* glsl: Add void to _mesa_destroy_shader_compiler() argument list.José Fonseca2011-03-251-2/+2
| | | | | At least MSVC sees a distinction between foo() and foo(void) and warns about it.
* mesa: Avoid redefining PUBLIC/USE/likely/unlikely macros.José Fonseca2011-03-251-13/+17
|
* mesa: Use appropriate call convention in VertexAttribI*v.José Fonseca2011-03-251-136/+136
| | | | | | | | | We were using typecasts because the functions pointers are polymorphic in the second argument type, which. Surprisingly the wrong calling convention didn't cause crashes on Windows, but it was causing certain registers to be trashed in MSVC optimized builds, when processing callists in the ClearView RC Flight Simulator.
* gallium: Avoid redefinition of likely/unlikely macros on non gcc compilers.José Fonseca2011-03-251-6/+8
|
* mesa,mapi: Remove spurious const keyword from ClearBufferfi args.José Fonseca2011-03-255-8/+8
|
* r300g: fix alpha-test with no colorbufferMarek Olšák2011-03-241-0/+5
| | | | | | | Piglit: - fbo-alphatest-nocolor NOTE: This is a candidate for the stable branches.
* mesa: added _mesa_dump_image() for debuggingBrian Paul2011-03-242-0/+28
|