summaryrefslogtreecommitdiffstats
path: root/src/gallium/auxiliary/util
Commit message (Collapse)AuthorAgeFilesLines
* gallium/util: add S8 tile sampling support.Dave Airlie2010-10-131-0/+27
|
* gallium/format: add X32_S8X24_USCALED format.Dave Airlie2010-10-133-0/+27
| | | | Has similiar use cases to the S8X24 and X24S8 formats.
* gallium/format: add support for X24S8 and S8X24 formats.Dave Airlie2010-10-134-0/+102
| | | | | | these formats are needed for hw that can sample and write stencil values. Signed-off-by: Dave Airlie <[email protected]>
* gallium: move sse intrinsics debug helpers to u_sse.hKeith Whitwell2010-10-121-1/+79
|
* util: Defined M_SQRT2 when not available.José Fonseca2010-10-091-0/+5
|
* util: Cleanup util_pack_z_stencil and friends.José Fonseca2010-10-061-22/+28
| | | | | | | | | | | - Handle PIPE_FORMAT_Z32_FLOAT packing correctly. - In the integer version z shouldn't be passed as as double. - Make it clear that the integer versions should only be used for masks. - Make integer type sizes explicit (uint32_t for now, although uint64_t will be necessary later to encode f32_s8_x24).
* Revert "Prefer intrinsics to handrolled atomic ops."Tom Fogal2010-09-301-2/+2
| | | | | This reverts commit 5f66b340aa49c6bc8d0acb2d1a6f8e9a7ef2cb2e, quickly fixing 30514.
* Prefer intrinsics to handrolled atomic ops.Tom Fogal2010-09-301-2/+2
|
* Implement x86_64 atomics for compilers w/o intrinsics.Tom Fogal2010-09-301-0/+47
| | | | | Really old gcc's (3.3, at least) don't have support for the intrinsics we need. This implements a fallback for that case.
* gallium/util: remove duplicated includeNicolas Kaiser2010-09-301-2/+0
| | | | | | Remove duplicated include. Signed-off-by: Brian Paul <[email protected]>
* util/u_blitter: fix leakJoakim Sindholt2010-09-261-1/+1
|
* util: fix util_pack_color for B4G4R4A4Marek Olšák2010-09-251-1/+1
| | | | NOTE: This is a candidate for the 7.9 branch.
* util: make calling remove_from_list multiple times in a row safeMarek Olšák2010-09-241-0/+2
| | | | | | | | | This commit fixes an infinite loop in foreach_s if remove_from_list is used more than once on the same item with other list operations in between. NOTE: This is a candidate for the 7.9 branch because the commit "r300g: fixup long-lived BO maps being incorrectly unmapped when flushing" depends on it.
* u_blitter: add a custom blitter call passing a dsa csoDave Airlie2010-09-232-14/+37
| | | | | reimplement the flush stage added for r300 to allow a custom DSA stage to be used in the pipeline, this allows for r600 hw DB->CB flushes.
* util/r300g: split the r300 index buffer modifier functions out to utilDave Airlie2010-09-202-0/+168
| | | | | | These can be used by other drivers, like r600g. Signed-off-by: Dave Airlie <[email protected]>
* auxiliary: fix depth-only and stencil-only clearsLuca Barbieri2010-09-191-1/+1
| | | | | | | Depth-only and stencil-only clears should mask out depth/stencil from the output, mask out stencil/input from input, and OR or ADD them together. However, due to a typo they were being ANDed, resulting in zeroing the buffer.
* util: linearized sRGB values don't fit into 8bitsJosé Fonseca2010-09-171-0/+8
| | | | Fixes glean texture_srgb test.
* auxiliary: fix unintended fallthroughLuca Barbieri2010-09-141-0/+1
|
* gallium: introduce get_shader_param (ALL DRIVERS CHANGED) (v3)Luca Barbieri2010-09-143-11/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes in v3: - Also change trace, which I forgot about Changes in v2: - No longer adds tessellation shaders Currently each shader cap has FS and VS versions. However, we want a version of them for geometry, tessellation control, and tessellation evaluation shaders, and want to be able to easily query a given cap type for a given shader stage. Since having 5 duplicates of each shader cap is unmanageable, add a new get_shader_param function that takes both a shader cap from a new enum and a shader stage. Drivers with non-unified shaders will first switch on the shader and, within each case, switch on the cap. Drivers with unified shaders instead first check whether the shader is supported, and then switch on the cap. MAX_CONST_BUFFERS is now per-stage. The geometry shader cap is removed in favor of checking whether the limit of geometry shader instructions is greater than 0, which is also used for tessellation shaders. WARNING: all drivers changed and compiled but only nvfx tested
* util: Helper function to determined whether two formats can be memcpy'ed.José Fonseca2010-09-052-4/+61
| | | | | | | | | | | | | | | | | | | | | | | | | | | These are the non-trivial conversions that this function recognizes, which was produced by u_format_compatible_test.c: b8g8r8a8_unorm -> b8g8r8x8_unorm a8r8g8b8_unorm -> x8r8g8b8_unorm b5g5r5a1_unorm -> b5g5r5x1_unorm b4g4r4a4_unorm -> b4g4r4x4_unorm l8_unorm -> r8_unorm i8_unorm -> l8_unorm i8_unorm -> a8_unorm i8_unorm -> r8_unorm l16_unorm -> r16_unorm z24_unorm_s8_uscaled -> z24x8_unorm s8_uscaled_z24_unorm -> x8z24_unorm r8g8b8a8_unorm -> r8g8b8x8_unorm a8b8g8r8_srgb -> x8b8g8r8_srgb b8g8r8a8_srgb -> b8g8r8x8_srgb a8r8g8b8_srgb -> x8r8g8b8_srgb a8b8g8r8_unorm -> x8b8g8r8_unorm r10g10b10a2_uscaled -> r10g10b10x2_uscaled r10sg10sb10sa2u_norm -> r10g10b10x2_snorm State trackers and pipe drivers should be updated to take advantage of this knowledge, e.g., in surface_copy.
* util: Utility function to determine the channels that can be written in a ↵José Fonseca2010-09-051-0/+33
| | | | color format.
* util: Include missing header in u_linear.h.Vinson Lee2010-09-021-0/+1
| | | | Include p_compiler.h for size_t and boolean symbols.
* util: Include missing header in u_draw.h.Vinson Lee2010-08-281-0/+1
| | | | Include p_state.h for complete type to pipe_draw_info.
* util: Add forward declaration in u_transfer.h.Vinson Lee2010-08-281-0/+1
|
* r300g,u_blitter: use u_framebufferMarek Olšák2010-08-292-35/+3
| | | | Removing another function duplication in u_blitter.
* util: remove util_is_pot in favor of util_is_power_of_twoMarek Olšák2010-08-291-10/+0
| | | | The function was duplicated.
* util: fix typo in MAX4Keith Whitwell2010-08-271-1/+1
| | | | Thanks to Michal for spotting it.
* util: add MIN4, MAX4Keith Whitwell2010-08-271-0/+3
|
* util: Include missing header in u_simple_shaders.c.Vinson Lee2010-08-261-0/+1
| | | | Include p_state.h for PIPE_MAX_COLOR_BUFS symbol.
* util: Include missing header in u_blit.h.Vinson Lee2010-08-251-5/+7
| | | | | Include p_compiler.h for uint symbol. Clean up forward declarations.
* util: Include missing header in u_bitmask.h.Vinson Lee2010-08-251-0/+3
| | | | Include p_compiler.h for boolean symbol.
* util: Include missing header in u_dirty_surfaces.h.Vinson Lee2010-08-251-0/+4
| | | | Include p_state.h for pipe_surface symbol.
* util: Add include guard in u_split_prim.h.Vinson Lee2010-08-251-0/+6
|
* util: Include missing headers in u_split_prim.h.Vinson Lee2010-08-251-1/+4
| | | | | Include p_compiler.h for boolean symbol. Include u_debug.h for assert symbol.
* util: Include missing headers in u_tile.h.Vinson Lee2010-08-251-0/+3
| | | | | Include p_format.h for enum pipe_format symbol. Include p_state.h for pipe_box symbol.
* util: Clean up header file inclusion in u_upload_mgr.h.Vinson Lee2010-08-251-4/+1
| | | | | | Remove p_defines.h. Remove unnecessary forward declarations. Add forward declaration for pipe_context.
* util: add rectangle helpers to u_rect.hKeith Whitwell2010-08-251-4/+53
| | | | | | This begins a process of repurposing this file. The existing usage is as a header file for some software blit fallbacks, which should be moved to a more appropriately named header.
* auxiliary: fix nvfx/nv50 primitive splitting for line loopsLuca Barbieri2010-08-231-1/+1
| | | | | | | s->close_first was on the wrong side of the inequality. Caught by blender. Thanks to AndrewR for reporting this.
* util: fix util_fill_rect to take util_color instead of u32 paramRoland Scheidegger2010-08-234-61/+47
| | | | | | | | util_fill_rect could not handle formats with more than 32 bits, since the fill color was a uint32_t value. Fix this by using a util_color union instead, and also expand the union so it works with formats which have up to 256 bits (the max of any format currently defined).
* nvfx: support clip planes sensibly and fix them on nv30Luca Barbieri2010-08-231-0/+3
| | | | | | | | | | Before, we were discarding the compiled vertex program on each vertex program change. Now we compile the program as if there were 6 clip planes and dynamically patch in an "end program" bit at the right place. Also, nv30 should now work.
* util: implement depth blitting in u_blitMarek Olšák2010-08-221-17/+43
| | | | Signed-off-by: Brian Paul <[email protected]>
* util: Use #ifdef instead of #if.Vinson Lee2010-08-211-1/+1
| | | | This is a typo fix of earlier commit 0f3b3751b8643352dcc242567b3696bd1505df1d.
* util: Define dump_cpu only for DEBUG builds.Vinson Lee2010-08-211-0/+2
| | | | | | | dump_cpu is used only when DEBUG is defined. Fixes the following GCC warning on builds without DEBUG defined. util/u_cpu_detect.c:76: warning: 'debug_get_option_dump_cpu' defined but not used
* util: Silence uninitialized variable warnings.Vinson Lee2010-08-211-0/+4
|
* util: Move loop variable declaration outside for loop.Vinson Lee2010-08-211-1/+2
| | | | Fixes build error with MSVC.
* gallium/auxiliary: add semantic linkage utility codeLuca Barbieri2010-08-212-0/+210
|
* u_debug_describe: use switch instead of if chainLuca Barbieri2010-08-211-7/+17
|
* u_debug_describe: add PIPE_TEXTURE_RECTLuca Barbieri2010-08-211-0/+2
|
* auxiliary: add copyright headersLuca Barbieri2010-08-219-5/+232
| | | | Thanks to Jose Fonseca for pointing out they were missing.
* util: Match printf format to silence warning.José Fonseca2010-08-211-1/+1
|