summaryrefslogtreecommitdiff
path: root/src/mesa/main/colormac.h
AgeCommit message (Collapse)AuthorFilesLines
2013-06-05mesa: remove outdated version lines in commentsRico Schüller1-1/+0
Signed-off-by: Brian Paul <brianp@vmware.com>
2013-04-23mesa: Restore 78-column wrapping of license text in C-style comments.Kenneth Graunke1-3/+4
The previous commit introduced extra words, breaking the formatting. This text transformation was done automatically via the following shell command: $ git grep 'THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY' | sed 's/:.*$//' | xargs -I {} sh -c 'vim -e -s {} < vimscript where 'vimscript' is a file containing: /THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY/;/\*\// !fmt -w 78 -p ' * ' :wq Reviewed-by: Brian Paul <brianp@vmware.com>
2013-04-23mesa: Add "OR COPYRIGHT HOLDERS" to license text disclaiming liability.Kenneth Graunke1-1/+1
This brings the license text in line with the MIT License as published on the Open Source Initiative website: http://opensource.org/licenses/mit-license.php Generated automatically be the following shell command: $ git grep 'THE AUTHORS BE LIABLE' | sed 's/:.*$//g' | xargs -I '{}' \ sed -i 's/THE AUTHORS/THE AUTHORS OR COPYRIGHT HOLDERS/' {} This introduces some wrapping issues, to be fixed in the next commit. Reviewed-by: Brian Paul <brianp@vmware.com>
2013-04-23mesa: Change "BRIAN PAUL" to "THE AUTHORS" in license text.Kenneth Graunke1-1/+1
Generated automatically be the following shell command: $ git grep 'BRIAN PAUL BE LIABLE' | sed 's/:.*$//g' | xargs -I '{}' \ sed -i 's/BRIAN PAUL/THE AUTHORS/' {} The intention here is to protect all authors, not just Brian Paul. I believe that was already the sensible interpretation, but spelling it out is probably better. More practically, it also prevents people from accidentally copy & pasting the license into a new file which says Brian is not liable when he isn't even one of the authors. Reviewed-by: Brian Paul <brianp@vmware.com>
2011-09-20mesa: fix PACK_COLOR_5551(), PACK_COLOR_1555() macrosBrian Paul1-2/+2
The 1-bit alpha channel was incorrectly encoded. Previously, any non-zero alpha value for the ubyte alpha value would set A=1. Instead, use the most significant bit of the ubyte alpha to determine the A bit. This is consistent with the other channels and other OpenGL implementations. Note: This is a candidate for the 7.11 branch. Reviewed-by: Michel Dänzer <michel@daenzer.net>
2011-09-20mesa: move last bits of GLchan stuff into swrastBrian Paul1-75/+0
This removes the last remnants of the GLchan datatype and associated macros out of core Mesa and into swrast.
2011-09-20mesa: remove unused UNCLAMPED_FLOAT_TO_RGB_CHAN() macroBrian Paul1-16/+0
2011-09-20mesa: remove unused <type>_TO_CHAN() macrosBrian Paul1-40/+0
2011-09-14mesa: minor clean-up on _mesa_unclamped_float_rgba_to_ubyte()Brian Paul1-1/+7
Add a comment and reformat to be under 80 columns.
2011-09-14mesa/colormac: introduce inline helper for 4 unclamped float to ubyte.Dave Airlie1-1/+6
This introduces an UNCLAMPED_FLOAT_TO_UBYTE x 4 inline function, as suggested by Brian. It uses it in a few places I noticed from previous color changes, and also some core mesa places. I haven't updated other places yet. Signed-off-by: Dave Airlie <airlied@redhat.com>
2011-08-31mesa: fix broken store_texel() functionsBrian Paul1-0/+6
This fixes the swrast failures for piglit's fbo-generatemipmap-formats test (for uncompressed formats). At some point down the road this code will go away so I haven't checked all the other store_texel() functions.
2011-01-04mesa: preserve 10 bits of precision in the texstore general path for ARGB2101010Marek Olšák1-1/+5
Use make_temp_float_image instead of _make_temp_chan_image. The latter converts the texture to 8 bits/component, losing 2 bits.
2010-12-23mesa: implement new texture format AL44Marek Olšák1-0/+3
Radeon GPUs can do this. R600 can even do render-to-texture. Packing and extracting aren't implemented, but we shouldn't hit them (I think). Tested with swrast, softpipe, and r300g.
2010-12-23mesa: implement new texture format ARGB2101010Marek Olšák1-0/+4
Radeon GPUs do support GL_RGB10_A2.
2010-07-30mesa: Remove unnecessary header from colormac.h.Vinson Lee1-1/+1
2009-11-16AL1616: Add macros to pack two GLushorts into a texelIan Romanick1-0/+6
2009-10-05mesa: add parenthesisBrian Paul1-7/+7
2009-04-01swrast: do texture sampling/combining in floating pointBrian Paul1-9/+0
The code's cleaner and a step toward supporting float-valued texture sampling. Some optimizations for common cases can be added and re-enabled...
2009-01-20Add RGBA4444 and RGBA5551 texture formats.Thomas Hellstrom1-0/+4
2008-10-10mesa: rename macro params to emphasize that there's no particular color orderingBrian Paul1-12/+12
2004-09-09Update the doxygen configuration file.Jose Fonseca1-0/+2
Minor updates/fixes to the source documentation.
2004-06-19Big-endian texture fixes from Michel Dänzer.Brian Paul1-5/+15
2004-05-12Added big-endian texture formats.Brian Paul1-55/+31
Moved CI->RGBA palette lookup into texel fetch function.
2003-07-17Merge Jose's documentation and core Mesa changes from embedded branchKeith Whitwell1-11/+59
2003-06-05Removed all RCS / CVS tags (Id, Header, Date, etc.) from everything.Ian Romanick1-1/+0
2003-03-01Killed mmath.[ch]. Moved low-level functions/assembly code into imports.[ch]Brian Paul1-7/+63
Moved type conversion and interpolation macros into macros.h Updated all the files that used to include mmath.h
2002-04-04fixup float/ushort conversion macrosBrian Paul1-7/+5
2001-07-16Various 16-bit GLchan fixes and Win32 fixes (Gerk Huisma)Brian Paul1-2/+2
2001-03-11Support for swappable tnl modules.Gareth Hughes1-2/+5
Core Mesa provides a neutral tnl module that verifies the currently module before installing the tnl function pointers in a lazy fashion. It also records which tnl functions have been swapped out, and only restores these when tnl modules themselves are swapped. Fallback strategies: Drivers set a bitmask of dangerous stage changes. When such a state change occurs, the driver should restore the neutral tnl module via _mesa_restore_exec_vtxfmt(). The neutral tnl module will call _mesa_update_state(), followed by ctx->Driver.ValidateTnlModule() if the validation bitmask matches the new state bitmask. The driver should call _tnl_wakeup_exec() if it can no longer handle the current state, which will revert to the default tnl module. In this case, previous vertices should be replayed as required (depending on the current primitive) after the new tnl module is installed. If the driver uses chooser functions for any part of the tnl module, these should generally be reinstalled as part of the fallback to the neutral tnl module. For example, if the lighting state changes, a driver might fall back to the neutral tnl module, verify that the current lighting state can be handled, and use the chooser function to pick the most efficient implementation of the current lighting state. It is up to the drivers to detect and handle fallback cases caused by tnl function calls themselves (such as glTexCoord4f* if the current tnl module can't handle projected textures, for example).
2001-03-08More g++ warning fixes. Fixes for CHAN_BITS==16, it seems to work.Brian Paul1-2/+2
2001-03-07added some casts in the 16-bit GLchan macros, just to be safeBrian Paul1-4/+4
2001-01-03More color macro clean-ups.Brian Paul1-7/+16
FLOAT_TO_CHAN() macro removed.
2001-01-02Removed fixed.h (GLfixed now in mtypes.h, fixed-pt macros in mmath.h)Brian Paul1-94/+24
Clean-up of color conversion macros. New mmath.h macros (IROUND, IFLOOR, ICEIL, FRAC) used in various places.
2000-11-24Support for swappable t&l modules, including an example one in the FXKeith Whitwell1-2/+2
driver (enable with FX_ALLOW_VTXFMT=t).
2000-11-16Move the transform and lighting code to two new directoriesKeith Whitwell1-2/+3
math: Provides basic matrix and vector functionality that might be useful to multiple software t&l implementations, and is used by core mesa to manage the Model, Project, etc matrices. tnl: The real transform & lighting code from core mesa, including everything from glVertex3f through vertex buffer handling, transformation, clipping, lighting and handoff to a driver for rasterization. The interfaces of these can be further tightened up, but the basic splitting up of state and code move is done.
2000-10-29More GLchan color channel changes.Brian Paul1-1/+9
Some header file re-org: Move matrix, vertex buffer structs to types.h to fix #include mess. Remove typedef, extern declarations from config.h
2000-10-28New colormac.h file for color-related macros.Brian Paul1-0/+187
Lot's of clean-up in macros.h and mmath.h