Commit graph

37526 commits

Author SHA1 Message Date
Vinson Lee
81bc4f4cbf intel: Remove unnecessary header. 2010-08-04 15:38:24 -07:00
Vinson Lee
9f7e7ce757 st/mesa: Add missing headers in st_cb_flush.h.
Add forward declarations.
Include p_compiler.h for uint symbol.
2010-08-04 15:32:53 -07:00
Vinson Lee
85dbb2904b st/mesa: Clean up header inclusion in st_cb_feedback.h.
Replace mtypes.h with forward declaration.
Include compiler.h for INLINE symbol.
2010-08-04 15:26:37 -07:00
Aras Pranckevicius
ea3a9eb53a glsl2: add gl_LightModel built-in uniform. 2010-08-04 14:41:01 -07:00
Eric Anholt
b6ceddc371 glsl2: Don't try to assign locations for samplers during linking.
Mesa will do the mapping at _mesa_add_sampler() time.  Fixes assertion
failures in debug builds, which might have caught real problems with
multiple samplers linked in a row.
2010-08-04 14:28:57 -07:00
Eric Anholt
fe1918c71c ir_to_mesa: Clean up the mapping of samplers to Mesa's sampler uniforms.
Instead of using a linker-assigned location (since samplers don't
actually take up uniform space, being a link-time choice), use the
sampler's varaible pointer as a hash key.
2010-08-04 14:21:01 -07:00
Eric Anholt
8e181b629f mesa: Don't null deref looking for Mesa IR code at compile time.
The new compiler doesn't generate Mesa IR at compile time, and that
compile time code previously wouldn't have reflected the link time
code that actually got used.  But do dump the info log of the compile
regardless.
2010-08-04 14:13:08 -07:00
Jerome Glisse
12dac449fb r600g: force flush on map as temporary fix to readpixel
Should allow more piglit test to pass. Need to plugin
proper flushing.

Signed-off-by: Jerome Glisse <jglisse@redhat.com>
2010-08-04 16:29:56 -04:00
Vinson Lee
2e85117b5f st/mesa: Add missing headers to st_cb_fbo.h. 2010-08-04 13:18:55 -07:00
Jerome Glisse
9a78e790dc r600g: always perform texture perspective divide + fix blending
quake3 engine seems to run fine at this point (ioquake)

Signed-off-by: Jerome Glisse <jglisse@redhat.com>
2010-08-04 16:11:39 -04:00
Vinson Lee
19bfb55fb5 st/mesa: Clean up header file inclusion in st_cb_eglimage.h.
Replace dd.h and mtypes.h with a forward declaration.
Include compiler.h for INLINE symbol.
2010-08-04 13:04:36 -07:00
Eric Anholt
952d0f88e1 glsl2: Skip talloc_parent in constant_expression of non-constant arrays. 2010-08-04 12:57:58 -07:00
Vinson Lee
988e86762f draw: Fix return type of draw_translate_vinfo_size.
Fixes typo from commit b609cfc7c9.
2010-08-04 12:55:21 -07:00
Vinson Lee
137c510097 st/mesa: Clean up header file inclusion in st_cb_drawtex.h.
Replace mtypes.h with forward declarations.
Include compiler.h for INLINE symbol.
2010-08-04 12:46:38 -07:00
Eric Anholt
8273bd4687 glsl2: Make the clone() method take a talloc context.
In most cases, we needed to be reparenting the cloned IR to a
different context (for example, to the linked shader instead of the
unlinked shader), or optimization before the reparent would cause
memory usage of the original object to grow and grow.
2010-08-04 12:42:47 -07:00
Vinson Lee
dce63cf431 st/mesa: Clean up header file inclusion in st_cb_drawpixels.h.
Replace mtypes.h with forward declarations.
Include compiler.h for INLINE symbol.
2010-08-04 12:29:26 -07:00
Vinson Lee
7fdf6d5c28 st/mesa: Add forward declaration in st_cb_condrender.h. 2010-08-04 12:24:51 -07:00
Vinson Lee
ed810ba724 st/mesa: Add forward declarations in st_cb_clear.h. 2010-08-04 12:22:31 -07:00
Vinson Lee
6bc17324da st/mesa: Include missing headers in st_cb_bufferobjects.h.
Include compiler.h for INLINE symbol.
Include mtypes.h for gl_buffer_object symbol.
2010-08-04 12:13:29 -07:00
Vinson Lee
eb4f2d4b02 st/mesa: Clean up header file inclusion in st_cb_blit.h.
Replaced mtypes.h and st_context.h with forward declarations.
Added compiler.h for INLINE symbol.
2010-08-04 12:08:17 -07:00
Vinson Lee
e6902afeee st/mesa: Clean up header file inclusion in st_cb_bitmap.h.
Removed mtypes.h.
Include compiler.h for INLINE symbol.
Added forward declarations.
2010-08-04 12:00:19 -07:00
Kristian Høgsberg
2542d8e0c2 glx: Move deref after NULL check 2010-08-04 12:51:26 -04:00
Aras Pranckevicius
84ee01f40a glsl2: Set ir_discard::ir_type when cloning it
Fixes unset ir_type after inlining.
2010-08-04 08:57:02 -07:00
Kristian Høgsberg
e3a0e468bc glx: Fix use after free in drisw error path 2010-08-04 08:57:02 -04:00
Kristian Høgsberg
e71c44cedd glx: We no longer need screen extensions for drisw
https://bugs.freedesktop.org/show_bug.cgi?id=29177
2010-08-04 08:52:26 -04:00
Kristian Høgsberg
9da1c9da13 glx: dri2InvalidateBuffers() needs the X drawable XID not the GLX one
This never ceases to entertain.
2010-08-04 08:47:36 -04:00
Andre Maasikas
8ad5b76d52 r600: relax stride/alignment requirements for vertices
seems hw can do unaligned accesses and unaligned strides
removes extra conversion when using vbo's

however I needed to switch 3 component byte format to 4 component formats
for tests to pass. Somewhat sililar to GL_SHORT fix done earlier

removes assert and gains +2 piglit especially draw-vertices
2010-08-04 12:49:39 +03:00
Chia-I Wu
5c2f01bbb0 draw: Fix the edge flags of flatshade_first polygons.
This bug can be triggered by rendering polygons with

   glProvokingVertexEXT(GL_FIRST_VERTEX_CONVENTION_EXT);
   glPolygonMode(GL_FRONT_AND_BACK, GL_LINE);
2010-08-04 14:03:05 +08:00
Tom Stellard
09c8fa570e r300/compiler: Always unroll loops when doing loop emulation. 2010-08-03 20:17:00 -07:00
Tom Stellard
2824d5687a r300/compiler: r500 hw support for break and continue in loops.
The BGNLOOP and ENDLOOP instructions are now being used correctly, which
makes break and continue possible.  The deadcode pass has been modified to
handle breaks, and the compiler is more careful about which loops are
unrolled.
2010-08-03 19:11:08 -07:00
Tom Stellard
9dcc500666 r300/compiler: KILP may not always be inside an IF statement. 2010-08-03 19:11:08 -07:00
Tom Stellard
680f486ffd r300/compiler: Don't unroll loops with continue or break. 2010-08-03 19:11:08 -07:00
Vinson Lee
a3ff6c2697 st/mesa: Clean up header file inclusion in st_cache.h. 2010-08-03 17:55:53 -07:00
Vinson Lee
279926859e st/mesa: Add forward declarations in st_atom_shader.h. 2010-08-03 17:35:29 -07:00
Dave Airlie
8bc5fe1ad6 r300g: disable multisample visuals until the state tracker bits catch up.
This stops us advertising lots of ms visuals we can't actually use.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2010-08-04 09:37:43 +10:00
Brian Paul
48268e0f2a draw: check for instance divisors in vcache_check_run()
When we have instance divisors we don't really know which vertex
elements we'll be fetching ahead of time.

This fixes a bug in instanced drawing which was exposed by the new
draw_vbo() code because of max_index not being ~0 as often as it used
to be.  The test for max_index >= DRAW_PIPE_MAX_VERTICES often hid
this problem before.
2010-08-03 16:37:58 -06:00
Brian Paul
e89e47e6d0 gallium/translate: make generic_run() and generic_run_elts() more alike
Plus more debug code and do clamping in generic_run().
2010-08-03 16:37:58 -06:00
Brian Paul
8c3cc83432 draw: added a comment 2010-08-03 16:37:58 -06:00
Brian Paul
0e7b53c75b draw: use instance divisor in draw_print_arrays() 2010-08-03 16:37:58 -06:00
Brian Paul
f94e7e25d1 draw: add assertion, rearrange debug code 2010-08-03 16:37:58 -06:00
Marek Olšák
afbf446de5 st/dri: fix crash when dri2_drawable_get_buffers fails
It's easily reproducible with Compiz with its Resize window mode
set to Normal (which is usually not the default mode).

https://bugs.freedesktop.org/show_bug.cgi?id=28658
https://bugs.freedesktop.org/show_bug.cgi?id=29303

This is actually a workaround to prevent Compiz crashes.
Instead, a completely white titlebar might show up during resizing
transparent windows (a rare case).

The underlying cause should be fixed by someone who has more knowledge
about the code. (dri2_drawable_get_buffers should not return NULL)

Acked-By: Jakob Bornecrantz <jakob@vmware.com>
2010-08-04 00:07:28 +02:00
Marek Olšák
0614006d09 mesa: increase the relative address offset limit to 4096 in ARB_vp/fp
Even though the spec says that the limits should be -64/+63, proprietary
drivers support much larger relative offsets and some applications do
depend on this non-standard behavior.

Also program_parse.tab.c has been regenerated.

This fixes the parser error:

  ARB_vp: error: relative address offset too large

See also: https://bugs.freedesktop.org/show_bug.cgi?id=28628

4096 * sizeof(vec4) is the maximum size of the constant buffer on NV50.
It is not supposed to be a definite hardware limit, it is for the parser
not to get in the way and let the underlying driver decide whether it can
run the shader or not.
2010-08-04 00:07:28 +02:00
Jerome Glisse
dd863bf5e7 r600g: add polygon offset support
Signed-off-by: Jerome Glisse <jglisse@redhat.com>
2010-08-03 17:45:51 -04:00
Jerome Glisse
a0b3944c30 r600g: flush and resubmit if we reach limit
Signed-off-by: Jerome Glisse <jglisse@redhat.com>
2010-08-03 17:02:48 -04:00
Jerome Glisse
3a8d4a8979 r600g: fix color target mask
Signed-off-by: Jerome Glisse <jglisse@redhat.com>
2010-08-03 16:16:01 -04:00
Zack Rusin
6f9d3516a4 gallium/draw: forgot about PIPE_PRIM_LINE_STRIP_ADJACENCY 2010-08-03 16:02:09 -04:00
Zack Rusin
1fd84b10f2 gallium/util: add extra primitives to the trimmer 2010-08-03 15:56:49 -04:00
Jerome Glisse
8f6341d421 r600g: fix stencil
Signed-off-by: Jerome Glisse <jglisse@redhat.com>
2010-08-03 15:49:21 -04:00
Eric Anholt
c22dee7216 glsl2: Fix ir_validate validating null variable names.
An unnamed variable in a prototype will have a NULL ->name, so don't
worry about storage then.

Fixes:
CorrectFunction1.vert
CorrectParse1.frag
2010-08-03 11:47:02 -07:00
Eric Anholt
900ab2f564 glsl2: No need to strdup the name passed in to ir_variable constructor.
ir_variable always strdups the incoming name so that it matches the
lifetime of the ir_variable.
2010-08-03 11:40:26 -07:00