summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/softpipe
Commit message (Collapse)AuthorAgeFilesLines
* gallium: add an interface for EXT_depth_bounds_testMarek Olšák2015-08-141-0/+1
| | | | | Reviewed-by: Roland Scheidegger <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* gallium: add support for GLES texture float extensions (v3)Marek Olšák2015-08-141-0/+2
| | | | | | | | | | | | Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=74329 v2: add a CAP for half floats drivers should not expose the CAPs if they don't support the formats v3: update relnotes Reviewed-by: Edward O'Callaghan <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* gallium: replace INLINE with inlineIlia Mirkin2015-07-2113-51/+51
| | | | | | | | | | | | | | | | Generated by running: git grep -l INLINE src/gallium/ | xargs sed -i 's/\bINLINE\b/inline/g' git grep -l INLINE src/mesa/state_tracker/ | xargs sed -i 's/\bINLINE\b/inline/g' git checkout src/gallium/state_trackers/clover/Doxyfile and manual edits to src/gallium/include/pipe/p_compiler.h src/gallium/README.portability to remove mentions of the inline define. Signed-off-by: Ilia Mirkin <[email protected]> Acked-by: Marek Olšák <[email protected]>
* gallium: add PIPE_CAP_MAX_SHADER_PATCH_VARYINGSMarek Olšák2015-07-161-0/+1
| | | | Reviewed-by: Ilia Mirkin <[email protected]>
* gallium: remove redundant pipe_context::fence_signalledMarek Olšák2015-07-051-10/+0
| | | | | | fence_finish(timeout=0) does the same thing Reviewed-by: Brian Paul <[email protected]>
* softpipe/query: force parenthesis around a logical notMartin Peres2015-06-081-1/+1
| | | | | | | This makes GCC5 happy. Reviewed-by: Brian Paul <[email protected]> Signed-off-by: Martin Peres <[email protected]>
* softpipe: fix offset wrapping calculations (v2)Dave Airlie2015-05-291-78/+68
| | | | | | | | | | | | | | | Roland pointed out my previous attempt was lacking, so I enhanced the texwrap piglit test, and tested them. This fixes the offset calculations in a number of areas by adding the offset first, it also fixes the fastpaths, which I forgot to address in the previous commit. v2: try and avoid divides in most paths, the repeat mirror path really was ugly no matter which way I went, so I left it having the divide. Also fix the gather lod calculation bug. Reviewed-by: Roland Scheidegger <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
* softpipe: start adding gather support (v2)Dave Airlie2015-05-203-83/+210
| | | | | | | | | | | | | | This adds both ARB_texture_gather and the enhanced gather for ARB_gpu_shader5. This passes all the piglit tests, it relies on the GLSL lowering pass to make textureGatherOffsets work. v2: use inline to get gather component (Brian) fix function name, add asserts (Brian) Reviewed-by: Brian Paul <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
* softpipe: use arrays to make gather easierDave Airlie2015-05-201-36/+36
| | | | | | | | This is a prep change for gather, and it makes more sense to use an array in these cases. Reviewed-by: Brian Paul <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
* softpipe: add textureOffset support.Dave Airlie2015-05-202-62/+97
| | | | | | | | | | | | | | This was an oversight when GLSL1.30 was enabled, I think my misunderstanding. This fixes a bunch of tex-miplevel-selection tests under softpipe, and is required for textureGather support. I'm not sure this won't make sampling slowering, but its softpipe, correctness first and all that. Reviewed-by: Brian Paul <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
* softpipe: move control into a filter args structDave Airlie2015-05-202-26/+32
| | | | | | | more stuff for offsets and gather will go in here later. Reviewed-by: Brian Paul <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
* softpipe: move some image filter parameters into a structDave Airlie2015-05-202-258/+224
| | | | | | | | | | | This moves some of the image filter args into a struct, and passes that instead, this is prep work for adding texture gather support which needs new arguments. review: make filter args const. Reviewed-by: Brian Paul <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
* gallium/drivers: Add extern "C" wrappers to public entryAlexander von Gluck IV2015-05-151-0/+8
| | | | Reviewed-by: Brian Paul <[email protected]>
* softpipe: enable ARB_texture_viewRoland Scheidegger2015-05-135-124/+179
| | | | | | | | | | | | | | | | | | | | | | Some bits were already there for texture views but some were missing. In particular for cube map views things needed to change a bit. For simplicity I ended up removing the separate face addr bit (just use the z bit) - cube arrays didn't use it already, so just follow the same logic there. (In theory using separate bits could allow for better hash function but I don't think anyone ever did some measurements of that so probably not worth the trouble, if we'd reintroduce it we'd certainly wanted to use the same logic for cube arrays and cube maps.) Also extend the seamless cube sampling to cube arrays - as there were no piglit failures before this is apparently untested, but things now generally work quite the same for cube textures and cube array textures so there hopefully shouldn't be any trouble... 49 new piglits, 47 pass, 2 fail (both due to fake multisampling). v2: incorporate Brian's feedback, add sampler view validation, function rename, formatting fixes. Reviewed-by: Brian Paul <[email protected]>
* gallium: add PIPE_CAP_DEVICE_RESET_STATUS_QUERYMarek Olšák2015-05-121-0/+1
| | | | Reviewed-by: Kenneth Graunke <[email protected]>
* gallium: make pipe_context::begin_query return a booleanSamuel Pitoiset2015-05-061-1/+2
| | | | | | | | | GL_AMD_performance_monitor must return an error when a monitoring session cannot be started. Signed-off-by: Samuel Pitoiset <[email protected]> Reviewed-by: Marek Olšák <[email protected]> Reviewed-by: Martin Peres <[email protected]>
* softpipe: fix stencil write to use an integer valueDave Airlie2015-04-231-1/+1
| | | | | | | | | | | This fixes a number of regressions since 61393bdcdc3b63624bf6e9730444f5e9deeedfc8 u_tile: fix stencil texturing tests under softpipe Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=89960 Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
* gallium: implement get_device_vendor() for existing driversGiuseppe Bilotta2015-03-231-0/+1
| | | | | | | | | The only hackish ones are llvmpipe and softpipe, which currently return the same string as for get_vendor(), while ideally they should return the CPU vendor. Signed-off-by: Giuseppe Bilotta <[email protected]> Reviewed-by: Tom Stellard <[email protected]>
* softpipe,trace: Set MSVC 2008 compat flags.Jose Fonseca2015-03-042-1/+3
| | | | | | Although we don't deploy these, we need to use them for debugging. Reviewed-by: Brian Paul <[email protected]>
* mesa: Use assert() instead of ASSERT wrapper.Matt Turner2015-02-231-1/+1
| | | | Acked-by: Eric Anholt <[email protected]>
* llvmpipe,softpipe: only support ETC1, not the upcoming ETC2Ilia Mirkin2015-02-181-0/+4
| | | | Signed-off-by: Ilia Mirkin <[email protected]>
* gallium: add interface and state tracker support for GL_AMD_pinned_memoryMarek Olšák2015-02-171-0/+1
| | | | | | v2: add alignment restrictions to docs, fix indentation in headers Reviewed-by: Christian König <[email protected]>
* gallium: Add MULTISAMPLE_Z_RESOLVE capAxel Davy2015-02-061-0/+2
| | | | | | | | | | | | | | | | Resolving a multisampled depth texture into a single sampled texture is supported on >= SM4.1 hw. It is possible some previous hw support it. The ability was tested on radeonsi and nvc0. Apparently is is also supported for radeon >= r700. This patch adds the MULTISAMPLE_Z_RESOLVE cap and add it to the drivers. It is advertised for drivers for which it is sure the ability is supported. Reviewed-by: Marek Olšák <[email protected]> Signed-off-by: Axel Davy <[email protected]>
* gallium/u_pstipple: add ability to specify a fixed texture unitMarek Olšák2015-02-041-1/+1
| | | | | | | E.g. r600g can use slot 17, which is outside of the API range. Reviewed-by: Glenn Kennard <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* gallium: add a cap to determine whether the driver supports offset_clampIlia Mirkin2015-02-021-0/+2
| | | | | | Signed-off-by: Ilia Mirkin <[email protected]> Reviewed-by: Glenn Kennard <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* gallium: add TGSI_SEMANTIC_VERTEXID_NOBASE and TGSI_SEMANTIC_BASEVERTEXRoland Scheidegger2014-12-161-0/+2
| | | | | | | | | | | | | | | | | | | Plus a new PIPE_CAP_VERTEXID_NOBASE query. The idea is that drivers not supporting vertex ids with base vertex offset applied (so, only support d3d10-style vertex ids) will get such a d3d10-style vertex id instead - with the caveat they'll also need to handle the basevertex system value too (this follows what core mesa already does). Additionally, this is also useful for other state trackers (for instance llvmpipe / draw right now implement the d3d10 behavior on purpose, but with different semantics it can just do both). Doesn't do anything yet. And fix up the docs wrt similar values. v2: incorporate feedback from Brian and others, better names, better docs. Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Jose Fonseca <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* gallium: Remove Android files from distribution.Matt Turner2014-12-121-1/+1
| | | | Android builds Mesa from git, so there don't need to be in the tarball.
* draw: implement TGSI_PROPERTY_VS_WINDOW_SPACE_POSITIONMarek Olšák2014-12-091-0/+2
| | | | | | | Required by Nine. Tested with util_run_tests. It's added to softpipe, llvmpipe, and r300g/swtcl. Tested-by: David Heidelberg <[email protected]>
* Remove useless checks for NULL before freeingMatt Turner2014-12-081-2/+1
| | | | | | | See commits 5067506e and b6109de3 for the Coccinelle script. Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* softpipe: use the tgsi_free_tokens() functionBrian Paul2014-10-311-6/+6
| | | | Reviewed-by: Charmaine Lee <[email protected]>
* util: simplify util_pstipple_create_fragment_shader() paramsBrian Paul2014-10-311-18/+15
| | | | | | | | Pass and return tgsi_token buffers instead of pipe_shader_state. And update softpipe driver (the only user of this function). Reviewed-by: Charmaine Lee <[email protected]>
* softpipe: remove unused softpipe_create_fs_variant_exec() parameterBrian Paul2014-10-313-5/+3
| | | | Reviewed-by: Charmaine Lee <[email protected]>
* softpipe: check for SP_NEW_STIPPLE when building quad pipelineBrian Paul2014-10-311-0/+1
| | | | | | | Fixes polygon stipple if both DO_PSTIPPLE_IN_DRAW_MODULE and DO_PSTIPPLE_IN_HELPER_MODULE are zero/off. Reviewed-by: Charmaine Lee <[email protected]>
* gallium: introduce PIPE_CAP_CLIP_HALFZ.Mathias Fröhlich2014-10-241-0/+2
| | | | | | | | | | | | In preparation of ARB_clip_control. Let the driver decide if it supports pipe_rasterizer_state::clip_halfz being set to true. v3: Initially enable on ilo. Reviewed-by: Roland Scheidegger <[email protected]> Reviewed-by: Brian Paul <[email protected]> Signed-off-by: Mathias Froehlich <[email protected]
* tgsi: change tgsi_shader_info::properties to a one-dimensional arrayMarek Olšák2014-10-042-3/+3
| | | | | | Reviewed-by: Roland Scheidegger <[email protected]> v2: fix svga too
* tgsi: remove some not so useful variables from tgsi_shader_infoMarek Olšák2014-10-042-7/+10
|
* softpipe: don't special case PIPE_TEXTURE_CUBE in softpipe_resource_layout()Brian Paul2014-09-301-2/+3
| | | | | | As with the previous patch for llvmpipe. Reviewed-by: Ilia Mirkin <[email protected]>
* gallium/softpipe,llvmpipe: add automake target 'templates'Emil Velikov2014-09-241-0/+15
| | | | | | | | Rather than duplicating the libdeps, extra define... all over the targets, define them only once and use when applicable. Signed-off-by: Emil Velikov <[email protected]> Acked-by: Matt Turner <[email protected]>
* gallium: add a texture target to sampler view and a CAP to use itIlia Mirkin2014-09-121-0/+1
| | | | | | | | | | This allows a sampler view to have a different texture target than the underlying resource. This will be used to implement the type casting between 2d arrays and cube maps as specified in ARB_texture_view. Signed-off-by: Ilia Mirkin <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]> Reviewed-by: Marek Olšák <[email protected]>
* gallium/softpipe: ship all files in the tarballEmil Velikov2014-09-052-10/+32
| | | | | | | | | - include all headers in Makefile.sources - sort the list(s) - bundle the android & scons buildscript Signed-off-by: Emil Velikov <[email protected]> Acked-by: Matt Turner <[email protected]>
* softpipe: handle vertex texture sampling when using llvm for drawRoland Scheidegger2014-08-307-34/+207
| | | | | | | | | | | | | Pretty trivial, just fill in the offsets and such. The implementation is near 100% copy and paste from llvmpipe. Should be useful for debugging. No piglit change when not using SOFTPIPE_USE_LLVM=1. Now that it can do the same tests with and without using llvm for vs/gs, with llvm more pass, the only things failing only with llvm seems to be edgeflags tests and vs/gs-pow-float-float (and for the latter I'm not convinced the zero tolerance it requires is somehow mandated by glsl). Reviewed-by: Jose Fonseca <[email protected]>
* softpipe: don't assert on illegal wrap mode for rect texturesRoland Scheidegger2014-08-301-2/+2
| | | | | | | | | | | | | | piglit tex-miplevel-selection nowadays doesn't use repeat wrap mode due to sampler objects any longer, however at the time of the clear the wrap mode is still illegal and at this point we get to verify the state, including samplers (even though they won't get used), and because mesa doesn't treat it as an incomplete texture as the spec says it should, we hit the assertion. Just warn about this for now instead. Gets crashes down from 44 to 14 in a piglit run (all were in various tests of tex-miplevel-selection with texture rectangles). Though just about all tex-miplevel-selection tests fail anyway for other reasons. Reviewed-by: Jose Fonseca <[email protected]>
* gallium: add cap for MAX_VERTEX_ATTRIB_STRIDETimothy Arceri2014-08-271-0/+2
| | | | | Signed-off-by: Timothy Arceri <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* draw: fix base instance handling in llvm pathRoland Scheidegger2014-08-281-1/+1
| | | | | | | | | | | | | The base instance needs to be passed to the jited function, otherwise the instanced data fetch will only work with the same start instance when the jit function was created (and baking that into the key instead is not a viable option). This fixes piglit arb_base_instance-drawarrays (modulo some unrelated core/compat context trouble I get for the test). And fix the pipe cap bit in llvmpipe for it now that it actually works (it already worked for softpipe). Reviewed-by: Jose Fonseca <[email protected]>
* llvmpipe/softpipe: enable ARB_conditional_render_invertedTobias Klausmann2014-08-191-1/+1
| | | | | | Reviewed-by: Ilia Mirkin <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]> Signed-off-by: Tobias Klausmann <[email protected]>
* gallium: Add and handle PIPE_CAP_CONDITIONAL_RENDER_INVERTEDTobias Klausmann2014-08-191-0/+2
| | | | | | Reviewed-by: Ilia Mirkin <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]> Signed-off-by: Tobias Klausmann <[email protected]>
* gallium/softpipe/llvmpipe: handle query_renderer capsEmil Velikov2014-08-151-0/+19
| | | | | | | | | | Both report 0xffffffff as both vendor and device id, and the maximum amount of system memory as video memory. v2: Use aux helper os_get_total_physical_memory(). Cc: Brian Paul <[email protected]> Signed-off-by: Emil Velikov <[email protected]>
* gallium: add opcodes/cap for fine derivative supportIlia Mirkin2014-08-141-0/+1
| | | | | | | Signed-off-by: Ilia Mirkin <[email protected]> Reviewed-by: Marek Olšák <[email protected]> (v1) Reviewed-by: Roland Scheidegger <[email protected]> (v1) v2: Reuse opcode gaps as suggested by Marek
* softpipe,llvmpipe: mark BPTC formats as unsupportedIlia Mirkin2014-08-121-0/+5
| | | | | | Signed-off-by: Ilia Mirkin <[email protected]> Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Roland Scheidegger <[email protected]>
* softpipe: fix sp_get_dims() for PIPE_BUFFERBrian Paul2014-07-101-6/+10
| | | | | | | | | | | | Before, we were checking the level against view->u.tex.last_level but level is not valid for buffers. Plus, the aliasing of the view->u.tex view->u.buf members (a union) caused the level checking arithmetic to be totally wrong. The net effect is we always returned early for PIPE_BUFFER size queries. This fixes the piglit "textureSize 140 fs samplerBuffer" test. Reviewed-by: Roland Scheidegger <[email protected]>