Commit Graph

39102 Commits

Author SHA1 Message Date
Benjamin Franzke 48d4a001b3 gbm: Add gallium (drm) backend 2011-06-23 21:07:17 +02:00
Benjamin Franzke 2ff797060d gbm: Add dri backend 2011-06-23 21:07:17 +02:00
Benjamin Franzke eddcecbf74 Add gbm (generic/graphics buffer manager) 2011-06-23 21:07:17 +02:00
Benjamin Franzke 15d7f1c1c7 st/dri: Implement DRIimageExtension::dupImage 2011-06-23 21:07:17 +02:00
Benjamin Franzke 3af3c58dfd intel: Implement DRIimageExtension::dupImage 2011-06-23 21:07:17 +02:00
Benjamin Franzke fa5478c5fe r600g: Add R8G8B8A8_UNORM to evergreen colorswap table
Fixes broken glTexImage2D with format=GL_RGBA since
1a339b6c71

The origin for this behaviour is that r600_is_format_supported
checks only against r600_state_inline.h tables not evergreens.
2011-06-23 21:06:36 +02:00
Marek Olšák 1e5cef96d1 r600g: bump shader input limits 2011-06-23 15:58:49 +02:00
Brian Paul 8a5a28b731 st/wgl: return height, not width for WGL_PBUFFER_HEIGHT_ARB
Fixes https://bugs.freedesktop.org/show_bug.cgi?id=38599
2011-06-23 06:54:53 -06:00
Benjamin Franzke 87c3bb65bb st/egl/wayland: Take resize parameters only if size changes
This matches what we do in egl_dri2, and clients should
behave like this anyway.
2011-06-23 12:17:48 +02:00
Chia-I Wu 7587c140cd st/mesa: use a helper for st_framebuffer creation
In st_api_make_current, we would like to reuse the exising
st_framebuffer if possible.  Use a helper function to make the code
clearer.
2011-06-23 10:36:00 +09:00
Stéphane Marchesin 1a339b6c71 st/mesa: prefer native texture formats when possible.
If possible, we want to match the hardware format to what the app uses. By
doing so, we avoid the need for pixel conversions and therefore greatly speed
up texture uploads.
2011-06-22 17:02:21 -07:00
Stéphane Marchesin 98ce1373e4 i915g: Add draw point sprites.
It's not that much work; hopefully blend func separate also works and we get GL 2.0 for real.
2011-06-22 16:51:02 -07:00
Stéphane Marchesin 468c2c0841 i915g: Fix comment.
Reported-by: Marcin Baczynski <marbacz@gmail.com>
2011-06-22 16:47:36 -07:00
Stéphane Marchesin 465183c6ae i915g: Support more texture and render target formats. 2011-06-22 16:44:54 -07:00
Alex Deucher 5ff22ab229 r600c: add missing bank tiling case for evergreen
Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
2011-06-22 12:38:29 -04:00
Alex Deucher c4930cb417 r600g: fix num_banks interpretation on eg+
Field is encoded:
0 = 4 banks
1 = 8 banks
2 = 16 banks

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
2011-06-22 12:34:37 -04:00
Michel Dänzer eb2c9b5814 r600g: Fix use of uninitialized local variable extra_size.
Should fix http://bugs.freedesktop.org/show_bug.cgi?id=38566 .
2011-06-22 16:23:36 +02:00
Brian Paul 9786688672 mesa: comments and 80-column wrapping 2011-06-22 08:12:10 -06:00
Brian Paul 3c95ff209f mesa: update comments in update_program_enables() 2011-06-22 08:12:10 -06:00
Brian Paul 79dddedfd1 mesa: update/fix comments in update_program() 2011-06-22 08:12:10 -06:00
Brian Paul f3f080e526 mesa: update comment for gl_texture_unit 2011-06-22 08:12:10 -06:00
Marcin Slusarz 50d7d03a79 xorg/nouveau: blacklist all pre NV30 cards
Bail out early in probe, so other driver can take control of the card.
Doing it in screen_create would be too late.
2011-06-22 12:35:40 +02:00
Andre Maasikas 63e8cda9f1 r600c: use BASE_VTX_LOC & AUTO_INDEX for drawing nonindexed with offset
Saves cmd buffer space as we were generating indexes into cs  in this case.
This was laying around in https://bugs.freedesktop.org/show_bug.cgi?id=32768
for a long time.
2011-06-22 12:40:12 +03:00
Alex Deucher 21972c85ea r600g: fix fbo depth/stencil texture allocation for evergreen+
evergreen+ stores depth and stencil separately so when we
allocate a depth/stencil fbo, make sure we allocate enough
memory for both depth and stencil buffers.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
2011-06-21 17:32:42 -04:00
Chad Versace 3db27d4a4a intel: Allocate s8_z24 non-texture renderbuffers when using separate stencil
Now all infrastructure is in place to support s8_z24 non-texture
renderbuffers for gen7.

Reviewed-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Chad Versace <chad@chad-versace.us>
2011-06-21 11:22:05 -07:00
Chad Versace 36e05c6870 intel: Unobfuscate intel_alloc_renderbuffer_storage
Hiz buffer allocation can only occur if the 'else' branch has been taken,
so move the hiz buffer allocation into the 'else' branch.

Having the hiz buffer allocation dangling outside of the if-tree was just
damn confusing.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Signed-off-by: Chad Versace <chad@chad-versace.us>
2011-06-21 11:21:57 -07:00
Chad Versace 39d0e3632a intel: Add fields to intel_renderbuffer for unwrapping packed depth/stencil buffers
Add the following fields:
    intel_renderbuffer.wrapped_depth;
    intel_renderbuffer.wrapped_stencil

If the intel_context is using separate stencil and the renderbuffer has
a packed depth/stencil format, then wrapped_depth and wrapped_stencil are
the real renderbuffers.

Alter the following functions to accomodate the wrapped buffers:
    intel_delete_renderbuffer
    intel_draw_buffer
    intel_get_renderbuffer
    intel_renderbuffer_map
    intel_renderbuffer_unmap

Subsequent commits allocate renderbuffer storage for wrapped_depth and
wrapped_stencil.

Reviewed-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Chad Versace <chad@chad-versace.us>
2011-06-21 11:21:57 -07:00
Chad Versace 23ed3b90c7 intel: Unconditionally enable support for S8_Z24 texture format
Commit b5c847c7ca erroneously disabled
support for S8_Z24 texture format when the context required separate
stencil (intel_context.must_use_separate_stencil).

But the GL spec requires implementations to support GL_DEPTH24_STENCIL8.
So we better find a way to fake it...

From page 180 (196 of pdf) of the OpenGL 3.0 spec:
    In addition, implementations are required to support the following
    sized internal [texture] formats.

    [...]

    - Combined depth+stencil formats: DEPTH32F_STENCIL8 and and
      DEPTH24_STENCIL8.

Reviewed-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Chad Versace <chad@chad-versace.us>
2011-06-21 11:21:57 -07:00
Benjamin Franzke 0cb356dd5c egl_dri2/wayland: Hook up new buffer.release event 2011-06-21 13:11:43 -04:00
Benjamin Franzke 8c91d751c8 winsys/wayland: Fix warning 2011-06-21 13:11:43 -04:00
Benjamin Franzke 0c74091591 st/mesa: Invalidate drawables on context switch 2011-06-21 15:09:55 +02:00
Dave Airlie e251b3903a r600g: use maths instead of a loop to work out mask.
This is equivalent results with less looping.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2011-06-21 15:18:44 +10:00
Dave Airlie 59a402cecd r600g: optimise draw vbo function a bit more.
this drop a bunch of unnecessary checks (i.e. should be trapped
at gallium level), and also removes the switch statement in favour
of some calculated values for the vgt values.

Signed-off-by: Dave Airlie <airlied@redhat.com>
2011-06-21 14:20:49 +10:00
Pierre-Eric Pelloux-Prayer abe74a9820 r600g: reorder LIT instructions to support src == dst
the attached patch should be an improvement over Vadim Girlin's patch
fixing LIT instruction for r600g (commit
2fe39b46e7).

Instructions used in tgsi_lit have been reordered to always write to a
dst channel after the same channel in src has been read (so if src ==
dst, input values are not overwritten before being used).

Signed-off-by: Dave Airlie <airlied@redhat.com>
2011-06-21 12:50:44 +10:00
Ben Skeggs 4112ca54e3 nvfx: nasty hack to make glFinish() actually finish..
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2011-06-21 12:59:53 +10:00
Stéphane Marchesin 75be6b76ee glx: Fix compile. 2011-06-20 17:19:00 -07:00
Stéphane Marchesin 649d03d54d st/mesa: Remove unneeded texture format terminators.
Signed-off-by: Brian Paul <brianp@vmware.com>
2011-06-20 18:15:50 -06:00
Brian Paul bc60a7515a st/mesa: put const qualifer on format_map table 2011-06-20 18:15:50 -06:00
Jeremy Huddleston 4fbdde889c glx: Bind to our context before __glXSetCurrentContext
We want to bind to our context before calling __glXSetCurrentContext or
messing with the gc rect in order to properly handle error conditions.

Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2011-06-20 16:54:58 -07:00
Jeremy Huddleston 517614141b glx: Destroy the old context only after the new one has been bound
This fixes a regression introduced by 49d7e48b33

Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2011-06-20 16:54:58 -07:00
Jeremy Huddleston 559e4f8ebc glx: Allow a context-specific fallback for glXGetProcAddress
In applegl, GLX advertises the same extensions provided by OpenGL.framework
even if such extensions are not provided by glapi.  This allows a client
to get access to such API.

Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2011-06-20 16:54:58 -07:00
Jeremy Huddleston fbd7448977 glapi: Update specs to correctly list FramebufferTextureLayerARB as an alias of FramebufferTextureLayerEXT
FramebufferTextureLayer is an alias of FramebufferTextureLayerEXT, so
FramebufferTextureLayerARB needs to be listed as an alias of
FramebufferTextureLayerEXT rather than FramebufferTextureLayer.

Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2011-06-20 16:54:58 -07:00
Ian Romanick de77324d8f linker: Reject shaders that use too many varyings
Previously it was up to the driver or later code generator to reject
these shaders.  It turns out that nobody did this.

This will need changes to support geometry shaders.

NOTE: This is a candidate for the stable branches.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=37743
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2011-06-20 15:01:10 -07:00
Dan Nicholson 4e5c51a05e glw: Mark all extern symbols GLAPI to regain default visibility (#31294)
Since switching to hidden visibility on gcc, GLw apps were failing to
link. Use the GLAPI definition to use default visibility where necessary.

$ nm lib/libGLw.so | grep DrawingArea
0000000000004020 T GLwCreateMDrawingArea
0000000000003430 T GLwDrawingAreaMakeCurrent
0000000000003410 T GLwDrawingAreaSwapBuffers
0000000000204c60 D glwDrawingAreaClassRec
0000000000204d48 D glwDrawingAreaWidgetClass
00000000002053c0 D glwMDrawingAreaClassRec
00000000002054e0 D glwMDrawingAreaWidgetClass

Signed-off-by: Dan Nicholson <dbn.lists@gmail.com>
Tested-by: justin <jlec@gentoo.org>
2011-06-20 12:31:01 -07:00
Eric Anholt f6e5230b26 i965/gen6: Apply documented workaround for nonpipelined state packets.
Fixes a 100% reproducible GPU hang in topogun-1.06-orc-84k.trace.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2011-06-20 08:42:16 -07:00
Eric Anholt 0ab7d6f437 i965/gen6: Limit the workaround flush to once per primitive.
We're about to call this function in a bunch of state emits, so let's
not spam the hardware with flushes too hard.
2011-06-20 08:37:43 -07:00
Eric Anholt dfada714f8 i965/gen6: Use an BO instead of writing to address 0 for PIPE_CONTROL W/A.
This was spectacularly unsafe.  On my system, address 0 happens to be
the hardware status page for the render ring, and the first quadword
of that happens to contain nothing we ever look at, but I sure didn't
look forward to having to debug some day when, for example, the kernel
happened to bind the ringbuffer before binding the hwsp.
2011-06-20 08:37:43 -07:00
Eric Anholt 8f9e8d79c8 i965/gen6: Factor the PIPE_CONTROL workaround to a separate function.
We're need this workaorund a lot more than we're currently doing, so
let's reuse it.
2011-06-20 08:37:43 -07:00
Eric Anholt 911768700e i965/gen6: Remove state flagging on BRW_NEW_CURBE_OFFSETS.
That flag was leftover from gen4, where brw_curbe.c is choosing ranges
of the CURBE space for constants to live in, and the unit state tells
where to load them from.  That's not the case on gen6 -- we don't set
this flag (since constants aren't in the URB), nor do we have any
state like that to upload.
2011-06-20 08:37:43 -07:00
Eric Anholt c860f48f11 i965/gen4: Remove old VS unit state key structure.
We're streaming VS state out now, not caching it.
2011-06-20 08:37:42 -07:00
Eric Anholt 7d4d608240 i965/gen6: Add missing state flag for VS push constants.
It was already annotated up above and everything.
2011-06-20 08:37:42 -07:00
Eric Anholt b46dc45cee i965/gen6+: Correct gratuitous dependency on NEW_POLYGONSTIPPLE.
That flag is for the contents of the stipple, not the enable flag.
2011-06-20 08:37:42 -07:00
Eric Anholt 416a698b3c i965/gen6+: Add a missing state flag for WM constants. 2011-06-20 08:37:42 -07:00
Kristian Høgsberg 16a04e019d wayland: Pass use_invalidate extension to driver 2011-06-20 11:05:26 -04:00
Benjamin Franzke 80636ff2da egl_dri2/x11: Check availability of the dri2 extension
Do this before query versions, or xcb will shutdown
and the connection can not be used for swrast.
2011-06-20 10:06:24 -04:00
Marcin Slusarz c772d4e6f3 xorg/nouveau: rename to nouveau2
Signed-off-by: Marek Olšák <maraeo@gmail.com>
2011-06-20 02:29:28 +02:00
Marcin Slusarz a97b40a886 st/xorg: initialize drm_mode.type
it's uninitialized, but used by kernel (drm_mode_setcrtc -> drm_mode_set_crtcinfo)

Signed-off-by: Marek Olšák <maraeo@gmail.com>
2011-06-20 02:28:02 +02:00
Marcin Slusarz 21c0556b61 st/xorg: add GALLIUM_AUXILIARIES to target dependencies
Without it changes to GALLIUM_AUXILIARIES don't induce target rebuild

Signed-off-by: Marek Olšák <maraeo@gmail.com>
2011-06-20 02:26:53 +02:00
Marcin Slusarz 2f6a9687cf gallium/nouveau: remove unused nouveau_screen_bo_user 2011-06-20 02:23:12 +02:00
Marcin Slusarz fe20edf959 st/xorg: fix crash triggered by rendercheck -t composite -f a8r8g8b8 -o Src, Saturate
samplers[0] may remain uninititialized if src picture/pixmap is null
2011-06-20 02:20:26 +02:00
Marcin Slusarz 54d1b718b8 st/xorg: fix crash triggered by rendercheck -t blend -f a8r8g8b8 -o Clear 2011-06-20 02:11:12 +02:00
Marek Olšák badf0335ef r600g: implement seamless_cube_map on r600-r700
st/mesa guarantees that all bound sampler states have the same value
in seamless_cube_map.
2011-06-20 00:19:07 +02:00
Marek Olšák 9bcce02f47 r600g: remove some magic numbers 2011-06-19 23:28:33 +02:00
Marek Olšák d1f66a9424 u_vbuf_mgr: make u_vbuf_mgr_draw_begin return flags in a bitmask 2011-06-19 21:09:18 +02:00
Marek Olšák 8623c68aec r600g: fix warning: assignment discards qualifiers from pointer target type 2011-06-19 21:09:18 +02:00
Marek Olšák 0d58723cde u_vbuf_mgr: fix uploading if format size is greater than stride 2011-06-19 21:09:18 +02:00
Kenneth Graunke dd3b812962 i965: Enable extension GL_ARB_shader_texture_lod.
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=36987

Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Eric Anholt <eric@anholt.net>
2011-06-18 17:54:01 -07:00
Kenneth Graunke 6430df3773 i965/fs: Add support for TXD with shadow comparisons.
Our hardware doesn't have a sample_d_c message, so we have to do a
regular sample_d and emit instructions to manually perform the
comparison.

This requires a state dependent recompile whenever the sampler's compare
mode or function change.  This adds the per-sampler comparison functions
to brw_wm_prog_key, but only sets them when the sampler's compare mode
is GL_COMPARE_R_TO_TEXTURE (i.e. only for shadow sampling).

Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Eric Anholt <eric@anholt.net>
2011-06-18 17:53:57 -07:00
Kenneth Graunke 01fa9addf4 i965/fs: Refactor texture result swizzling into a helper function.
The next patch will add a few additional uses.

Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Eric Anholt <eric@anholt.net>
2011-06-18 17:53:55 -07:00
Kenneth Graunke f1622cfe9c i965/fs: Move sampler fetch to the top of the ir_texture visit function.
This makes it available earlier, which will soon be necessary.
(Separating code motion from actual changes.)

Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Eric Anholt <eric@anholt.net>
2011-06-18 17:53:53 -07:00
Kenneth Graunke 6c947cfd19 i965/fs: Add support for non-shadow textureGrad (TXD) on gen4.
Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Eric Anholt <eric@anholt.net>
2011-06-18 17:53:52 -07:00
Kenneth Graunke 2f4a4b943f i965/fs: Add support for non-shadow textureGrad (TXD) on gen5/6.
Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Eric Anholt <eric@anholt.net>
2011-06-18 17:53:50 -07:00
Kenneth Graunke 3fa910fff9 i965/fs: Add support for non-shadow textureGrad (TXD) on Ivybridge.
This is somewhat ugly, but I couldn't think of a nicer way to handle the
interleaved coordinate/derivative parameter loading.

Ironlake and Sandybridge will still hit an assertion in visit().

Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Eric Anholt <eric@anholt.net>
2011-06-18 17:53:47 -07:00
Kenneth Graunke ad9481e128 i965/fs: Check for compilation failure and bail before optimizing.
Prior to this patch, it would attempt to optimize and allocate registers
for the program even if it failed to compile.  This seems wasteful.

More importantly, the "message length > 11" failure seems to choke the
instruction scheduler, making it somehow use an undefined value and
segmentation fault.

Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Eric Anholt <eric@anholt.net>
2011-06-18 17:53:24 -07:00
Eric Anholt c173541d97 i965: Use state streaming on programs, and state base address on gen5+.
There will be a little bit of thrashing of the program cache BO as the
cache warms up, but once the application is in steady state, this
reduces relocations on gen5 and later.

On my T420 laptop, cairogl firefox-talos-gfx performance improves 2.6%
+/- 1.3% (n=6).  No statistically significant performance difference
on nexuiz (n=5).
2011-06-18 16:00:45 -07:00
Eric Anholt 962dab9486 i965: Only flag the new-batch related state as dirty at new batch time.
This was debug code from the initial import of the driver.  No
statistically significant performance difference on cairo-gl or
nexuiz (n=6).
2011-06-18 16:00:45 -07:00
Eric Anholt 6f998b58bc mesa: Fix render-to-texture regression.
Accidentally introduced in fc8c4a3a7b.
Fixes fbo-drawbuffers-maxtargets and friends.
2011-06-18 15:59:00 -07:00
Eric Anholt 001e071443 mesa: Flag _NEW_BUFFERS when unbinding an attachment on glDeleteTextures.
The _ColorDrawBuffers[] wouldn't get updated despite us having updated
what it depends on (Attachments[]->Renderbuffer).  Other callers of
_mesa_remove_attachment are already flagging _NEW_BUFFERS for other
reasons.  The specific bug report that led to this fix (and
the fbo-finish-deleted testcase) was fixed by
23b6f9606d, though.

Reviewed-by: Brian Paul <brianp@vmware.com>
2011-06-18 15:26:26 -07:00
Eric Anholt a5a36d9b15 i965: Don't try to continue space before the start of a VBO.
This loop is trying to see if all the buffers to be uploaded happen to
be the same increment from the start of the 3DSTATE_VERTEX_BUFFERS
currently loaded in the hardware.  However, we might be at a smaller
offset than the previous set of VERTEX_BUFFERS, so we can't reuse
because that packet made the first entry be its starting offset (you
can't access outside the given bounds).

Fixes piglit ARB_vertex_buffer_object/elements-negative-offset.
2011-06-18 15:20:36 -07:00
Eric Anholt 5c2c60175d i965: Add missing state flag for vertex elements on current VS program.
Fixes a missing 3DSTATE_VERTEX_ELEMENTS on topogun.trace.
2011-06-18 15:20:35 -07:00
Marek Olšák a4f4e24f07 r300g: rename AOS -> VARRAYS 2011-06-18 21:09:08 +02:00
Marek Olšák 7df7eaf845 r300g: fix handling PREP_* options
This should fix rendering >65532 vertices using draw_arrays on r300-r400.

NOTE: This is a candidate for the 7.10 branch.
2011-06-18 21:09:08 +02:00
Vadim Girlin 2fe39b46e7 r600g: fix LIT to handle src==dst properly
Current LIT implementation uses dst components for storing temp
results, possibly overwriting still needed values (depends on the
swizzles).
This patch uses temp reg for one of such cases (found in etqw) and
fixes "LIT R.z, R.xyzz".

Tested on evergreen. Fixes some etqw-demo rendering glitches when
"Lighting" is set to "High" in the settings.

Signed-off-by: Vadim Girlin <vadimgirlin@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2011-06-18 16:03:04 +10:00
Vadim Girlin 8ab1c5328b r600g: fix RSQ to use abs value of operand on evergreen
fixes https://bugs.freedesktop.org/show_bug.cgi?id=36917

Signed-off-by: Vadim Girlin <vadimgirlin@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2011-06-18 16:01:03 +10:00
Vadim Girlin a916d4279a r600g: fix source box in r600_resource_copy_region
Source box needs to be adjusted for blitting from compressed formats.

fixes https://bugs.freedesktop.org/show_bug.cgi?id=35434

Signed-off-by: Vadim Girlin <vadimgirlin@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2011-06-18 15:45:59 +10:00
Brian Paul 753660780a mesa: allow depth texture arrays
The GL_EXT_texture_array spec allows this (Section 3.8.1).
Fixes failing piglit fbo-depth-array test.

NOTE: This is a candidate for the 7.10 branch.
2011-06-17 13:44:59 -06:00
Brian Paul da5c852d63 st/mesa: remove unneeded test for GL_TRUE 2011-06-17 13:44:59 -06:00
Brian Paul 15750d89b9 st/mesa: remove redundant _mesa_is_depth_format() call
The _mesa_is_depth_or_stencil_format() call covers all depth
format cases too.
2011-06-17 13:44:59 -06:00
Brian Paul 3ea6fdfdf1 st/mesa: remove trailing whitespace in st_format.c 2011-06-17 13:44:59 -06:00
Brian Paul befaab8fa1 st/mesa: move comment for ChooseTextureFormat() to right place 2011-06-17 13:44:59 -06:00
Jeremy Huddleston cb5a5f055b apple: Use apple_cgl_get_dl_handle() rather than opening a new handle
Signed-off-by: Jeremy Huddleston <jeremyhu@apple.com>
2011-06-17 12:20:57 -07:00
José Fonseca d6a0fe19e8 scons: Correct glapi USE_xxx_ASM flags. 2011-06-17 20:13:16 +01:00
Stéphane Marchesin bf69ce37f0 glx: implement drawable refcounting.
The current dri context unbind logic will leak drawables until the process
dies (they will then get released by the GEM code). There are two ways to fix
this: either always call driReleaseDrawables every time we unbind a context
(but that costs us round trips to the X server at getbuffers() time) or
implement proper drawable refcounting. This patch implements the latter.

Signed-off-by: Antoine Labour <piman@chromium.org>
Signed-off-by: Stéphane Marchesin <marcheu@chromium.org>
Reviewed-by: Adam Jackson <ajax@redhat.com>
2011-06-17 11:20:19 -07:00
José Fonseca 4175010749 scons: make embedding orthogonal to the platform
To enable embedding in platforms other than linux.
2011-06-17 14:50:37 +01:00
Brian Paul fc8c4a3a7b mesa: use helper functions to distinguish between user/winsys FBOs
And replace IS_CUBE_FACE() macro w/ inline function.
2011-06-16 07:31:58 -06:00
Brian Paul 37e6ab7b2d mesa: refactor, create _mesa_update_draw_buffers() helper
Move this code out of _mesa_make_current() and put it into a
helper function.
2011-06-16 07:31:58 -06:00
Brian Paul 2960526816 mesa: updated comments in _make_current() 2011-06-16 07:31:58 -06:00
Vadim Girlin 016621ee14 r600: fix SPI inputs setup on r600/r700
Signed-off-by: Vadim Girlin <vadimgirlin@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
2011-06-16 15:23:06 +10:00
Chad Versace 8875dd5871 intel: Fix typo in intel_offset_S8 comments
Signed-off-by: Chad Versace <chad@chad-versace.us>
2011-06-15 15:50:45 -07:00
Chad Versace d105f6684d i965/gen5,6: Fix hang when emitting hiz buffer without stencil buffer
When emitting either a hiz or stencil buffer, the 'separate stencil
enable' and 'hiz enable' bits are set in 3DSTATE_DEPTH_BUFFER. Therefore
we must emit both 3DSTATE_HIER_DEPTH_BUFFER and 3DSTATE_STENCIL_BUFFER.

Even if there is no stencil buffer, 3DSTATE_STENCIL_BUFFER must be
emitted; failure to do so causes a hang on gen5 and a stall on gen6.

This also fixes a silly, obvious segfault that occured when a hiz buffer
xor separate stencil buffer existed.

Fixes the piglit tests below on Gen5 when hiz and separate stencil are
manually enabled:
    fbo-alphatest-nocolor
    fbo-depth-sample-compare
    fbo
    hiz-depth-read-fbo-d24-s0
    hiz-depth-stencil-test-fbo-d24-s0
    hiz-depth-test-fbo-d24-s0
    hiz-stencil-read-fbo-d0-s8
    hiz-stencil-test-fbo-d0-s8
    fbo-missing-attachment-clear
    fbo-clear-formats
    fbo-depth-*

Changes piglit test result from crash to fail:
    hiz-depth-stencil-test-fbo-d0-s8

Signed-off-by: Chad Versace <chad@chad-versace.us>
2011-06-15 15:47:59 -07:00