[Mesa-dev] [PATCH V2 02/22] mesa: add stubs for new entrypoints for ARB_texture_multisample

2013-02-04 Thread Chris Forbes
V2: - Remove spurious duplicate prototypes in teximage.h Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/main/multisample.c | 15 +++ src/mesa/main/multisample.h | 5 + src/mesa/main/teximage.c| 20 src/mesa/main/teximage.h| 10

[Mesa-dev] [PATCH V2 00/22] Add ARB_texture_multisample support

2013-02-04 Thread Chris Forbes
This series adds the core mesa bits and i965 driver support for ARB_texture_multisample. Big changes from V1: - Generally cleaner - GLSL texelFetch() with a multisample sampler is converted to a new ir_txf_ms opcode in the GLSL IR, which makes the driver side a lot tidier. -

[Mesa-dev] [PATCH V2 01/22] glapi: add ARB_texture_multisample

2013-02-04 Thread Chris Forbes
V2: - Drop placeholder - Align enum values - Remove explicit exec=mesa; it *is* the dispatch flavor we want, but it's also the default. I misunderstood how this worked before; after actually reading the generator it makes good sense. Signed-off-by: Chris Forbes chr

[Mesa-dev] [PATCH V2 03/22] dispatch_sanity: enable checks for ARB_texture_multisample

2013-02-04 Thread Chris Forbes
V2: - reorder after introducing stubs Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/main/tests/dispatch_sanity.cpp | 8 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/mesa/main/tests/dispatch_sanity.cpp b/src/mesa/main/tests/dispatch_sanity.cpp index

[Mesa-dev] [PATCH V2 04/22] mesa: add texobj support for ARB_texture_multisample

2013-02-04 Thread Chris Forbes
in a newer extension. Fixed weird indentation. - Allow multisample array textures in glFramebufferTextureLayer. This was overlooked as the tests originally only used 2d multisample textures. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/main/fbobject.c

[Mesa-dev] [PATCH V2 05/22] tests: add ARB_texture_multisample enums to table

2013-02-04 Thread Chris Forbes
Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/main/tests/enum_strings.cpp | 21 + 1 file changed, 21 insertions(+) diff --git a/src/mesa/main/tests/enum_strings.cpp b/src/mesa/main/tests/enum_strings.cpp index 5d70007..1dae60f 100644 --- a/src/mesa/main/tests

[Mesa-dev] [PATCH V2 06/22] glsl: add support for ARB_texture_multisample

2013-02-04 Thread Chris Forbes
V2: - emit `sample` parameter properly for multisample texelFetch() V3: - fix spurious whitespace change - introduce a new opcode ir_txf_ms rather than overloading the existing ir_txf further. This makes doing the right thing in the driver somewhat simpler. Signed-off-by: Chris

[Mesa-dev] [PATCH V2 09/22] mesa: implement GetMultisamplefv

2013-02-04 Thread Chris Forbes
for winsys FBOs, at Paul's suggestion Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/drivers/common/driverfuncs.c | 3 +++ src/mesa/main/dd.h| 8 src/mesa/main/multisample.c | 25 +++-- 3 files changed, 34 insertions(+), 2

[Mesa-dev] [PATCH V2 08/22] i965: expose new max sample counts

2013-02-04 Thread Chris Forbes
V2: For now, only expose a depth sample count of 1, since there are unresolved interactions with W-tiling for stencil textures and possibly also HiZ for depth textures. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/drivers/dri/i965/brw_context.c | 12 ++-- 1 file changed, 10

[Mesa-dev] [PATCH V2 10/22] mesa: implement sample mask

2013-02-04 Thread Chris Forbes
V2: - fix multiline comment style - stop using ASSERT_OUTSIDE_BEGIN_END_AND_FLUSH since that doesn't exist anymore. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/main/enable.c | 15 +++ src/mesa/main/get.c | 9 + src/mesa/main

[Mesa-dev] [PATCH V2 11/22] i965: add support for sample mask on Gen6+

2013-02-04 Thread Chris Forbes
Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/drivers/dri/i965/brw_context.h| 2 +- src/mesa/drivers/dri/i965/gen6_blorp.cpp | 2 +- src/mesa/drivers/dri/i965/gen6_multisample_state.c | 19 +-- src/mesa/drivers/dri/i965/gen7_blorp.cpp

[Mesa-dev] [PATCH V2 12/22] i965: expose sample positions

2013-02-04 Thread Chris Forbes
Moves the definition of the sample positions out of gen6_emit_3dstate_multisample, and unpacks them in gen6_get_sample_position. V2: Be consistent about `sample position` rather than `location`. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/drivers/dri/i965/brw_context.c

[Mesa-dev] [PATCH V2 13/22] mesa: support multisample textures in framebuffer completeness check

2013-02-04 Thread Chris Forbes
, debug message, fix for state moving from texobj to image. - stencil texturing tweaks tidied up and folded in here. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/main/fbobject.c | 50 1 file changed, 38 insertions(+), 12 deletions

[Mesa-dev] [PATCH V2 14/22] mesa: adjust texture completeness for multisample

2013-02-04 Thread Chris Forbes
like GL_TEXTURE_BUFFER. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/main/texobj.h | 8 +++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/src/mesa/main/texobj.h b/src/mesa/main/texobj.h index f86b4eb..f8a935b 100644 --- a/src/mesa/main/texobj.h +++ b/src/mesa/main

[Mesa-dev] [PATCH V2 15/22] mesa: implement TexImage*Multisample

2013-02-04 Thread Chris Forbes
V2: - fix formatting issues - generate GL_OUT_OF_MEMORY if teximage cannot be allocated - fix for state moving from texobj to image Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/main/teximage.c | 153 +-- 1 file changed, 149

[Mesa-dev] [PATCH V2 16/22] i965: add support for multisample textures

2013-02-04 Thread Chris Forbes
-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/drivers/dri/i965/brw_tex_layout.c | 1 + src/mesa/drivers/dri/i965/brw_wm_surface_state.c | 2 ++ src/mesa/drivers/dri/intel/intel_fbo.c | 24 +--- src/mesa/drivers/dri/intel/intel_mipmap_tree.c | 24

[Mesa-dev] [PATCH V2 17/22] i965: Support multisampling in surface_state for textures

2013-02-04 Thread Chris Forbes
- set GEN7_SURFACE_ARYSPC_LOD0 if it's set in the miptree. V2: - Clarify commit message - Rebased onto Paul's physical/logical dims cleanup - Added Gen7 support Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/drivers/dri/i965/brw_wm_surface_state.c | 2 +- src/mesa

[Mesa-dev] [PATCH V2 18/22] i965: take the target into account for Gen7 MSAA modes

2013-02-04 Thread Chris Forbes
-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/drivers/dri/intel/intel_mipmap_tree.c | 15 --- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/src/mesa/drivers/dri/intel/intel_mipmap_tree.c b/src/mesa/drivers/dri/intel/intel_mipmap_tree.c index e68285c..be13c07 100644

[Mesa-dev] [PATCH V2 19/22] i965: add a new virtual opcode: SHADER_OPCODE_TXF_MS

2013-02-04 Thread Chris Forbes
This is very similar to the TXF opcode, but lowers to `ld2dms` rather than `ld` on Gen7. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/drivers/dri/i965/brw_defines.h | 1 + src/mesa/drivers/dri/i965/brw_fs.cpp| 1 + src/mesa/drivers/dri/i965/brw_fs_emit.cpp | 7

[Mesa-dev] [PATCH V2 20/22] i965/vs: add support for ir_txf_ms on Gen6+

2013-02-04 Thread Chris Forbes
: Reworked completely, added support for Gen7. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp | 19 +-- 1 file changed, 17 insertions(+), 2 deletions(-) diff --git a/src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp b/src/mesa/drivers

[Mesa-dev] [PATCH V2 21/22] i965/fs: add support for ir_txf_ms on Gen6+

2013-02-04 Thread Chris Forbes
layout, we can emit a slightly shorter message here in the UMS case. V2: Reworked completely, added support for Gen7. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/drivers/dri/i965/brw_fs_visitor.cpp | 44 1 file changed, 38 insertions(+), 6 deletions

[Mesa-dev] [PATCH V2 22/22] i965: enable ARB_texture_multisample on Gen6+

2013-02-05 Thread Chris Forbes
V2: Works on Ivy Bridge now too, so this can be 6+. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/drivers/dri/intel/intel_extensions.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/mesa/drivers/dri/intel/intel_extensions.c b/src/mesa/drivers/dri/intel/intel_extensions.c

Re: [Mesa-dev] [PATCH V2 13/22] mesa: support multisample textures in framebuffer completeness check

2013-02-05 Thread Chris Forbes
I've re-read the spec and am pretty certain now that allowing STENCIL_INDEX is bogus. I had got confused about what was actually required where the extension spec says: internalformat must be color-renderable, depth-renderable, or stencil- renderable (as defined in section 4.4.4). --

Re: [Mesa-dev] [PATCH V2 14/22] mesa: adjust texture completeness for multisample

2013-02-05 Thread Chris Forbes
Yes, that's much more sensible, thanks. -- Chris On Wed, Feb 6, 2013 at 12:00 PM, Eric Anholt e...@anholt.net wrote: Chris Forbes chr...@ijw.co.nz writes: GL_TEXTURE_2D_MULTISAMPLE and GL_TEXTURE_2D_MULTISAMPLE_ARRAY targets don't allow filtering state to be set, but the default state fails

[Mesa-dev] [PATCH V3 00/19] ARB_texture_multisample support

2013-02-08 Thread Chris Forbes
This series adds the core mesa bits for ARB_texture_multisample, and support in the i965 driver on Gen6 and Gen7. I've tidied up all the things that were commented on in V2. Big changes: - First three patches were squashed together. The result adds the glapi bits, the dispatch_sanity

[Mesa-dev] [PATCH V3 01/19] glapi: add ARB_texture_multisample

2013-02-08 Thread Chris Forbes
the generator it makes good sense. V3: - Squash in stubs for new entrypoints, and dispatch_sanity tweaks, so we don't get build breakage between those patches. Signed-off-by: Chris Forbes chr...@ijw.co.nz [1/3 V2] Reviewed-by: Matt Turner matts...@gmail.com [V3] Reviewed-by: Eric Anholt e

[Mesa-dev] [PATCH V3 02/19] mesa: add texobj support for ARB_texture_multisample

2013-02-08 Thread Chris Forbes
actually be changed by the user, so it's more sensible to initialize it correctly than to hack around it being bogus later. Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Paul Berry stereotype...@gmail.com --- src/mesa/main/fbobject.c | 11 - src/mesa/main/get.c

[Mesa-dev] [PATCH V3 03/19] tests: add ARB_texture_multisample enums to table

2013-02-08 Thread Chris Forbes
Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Eric Anholt e...@anholt.net Reviewed-by: Paul Berry stereotype...@gmail.com --- src/mesa/main/tests/enum_strings.cpp | 21 + 1 file changed, 21 insertions(+) diff --git a/src/mesa/main/tests/enum_strings.cpp b/src

[Mesa-dev] [PATCH V3 04/19] glsl: add support for ARB_texture_multisample

2013-02-08 Thread Chris Forbes
whitespace Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Eric Anholt e...@anholt.net Reviewed-by: Paul Berry stereotype...@gmail.com --- src/glsl/builtin_types.h | 19 + .../builtins/profiles/ARB_texture_multisample.glsl | 18 src/glsl

[Mesa-dev] [PATCH V3 05/19] mesa: add new max sample count state

2013-02-08 Thread Chris Forbes
- GL_MAX_COLOR_TEXTURE_SAMPLES - GL_MAX_DEPTH_TEXTURE_SAMPLES - GL_MAX_INTEGER_SAMPLES V2: initialize limits to 1 in _mesa_init_constants as suggested by Brian and Paul Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Paul Berry stereotype...@gmail.com --- src/mesa/main/context.c

[Mesa-dev] [PATCH V3 06/19] i965: expose new max sample counts

2013-02-08 Thread Chris Forbes
V2: For now, only expose a depth sample count of 1, since there are unresolved interactions with W-tiling for stencil textures and possibly also HiZ for depth textures. Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Paul Berry stereotype...@gmail.com --- src/mesa/drivers/dri/i965

[Mesa-dev] [PATCH V3 07/19] mesa: implement GetMultisamplefv

2013-02-08 Thread Chris Forbes
for winsys FBOs, at Paul's suggestion Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Paul Berry stereotype...@gmail.com --- src/mesa/drivers/common/driverfuncs.c | 3 +++ src/mesa/main/dd.h| 8 src/mesa/main/multisample.c | 25

[Mesa-dev] [PATCH V3 08/19] mesa: implement sample mask

2013-02-08 Thread Chris Forbes
V2: - fix multiline comment style - stop using ASSERT_OUTSIDE_BEGIN_END_AND_FLUSH since that doesn't exist anymore. V3: - check for the extension being enabled - tidier flagging of _NEW_MULTISAMPLE - fix weird indentation in get.c Signed-off-by: Chris Forbes chr...@ijw.co.nz

[Mesa-dev] [PATCH V3 09/19] i965: add support for sample mask on Gen6+

2013-02-08 Thread Chris Forbes
Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Eric Anholt e...@anholt.net Reviewed-by: Paul Berry stereotype...@gmail.com --- src/mesa/drivers/dri/i965/brw_context.h| 2 +- src/mesa/drivers/dri/i965/gen6_blorp.cpp | 2 +- src/mesa/drivers/dri/i965

[Mesa-dev] [PATCH V3 10/19] i965: expose sample positions

2013-02-08 Thread Chris Forbes
Moves the definition of the sample positions out of gen6_emit_3dstate_multisample, and unpacks them in gen6_get_sample_position. V2: Be consistent about `sample position` rather than `location`. Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Paul Berry stereotype...@gmail.com --- src

[Mesa-dev] [PATCH V3 11/19] mesa: support multisample textures in framebuffer completeness check

2013-02-08 Thread Chris Forbes
-specific blocks, as suggested by Eric Signed-off-by: Chris Forbes chr...@ijw.co.nz [V2] Reviewed-by: Paul Berry stereotype...@gmail.com --- src/mesa/main/fbobject.c | 60 ++-- 1 file changed, 43 insertions(+), 17 deletions(-) diff --git a/src/mesa/main

[Mesa-dev] [PATCH V3 12/19] mesa: implement TexImage*Multisample

2013-02-08 Thread Chris Forbes
, to deallocate the texture - dont forget to call _mesa_update_fbo_texture Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/main/teximage.c | 151 +-- 1 file changed, 147 insertions(+), 4 deletions(-) diff --git a/src/mesa/main/teximage.c b/src/mesa

[Mesa-dev] [PATCH V3 13/19] i965: add support for multisample textures

2013-02-08 Thread Chris Forbes
-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Paul Berry stereotype...@gmail.com --- src/mesa/drivers/dri/i965/brw_tex_layout.c | 1 + src/mesa/drivers/dri/i965/brw_wm_surface_state.c | 2 ++ src/mesa/drivers/dri/intel/intel_fbo.c | 24 +--- src/mesa/drivers

[Mesa-dev] [PATCH V3 14/19] i965: Support multisampling in surface_state for textures

2013-02-08 Thread Chris Forbes
- set GEN7_SURFACE_ARYSPC_LOD0 if it's set in the miptree. V2: - Clarify commit message - Rebased onto Paul's physical/logical dims cleanup - Added Gen7 support Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Paul Berry stereotype...@gmail.com --- src/mesa/drivers/dri

[Mesa-dev] [PATCH V3 15/19] i965: take the target into account for Gen7 MSAA modes

2013-02-08 Thread Chris Forbes
be accessed. Software must ensure that the surface is defined to avoid GTT errors. To allow the shader to treat all surfaces uniformly, force UMS if the surface is to be used as a multisample texture, even if CMS would have been possible. V3: - Quoted erratum text Signed-off-by: Chris Forbes

[Mesa-dev] [PATCH V3 16/19] i965: add a new virtual opcode: SHADER_OPCODE_TXF_MS

2013-02-08 Thread Chris Forbes
This is very similar to the TXF opcode, but lowers to `ld2dms` rather than `ld` on Gen7. Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Paul Berry stereotype...@gmail.com --- src/mesa/drivers/dri/i965/brw_defines.h | 1 + src/mesa/drivers/dri/i965/brw_fs.cpp| 1 + src/mesa

[Mesa-dev] [PATCH V3 17/19] i965/vs: add support for ir_txf_ms on Gen6+

2013-02-08 Thread Chris Forbes
: Reworked completely, added support for Gen7. V3: - Use new sample_index, sample_index_type rather than reusing lod - Clarify commit message. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/drivers/dri/i965/brw_vec4_visitor.cpp | 24 1 file changed, 20

[Mesa-dev] [PATCH V3 18/19] i965/fs: add support for ir_txf_ms on Gen6+

2013-02-08 Thread Chris Forbes
: - Introduce sample_index parameter rather than reusing lod - Removed spurious whitespace change - Clarify commit message Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/drivers/dri/i965/brw_fs.h | 6 ++-- src/mesa/drivers/dri/i965/brw_fs_fp.cpp | 5 +-- src/mesa/drivers

[Mesa-dev] [PATCH V3 19/19] i965: enable ARB_texture_multisample on Gen6+

2013-02-08 Thread Chris Forbes
V2: Works on Ivy Bridge now too, so this can be 6+. Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Paul Berry stereotype...@gmail.com --- src/mesa/drivers/dri/intel/intel_extensions.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/mesa/drivers/dri/intel/intel_extensions.c b

Re: [Mesa-dev] [PATCH V3 12/19] mesa: implement TexImage*Multisample

2013-02-08 Thread Chris Forbes
Oops -- there's still one TODO in here, for the interaction with ARB_internalformat_query. I'll fix that soon. On Fri, Feb 8, 2013 at 10:19 PM, Chris Forbes chr...@ijw.co.nz wrote: V2: - fix formatting issues - generate GL_OUT_OF_MEMORY if teximage cannot be allocated - fix for state

Re: [Mesa-dev] [PATCH V3 11/19] mesa: support multisample textures in framebuffer completeness check

2013-02-11 Thread Chris Forbes
Yikes, apparently I missed one. Thanks for spotting that. -- Chris On Tue, Feb 12, 2013 at 3:35 PM, Eric Anholt e...@anholt.net wrote: Chris Forbes chr...@ijw.co.nz writes: - sample count must be the same on all attachments - fixedsamplepositions must be the same on all attachments

Re: [Mesa-dev] [PATCH V3 04/19] glsl: add support for ARB_texture_multisample

2013-02-13 Thread Chris Forbes
Ouch. Thanks for catching that -- are there any other similar things I need to be aware of? On Wed, Feb 13, 2013 at 8:19 PM, Kenneth Graunke kenn...@whitecape.org wrote: On 02/08/2013 01:19 AM, Chris Forbes wrote: V2: - emit `sample` parameter properly for multisample texelFetch() - fix

[Mesa-dev] [PATCH 0/3] Revisit sample count limits with internalformat_query

2013-02-17 Thread Chris Forbes
This series implements the interactions between internalformat_query, texture_multisample, and multisample renderbuffer creation. Applies on top of V4 of the texture_multisample series (which I'll send out soon), or V3 with small modifications. 2/3 might be interesting on its own, for the 9.1

[Mesa-dev] [PATCH 1/3] mesa: allow internalformat_query with multisample texture targets

2013-02-17 Thread Chris Forbes
, but the driver may still be able to implement a reasonable resolve operation, so it can be supported for renderbuffers. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/drivers/dri/i965/brw_context.c | 6 -- src/mesa/main/dd.h | 4 +++- src/mesa/main

[Mesa-dev] [PATCH 2/3] mesa: helper for checking renderbuffer sample count

2013-02-17 Thread Chris Forbes
(or GL4.2): If samples is greater than the maximum number of samples supported for internalformat then the error INVALID_OPERATION is generated (see GetInternalformativ in section 6.X). Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/main/fbobject.c | 43

[Mesa-dev] [PATCH 3/3] mesa: use _mesa_check_sample_count() for multisample textures

2013-02-17 Thread Chris Forbes
with a pname of SAMPLES (see section 6.X). This resolves the remaining TODO in the implementation of TexImage*DMultisample. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/main/fbobject.c | 11 +++ src/mesa/main/teximage.c | 30 +- 2 files changed, 16

[Mesa-dev] [PATCH V4 00/19] ARB_texture_multisample support

2013-02-26 Thread Chris Forbes
This series adds the core mesa bits for ARB_texture_multisample, and support in the i965 driver for Gen6 and Gen7. I've addressed the issues that were raised for V3, and also fixed some other bugs which I found while beefing up the piglit coverage for this. - Proxy texture targets were denied in

[Mesa-dev] [PATCH V4 01/19] glapi: add ARB_texture_multisample

2013-02-26 Thread Chris Forbes
the generator it makes good sense. V3: - Squash in stubs for new entrypoints, and dispatch_sanity tweaks, so we don't get build breakage between those patches. V4: - Fix various remaining whitespace issues Signed-off-by: Chris Forbes chr...@ijw.co.nz [1/3 V2] Reviewed-by: Matt Turner matts

[Mesa-dev] [PATCH V4 02/19] mesa: add texobj support for ARB_texture_multisample

2013-02-26 Thread Chris Forbes
with correct values. For V4, just do the setup in finish_texture_init(). Signed-off-by: Chris Forbes chr...@ijw.co.nz [V2] Reviewed-by: Paul Berry stereotype...@gmail.com [V4] Reviewed-by: Eric Anholt e...@anholt.net --- src/mesa/main/fbobject.c | 11 -- src/mesa/main/get.c

[Mesa-dev] [PATCH V4 03/19] tests: add ARB_texture_multisample enums to table

2013-02-26 Thread Chris Forbes
Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Eric Anholt e...@anholt.net Reviewed-by: Paul Berry stereotype...@gmail.com --- src/mesa/main/tests/enum_strings.cpp | 21 + 1 file changed, 21 insertions(+) diff --git a/src/mesa/main/tests/enum_strings.cpp b/src

[Mesa-dev] [PATCH V4 04/19] glsl: add support for ARB_texture_multisample

2013-02-26 Thread Chris Forbes
whitespace V4: - don't forget to include the new opcode in tex_opcode_strs[] (thanks Kenneth for spotting this) Signed-off-by: Chris Forbes chr...@ijw.co.nz [V2] Reviewed-by: Eric Anholt e...@anholt.net [V2] Reviewed-by: Paul Berry stereotype...@gmail.com --- src/glsl/builtin_types.h

[Mesa-dev] [PATCH V4 05/19] mesa: add new max sample count state

2013-02-26 Thread Chris Forbes
- GL_MAX_COLOR_TEXTURE_SAMPLES - GL_MAX_DEPTH_TEXTURE_SAMPLES - GL_MAX_INTEGER_SAMPLES V2: initialize limits to 1 in _mesa_init_constants as suggested by Brian and Paul Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Paul Berry stereotype...@gmail.com Reviewed-by: Eric Anholt e

[Mesa-dev] [PATCH V4 06/19] i965: expose new max sample counts

2013-02-26 Thread Chris Forbes
V2: For now, only expose a depth sample count of 1, since there are unresolved interactions with W-tiling for stencil textures and possibly also HiZ for depth textures. Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Paul Berry stereotype...@gmail.com Reviewed-by: Eric Anholt e

[Mesa-dev] [PATCH V4 07/19] mesa: implement GetMultisamplefv

2013-02-26 Thread Chris Forbes
for winsys FBOs, at Paul's suggestion Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Paul Berry stereotype...@gmail.com Reviewed-by: Eric Anholt e...@anholt.net --- src/mesa/drivers/common/driverfuncs.c | 3 +++ src/mesa/main/dd.h| 8 src/mesa/main

[Mesa-dev] [PATCH V4 08/19] mesa: implement sample mask

2013-02-26 Thread Chris Forbes
-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Eric Anholt e...@anholt.net --- src/mesa/main/enable.c | 18 ++ src/mesa/main/get.c | 9 + src/mesa/main/get_hash_params.py | 2 ++ src/mesa/main/mtypes.h | 6 ++ src/mesa/main

[Mesa-dev] [PATCH V4 09/19] i965: add support for sample mask on Gen6+

2013-02-26 Thread Chris Forbes
Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Eric Anholt e...@anholt.net Reviewed-by: Paul Berry stereotype...@gmail.com --- src/mesa/drivers/dri/i965/brw_context.h| 2 +- src/mesa/drivers/dri/i965/gen6_blorp.cpp | 2 +- src/mesa/drivers/dri/i965

[Mesa-dev] [PATCH V4 10/19] i965: expose sample positions

2013-02-26 Thread Chris Forbes
Moves the definition of the sample positions out of gen6_emit_3dstate_multisample, and unpacks them in gen6_get_sample_position. V2: Be consistent about `sample position` rather than `location`. Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Paul Berry stereotype...@gmail.com --- src

[Mesa-dev] [PATCH V4 11/19] mesa: support multisample textures in framebuffer completeness check

2013-02-26 Thread Chris Forbes
-specific blocks, as suggested by Eric V4: - Removed stencil hacks which were missed in V3 (thanks Eric) - Don't move the declaration of texImg; only required pre-V3. Signed-off-by: Chris Forbes chr...@ijw.co.nz [V2] Reviewed-by: Paul Berry stereotype...@gmail.com --- src/mesa/main/fbobject.c

[Mesa-dev] [PATCH V4 12/19] mesa: implement TexImage*Multisample

2013-02-26 Thread Chris Forbes
, to deallocate the texture - dont forget to call _mesa_update_fbo_texture V4: - fix indentation - don't throw errors on proxy texture targets Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/main/teximage.c | 167 +-- 1 file changed, 163

[Mesa-dev] [PATCH V4 13/19] i965: add support for multisample textures

2013-02-26 Thread Chris Forbes
-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Paul Berry stereotype...@gmail.com --- src/mesa/drivers/dri/i965/brw_tex_layout.c | 1 + src/mesa/drivers/dri/i965/brw_wm_surface_state.c | 2 ++ src/mesa/drivers/dri/intel/intel_fbo.c | 24 +--- src/mesa/drivers

[Mesa-dev] [PATCH V4 14/19] i965: Support multisampling in surface_state for textures

2013-02-26 Thread Chris Forbes
- set GEN7_SURFACE_ARYSPC_LOD0 if it's set in the miptree. V2: - Clarify commit message - Rebased onto Paul's physical/logical dims cleanup - Added Gen7 support Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Paul Berry stereotype...@gmail.com --- src/mesa/drivers/dri

[Mesa-dev] [PATCH V4 15/19] i965: take the target into account for Gen7 MSAA modes

2013-02-26 Thread Chris Forbes
be accessed. Software must ensure that the surface is defined to avoid GTT errors. To allow the shader to treat all surfaces uniformly, force UMS if the surface is to be used as a multisample texture, even if CMS would have been possible. V3: - Quoted erratum text Signed-off-by: Chris Forbes

[Mesa-dev] [PATCH V4 16/19] i965: add a new virtual opcode: SHADER_OPCODE_TXF_MS

2013-02-26 Thread Chris Forbes
clobbered, producing bad results. Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Paul Berry stereotype...@gmail.com --- src/mesa/drivers/dri/i965/brw_defines.h | 1 + src/mesa/drivers/dri/i965/brw_fs.cpp| 2 ++ src/mesa/drivers/dri/i965/brw_fs_emit.cpp | 7 +++ src

[Mesa-dev] [PATCH V4 17/19] i965/vs: add support for ir_txf_ms on Gen6+

2013-02-26 Thread Chris Forbes
: Reworked completely, added support for Gen7. V3: - Use new sample_index, sample_index_type rather than reusing lod - Clarify commit message. V4: - Fix comment style Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Eric Anholt e...@anholt.net --- src/mesa/drivers/dri/i965

[Mesa-dev] [PATCH V4 19/19] i965: enable ARB_texture_multisample on Gen6+

2013-02-26 Thread Chris Forbes
V2: Works on Ivy Bridge now too, so this can be 6+. Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Paul Berry stereotype...@gmail.com Reviewed-by: Eric Anholt e...@anholt.net --- src/mesa/drivers/dri/intel/intel_extensions.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/mesa

Re: [Mesa-dev] [PATCH V4 00/19] ARB_texture_multisample support

2013-03-01 Thread Chris Forbes
The minmax regression is addressed by my followup series, which adds the internalformat_query interactions. Do I need to fold that into this one? On Sat, Mar 2, 2013 at 7:59 AM, Paul Berry stereotype...@gmail.com wrote: On 26 February 2013 02:10, Chris Forbes chr...@ijw.co.nz wrote

Re: [Mesa-dev] [PATCH V4 00/19] ARB_texture_multisample support

2013-03-01 Thread Chris Forbes
I've had a quick look at the push-pop-texture-state regression, and that looks like a real bug I've introduced. I'm looking into it. On Sat, Mar 2, 2013 at 8:44 AM, Chris Forbes chr...@ijw.co.nz wrote: The minmax regression is addressed by my followup series, which adds the internalformat_query

Re: [Mesa-dev] [PATCH V4 00/19] ARB_texture_multisample support

2013-03-01 Thread Chris Forbes
I missed a case in attrib.c; this small patch should be folded in with the rest of the changes which add support for the new targets: commit 8b16367bab07cfe2eb44cc96a22bb925593b1e20 Author: Chris Forbes chr...@ijw.co.nz Date: Sat Mar 2 09:10:25 2013 +1300 fixup glPopAttrib(GL_TEXTURE_BIT

[Mesa-dev] [PATCH 0/7] Add support for ARB_texture_storage_multisample

2013-03-15 Thread Chris Forbes
This series adds support for ARB_texture_storage_multisample, which adds two interesting bits of behavior for multisample textures: - Immutable-format support, consistent with ARB_texture_storage - [Get]TexParameter* support This is admittedly not very useful by itself, but becomes more

[Mesa-dev] [PATCH 1/7] mesa: add support for immutable textures to teximagemultisample()

2013-03-15 Thread Chris Forbes
this behavior to TexImage*Multisample, but it seems like the reasonable thing to do. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/main/teximage.c | 15 --- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/src/mesa/main/teximage.c b/src/mesa/main/teximage.c index

[Mesa-dev] [PATCH 2/7] glapi: add definition of ARB_texture_storage_multisample

2013-03-15 Thread Chris Forbes
Adds XML for the extension, dispatch_sanity enabling, and the two new entrypoints. These are both implemented by calling the shared teximagemultisample() with immutable=GL_TRUE. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- .../glapi/gen/ARB_texture_storage_multisample.xml | 31

[Mesa-dev] [PATCH 3/7] mesa: add enable bit for ARB_texture_storage_multisample

2013-03-15 Thread Chris Forbes
--- src/mesa/main/extensions.c | 1 + src/mesa/main/mtypes.h | 1 + 2 files changed, 2 insertions(+) diff --git a/src/mesa/main/extensions.c b/src/mesa/main/extensions.c index e90a296..004fc8e 100644 --- a/src/mesa/main/extensions.c +++ b/src/mesa/main/extensions.c @@ -148,6 +148,7 @@ static

[Mesa-dev] [PATCH 4/7] mesa: improve reported function name in Tex*Multisample

2013-03-15 Thread Chris Forbes
Now that there are 4 variants, just pass the function name into teximagemultisample rather than reconstructing it. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/main/teximage.c | 30 ++ 1 file changed, 14 insertions(+), 16 deletions(-) diff --git a/src

[Mesa-dev] [PATCH 5/7] mesa: allow multisample texture targets in [Get]TexParameter*

2013-03-15 Thread Chris Forbes
- any state which appears in the `per-sampler` state table may not be set; generates INVALID_OPERATION Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/main/texparam.c | 92 +++- 1 file changed, 91 insertions(+), 1 deletion(-) diff --git a/src

[Mesa-dev] [PATCH 6/7] i965: enable ARB_texture_storage_multisample on Gen6+

2013-03-15 Thread Chris Forbes
This can be enabled everywhere that ARB_texture_multisample is supported -- ARB_texture_storage is supported on everything. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/drivers/dri/intel/intel_extensions.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/mesa/drivers/dri

[Mesa-dev] [PATCH 7/7] docs: mark ARB_texture_storage_multisample done

2013-03-15 Thread Chris Forbes
Signed-off-by: Chris Forbes chr...@ijw.co.nz --- docs/GL3.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/GL3.txt b/docs/GL3.txt index de51693..3c97c8d 100644 --- a/docs/GL3.txt +++ b/docs/GL3.txt @@ -151,7 +151,7 @@ ARB_shader_storage_buffer_object

Re: [Mesa-dev] Basic GLSL 1.50 support: new types built-in functions

2013-03-19 Thread Chris Forbes
For the series: Reviewed-by: Chris Forbes chr...@ijw.co.nz On Tue, Mar 19, 2013 at 2:57 PM, Kenneth Graunke kenn...@whitecape.org wrote: This series improves our basic GLSL 1.50 support. First, it makes 1.50 shaders using built-in functions work. Secondly, it adds the new types and built-ins

[Mesa-dev] [PATCH V2 0/3] Sample count limit tidy-up

2013-03-23 Thread Chris Forbes
This series tidies up the missing interactions between unextended GL3, ARB_texture_multisample and ARB_internalformat_query. No serious functional changes from V1, just a lot of shuffling things around. -- Chris ___ mesa-dev mailing list

[Mesa-dev] [PATCH V2 1/3] mesa: allow internalformat_query with multisample texture targets

2013-03-23 Thread Chris Forbes
, but the driver may still be able to implement a reasonable resolve operation, so it can be supported for renderbuffers. V2: - Don't break Gallium compile. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/drivers/dri/i965/brw_context.c | 6 -- src/mesa/main/dd.h

[Mesa-dev] [PATCH V2 2/3] mesa: helper for checking renderbuffer sample count

2013-03-23 Thread Chris Forbes
-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/main/fbobject.c| 13 --- src/mesa/main/multisample.c | 54 + src/mesa/main/multisample.h | 5 + 3 files changed, 69 insertions(+), 3 deletions(-) diff --git a/src/mesa/main/fbobject.c b/src

[Mesa-dev] [PATCH V2 3/3] mesa: use _mesa_check_sample_count() for multisample textures

2013-03-23 Thread Chris Forbes
. - Do this in multisample.c instead. - Fix typo in error message. - Inline spec quotes Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Brian Paul bri...@vmware.com --- src/mesa/main/multisample.c | 29 ++--- src/mesa/main/teximage.c| 34

[Mesa-dev] [PATCH] mesa: only check sample count if we actually wanted multisampling

2013-03-25 Thread Chris Forbes
in the nonmultisampling case at all. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/main/fbobject.c | 19 ++- 1 file changed, 10 insertions(+), 9 deletions(-) diff --git a/src/mesa/main/fbobject.c b/src/mesa/main/fbobject.c index 3fdf626..c1f5299 100644 --- a/src/mesa/main/fbobject.c

[Mesa-dev] [PATCH] intel: provide a default QuerySamplesForFormat func

2013-03-28 Thread Chris Forbes
We claim to support ARB_internalformat_query on everything, but only i965+ bothered to provide the hook -- so QueryInternalformativ() would just explode (fail the assert in debug; segfault otherwise) on earlier platforms. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/drivers/dri

[Mesa-dev] [PATCH V2] mesa: provide default implementation of QuerySamplesForFormat

2013-03-28 Thread Chris Forbes
: - Move from intel to core mesa. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/drivers/common/driverfuncs.c | 3 ++- src/mesa/main/formatquery.c | 15 +++ src/mesa/main/formatquery.h | 4 3 files changed, 21 insertions(+), 1 deletion(-) diff --git

[Mesa-dev] [PATCH V2 0/8] ARB_texture_storage_multisample support

2013-03-29 Thread Chris Forbes
This series adds support for the ARB_texture_storage_multisample extension. Only minor changes from V1: * Added missing error cases in TexStorage*Multisample. Thanks Eric for pointing out that this was a bit lacking. * Dropped spurious special case for TEXTURE_MAX_LEVELS. This wasn't in the

[Mesa-dev] [PATCH V2 1/8] mesa: extract _mesa_is_legal_tex_storage_format helper

2013-03-29 Thread Chris Forbes
This is about to be used in teximagemultisample() when immutable=true. Signed-off-by: Chris Forbes chr...@ijw.co.nz --- src/mesa/main/texstorage.c | 37 - src/mesa/main/texstorage.h | 3 +++ 2 files changed, 23 insertions(+), 17 deletions(-) diff --git a/src

[Mesa-dev] [PATCH V2 2/8] mesa: add support for immutable textures to teximagemultisample()

2013-03-29 Thread Chris Forbes
this behavior to TexImage*Multisample, but it seems like the reasonable thing to do. V2: - Cover missing error cases (unsized formats; texture object zero) Signed-off-by: Chris Forbes chr...@ijw.co.nz [V1] Reviewed-by: Eric Anholt e...@anholt.net --- src/mesa/main/teximage.c | 31

[Mesa-dev] [PATCH V2 3/8] glapi: add definition of ARB_texture_storage_multisample

2013-03-29 Thread Chris Forbes
Adds XML for the extension, dispatch_sanity enabling, and the two new entrypoints. These are both implemented by calling the shared teximagemultisample() with immutable=GL_TRUE. Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Eric Anholt e...@anholt.net --- .../glapi/gen

[Mesa-dev] [PATCH V2 4/8] mesa: add enable bit for ARB_texture_storage_multisample

2013-03-29 Thread Chris Forbes
Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Eric Anholt e...@anholt.net --- src/mesa/main/extensions.c | 1 + src/mesa/main/mtypes.h | 1 + 2 files changed, 2 insertions(+) diff --git a/src/mesa/main/extensions.c b/src/mesa/main/extensions.c index e90a296..004fc8e 100644

[Mesa-dev] [PATCH V2 5/8] mesa: improve reported function name in Tex*Multisample

2013-03-29 Thread Chris Forbes
Now that there are 4 variants, just pass the function name into teximagemultisample rather than reconstructing it. Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Eric Anholt e...@anholt.net --- src/mesa/main/teximage.c | 30 ++ 1 file changed, 14 insertions

[Mesa-dev] [PATCH V2 6/8] mesa: allow multisample texture targets in [Get]TexParameter*

2013-03-29 Thread Chris Forbes
- any state which appears in the `per-sampler` state table may not be set; generates INVALID_OPERATION V2: Don't introduce bogus handling of TEXTURE_MAX_LEVEL Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Eric Anholt e...@anholt.net --- src/mesa/main/texparam.c | 88

[Mesa-dev] [PATCH V2 7/8] i965: enable ARB_texture_storage_multisample on Gen6+

2013-03-29 Thread Chris Forbes
This can be enabled everywhere that ARB_texture_multisample is supported -- ARB_texture_storage is supported on everything. Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Eric Anholt e...@anholt.net --- src/mesa/drivers/dri/intel/intel_extensions.c | 1 + 1 file changed, 1 insertion

[Mesa-dev] [PATCH V2 8/8] docs: mark ARB_texture_storage_multisample done

2013-03-29 Thread Chris Forbes
Signed-off-by: Chris Forbes chr...@ijw.co.nz Reviewed-by: Eric Anholt e...@anholt.net --- docs/GL3.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/GL3.txt b/docs/GL3.txt index 640dec2..898d921 100644 --- a/docs/GL3.txt +++ b/docs/GL3.txt @@ -151,7 +151,7

Re: [Mesa-dev] mesa : ARB_texture_gather implementation - WIP[PATCH1/1] but need advice !

2013-03-29 Thread Chris Forbes
sure I won't be really efficient for it at this time. But certainly for other features in the coming weeks/months. Le 24/03/2013 22:29, Chris Forbes a écrit : Hi OK, thanks. Just thought I'd ask :) -- Chris On Mon, Mar 25, 2013 at 10:23 AM, Maxence Le Doré maxence.led...@gmail.com wrote

Re: [Mesa-dev] [PATCH V2] mesa: provide default implementation of QuerySamplesForFormat

2013-03-29 Thread Chris Forbes
A slightly modified version of this (drop the target parameter) should be a candidate for the 9.1 branch. On Fri, Mar 29, 2013 at 5:23 PM, Kenneth Graunke kenn...@whitecape.org wrote: On 03/28/2013 08:28 PM, Chris Forbes wrote: Previously at least i915 failed to provide an implementation

  1   2   3   4   5   6   7   8   9   10   >