aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/state_tracker/st_atom_blend.c
Commit message (Collapse)AuthorAgeFilesLines
* st/mesa: disable alpha-test, alpha-to-coverage, alpha-to-one for integer FBsMarek Olšák2016-10-191-1/+2
| | | | | | v2: rebased Reviewed-by: Brian Paul <[email protected]>
* st/mesa: only enable MSAA coverage options when we have a MSAA bufferBrian Paul2016-09-161-3/+5
| | | | | | | | | | | | | | | | | Regardless of whether GL_MULTISAMPLE is enabled (it's enabled by default) we should not set the alpha_to_coverage or alpha_to_one flags if the current drawing buffer does not do MSAA. This fixes the new piglit gl-1.3-alpha_to_coverage_nop test. ETQW is a game that enables GL_SAMPLE_ALPHA_TO_COVERAGE without MSAA. Shrubs along the side of roads were invisible because fragments with alpha < 0.5 were being discarded (zero coverage). v2: remove ctx->DrawBuffer != NULL check. Reviewed-by: Roland Scheidegger <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* st/mesa: completely rewrite state atomsMarek Olšák2016-07-301-4/+0
| | | | | | | | | | | | | | | | | | | | The goal is to do this in st_validate_state: while (dirty) atoms[u_bit_scan(&dirty)]->update(st); That implies that atoms can't specify which flags they consume. There is exactly one ST_NEW_* flag for each atom. (58 flags in total) There are macros that combine multiple flags into one for easier use. All _NEW_* flags are translated into ST_NEW_* flags in st_invalidate_state. st/mesa doesn't keep the _NEW_* flags after that. torcs is 2% faster between the previous patch and the end of this series. v2: - add st_atom_list.h to Makefile.sources Reviewed-by: Nicolai Hähnle <[email protected]>
* st/mesa: remove st_tracked_state::nameMarek Olšák2016-07-301-1/+0
| | | | Reviewed-by: Nicolai Hähnle <[email protected]>
* mesa: Fix some signed-unsigned comparison warningsJan Vesely2015-01-211-1/+1
| | | | | | | | v2: s/unsigned int/unsigned/ in prog_optimize.c Signed-off-by: Jan Vesely <[email protected]> Reviewed-by: David Heidelberg <[email protected]> Reviewed-by: Jose Fonseca <[email protected]>
* st/mesa: minor simplification of some state atom assignmentsBrian Paul2014-07-091-6/+3
|
* s/Tungsten Graphics/VMware/José Fonseca2014-01-171-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Tungsten Graphics Inc. was acquired by VMware Inc. in 2008. Leaving the old copyright name is creating unnecessary confusion, hence this change. This was the sed script I used: $ cat tg2vmw.sed # Run as: # # git reset --hard HEAD && find include scons src -type f -not -name 'sed*' -print0 | xargs -0 sed -i -f tg2vmw.sed # # Rename copyrights s/Tungsten Gra\(ph\|hp\)ics,\? [iI]nc\.\?\(, Cedar Park\)\?\(, Austin\)\?\(, \(Texas\|TX\)\)\?\.\?/VMware, Inc./g /Copyright/s/Tungsten Graphics\(,\? [iI]nc\.\)\?\(, Cedar Park\)\?\(, Austin\)\?\(, \(Texas\|TX\)\)\?\.\?/VMware, Inc./ s/TUNGSTEN GRAPHICS/VMWARE/g # Rename emails s/[email protected]/[email protected]/ s/[email protected]/[email protected]/g s/jrfonseca-at-tungstengraphics-dot-com/jfonseca-at-vmware-dot-com/ s/jrfonseca\[email protected]/[email protected]/g s/keithw\[email protected]/[email protected]/g s/[email protected]/[email protected]/g s/thomas-at-tungstengraphics-dot-com/thellstom-at-vmware-dot-com/ s/[email protected]/[email protected]/ # Remove dead links s@Tungsten Graphics (http://www.tungstengraphics.com)@Tungsten Graphics@g # C string src/gallium/state_trackers/vega/api_misc.c s/"Tungsten Graphics, Inc"/"VMware, Inc"/ Reviewed-by: Brian Paul <[email protected]>
* st/mesa: add ARB_blend_func_extended support to state tracker.Dave Airlie2012-04-131-4/+4
| | | | | | | | This adds the blend mode mapping, it also uses the var->index in the glsl to tgsi convertor - this is the other half of my using 4 in the GLSL compiler. Signed-off-by: Dave Airlie <[email protected]>
* st/mesa: Remove support for GL_EXT_blend_logic_opIan Romanick2011-09-191-9/+1
| | | | | | | | | | It was broken, and it isn't really useful anyway. Signed-off-by: Ian Romanick <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]> Reviewed-by: Eric Anholt <[email protected]> Reviewed-by: Marek Olšák <[email protected]> Cc: Brian Paul <[email protected]>
* st/mesa: replace st->ctx with ctxBrian Paul2011-06-141-30/+31
|
* gallium: implement clamping controls (ARB_color_buffer_float)Luca Barbieri2011-03-291-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | BTW this changes the gallium interface. Some rather cosmetic changes by Marek. Squashed commit of the following: commit 513b37d484f0318311e84bb86ed4c93cdff71f13 Author: Luca Barbieri <[email protected]> Date: Thu Aug 26 18:17:54 2010 +0200 mesa/st: respect fragment clamping in st_DrawPixels commit 546a31e42cad459d7a7a10ebf77fc5ffcf89e9b8 Author: Luca Barbieri <[email protected]> Date: Thu Aug 26 18:17:28 2010 +0200 mesa/st: support fragment and vertex color clamping commit c406514a1fbee6891da4cf9ac3eebe4e4407ec13 Author: Luca Barbieri <[email protected]> Date: Tue Aug 24 21:56:37 2010 +0200 mesa/st: expose ARB_color_buffer_float if unclamping is supported commit d0c5ea11b6f75f3da2f4ca989115f150ebc7cf8d Author: Luca Barbieri <[email protected]> Date: Thu Aug 26 17:53:41 2010 +0200 mesa/st: use unclamped colors This assumes that Gallium is to be interpreted as given drivers the responsibility to clamp these colors if necessary. commit aef5c3c6be6edd076e955e37c80905bc447f8a82 Author: Luca Barbieri <[email protected]> Date: Thu Aug 26 18:12:34 2010 +0200 mesa, mesa/st: handle read color clamping properly We set IMAGE_CLAMP_BIT in the caller based on _ClampReadColor, where the operation mandates it. (see the removed XXX comment. -Marek) TODO: did I get the set of operations mandating it right? commit 76bdfcfe3ff4145a1818e6cb6e227b730a5f12d8 Author: Luca Barbieri <[email protected]> Date: Thu Aug 26 18:18:25 2010 +0200 gallium: add color clamping to the interface
* st/mesa: Use blend equation and function of first render target for all ↵Fabian Bieler2011-02-141-8/+11
| | | | | | | | | | | render targets if ARB_draw_buffers_blend is not supported If EXT_draw_buffers2 is supported but ARB_draw_buffers_blend isn't _mesa_BlendFuncSeparateEXT only sets up the blend equation and function for the first render target. This patch makes sure that update_blend doesn't try to use the data from other rendertargets in such cases. Signed-off-by: Brian Paul <[email protected]>
* mesa: begin implementation of GL_ARB_draw_buffers_blendBrian Paul2011-01-151-12/+25
|
* Drop GLcontext typedef and use struct gl_context insteadKristian Høgsberg2010-10-131-2/+2
|
* mesa/st: adapt to interface changesRoland Scheidegger2010-05-171-1/+10
| | | | | adapt to blit changes, and also handle a bit more msaa state in theory (incomplete, doesn't handle resolves in any way for now).
* mesa/st: code cleanups for new blend functionalityRoland Scheidegger2010-01-261-9/+23
| | | | minor code changes, style and comment fixes
* st/mesa: handle EXT_draw_buffers2 per rendertarget blend enables / colormasksRoland Scheidegger2010-01-251-31/+62
| | | | uses the new gallium per-rt blend functionality
* gallium: prepare for per-rendertarget blend enables, writemasks, blend funcsRoland Scheidegger2010-01-201-15/+15
| | | | | | | | 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.
* mesa: implement per-buffer color maskingBrian Paul2009-12-291-4/+4
| | | | | | | | | | | This is part of the GL_EXT_draw_buffers2 extension and part of GL 3.0. The ctx->Color.ColorMask field is now a 2-D array. Until drivers are modified to support per-buffer color masking, they can just look at the 0th color mask. The new _mesa_ColorMaskIndexed() function will be called by glColorMaskIndexedEXT() or glColorMaski().
* revert mode change back to 644Alan Hourihane2008-05-021-0/+0
|
* Some changed for non-C99 compilersAlan Hourihane2008-05-021-10/+5
|
* gallium: implement CSO save/restore functions for use by meta operations ↵Brian2008-03-191-7/+5
| | | | | | | (blit, gen-mipmaps, quad-clear, etc) Also, additional cso_set_*() functions for viewport, framebuffer, blend color, etc. state.
* gallium: rework CSO-related code in state trackerBrian2008-03-111-30/+22
| | | | | | | | | | Use the code in cso_context.c rather than st_cache.c. Basically, binding of state objects now goes through the CSO module. But Vertex/fragment shaders go through pipe->bind_fs/vs_state() since they're not cached by the CSO module at this time. Also, update softpipe driver to handle NULL state objects in various places. This happens during context destruction. May need to update other drivers...
* fix blend term translation bug, rename some funcsBrian2007-10-161-13/+13
|
* Avoid redundant reallocation of the template.Zack Rusin2007-09-191-2/+2
| | | | | | cso already allocated the template for us. Returning 0 means we have no driver specific representation and just want the template on the bind.
* Redo the cso cache to map driver data in a lot more pleasing way.Zack Rusin2007-09-191-4/+4
| | | | | | Drivers can now create whatever they want from the state template. We use cso_state object to store the template (necessary during lookups), and the driver data. Convert blend state to the new semantics.
* Implementing a better hash, removing state_tracker dependency from the cache.Zack Rusin2007-09-181-2/+3
| | | | | Replacing mesa's main hash with one that handles collisions, moving state_tracker related caching to the state tracker to keep cso cache independent of it. Cleanups.
* First stab at immutable state objects (create/bind/delete)Zack Rusin2007-09-181-3/+8
| | | | | | | We want our state objects to be immutable, handled via the create/bind/delete calls instead of struct propagation. Only implementing the blend state to see how it would look like and work.
* add names to tracked state atoms to improve debugkeithw2007-08-251-0/+1
|
* Added colormask, dither, multisample state. Implement colormasking stage.Brian2007-07-121-0/+13
|
* hook in state tracking for blend colorBrian2007-07-031-0/+9
|
* Blend MIN/MAX modes are special: the src/dest terms are always one.Brian2007-07-031-4/+20
|
* Rename directories again?!Keith Whitwell2007-06-141-46/+46
| | | | Some git wierdness going on.
* Renamed softpipe directories and files to something less confusing.Keith Whitwell2007-06-141-0/+202
softpipe/state_tracker --> state_tracker/ softpipe/ --> pipe/ softpipe/generic --> pipe/softpipe/ I don't think pipe is a great name, but I disliked all the others too. Luckily it's fairly easy to rename with git, so this can be revisited later.