aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium/auxiliary/cso_cache
Commit message (Collapse)AuthorAgeFilesLines
* cso: move cso hashes to a more table driven schemeDave Airlie2011-06-032-84/+21
| | | | | | this removes a bad branch pain in the hash table lookup fn. Signed-off-by: Dave Airlie <[email protected]>
* gallium: always save and restore vertex buffers using cso_cacheMarek Olšák2011-02-142-0/+52
|
* cso: don't tell drivers to bind null samplers, sampler viewsBrian Paul2011-02-031-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Before, the set_sampler_views() and restore_sampler_views() functions used MAX2(old,new) to tell the driver how many samplers or sampler views to set. This could result in cases such as: pipe->set_fragment_sampler_views(pipe, 4, views={foo, bar, NULL, NULL}) Many/most gallium drivers would take this as-is and set ctx->num_sampler_views=4 and ctx->sampler_views={foo, bar, NULL, NULL, ...}. Later, loops over ctx->num_sampler_views would have to check for null pointers. Worse, the number of sampler views and number of sampler CSOs could get out of sync: ctx->num_samplers = 2 ctx->samplers = {foo, bar, ...} ctx->num_sampler_views = 4 ctx->sampler_views={Foo, Bar, NULL, NULL, ...} So loops over the num_samplers could run into null sampler_views pointers or vice versa. This fixes a failed assertion in the SVGA driver when running the Mesa engine demo in AA line mode (and possibly other cases). It looks like all gallium drivers are careful to unreference views and null-out sampler CSO pointers for the units beyond what's set with the pipe::bind_x_sampler_states() and pipe::set_x_sampler_views() functions. I'll update the gallium docs to explain this as well.
* cso: refactor texture sampler and sampler view codeBrian Paul2011-02-021-326/+307
| | | | | | This consolidates the code duplicated between the fragment sampler and vertex sampler functions. Plus, it'll make adding support for geometry shader samplers trivial.
* cso: rename fragment sampler-related fieldsBrian Paul2011-02-021-21/+26
| | | | To better distinguish from vertex sampler fields.
* cso: fix loop bound in cso_set_vertex_samplers()Brian Paul2011-02-021-1/+1
| | | | | | | Before we were looping to nr_samplers, which is the number of fragment samplers, not vertex samplers. NOTE: This is a candidate for the 7.9 and 7.10 branches.
* cso: handle depth clampMarek Olšák2010-07-211-0/+4
|
* gallium/cso: check for set_vertex_sampler_views != NULL before calling itBrian Paul2010-07-021-1/+2
| | | | | Not all drivers implement this method. Fixes regression reported by Chris Rankin and bug 28889.
* gallium/cso: unbind sampler views in cso_release_all()Brian Paul2010-07-011-0/+2
|
* Merge commit 'origin/master' into gallium-msaaRoland Scheidegger2010-05-041-41/+7
|\
| * cso: use framebuffer utility functionsBrian Paul2010-05-031-41/+7
| |
* | Merge commit 'origin/master' into gallium-msaaRoland Scheidegger2010-04-301-1/+4
|\|
| * cso: remove commented-out code, update function docsBrian Paul2010-04-291-1/+4
| |
* | gallium: fix glaring bugs in last commitRoland Scheidegger2010-04-271-1/+1
| |
* | gallium: interface changes for multisamplingRoland Scheidegger2010-04-262-0/+13
|/ | | | | | | | | | | | | | | | | | | | | | add function to set sample mask, and state for alpha-to-coverage and alpha-to-one. Also make it possible to query for supported sample count with is_msaa_supported(). Use explicit resource_resolve() to resolve a resource. Note that it is illegal to bind a unresolved resource as a sampler view, must be resolved first (as per d3d10 and OGL APIs, binding unresolved resource would mean that special texture fetch functions need to be used which give explicit control over what samples to fetch, which isn't supported yet). Also change surface_fill() and surface_copy() to operate directly on resources. Blits should operate directly on resources, most often state trackers just used get_tex_surface() then did a blit. Note this also means the blit bind flags are gone, if a driver implements this functionality it is expected to handle it for all resources having depth_stencil/render_target/sampler_view bind flags (might even require it for all bind flags?). Might want to introduce quality levels for MSAA later. Might need to revisit this for hw which does instant resolve.
* cso_cache: Ensure irrelevant state of the blend state is zeroed.José Fonseca2010-04-241-0/+1
| | | | | | | Otherwise drivers that bake the full blend state in a key end up having uninitialized memory in their key. Courtesy of valgrind.
* cso: Remove unnecessary header.Vinson Lee2010-03-221-1/+0
|
* cso: remove cso_set/save/restore_sampler_texturesRoland Scheidegger2010-03-192-76/+0
| | | | no longer used after all statetrackers have been converted.
* cso: Do not hold references to bound textures.Keith Whitwell2010-03-151-22/+8
| | | | Sampler views already hold references to those.
* cso: Remove set/save/restore_vertex_sampler_textures().Michal Krol2010-03-122-98/+0
|
* cso: Add entry points for vertex/fragment sampler views.Michal Krol2010-03-122-15/+167
|
* Merge branch 'master' into gallium-sampler-viewMichal Krol2010-03-104-2/+190
|\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/gallium/auxiliary/Makefile src/gallium/auxiliary/SConscript src/gallium/auxiliary/tgsi/tgsi_exec.c src/gallium/auxiliary/util/u_blitter.c src/gallium/drivers/i915/i915_context.h src/gallium/drivers/i965/brw_context.h src/gallium/drivers/llvmpipe/lp_context.h src/gallium/drivers/nv50/nv50_context.h src/gallium/drivers/nv50/nv50_state_validate.c src/gallium/drivers/nv50/nv50_tex.c src/gallium/drivers/r300/r300_blit.c src/gallium/drivers/r300/r300_context.h src/gallium/drivers/r300/r300_emit.c src/gallium/drivers/r300/r300_state.c src/gallium/drivers/softpipe/sp_context.h src/gallium/drivers/svga/svga_context.h src/gallium/drivers/svga/svga_pipe_sampler.c
| * cso: don't forget to release vertex elements stateRoland Scheidegger2010-03-091-0/+1
| |
| * cso: Fix typo in assert.Corbin Simpson2010-03-091-1/+1
| |
| * Merge branch 'gallium-vertexelementcso'Roland Scheidegger2010-03-094-3/+123
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/gallium/auxiliary/cso_cache/cso_context.c src/gallium/auxiliary/util/u_blit.c src/gallium/auxiliary/util/u_gen_mipmap.c src/gallium/drivers/i915/i915_context.h src/gallium/drivers/i965/brw_draw_upload.c src/gallium/drivers/r300/r300_blit.c src/gallium/drivers/r300/r300_context.h src/gallium/drivers/r300/r300_render.c src/gallium/drivers/r300/r300_state_derived.c src/mesa/state_tracker/st_cb_bitmap.c src/mesa/state_tracker/st_cb_clear.c
| | * auxiliary: fix vertex elements csoRoland Scheidegger2010-03-092-7/+19
| | | | | | | | | | | | | | | potentially could have got a match even though the cso was different (in case of different count and first few elements the same).
| | * gallium: use cso state handling for pipe_vertex_element stateRoland Scheidegger2010-02-184-2/+111
| | |
| * | cso: Track clip state with cso context.Michal Krol2010-02-242-0/+67
| |/
* / gallium: WIP: Introduce sampler views.Michal Krol2010-02-191-10/+68
|/
* gallium: give pipe_stencil_ref its own cso_save/restore functionsRoland Scheidegger2010-02-112-5/+16
| | | | seems cleaner, and other dynamic state like viewport is handled that way too
* gallium: also save/restore stencil_ref in cso_save/restore_depth_stencil_alphaRoland Scheidegger2010-02-111-3/+6
| | | | makes life of state trackers easier
* gallium: don't put stencil ref value in pipe_depth_stencil_alpha_stateRoland Scheidegger2010-02-092-0/+15
| | | | | | | | This will make driver's life a bit harder, however it makes sense that stencil reference value is not part of the pipe_depth_stencil_alpha_state, because it often (there are some algorithms which require this) changes more frequently than the rest of the dsa state. This is also encouraged by some graphic APIs. Treat it similar to pipe_blend_color.
* gallium: pipe/p_inlines.h -> util/u_inlines.hJosé Fonseca2010-02-021-0/+1
|
* gallium: fix blend state csoRoland Scheidegger2010-01-303-37/+20
| | | | | | | if independent blend state was disabled, only the data from first rt was stored, however the comparison used the full state, hence there never was a match and always a new object was created. Fixes a huge performance drop with llvmpipe due to recompilation.
* gallium: fix cast for size calc of pipe_blend_stateRoland Scheidegger2010-01-251-1/+1
|
* gallium: prepare for per-rendertarget blend enables, writemasks, blend funcsRoland Scheidegger2010-01-201-5/+8
| | | | | | | | GL 3.0 (EXT_draw_buffers2) and other APIs allow independent blend enables and write masks per render target, ARB_draw_buffers_blend (and other APIs) also allow independent blend functions. Things like dithering, logic ops however are not extended to be per rendertarget, that might be conceptually possible however it doesn't look like any API wants to expose this.
* cso: Add set_vertex_samplers functionJakob Bornecrantz2010-01-182-0/+36
|
* gallium: Generate a single library for auxiliaries with Make too.José Fonseca2010-01-011-11/+0
|
* scons: Aggregate all tiny libraries in a single library.José Fonseca2010-01-011-11/+0
| | | | | Makes integration of gallium into out of tree components much easier. No pratical change for components in this tree,
* gallium: add geometry shader support to galliumZack Rusin2009-12-252-2/+45
|
* cso: check if pipe_context::bind_vertex_sampler_states is non-nullBrian Paul2009-12-021-1/+2
| | | | Fixes segfaults upon exit when the CSO module is releasing its objects.
* cso: Fix function prototype.Michal Krol2009-12-011-1/+1
|
* cso: Add support for separate vertex sampler state.Michal Krol2009-12-012-4/+192
|
* gallium: Move enum pipe_error into p_defines.h.José Fonseca2009-10-251-1/+1
| | | | It's really just another define. No need for its own header.
* gallium: replace // comments with /* */Brian Paul2009-10-021-1/+1
|
* gallium: rearrange some members to avoid memory holes/paddingZack Rusin2009-07-061-2/+2
| | | | plus it saves us a cacheline in the cso
* cso: possible null pointer dereferenceZack Rusin2009-07-061-0/+4
| | | | reported by clang static analyzer
* gallium: Remove some superfluous instances of #include "p_inlines.h".Michel Dänzer2009-03-041-1/+0
|
* gallium: Improve makefiles for librariesJakob Bornecrantz2009-02-201-3/+0
| | | | | | | | The template makefile that most libraries in gallium included was based on dri and had a bunch unrelevant junk in it. Update it and improve the depending makefiles.
* util: Move p_debug.h into util module.José Fonseca2009-02-182-2/+2
| | | | | The debug functions depend on several util function for os abstractions, and these depend on debug functions, so a seperate module is not possible.