Re: [Mesa-dev] GL 3.0 glDrawPixels(integer format)

2011-11-28 Thread Dave Airlie
While looking into MapRenderbuffer for glDrawPixels, I ended up looking at integer again.  It looks like GL 3.0 has added sanity to drawpixels for integer, which is to say that they've disallowed it. Well I suppose the usual plan, test on binary drivers, though I expect it works on nvidia,

Re: [Mesa-dev] [PATCH] mesa: move ElementArrayBufferObj to gl_array_object

2011-11-28 Thread Yuanhan Liu
On Sat, Nov 26, 2011 at 09:01:51AM -0700, Brian Paul wrote: On 11/23/2011 06:15 PM, Yuanhan Liu wrote: On Wed, Nov 23, 2011 at 08:25:59AM -0700, Brian Paul wrote: On 11/23/2011 02:26 AM, Yuanhan Liu wrote: According opengl spec 4.2.pdf table 6.12 (Vertex Array Object State) at page 515, the

Re: [Mesa-dev] [PATCH 1/3] mesa/formats: add mesa MESA_FORMAT_ARGB2101010_UINT description.

2011-11-28 Thread Dave Airlie
On Sun, Nov 27, 2011 at 10:42 PM, Eric Anholt e...@anholt.net wrote: On Sun, 27 Nov 2011 19:27:15 +, Dave Airlie airl...@gmail.com wrote: From: Dave Airlie airl...@redhat.com This format is used in the ARB_texture_rgb10_a2ui spec. Signed-off-by: Dave Airlie airl...@redhat.com ---  

Re: [Mesa-dev] [PATCH 1/3] mesa/formats: add mesa MESA_FORMAT_ARGB2101010_UINT description.

2011-11-28 Thread Brian Paul
On 11/28/2011 02:24 AM, Dave Airlie wrote: On Sun, Nov 27, 2011 at 10:42 PM, Eric Anholte...@anholt.net wrote: On Sun, 27 Nov 2011 19:27:15 +, Dave Airlieairl...@gmail.com wrote: From: Dave Airlieairl...@redhat.com This format is used in the ARB_texture_rgb10_a2ui spec. Signed-off-by:

Re: [Mesa-dev] [PATCH] mesa: move ElementArrayBufferObj to gl_array_object

2011-11-28 Thread Brian Paul
On 11/28/2011 01:50 AM, Yuanhan Liu wrote: On Sat, Nov 26, 2011 at 09:01:51AM -0700, Brian Paul wrote: On 11/23/2011 06:15 PM, Yuanhan Liu wrote: On Wed, Nov 23, 2011 at 08:25:59AM -0700, Brian Paul wrote: On 11/23/2011 02:26 AM, Yuanhan Liu wrote: According opengl spec 4.2.pdf table 6.12

Re: [Mesa-dev] [PATCH] gl-3.0/api/drawpixels-integer: New test for GL 3.0 integer glDrawPixels.

2011-11-28 Thread Brian Paul
On 11/27/2011 07:08 PM, Eric Anholt wrote: When the extension was folded in, glDrawPixels of integer formats was disallowed. Disable the GL_EXT_texture_integer if 3.0 is exposed, and replace it with a simple make sure it throws the error API test. I think actually the intent was that this is a

Re: [Mesa-dev] [PATCH] mesa: Reject glDrawPixels(integer format) on GL 3.0 or greater.

2011-11-28 Thread Brian Paul
On 11/27/2011 07:08 PM, Eric Anholt wrote: When folding GL_EXT_texture_integer into the core, a new (and very sensible) restriction was added. --- src/mesa/main/drawpix.c | 13 + 1 files changed, 13 insertions(+), 0 deletions(-) Reviewed-by: Brian Paul bri...@vmware.com

Re: [Mesa-dev] [PATCH 5/7] mesa: Fix the datatype of GL_DEPTH32F_STENCIL8's depth channel.

2011-11-28 Thread Brian Paul
On 11/27/2011 03:48 PM, Eric Anholt wrote: On Wed, 23 Nov 2011 13:52:07 -0700, Brian Paulbri...@vmware.com wrote: On 11/23/2011 01:37 PM, Eric Anholt wrote: Asking for the datatype of MESA_FORMAT_Z32_FLOAT_X24S8 is a bit funny -- there's a float depth channel, and a stencil channel that

Re: [Mesa-dev] [PATCH] Allow glTexImage2D with a depth component cube map

2011-11-28 Thread Brian Paul
On 11/26/2011 08:13 PM, Anuj Phogat wrote: Hi Brian, This is an updated patch to allow glTexImage2D with a depth component cube map. Patch was producing an expected ouput with depth-cube-map test (posted on piglit mailing list). But i'm getting an incorrect output since i updated my mesa

[Mesa-dev] [PATCH 2/2] mesa: access pixels as GLushort in unpack_SL8()

2011-11-28 Thread Brian Paul
Per the format comments and the texstore code, use a GLushort to access the pixel. The code was OK as-is on little endian machines. --- src/mesa/main/format_unpack.c |6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/mesa/main/format_unpack.c

[Mesa-dev] [PATCH 2/3] i965: Don't depth test the fake depthbuffer when one isn't present.

2011-11-28 Thread Eric Anholt
For the non-separate-stencil-only case, we've been using a NULL surface for depth, so we didn't have to care. However, to support separate stencil with no depthbuffer, we have to make the depth surface non-NULL or the stencil test always fails thanks to separate stencil inheriting the surface

[Mesa-dev] [PATCH 1/3] i965: Don't double the depth width for separate-stencil-only rendering.

2011-11-28 Thread Eric Anholt
This looks to have been confused with pitch setup, which does have to be doubled. The width is inherited by separate stencil, and it should naturally look like the setup in the block below involving a valid depthbuffer. --- src/mesa/drivers/dri/i965/brw_misc_state.c |2 +- 1 files changed, 1

[Mesa-dev] [PATCH 3/3] i965: Don't perform the precompile on fragment shaders by default.

2011-11-28 Thread Eric Anholt
It is useful to have this option for shader-db, and it was also good at the time where we were rejecting shaders due to various internal limits we hadn't supported yet. However, at this point the precompile step takes extra time (since not all NOS is known at link time) and spews misleading debug

Re: [Mesa-dev] [PATCH 1/2] mesa: fix comments for RG formats

2011-11-28 Thread Eric Anholt
On Mon, 28 Nov 2011 11:14:17 -0700, Brian Paul bri...@vmware.com wrote: The position of the red and green bits was misstated in the comments. Arguably, the names of these formats should be changed to GR to reflect the component ordering and to be consistent with other formats. Actually, could

[Mesa-dev] [PATCH] swrast: Fix some static analysis warnings

2011-11-28 Thread Chad Versace
To each switch statement in s_texfilter.c, add a break statement to the default case. Eliminates the Eclipse static analysis warning: No break at the end of this case. Signed-off-by: Chad Versace chad.vers...@linux.intel.com --- src/mesa/swrast/s_texfilter.c |9 + 1 files changed, 9

[Mesa-dev] [Bug 43316] New: swrast/s_texfetch.c:1274: _mesa_get_texel_fetch_func: Assertion `texfetch_funcs[fmt].Name == fmt' failed.

2011-11-28 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=43316 Bug #: 43316 Summary: swrast/s_texfetch.c:1274: _mesa_get_texel_fetch_func: Assertion `texfetch_funcs[fmt].Name == fmt' failed. Classification: Unclassified Product: Mesa

Re: [Mesa-dev] [PATCH 1/7] i965: Base HW depth format setup based on MESA_FORMAT, not bpp.

2011-11-28 Thread Chad Versace
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 11/23/2011 12:37 PM, Eric Anholt wrote: This will make handling new formats (like actually exposing Z32F) easier and more reliable. --- src/mesa/drivers/dri/i965/brw_misc_state.c | 53 +--

Re: [Mesa-dev] XCB-only GLX protocol?

2011-11-28 Thread Adam Jackson
On 11/27/11 9:13 PM, Ian Romanick wrote: I'm starting to work on GLX_ARB_create_context. This extension and the layered GLX_ARB_create_context_profile extension add some GLX protocol. Is there any reason to keep supporting non-XCB protocol? Are there any platforms that can't / don't use XCB for

Re: [Mesa-dev] reworking pipe_video_decoder / pipe_video_buffer

2011-11-28 Thread Andy Furniss
Maarten Lankhorst wrote: For some reason mplayer handles all the above images as progressive with vdpau, and it sets picture_structure to 3. I can see the interlacing on movement, but it doesn't seem like mplayer tells vdpau it is interlaced, sigh. :/ That's a shame. Is there another way

[Mesa-dev] [Bug 43316] swrast/s_texfetch.c:1274: _mesa_get_texel_fetch_func: Assertion `texfetch_funcs[fmt].Name == fmt' failed.

2011-11-28 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=43316 --- Comment #3 from Vinson Lee v...@vmware.com 2011-11-28 13:26:14 PST --- (In reply to comment #2) Created attachment 53914 [details] [review] patch to add missing table entry This should do it, Vinson. Can you test? Patch 53914 fixes

[Mesa-dev] [PATCH] gallium/i965g: hide that utterly broken driver better

2011-11-28 Thread Daniel Vetter
And warn loudly in case people want to use it. Too many tester report gpu hangs on irc and we rootcause this ... Signed-Off-by: Daniel Vetter daniel.vet...@ffwll.ch --- configure.ac |9 - 1 files changed, 8 insertions(+), 1 deletions(-) diff --git a/configure.ac b/configure.ac index

Re: [Mesa-dev] [PATCH] gallium/i965g: hide that utterly broken driver better

2011-11-28 Thread Patrick Baggett
On Mon, Nov 28, 2011 at 3:32 PM, Daniel Vetter daniel.vet...@ffwll.chwrote: And warn loudly in case people want to use it. Too many tester report gpu hangs on irc and we rootcause this ... Signed-Off-by: Daniel Vetter daniel.vet...@ffwll.ch --- configure.ac |9 - 1 files

Re: [Mesa-dev] [PATCH] gallium/i965g: hide that utterly broken driver better

2011-11-28 Thread Chad Versace
On 11/28/2011 01:32 PM, Daniel Vetter wrote: And warn loudly in case people want to use it. Too many tester report gpu hangs on irc and we rootcause this ... Signed-Off-by: Daniel Vetter daniel.vet...@ffwll.ch Yes! This eliminate some future bug reports too. Reviewed-by: Chad Versace

Re: [Mesa-dev] [PATCH] swrast: Fix some static analysis warnings

2011-11-28 Thread Brian Paul
On 11/28/2011 12:47 PM, Chad Versace wrote: To each switch statement in s_texfilter.c, add a break statement to the default case. Eliminates the Eclipse static analysis warning: No break at the end of this case. Signed-off-by: Chad Versacechad.vers...@linux.intel.com That's pretty picky, but

[Mesa-dev] [Bug 43317] New: swrast: glean basic sanity fails

2011-11-28 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=43317 Bug #: 43317 Summary: swrast: glean basic sanity fails Classification: Unclassified Product: Mesa Version: unspecified Platform: Other OS/Version: All Status: NEW

Re: [Mesa-dev] [PATCH 1/2] mesa: fix comments for RG formats

2011-11-28 Thread Brian Paul
On 11/28/2011 12:24 PM, Eric Anholt wrote: On Mon, 28 Nov 2011 11:14:17 -0700, Brian Paulbri...@vmware.com wrote: The position of the red and green bits was misstated in the comments. Arguably, the names of these formats should be changed to GR to reflect the component ordering and to be

Re: [Mesa-dev] [PATCH 4/7] i965: Add support for Z16 depth formats.

2011-11-28 Thread Chad Versace
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 11/23/2011 12:37 PM, Eric Anholt wrote: This is required by GL 3.0's Required Texture Formats section. All the other code for this format in hardware was already in place. --- src/mesa/drivers/dri/i965/brw_vtbl.c |3 ++-

[Mesa-dev] [Bug 43316] swrast/s_texfetch.c:1274: _mesa_get_texel_fetch_func: Assertion `texfetch_funcs[fmt].Name == fmt' failed.

2011-11-28 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=43316 Brian Paul bri...@vmware.com changed: What|Removed |Added Status|NEW |RESOLVED

Re: [Mesa-dev] [PATCH 6/7] i965: Add support for MESA_FORMAT_Z32_FLOAT and expose it under 3.0 override.

2011-11-28 Thread Chad Versace
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 11/23/2011 12:37 PM, Eric Anholt wrote: The MESA_FORMAT_Z32_FLOAT_X24S8 support will come later, and involves a bunch of trickery with hiz. Also, Z32_FLOAT will fail for swrast paths until they change to MapRenderbuffer. ---

Re: [Mesa-dev] [PATCH] gallium/i965g: hide that utterly broken driver better

2011-11-28 Thread Jose Fonseca
- Original Message - And warn loudly in case people want to use it. Too many tester report gpu hangs on irc and we rootcause this ... Signed-Off-by: Daniel Vetter daniel.vet...@ffwll.ch If you're doing this then why not just remove the drive all together, as agreed a few days ago?

Re: [Mesa-dev] [PATCH 1/3] i965: Don't double the depth width for separate-stencil-only rendering.

2011-11-28 Thread Chad Versace
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 The code that this patch fixes is indeed correct, but not for the reason you believe. On 11/28/2011 10:48 AM, Eric Anholt wrote: This looks to have been confused with pitch setup, which does have to be doubled. It was intentional. The width is

Re: [Mesa-dev] [PATCH 2/3] i965: Don't depth test the fake depthbuffer when one isn't present.

2011-11-28 Thread Chad Versace
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 11/28/2011 10:48 AM, Eric Anholt wrote: For the non-separate-stencil-only case, we've been using a NULL surface for depth, so we didn't have to care. However, to support separate stencil with no depthbuffer, we have to make the depth surface

Re: [Mesa-dev] reworking pipe_video_decoder / pipe_video_buffer

2011-11-28 Thread Andy Furniss
Maarten Lankhorst wrote: Sadly mplayer tells vdpau to have all videos decoded as progressive so I can't really do anything. :-( I just had a look at an old copy of h.262 spec I have. Unless I am misreading it seems that picture_structure = 3 (frame) is perfectly valid for interlaced. It

[Mesa-dev] [Bug 43316] swrast/s_texfetch.c:1274: _mesa_get_texel_fetch_func: Assertion `texfetch_funcs[fmt].Name == fmt' failed.

2011-11-28 Thread bugzilla-daemon
https://bugs.freedesktop.org/show_bug.cgi?id=43316 Vinson Lee v...@vmware.com changed: What|Removed |Added Status|RESOLVED|CLOSED --- Comment #5 from

Re: [Mesa-dev] [PATCH] gallium/i965g: hide that utterly broken driver better

2011-11-28 Thread Daniel Vetter
On Mon, Nov 28, 2011 at 03:17:09PM -0800, Jose Fonseca wrote: - Original Message - And warn loudly in case people want to use it. Too many tester report gpu hangs on irc and we rootcause this ... Signed-Off-by: Daniel Vetter daniel.vet...@ffwll.ch If you're doing this then why

[Mesa-dev] [PATCH 1/5] mesa: add STATIC_ASSERT() macro for compile-time assertions

2011-11-28 Thread Brian Paul
This can be used to check that tables have the right number of entries, etc. at compile-time. This will hopefully catch things that are missed if particular drivers aren't tested, for example. --- src/mesa/main/compiler.h | 11 +++ 1 files changed, 11 insertions(+), 0 deletions(-)

[Mesa-dev] [PATCH 2/5] swrast: use STATIC_ASSERT to make sure texfetch table isn't missing entries

2011-11-28 Thread Brian Paul
When new MESA_FORMAT_x enums are added we need to add a new entry in the table of texture fetch functions. In the past this has been missed if swrast isn't actually tested. Using a static assertion should help with that. --- src/mesa/swrast/s_texfetch.c |3 ++- 1 files changed, 2

Re: [Mesa-dev] [PATCH 1/3] glapi: s/INLINE/inline/ for dispatch.h file

2011-11-28 Thread Brian Paul
Patch 2 in this series is the regenerated dispatch.h file. The patch/email is 723KB so I'm omitting it. -Brian On 11/28/2011 06:16 PM, Brian Paul wrote: --- src/mapi/glapi/gen/gl_table.py |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git

Re: [Mesa-dev] [PATCH 1/2] mesa: fix comments for RG formats

2011-11-28 Thread Eric Anholt
On Mon, 28 Nov 2011 15:16:58 -0700, Brian Paul bri...@vmware.com wrote: On 11/28/2011 12:24 PM, Eric Anholt wrote: On Mon, 28 Nov 2011 11:14:17 -0700, Brian Paulbri...@vmware.com wrote: The position of the red and green bits was misstated in the comments. Arguably, the names of these

Re: [Mesa-dev] [PATCH 1/5] mesa: add STATIC_ASSERT() macro for compile-time assertions

2011-11-28 Thread Eric Anholt
On Mon, 28 Nov 2011 18:15:27 -0700, Brian Paul bri...@vmware.com wrote: This can be used to check that tables have the right number of entries, etc. at compile-time. This will hopefully catch things that are missed if particular drivers aren't tested, for example. I've always wanted to go dig

Re: [Mesa-dev] [PATCH 1/3] i965: Don't double the depth width for separate-stencil-only rendering.

2011-11-28 Thread Eric Anholt
On Mon, 28 Nov 2011 15:46:38 -0800, Chad Versace chad.vers...@linux.intel.com wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 The code that this patch fixes is indeed correct, but not for the reason you believe. On 11/28/2011 10:48 AM, Eric Anholt wrote: This looks to have been

Re: [Mesa-dev] XCB-only GLX protocol?

2011-11-28 Thread Eric Anholt
On Sun, 27 Nov 2011 18:13:45 -0800, Ian Romanick i...@freedesktop.org wrote: All, I'm starting to work on GLX_ARB_create_context. This extension and the layered GLX_ARB_create_context_profile extension add some GLX protocol. Is there any reason to keep supporting non-XCB protocol? Are

Re: [Mesa-dev] XCB-only GLX protocol?

2011-11-28 Thread Jakob Bornecrantz
On Mon, Nov 28, 2011 at 3:13 AM, Ian Romanick i...@freedesktop.org wrote: All, I'm starting to work on GLX_ARB_create_context.  This extension and the layered GLX_ARB_create_context_profile extension add some GLX protocol.  Is there any reason to keep supporting non-XCB protocol?  Are there

Re: [Mesa-dev] XCB-only GLX protocol?

2011-11-28 Thread Alan Coopersmith
On 11/28/11 18:56, Jakob Bornecrantz wrote: On Mon, Nov 28, 2011 at 3:13 AM, Ian Romanicki...@freedesktop.org wrote: All, I'm starting to work on GLX_ARB_create_context. This extension and the layered GLX_ARB_create_context_profile extension add some GLX protocol. Is there any reason to

Re: [Mesa-dev] [PATCH 1/5] mesa: add STATIC_ASSERT() macro for compile-time assertions

2011-11-28 Thread Brian Paul
On Mon, Nov 28, 2011 at 7:06 PM, Eric Anholt e...@anholt.net wrote: On Mon, 28 Nov 2011 18:15:27 -0700, Brian Paul bri...@vmware.com wrote: This can be used to check that tables have the right number of entries, etc. at compile-time.  This will hopefully catch things that are missed if

[Mesa-dev] [PATCH] mesa: add STATIC_ASSERT() macro for compile-time assertions

2011-11-28 Thread Brian Paul
This can be used to check that tables have the right number of entries, etc. at compile-time. This will hopefully catch things that are missed if particular drivers aren't tested, for example. v2: Simplify the macro to omit the extra line number info (the compiler already indicates the line

[Mesa-dev] [PATCH] i965: Make gen6_resolve_implied_move a no-op for MRF sources.

2011-11-28 Thread Kenneth Graunke
Attempting to move an MRF to a MRF is not only pointless, it will fail because MRFs are read-only, resulting in garbage in your register. If we already set up a MRF source, there's nothing to resolve anyway. Signed-off-by: Kenneth Graunke kenn...@whitecape.org ---

Re: [Mesa-dev] XCB-only GLX protocol?

2011-11-28 Thread Jeremy Huddleston
On Nov 28, 2011, at 6:56 PM, Jakob Bornecrantz wrote: On Mon, Nov 28, 2011 at 3:13 AM, Ian Romanick i...@freedesktop.org wrote: All, I'm starting to work on GLX_ARB_create_context. This extension and the layered GLX_ARB_create_context_profile extension add some GLX protocol. Is there

Re: [Mesa-dev] [PATCH 6/6] mesa: Use VERT_ATTRIB_* indexed array in gl_array_object.

2011-11-28 Thread Mathias Fröhlich
Hi, On Sunday, November 27, 2011 22:52:29 Eric Anholt wrote: Not an issue for this patch, but I noticed that there's this _mesa_update_array_object_max_element that does something similar, but doesn't follow this rule and would trash the _MaxElement value. Some day, the body of this