mesa.git
13 years agost/egl: Set pipe_resource::array_size to 1.
Chia-I Wu [Fri, 3 Dec 2010 03:57:37 +0000 (11:57 +0800)]
st/egl: Set pipe_resource::array_size to 1.

13 years agor300g: do not remove unused constants if we are not near the limit
Marek Olšák [Fri, 3 Dec 2010 05:32:10 +0000 (06:32 +0100)]
r300g: do not remove unused constants if we are not near the limit

13 years agor300g: fix pointer arithmetic with void* in transfer_inline_write
Marek Olšák [Fri, 3 Dec 2010 05:08:50 +0000 (06:08 +0100)]
r300g: fix pointer arithmetic with void* in transfer_inline_write

13 years agomesa, st/mesa: fix gl_FragCoord with FBOs in Gallium
Marek Olšák [Thu, 2 Dec 2010 19:39:59 +0000 (20:39 +0100)]
mesa, st/mesa: fix gl_FragCoord with FBOs in Gallium

gl_FragCoord.y needs to be flipped upside down if a FBO is bound.

This fixes:
- piglit/fbo-fragcoord
- https://bugs.freedesktop.org/show_bug.cgi?id=29420

Here I add a new program state STATE_FB_WPOS_Y_TRANSFORM, which is set based
on whether a FBO is bound. The state contains a pair of transformations.
It can be either (XY=identity, ZW=transformY) if a FBO is bound,
or (XY=transformY, ZW=identity) otherwise, where identity = (1, 0),
transformY = (-1, height-1).

A classic driver (or st/mesa) may, based on some other state, choose whether
to use XY or ZW, thus negate the conditional "if (is a FBO bound) ...".
The reason for this is that a Gallium driver is allowed to only support WPOS
relative to either the lower left or the upper left corner, so we must flip
the Y axis accordingly again. (the "invert" parameter in emit_wpos_inversion)

NOTE: This is a candidate for the 7.9 branch.

Signed-off-by: Marek Olšák <maraeo@gmail.com>
Signed-off-by: Brian Paul <brianp@vmware.com>
13 years agor300g: implement simple transfer_inline_write for buffers
Marek Olšák [Fri, 3 Dec 2010 04:44:47 +0000 (05:44 +0100)]
r300g: implement simple transfer_inline_write for buffers

r600g might need something like that as well. This speeds up constant buffer
upload a bit.

13 years agor300g: use internal BO handle for add_buffer and write_reloc
Marek Olšák [Fri, 3 Dec 2010 01:48:11 +0000 (02:48 +0100)]
r300g: use internal BO handle for add_buffer and write_reloc

Small perf improvement in ipers.

radeon_drm_get_cs_handle is exactly what this commit tries to avoid
in every write_reloc.

13 years agogallivm/llvmpipe: remove lp_build_context::builder
Brian Paul [Fri, 3 Dec 2010 01:11:13 +0000 (18:11 -0700)]
gallivm/llvmpipe: remove lp_build_context::builder

The field was redundant.  Use the gallivm->builder value instead.

13 years agomesa: replace more MAX_WIDTH stack allocations with heap allocations
Brian Paul [Fri, 3 Dec 2010 01:06:40 +0000 (18:06 -0700)]
mesa: replace more MAX_WIDTH stack allocations with heap allocations

13 years agor300g: fix build
Marek Olšák [Thu, 2 Dec 2010 23:54:05 +0000 (00:54 +0100)]
r300g: fix build

13 years agor300g: Drop unnecessary cast
nobled [Thu, 2 Dec 2010 21:48:40 +0000 (21:48 +0000)]
r300g: Drop unnecessary cast

13 years agor300g: Abort if draw_create() fails
nobled [Thu, 2 Dec 2010 22:49:05 +0000 (22:49 +0000)]
r300g: Abort if draw_create() fails

The other drivers need to be updated to do this, too.

13 years agor300g: Abort if atom allocations fail
nobled [Thu, 2 Dec 2010 21:46:04 +0000 (21:46 +0000)]
r300g: Abort if atom allocations fail

13 years agonv50: silence some unknown get_param warnings
Ben Skeggs [Thu, 2 Dec 2010 22:23:44 +0000 (08:23 +1000)]
nv50: silence some unknown get_param warnings

Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
13 years agost/mesa: avoid large stack allocations in readpixels code
Brian Paul [Thu, 2 Dec 2010 21:23:43 +0000 (14:23 -0700)]
st/mesa: avoid large stack allocations in readpixels code

13 years agoswrast: avoid large stack allocations in tex combine code
Brian Paul [Thu, 2 Dec 2010 21:18:31 +0000 (14:18 -0700)]
swrast: avoid large stack allocations in tex combine code

13 years agoswrast: avoid large stack allocations in blend code
Brian Paul [Thu, 2 Dec 2010 21:18:18 +0000 (14:18 -0700)]
swrast: avoid large stack allocations in blend code

13 years agomesa: replace large/MAX_WIDTH stack allocations with heap allocations
Brian Paul [Thu, 2 Dec 2010 21:00:30 +0000 (14:00 -0700)]
mesa: replace large/MAX_WIDTH stack allocations with heap allocations

13 years agomesa: replace large/MAX_WIDTH stack allocations with heap allocations
Brian Paul [Thu, 2 Dec 2010 20:56:58 +0000 (13:56 -0700)]
mesa: replace large/MAX_WIDTH stack allocations with heap allocations

13 years agor600g: bump texture/cb limits appropriately for evergreen
Alex Deucher [Thu, 2 Dec 2010 21:09:22 +0000 (16:09 -0500)]
r600g: bump texture/cb limits appropriately for evergreen

13 years agor600c: bump texture limits to hw limits
Alex Deucher [Thu, 2 Dec 2010 20:39:28 +0000 (15:39 -0500)]
r600c: bump texture limits to hw limits

13 years agogallium/util: add states relevant to geometry shaders
Zack Rusin [Thu, 2 Dec 2010 20:49:36 +0000 (15:49 -0500)]
gallium/util: add states relevant to geometry shaders

13 years agomesa: Temporary hack to prevent stack overflow on windows
José Fonseca [Thu, 2 Dec 2010 20:30:59 +0000 (20:30 +0000)]
mesa: Temporary hack to prevent stack overflow on windows

e.g. st_readpixels is trying to alloca() an huge ammount of memory from
the stack.

13 years agowgl: Fix visual's buffer_mask configuration.
José Fonseca [Thu, 2 Dec 2010 20:21:39 +0000 (20:21 +0000)]
wgl: Fix visual's buffer_mask configuration.

13 years agomapi: Hack to avoid vgCreateFont being generated as vgCreateFontA.
José Fonseca [Thu, 2 Dec 2010 19:33:41 +0000 (19:33 +0000)]
mapi: Hack to avoid vgCreateFont being generated as vgCreateFontA.

Right fix is probably stop C-preprocessor abuse and stick 100% with
scripted code generation.

13 years agomesa: Add getters for ARB_copy_buffer's attachment points.
Eric Anholt [Thu, 2 Dec 2010 17:24:19 +0000 (09:24 -0800)]
mesa: Add getters for ARB_copy_buffer's attachment points.

Fixes more complaints by oglconform.

13 years agomesa: Add getters for the rest of the supported draw buffers.
Eric Anholt [Thu, 2 Dec 2010 17:05:53 +0000 (09:05 -0800)]
mesa: Add getters for the rest of the supported draw buffers.

MAX_DRAW_BUFFERS is 8, so allow all 8 GL_DRAW_BUFFER# to be retrieved.
Fixes complaints by oglconform.

13 years agoglsl: Fix flipped return of has_value() for array constants.
Eric Anholt [Thu, 2 Dec 2010 16:52:58 +0000 (08:52 -0800)]
glsl: Fix flipped return of has_value() for array constants.

Fixes glsl-array-uniform.

13 years agoWIN32_THREADS -> WIN32
José Fonseca [Thu, 2 Dec 2010 17:27:05 +0000 (17:27 +0000)]
WIN32_THREADS -> WIN32

Fixes nasty bug where some parts of the code didn't define WIN32_THREADS
and were using the integer mutex implementation, causing even confusion
to the debuggers.

And there is little interest of other thread implemenation on Win32
besides Win32 threads.

13 years agosoftpipe: increase max texture size to 16K
Brian Paul [Thu, 2 Dec 2010 17:08:33 +0000 (10:08 -0700)]
softpipe: increase max texture size to 16K

13 years agomesa: raise max texture sizes to 16K
Brian Paul [Thu, 2 Dec 2010 15:20:08 +0000 (08:20 -0700)]
mesa: raise max texture sizes to 16K

This allows 16K x 16K 2D textures, for example, but we don't want to
allow that for 3D textures.  The new gl_constants::MaxTextureMBytes
field is used to prevent allocating too large of texture image.
This allows a 16K x 32 x 32 3D texture, for example, but prevents 16K^3.
Drivers can override this limit.  The default is currently 1GB.

Apps should use the proxy texture mechanism to determine the actual
max texture size.

13 years agor300/compiler: disable the swizzle lowering pass in vertex shaders
Marek Olšák [Thu, 2 Dec 2010 14:56:38 +0000 (15:56 +0100)]
r300/compiler: disable the swizzle lowering pass in vertex shaders

It was a no-op because all swizzles are native there.

13 years agowgl: Unreference the current framebuffer after the make_current call.
José Fonseca [Thu, 2 Dec 2010 16:28:36 +0000 (16:28 +0000)]
wgl: Unreference the current framebuffer after the make_current call.

To prevent a dangling pointer dereference.

13 years agoutil: Don't try to use imagehlp on mingw.
José Fonseca [Thu, 2 Dec 2010 15:14:20 +0000 (15:14 +0000)]
util: Don't try to use imagehlp on mingw.

13 years agoutil: __builtin_frame_address() doesn't work on mingw.
José Fonseca [Thu, 2 Dec 2010 15:14:07 +0000 (15:14 +0000)]
util: __builtin_frame_address() doesn't work on mingw.

13 years agoutil: Plug leaks in util_destroy_gen_mipmap.
José Fonseca [Thu, 2 Dec 2010 15:13:46 +0000 (15:13 +0000)]
util: Plug leaks in util_destroy_gen_mipmap.

13 years agowgl: Fix double free. Remove dead code.
José Fonseca [Thu, 2 Dec 2010 14:57:40 +0000 (14:57 +0000)]
wgl: Fix double free. Remove dead code.

13 years agor300g: fix up cubemap texture offset computation
Marek Olšák [Thu, 2 Dec 2010 13:30:56 +0000 (14:30 +0100)]
r300g: fix up cubemap texture offset computation

Broken since 4c7001462607e6e99e474d6271dd481d3f8f201c.

13 years agoutil: C++ safe.
José Fonseca [Thu, 2 Dec 2010 12:26:55 +0000 (12:26 +0000)]
util: C++ safe.

13 years agoretrace: Some fixes.
José Fonseca [Thu, 2 Dec 2010 12:17:07 +0000 (12:17 +0000)]
retrace: Some fixes.

13 years agost/vega: polygon_array requires a deep free.
Chia-I Wu [Thu, 2 Dec 2010 09:53:42 +0000 (17:53 +0800)]
st/vega: polygon_array requires a deep free.

A polygon array is an array of pointers to polygons.  The polygons
should be freed with the array.

13 years agost/vega: Destroy the pipe context with vg_context.
Chia-I Wu [Thu, 2 Dec 2010 09:26:55 +0000 (17:26 +0800)]
st/vega: Destroy the pipe context with vg_context.

13 years agoglsl: Fix linker bug in cross_validate_globals()
Chad Versace [Wed, 17 Nov 2010 22:34:38 +0000 (14:34 -0800)]
glsl: Fix linker bug in cross_validate_globals()

Cause linking to fail if a global has mismatching invariant qualifiers.

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

13 years agogallium: support for array textures and related changes
Roland Scheidegger [Thu, 2 Dec 2010 03:33:43 +0000 (04:33 +0100)]
gallium: support for array textures and related changes

resources have a array_size parameter now.
get_tex_surface and tex_surface_destroy have been renamed to create_surface
and surface_destroy and moved to context, similar to sampler views (and
create_surface now uses a template just like create_sampler_view). Surfaces
now really should only be used for rendering. In particular they shouldn't be
used as some kind of 2d abstraction for sharing a texture. offset/layout fields
don't make sense any longer and have been removed, width/height should go too.
surfaces and sampler views now specify a layer range (for texture resources),
layer is either array slice, depth slice or cube face.
pipe_subresource is gone array slices (or cube faces) are now treated the same
as depth slices in transfers etc. (that is, they use the z coord of the
respective functions).

Squashed commit of the following:

commit a45bd509014743d21a532194d7b658a1aeb00cb7
Merge: 1aeca28 32e1e59
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Thu Dec 2 04:32:06 2010 +0100

    Merge remote branch 'origin/master' into gallium-array-textures

    Conflicts:
     src/gallium/drivers/i915/i915_resource_texture.c
     src/gallium/drivers/i915/i915_state_emit.c
     src/gallium/drivers/i915/i915_surface.c

commit 1aeca287a827f29206078fa1204715a477072c08
Merge: 912f042 6f7c8c3
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Thu Dec 2 00:37:11 2010 +0100

    Merge remote branch 'origin/master' into gallium-array-textures

    Conflicts:
     src/gallium/state_trackers/vega/api_filters.c
     src/gallium/state_trackers/vega/api_images.c
     src/gallium/state_trackers/vega/mask.c
     src/gallium/state_trackers/vega/paint.c
     src/gallium/state_trackers/vega/renderer.c
     src/gallium/state_trackers/vega/st_inlines.h
     src/gallium/state_trackers/vega/vg_context.c
     src/gallium/state_trackers/vega/vg_manager.c

commit 912f042e1d439de17b36be9a740358c876fcd144
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Wed Dec 1 03:01:55 2010 +0100

    gallium: even more compile fixes after merge

commit 6fc95a58866d2a291def333608ba9c10c3f07e82
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Wed Dec 1 00:22:26 2010 +0100

    gallium: some fixes after merge

commit a8d5ffaeb5397ffaa12fb422e4e7efdf0494c3e2
Merge: f7a202f 2da02e7
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Tue Nov 30 23:41:26 2010 +0100

    Merge remote branch 'origin/master' into gallium-array-textures

    Conflicts:
     src/gallium/drivers/i915/i915_state_emit.c
     src/gallium/state_trackers/vega/api_images.c
     src/gallium/state_trackers/vega/vg_context.c

commit f7a202fde2aea2ec78ef58830f945a5e214e56ab
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Wed Nov 24 19:19:32 2010 +0100

    gallium: even more fixes/cleanups after merge

commit 6895a7f969ed7f9fa8ceb788810df8dbcf04c4c9
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Wed Nov 24 03:07:36 2010 +0100

    gallium: more compile fixes after merge

commit af0501a5103b9756bc4d79167bd81051ad6e8670
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Tue Nov 23 19:24:45 2010 +0100

    gallium: lots of compile fixes after merge

commit 0332003c2feb60f2a20e9a40368180c4ecd33e6b
Merge: 26c6346 b6b91fa
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Tue Nov 23 17:02:26 2010 +0100

    Merge remote branch 'origin/master' into gallium-array-textures

    Conflicts:
     src/gallium/auxiliary/gallivm/lp_bld_sample.c
     src/gallium/auxiliary/util/u_blit.c
     src/gallium/auxiliary/util/u_blitter.c
     src/gallium/auxiliary/util/u_inlines.h
     src/gallium/auxiliary/util/u_surface.c
     src/gallium/auxiliary/util/u_surfaces.c
     src/gallium/docs/source/context.rst
     src/gallium/drivers/llvmpipe/lp_rast.c
     src/gallium/drivers/nv50/nv50_state_validate.c
     src/gallium/drivers/nvfx/nv04_surface_2d.c
     src/gallium/drivers/nvfx/nv04_surface_2d.h
     src/gallium/drivers/nvfx/nvfx_buffer.c
     src/gallium/drivers/nvfx/nvfx_miptree.c
     src/gallium/drivers/nvfx/nvfx_resource.c
     src/gallium/drivers/nvfx/nvfx_resource.h
     src/gallium/drivers/nvfx/nvfx_state_fb.c
     src/gallium/drivers/nvfx/nvfx_surface.c
     src/gallium/drivers/nvfx/nvfx_transfer.c
     src/gallium/drivers/r300/r300_state_derived.c
     src/gallium/drivers/r300/r300_texture.c
     src/gallium/drivers/r600/r600_blit.c
     src/gallium/drivers/r600/r600_buffer.c
     src/gallium/drivers/r600/r600_context.h
     src/gallium/drivers/r600/r600_screen.c
     src/gallium/drivers/r600/r600_screen.h
     src/gallium/drivers/r600/r600_state.c
     src/gallium/drivers/r600/r600_texture.c
     src/gallium/include/pipe/p_defines.h
     src/gallium/state_trackers/egl/common/egl_g3d_api.c
     src/gallium/state_trackers/glx/xlib/xm_st.c
     src/gallium/targets/libgl-gdi/gdi_softpipe_winsys.c
     src/gallium/targets/libgl-gdi/libgl_gdi.c
     src/gallium/tests/graw/tri.c
     src/mesa/state_tracker/st_cb_blit.c
     src/mesa/state_tracker/st_cb_readpixels.c

commit 26c6346b385929fba94775f33838d0cceaaf1127
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Mon Aug 2 19:37:21 2010 +0200

    fix more merge breakage

commit b30d87c6025eefe7f6979ffa8e369bbe755d5c1d
Merge: 9461bf3 1f1928d
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Mon Aug 2 19:15:38 2010 +0200

    Merge remote branch 'origin/master' into gallium-array-textures

    Conflicts:
     src/gallium/drivers/llvmpipe/lp_rast.c
     src/gallium/drivers/llvmpipe/lp_rast_priv.h
     src/gallium/drivers/r300/r300_blit.c
     src/gallium/drivers/r300/r300_screen_buffer.c
     src/gallium/drivers/r300/r300_state_derived.c
     src/gallium/drivers/r300/r300_texture.c
     src/gallium/drivers/r300/r300_texture.h
     src/gallium/drivers/r300/r300_transfer.c
     src/gallium/drivers/r600/r600_screen.c
     src/gallium/drivers/r600/r600_state.c
     src/gallium/drivers/r600/r600_texture.c
     src/gallium/drivers/r600/r600_texture.h
     src/gallium/state_trackers/dri/common/dri1_helper.c
     src/gallium/state_trackers/dri/sw/drisw.c
     src/gallium/state_trackers/xorg/xorg_exa.c

commit 9461bf3cfb647d2301364ae29fc3084fff52862a
Merge: 17492d7 0eaccb3
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Thu Jul 15 20:13:45 2010 +0200

    Merge commit 'origin/master' into gallium-array-textures

    Conflicts:
     src/gallium/auxiliary/util/u_blitter.c
     src/gallium/drivers/llvmpipe/lp_rast.c
     src/gallium/drivers/llvmpipe/lp_surface.c
     src/gallium/drivers/r300/r300_render.c
     src/gallium/drivers/r300/r300_state.c
     src/gallium/drivers/r300/r300_texture.c
     src/gallium/drivers/r300/r300_transfer.c
     src/gallium/tests/trivial/quad-tex.c

commit 17492d705e7b7f607b71db045c3bf344cb6842b3
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Fri Jun 18 10:58:08 2010 +0100

    gallium: rename element_offset/width fields in views to first/last_element

    This is much more consistent with the other fields used there
    (first/last level, first/last layer).
    Actually thinking about removing the ugly union/structs again and
    rename first/last_layer to something even more generic which could also
    be used for buffers (like first/last_member) without inducing headaches.

commit 1b717a289299f942de834dcccafbab91361e20ab
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Thu Jun 17 14:46:09 2010 +0100

    gallium: remove PIPE_SURFACE_LAYOUT_LINEAR definition

    This was only used by the layout field of pipe_surface, but this
    driver internal stuff is gone so there's no need for this driver independent
    layout definition neither.

commit 10cb644b31b3ef47e6c7b55e514ad24bb891fac4
Merge: 5691db9 c85971d
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Thu Jun 17 12:20:41 2010 +0100

    Merge commit 'origin/master' into gallium-array-textures

    Conflicts:
     src/gallium/docs/source/glossary.rst
     src/gallium/tests/graw/fs-test.c
     src/gallium/tests/graw/gs-test.c

commit 5691db960ca3d525ce7d6c32d9c7a28f5e907f3b
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Thu Jun 17 11:29:03 2010 +0100

    st/wgl: fix interface changes bugs

commit 2303ec32143d363b46e59e4b7c91b0ebd34a16b2
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Wed Jun 16 19:42:32 2010 +0100

    gallium: adapt code to interface changes...

commit dcae4f586f0d0885b72674a355e5d56d47afe77d
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Wed Jun 16 19:42:05 2010 +0100

    gallium: separate depth0 and array_size in the resource itself.

    These fields are still mutually exclusive (since no 3d array textures exist)
    but it ultimately seemed to error-prone to adapt all code accept the new
    meaning of depth0 (drivers stick that into hardware regs, calculate mipmap
    sizes etc.). And it isn't really cleaner anyway.
    So, array textures will have depth0 of 1, but instead use array_size,
    3D textures will continue to use depth0 (and have array_size of 1). Cube
    maps also will use array_size to indicate their 6 faces, but since all drivers
    should just be fine by inferring this themselves from the fact it's a cube map
    as they always used to nothing should break.

commit 621737a638d187d208712250fc19a91978fdea6b
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Wed Jun 16 17:47:38 2010 +0100

    gallium: adapt code to interface changes

    There are still usages of pipe_surface where pipe_resource should be used,
    which should eventually be fixed.

commit 2d17f5efe166b2c3d51957c76294165ab30b8ae2
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Wed Jun 16 17:46:14 2010 +0100

    gallium: more interface changes

    In particular to enable usage of buffers in views, and ability to use a
    different pipe_format in pipe_surface.
    Get rid of layout and offset parameter in pipe_surface - the former was
    not used in any (public) code anyway, and the latter should either be computed
    on-demand or driver can use subclass of pipe_surface.
    Also make create_surface() use a template to be more consistent with
    other functions.

commit 71f885ee16aa5cf2742c44bfaf0dc5b8734b9901
Merge: 3232d11 8ad410d
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Mon Jun 14 14:19:51 2010 +0100

    Merge commit 'origin/master' into gallium-array-textures

    Conflicts:
     src/gallium/auxiliary/util/u_box.h
     src/gallium/drivers/nv50/nv50_surface.c
     src/gallium/drivers/nvfx/nvfx_surface.c
     src/gallium/drivers/r300/r300_blit.c
     src/gallium/drivers/r300/r300_texture.c
     src/gallium/drivers/r300/r300_transfer.c
     src/gallium/drivers/r600/r600_blit.c
     src/gallium/drivers/r600/r600_screen.h
     src/gallium/include/pipe/p_state.h

commit 3232d11fe3ebf7686286013c357b404714853984
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Mon Jun 14 11:40:04 2010 +0100

    mesa/st: adapt to interface changes

    still need to fix pipe_surface sharing
    (as that is now per-context).
    Also broken is depth0 handling - half the code assumes
    this is also used for array textures (and hence by extension
    of that cube maps would have depth 6), half the code does not...

commit f433b7f7f552720e5eade0b4078db94590ee85e1
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Mon Jun 14 11:35:52 2010 +0100

    gallium: fix a couple of bugs in interface chnage fixes

commit 818366b28ea18f514dc791646248ce6f08d9bbcf
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:42:11 2010 +0200

    targets: adapt to interface changes

    Yes even that needs adjustments...

commit 66c511ab1682c9918e0200902039247793acb41e
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:41:13 2010 +0200

    tests: adapt to interface changes

    Everything needs to be fixed :-(.

commit 6b494635d9dbdaa7605bc87b1ebf682b138c5808
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:39:50 2010 +0200

    st: adapt non-rendering state trackers to interface changes

    might not be quite right in all places, but they really don't want
    to use pipe_surface.

commit 00c4289a35d86e4fe85919ec32aa9f5ffe69d16d
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:38:48 2010 +0200

    winsys: adapt to interface changes

commit 39d858554dc9ed5dbc795626fec3ef9deae552a0
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:26:54 2010 +0200

    st/python: adapt to interface changes

    don't think that will work, sorry.

commit 6e9336bc49b32139cec4e683857d0958000e15e3
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:26:07 2010 +0200

    st/vega: adapt to interface changes

commit e07f2ae9aaf8842757d5d50865f76f8276245e11
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:25:56 2010 +0200

    st/xorg: adapt to interface changes

commit 05531c10a74a4358103e30d3b38a5eceb25c947f
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:24:53 2010 +0200

    nv50: adapt to interface changes

commit 97704f388d7042121c6d496ba8c003afa3ea2bf3
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:24:45 2010 +0200

    nvfx: adapt to interface changes

commit a8a9c93d703af6e8f5c12e1cea9ec665add1abe0
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:24:01 2010 +0200

    i965g: adapt to interface changes

commit 0dde209589872d20cc34ed0b237e3ed7ae0e2de3
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:22:38 2010 +0200

    i915g: adapt to interface changes

commit 5cac9beede69d12f5807ee1a247a4c864652799e
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:20:58 2010 +0200

    svga: adapt to interface changes

    resource_copy_region still looking fishy.
    Was not very suited to unified zslice/face approach...

commit 08b5a6af4b963a3e4c75fc336bf6c0772dce5150
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:20:01 2010 +0200

    rbug: adapt to interface changes

    Not sure if that won't need changes elsewhere?

commit c9fd24b1f586bcef2e0a6e76b68e40fca3408964
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:19:31 2010 +0200

    trace: adapt to interface changes

commit ed84e010afc5635a1a47390b32247a266f65b8d1
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:19:21 2010 +0200

    failover: adapt to interface changes

commit a1d4b4a293da933276908e3393435ec4b43cf201
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:19:12 2010 +0200

    identity: adapt to interface changes

commit a8dd73e2c56c7d95ffcf174408f38f4f35fd2f4c
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:18:55 2010 +0200

    softpipe: adapt to interface changes

commit a886085893e461e8473978e8206ec2312b7077ff
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:18:44 2010 +0200

    llvmpipe: adapt to interface changes

commit 70523f6d567d8b7cfda682157556370fd3c43460
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:18:14 2010 +0200

    r600g: adapt to interface changes

commit 3f4bc72bd80994865eb9f6b8dfd11e2b97060d19
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:18:05 2010 +0200

    r300g: adapt to interface changes

commit 5d353b55ee14db0ac0515b5a3cf9389430832c19
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:17:37 2010 +0200

    cell: adapt to interface changes

    not even compile tested

commit cf5d03601322c2dcb12d7a9c2f1745e2b2a35eb4
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:14:59 2010 +0200

    util: adapt to interface changes

    amazing how much code changes just due to some subtle interface changes?

commit dc98d713c6937c0e177fc2caf23020402cc7ea7b
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Sat Jun 12 02:12:40 2010 +0200

    gallium: more interface fail, docs

    this also changes flush_frontbuffer to use a pipe_resource instead of
    a pipe_surface - pipe_surface is not meant to be (or at least no longer)
    an abstraction for standalone 2d images which get passed around.
    (This has also implications for the non-rendering state-trackers.)

commit 08436d27ddd59857c22827c609b692aa0c407b7b
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Thu Jun 10 17:42:52 2010 +0200

    gallium: fix array texture interface changes bugs, docs

commit 4a4d927609b62b4d7fb9dffa35158afe282f277b
Author: Roland Scheidegger <sroland@vmware.com>
Date:   Thu Jun 3 22:02:44 2010 +0200

    gallium: interface changes for array textures and related cleanups

    This patch introduces array textures to gallium (note they are not immediately
    usable without the associated changes to the shader side).
    Also, this abandons pipe_subresource in favor of using level and layer
    parameters since the distinction between several faces (which was part of
    pipe_subresource for cube textures) and several z slices (which were not part
    of pipe_subresource but instead part of pipe_box where appropriate for 3d
    textures) is gone at the resource level.
    Textures, be it array, cube, or 3d, now use a "unified" set of parameters,
    there is no distinction between array members, cube faces, or 3d zslices.
    This is unlike d3d10, whose subresource index includes layer information for
    array textures, but which considers all z slices of a 3d texture to be part
    of the same subresource.
    In contrast to d3d10, OpenGL though reuses old 2d and 3d function entry points
    for 1d and 2d array textures, respectively, which also implies that for instance
    it is possible to specify all layers of a 2d array texture at once (note that
    this is not possible for cube maps, which use the 2d entry points, although
    it is possible for cube map arrays, which aren't supported yet in gallium).
    This should possibly make drivers a bit simpler, and also get rid of mutually
    exclusive parameters in some functions (as z and face were exclusive), one
    potential downside would be that 3d array textures could not easily be supported
    without reverting this, but those are nowhere to be seen.

    Also along with adjusting to new parameters, rename get_tex_surface /
    tex_surface_destroy to create_surface / surface_destroy and move them from
    screen to context, which reflects much better what those do (they are analogous
    to create_sampler_view / sampler_view_destroy).

    PIPE_CAP_ARRAY_TEXTURES is used to indicate if a driver supports all of this
    functionality (that is, both sampling from array texture as well as use a range
    of layers as a render target, with selecting the layer from the geometry shader).

13 years agoi965: add support for polygon mode on Sandybridge.
Xiang, Haihao [Wed, 1 Dec 2010 08:59:36 +0000 (16:59 +0800)]
i965: add support for polygon mode on Sandybridge.

This fixes some mesa demos such as fslight/engine in wireframe mode.

13 years agoi915g: Make sure that new vbo gets updated
Jakob Bornecrantz [Mon, 29 Nov 2010 19:53:26 +0000 (20:53 +0100)]
i915g: Make sure that new vbo gets updated

Malloc likes to reuse old address as soon as possible this would cause the
new vbo buffer to get the same address as the old. So make sure we set it to
NULL when we allocate a new one. This fixes ipers which will fill up a couple
of VBO buffers per frame.

Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
13 years agoi915g: Improve debug printing for textures
Jakob Bornecrantz [Sun, 28 Nov 2010 23:14:59 +0000 (00:14 +0100)]
i915g: Improve debug printing for textures

Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
13 years agoi915g: Fix closure of full batch buffers
Chris Wilson [Wed, 1 Dec 2010 20:57:41 +0000 (21:57 +0100)]
i915g: Fix closure of full batch buffers

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
[danvet: incorporate comments by Dr_Jakob]
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Jakob Bornecrantz <wallbraker@gmail.com>
Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
13 years agoi915g: track TODO items
Daniel Vetter [Sun, 21 Nov 2010 16:56:09 +0000 (17:56 +0100)]
i915g: track TODO items

Just as a reminder for all things currently broken with i915g.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Jakob Bornecrantz <wallbraker@gmail.com>
Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
13 years agoi915g: assert(depth_surface->offset == 0)
Daniel Vetter [Sun, 28 Nov 2010 20:56:24 +0000 (21:56 +0100)]
i915g: assert(depth_surface->offset == 0)

Shouldn't happen and not supported, anyway.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Jakob Bornecrantz <wallbraker@gmail.com>
Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
13 years agoi915g: enable x-tiling for render targets
Daniel Vetter [Sun, 28 Nov 2010 20:37:03 +0000 (21:37 +0100)]
i915g: enable x-tiling for render targets

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Jakob Bornecrantz <wallbraker@gmail.com>
Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
13 years agoi915g: switch rendering to mipmapped textures to (x,y) offsets
Daniel Vetter [Wed, 1 Dec 2010 20:04:56 +0000 (21:04 +0100)]
i915g: switch rendering to mipmapped textures to (x,y) offsets

Byte offsets simply don't work with tiled render targets when using
tiling bits. Luckily we can cox the hw into doing the right thing
with the DRAWING_RECT command by disabling the drawing rect offset
for the depth buffer.

Minor fixes by Jakob Bornecrantz.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Jakob Bornecrantz <wallbraker@gmail.com>
Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
13 years agoi915g: enable X-tiling for textures
Daniel Vetter [Sat, 20 Nov 2010 10:17:55 +0000 (11:17 +0100)]
i915g: enable X-tiling for textures

Tiling is rather fragile in general and results in pure blackness when
unlucky.  Hence add a new option to disable tiling.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Jakob Bornecrantz <wallbraker@gmail.com>
Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
13 years agoi915g: don't pot-align stride for tiled buffers
Daniel Vetter [Sat, 20 Nov 2010 09:23:03 +0000 (10:23 +0100)]
i915g: don't pot-align stride for tiled buffers

libdrm will do this for us, if it's required (i.e. if tiling is
possible).

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Jakob Bornecrantz <wallbraker@gmail.com>
Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
13 years agoi915g: postpone mipmap/face offset calculation
Daniel Vetter [Sat, 20 Nov 2010 09:00:38 +0000 (10:00 +0100)]
i915g: postpone mipmap/face offset calculation

libdrm-intel can refuse to tile buffers for various reasons. For
potentially tiled buffers the stride is therefore only known after
the iws->buffer_create_tiled call. Unconditionally rounding up to whatever
tiling requires wastes space, so rework the code to not use tex->stride
in the layout code.

Luckily only the mimap/face offset calculation uses it which can easily
be solved by storing an (x, y) coordinate pair. Furthermore this will
be usefull later for properly supporting rendering into the different
levels of tiled mipmap textures.

v2: switch to nblocks(x|y): More in line with gallium and better
suited for rendering into mipmap textures.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Jakob Bornecrantz <wallbraker@gmail.com>
Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
13 years agoi915g: implement unfenced relocs for textures using tiling bits
Daniel Vetter [Wed, 1 Dec 2010 20:03:13 +0000 (21:03 +0100)]
i915g: implement unfenced relocs for textures using tiling bits

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Jakob Bornecrantz <wallbraker@gmail.com>
Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
13 years agoi915g: implement unfenced color&depth buffer using tiling bits
Daniel Vetter [Wed, 1 Dec 2010 19:59:45 +0000 (20:59 +0100)]
i915g: implement unfenced color&depth buffer using tiling bits

v2: Clarify tiling bit calculation as suggested by Chris Wilson.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Jakob Bornecrantz <wallbraker@gmail.com>
Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
13 years agoi915g: return tiling in iws->buffer_from_handle
Daniel Vetter [Sun, 21 Nov 2010 19:25:33 +0000 (20:25 +0100)]
i915g: return tiling in iws->buffer_from_handle

This is needed to properly implement tiling flags. And the gem
implemention fo buffer_from_handle already calls get_tiling, so
it's for free.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Jakob Bornecrantz <wallbraker@gmail.com>
Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
13 years agoi915g: prepare winsys/batchbuffer for execbuf2
Daniel Vetter [Sun, 21 Nov 2010 19:21:00 +0000 (20:21 +0100)]
i915g: prepare winsys/batchbuffer for execbuf2

Wire up a fenced parameter, switch all relocations to _FENCED

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Jakob Bornecrantz <wallbraker@gmail.com>
Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
13 years agoi915g: switch to tiled allocations, kill set_fence
Daniel Vetter [Sun, 21 Nov 2010 19:36:01 +0000 (20:36 +0100)]
i915g: switch to tiled allocations, kill set_fence

This way relaxed fencing is handled by libdrm. And buffers _can't_
ever change their tiling.

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Jakob Bornecrantz <wallbraker@gmail.com>
Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
13 years agoi915g: add winsys function to create tiled buffers
Daniel Vetter [Sun, 21 Nov 2010 19:34:44 +0000 (20:34 +0100)]
i915g: add winsys function to create tiled buffers

Different kernels have different restrictions for tiled buffers.
Hence use the libdrm abstraction to calculate the necessary
stride and height alignment requirements.

Not yet used.

v2: Incorporate review comments from Jakob Bornecrantz

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Jakob Bornecrantz <wallbraker@gmail.com>
Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
13 years agoi915g: drop alignment parameter from iws->buffer_create
Daniel Vetter [Sun, 21 Nov 2010 18:06:48 +0000 (19:06 +0100)]
i915g: drop alignment parameter from iws->buffer_create

It's unnecessary. The kernel gem ignores it totally and we can't
run on the old userspace fake bo manager due to lack of dri2.

Also drop the redundant name string from the sw winsys as suggested
by Jakob Bornecrantz

Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Jakob Bornecrantz <wallbraker@gmail.com>
Signed-off-by: Jakob Bornecrantz <wallbraker@gmail.com>
13 years agoglsl: Mark the array access for whole-array comparisons.
Eric Anholt [Wed, 1 Dec 2010 23:55:53 +0000 (15:55 -0800)]
glsl: Mark the array access for whole-array comparisons.

By not doing so, the uniform contents of
glsl-uniform-non-uniform-array-compare.shader_test was getting thrown
out since nobody was recorded as dereferencing the array.

13 years agoi965: Add support for loops in the VS.
Eric Anholt [Wed, 1 Dec 2010 23:37:10 +0000 (15:37 -0800)]
i965: Add support for loops in the VS.

This follows the changes done for the FS alongside the EU emit code.

13 years agoi965: Enable IF statements in the VS.
Eric Anholt [Wed, 1 Dec 2010 23:36:26 +0000 (15:36 -0800)]
i965: Enable IF statements in the VS.

While the actual IF instructions were fixed by Zhenyu, we were still
flattening them to conditional moves.

13 years agoi965: Add support for gen6 CONTINUE instruction emit.
Eric Anholt [Wed, 1 Dec 2010 22:02:14 +0000 (14:02 -0800)]
i965: Add support for gen6 CONTINUE instruction emit.

At this point, piglit tests for fragment shader loops are working.

13 years agoi965: Add support for gen6 BREAK ISA emit.
Eric Anholt [Wed, 1 Dec 2010 19:46:46 +0000 (11:46 -0800)]
i965: Add support for gen6 BREAK ISA emit.

There are now two targets: the hop-to-end-of-block target, and the
target for where to resume execution for active channels.

13 years agoi965: Add support for gen6 DO/WHILE ISA emit.
Eric Anholt [Wed, 1 Dec 2010 18:45:52 +0000 (10:45 -0800)]
i965: Add support for gen6 DO/WHILE ISA emit.

There's no more DO since there's no more mask stack, and WHILE has
been shuffled like IF was.

13 years agoi965: Dump the WHILE jump distance on gen6.
Eric Anholt [Wed, 1 Dec 2010 23:00:08 +0000 (15:00 -0800)]
i965: Dump the WHILE jump distance on gen6.

13 years agor300g: disable ARB_texture_swizzle if S3TC is enabled on r3xx-only
Marek Olšák [Wed, 1 Dec 2010 21:49:02 +0000 (22:49 +0100)]
r300g: disable ARB_texture_swizzle if S3TC is enabled on r3xx-only

r3xx cannot swizzle compressed textures. r4xx+ is unaffected.

NOTE: This is a candidate for the 7.9 branch.

13 years agor300g: fix texture swizzling with compressed textures on r400-r500
Marek Olšák [Tue, 30 Nov 2010 22:28:43 +0000 (23:28 +0100)]
r300g: fix texture swizzling with compressed textures on r400-r500

This fixes all S3TC piglit/texwrap tests.

NOTE: This is a candidate for the 7.9 branch.

13 years agoi915: Correctly generate unconditional KIL instructions
Ian Romanick [Wed, 1 Dec 2010 19:57:33 +0000 (11:57 -0800)]
i915: Correctly generate unconditional KIL instructions

Fixes piglit test glsl-fs-discard-03.

NOTE: This is a candidate for the 7.9 branch.

13 years agoi915: Request that POW instructions be lowered
Ian Romanick [Thu, 25 Nov 2010 06:21:34 +0000 (22:21 -0800)]
i915: Request that POW instructions be lowered

13 years agoglsl: Lower ir_binop_pow to a sequence of EXP2 and LOG2
Ian Romanick [Thu, 25 Nov 2010 06:21:10 +0000 (22:21 -0800)]
glsl: Lower ir_binop_pow to a sequence of EXP2 and LOG2

13 years agoglsl: Use M_LOG2E constant instead of calling log2
Ian Romanick [Wed, 24 Nov 2010 22:03:57 +0000 (14:03 -0800)]
glsl: Use M_LOG2E constant instead of calling log2

13 years agoglsl: Add comments to lower_jumps (from the commit message).
Kenneth Graunke [Mon, 29 Nov 2010 19:00:10 +0000 (11:00 -0800)]
glsl: Add comments to lower_jumps (from the commit message).

This is essentially Luca's commit message, but placed at the top of the
file.

13 years agoglsl: Remove "discard" support from lower_jumps.
Kenneth Graunke [Mon, 29 Nov 2010 18:59:16 +0000 (10:59 -0800)]
glsl: Remove "discard" support from lower_jumps.

The new lower_discard and opt_discard_simplification passes should
handle all the necessary transformations, so lower_jumps doesn't need to
support it.

Also, lower_jumps incorrectly handled conditional discards - it would
unconditionally truncate all code after the discard.  Rather than fixing
the bug, simply remove the code.

NOTE: This is a candidate for the 7.9 branch.

13 years agoglsl: Add a lowering pass to move discards out of if-statements.
Kenneth Graunke [Thu, 25 Nov 2010 09:09:26 +0000 (01:09 -0800)]
glsl: Add a lowering pass to move discards out of if-statements.

This should allow lower_if_to_cond_assign to work in the presence of
discards, fixing bug #31690 and likely #31983.

NOTE: This is a candidate for the 7.9 branch.

13 years agoglsl: Add an optimization pass to simplify discards.
Kenneth Graunke [Thu, 25 Nov 2010 06:02:26 +0000 (22:02 -0800)]
glsl: Add an optimization pass to simplify discards.

NOTE: This is a candidate for the 7.9 branch.

13 years agoir_to_mesa: Add support for conditional discards.
Marek Olšák [Thu, 25 Nov 2010 11:13:36 +0000 (03:13 -0800)]
ir_to_mesa: Add support for conditional discards.

NOTE: This is a candidate for the 7.9 branch.

Signed-off-by: Marek Olšák <maraeo@gmail.com>
Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
13 years agor600c: fix some opcodes on evergreen
Alex Deucher [Wed, 1 Dec 2010 18:22:00 +0000 (13:22 -0500)]
r600c: fix some opcodes on evergreen

There were a few places where we were using the wrong opcodes
on evergreen.  arl still needs to be fixed on evergreen; see
r600g for reference.

NOTE: This is a candidate for the 7.9 branch.

Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
13 years agor300/compiler: implement and lower OPCODE_CLAMP
Marek Olšák [Wed, 1 Dec 2010 15:44:22 +0000 (16:44 +0100)]
r300/compiler: implement and lower OPCODE_CLAMP

Needed for st/vega.

13 years agovega: Remove extraneous ;
José Fonseca [Wed, 1 Dec 2010 12:31:21 +0000 (12:31 +0000)]
vega: Remove extraneous ;

13 years agoscons: Move MSVS_VERSION option to common module.
José Fonseca [Wed, 1 Dec 2010 12:20:58 +0000 (12:20 +0000)]
scons: Move MSVS_VERSION option to common module.

13 years agosvga: Silence debug printf.
José Fonseca [Tue, 30 Nov 2010 14:06:34 +0000 (14:06 +0000)]
svga: Silence debug printf.

13 years agost/vega: Avoid unnecessary constant bufer upload.
Chia-I Wu [Wed, 1 Dec 2010 10:23:53 +0000 (18:23 +0800)]
st/vega: Avoid unnecessary constant bufer upload.

Remember the last uploaded data and avoid re-uploading.

13 years agost/vega: Initialize pipe states with renderer.
Chia-I Wu [Wed, 1 Dec 2010 09:13:09 +0000 (17:13 +0800)]
st/vega: Initialize pipe states with renderer.

Initialize vertex elements, rasterizer, stencil ref, and vertex shader
with renderer_create.  Remove RASTERIZER_DIRTY and VS_DIRTY flags.

13 years agost/vega: Create drawing surface mask as needed.
Chia-I Wu [Wed, 1 Dec 2010 09:51:41 +0000 (17:51 +0800)]
st/vega: Create drawing surface mask as needed.

As the blend texture, a drawing surface mask is used when masking is
enabled.  It should be created as needed.

s/alpha_mask/surface_mask/ to follow OpenVG 1.1 naming.

13 years agost/vega: Delay blend texture creation until needed.
Chia-I Wu [Wed, 1 Dec 2010 09:38:57 +0000 (17:38 +0800)]
st/vega: Delay blend texture creation until needed.

It is used for more advanced blending or mask update.  It might not be
ever needed for some applications.

13 years agost/vega: Remove st_inlines.h.
Chia-I Wu [Wed, 1 Dec 2010 08:59:43 +0000 (16:59 +0800)]
st/vega: Remove st_inlines.h.

Per b0427bedde80e3189524651a327235bdfddbc613.

13 years agost/vega: Simplify radial gradient.
Chia-I Wu [Wed, 1 Dec 2010 05:39:59 +0000 (13:39 +0800)]
st/vega: Simplify radial gradient.

Eight less instructions with comments.

13 years agost/vega: Fix degenerate paints.
Chia-I Wu [Wed, 1 Dec 2010 03:54:58 +0000 (11:54 +0800)]
st/vega: Fix degenerate paints.

Fix the case that the two points of a linear gradient coincide, or the
case that the radius of a radial gradient is equal to or less than 0.

13 years agoi965: also using align1 mode for math2 on sandybridge
Zhenyu Wang [Wed, 1 Dec 2010 07:02:46 +0000 (15:02 +0800)]
i965: also using align1 mode for math2 on sandybridge

Like Eric's workaround patch of commit 490c23ee6be2e8531b5a14d42f808de83d401130.
This forces to align1 mode for math2 too.

13 years agost/vega: Fix negated logic in image_draw.
Chia-I Wu [Wed, 1 Dec 2010 03:39:02 +0000 (11:39 +0800)]
st/vega: Fix negated logic in image_draw.

A typo from last commit.

13 years agost/vega: Fix paint coordinates transformations.
Chia-I Wu [Tue, 30 Nov 2010 18:30:59 +0000 (02:30 +0800)]
st/vega: Fix paint coordinates transformations.

Depending on whether vgDrawPath(mode), vgDrawImage, or vgDrawGlyph[s] is
called, different paint-to-user and user-to-surface matrices should be
used to derive the sample points for the paint.

This fixes "paint" demo.

13 years agost/vega: Bump version to 1.1.
Chia-I Wu [Mon, 29 Nov 2010 07:11:16 +0000 (15:11 +0800)]
st/vega: Bump version to 1.1.

13 years agost/vega: Add color transformation support.
Chia-I Wu [Mon, 29 Nov 2010 03:49:18 +0000 (11:49 +0800)]
st/vega: Add color transformation support.

Per OpenVG 1.1.  A new shader stage is added.  It uses the first two
constants of the fragment shader for color transformation parameters.

13 years agost/vega: More flexible shader selection.
Chia-I Wu [Mon, 29 Nov 2010 11:15:03 +0000 (19:15 +0800)]
st/vega: More flexible shader selection.

Divide bits of VegaShaderType into 6 groups: paint, image, mask, fill,
premultiply, and bw.  Each group represents a stage.  At most one shader
from each group will be selected when constructing the final fragment
shader.

13 years agost/vega: Revive mask layer support.
Chia-I Wu [Sun, 28 Nov 2010 16:15:51 +0000 (00:15 +0800)]
st/vega: Revive mask layer support.

13 years agost/vega: Add primitive text support.
Chia-I Wu [Tue, 23 Nov 2010 17:24:38 +0000 (01:24 +0800)]
st/vega: Add primitive text support.

Optional features such as auth-hinting are not implemented.  There is no
anti-aliasing, and no effort is done to keep the glyph origin integral.
So the text quality is poor.

13 years agost/vega: Make image_draw take a matrix.
Chia-I Wu [Wed, 24 Nov 2010 07:51:46 +0000 (15:51 +0800)]
st/vega: Make image_draw take a matrix.