summaryrefslogtreecommitdiffstats
path: root/src/gallium/state_trackers/nine/nine_pipe.c
Commit message (Collapse)AuthorAgeFilesLines
* st/nine: Set CLAMP_TO_EDGE on cubetexturesPatrick Rudolph2016-10-101-3/+11
| | | | | | | | | | | Wine tests show that cubetextures always use PIPE_TEX_WRAP_CLAMP_TO_EDGE regardless of set sampler states. Fixes failing d3d9 wine test test_cube_wrap. Signed-off-by: Patrick Rudolph <siro@das-labor.org> Reviewed-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Disable seamless cubemap for d3dAxel Davy2016-10-101-1/+1
| | | | | | d3d9 doesn't have seamless cubemap. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Use offset_units_unscaledAxel Davy2016-06-251-9/+9
| | | | | | | | | | | | offset_units_unscaled enables proper support for depth bias for gallium nine. Use it if available. Solves issues with some games using depth bias. For example: https://github.com/iXit/Mesa-3D/issues/220 Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Fix usage of rasterizer multisample bit.Axel Davy2016-05-181-1/+1
| | | | | | | | | | | pipe_rasterizer multisample bit should be enabled only when really wanting to do multisampling, thus we should disable when not having msaa render target. This fixes some depth calculation precision issues on radeon. Also disable it when depth and stencil tests are disabled, since in that case multisampling is same as not multisampled. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: ATOC has effect only with ALPHATESTENABLEAxel Davy2016-05-181-1/+1
| | | | | | | ATOC extension does something only when alpha test is enabled. Use a second bit to encode the difference with ATIATOC. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Add support for X8L8V8U8Axel Davy2016-05-181-2/+2
| | | | | | | | | | | | | | X8L8V8U8 support should be common. Some more recent cards do support this format, but not L6V5U5. Add fallback for this format to have it alwaus supported. L6V5U5 conversion rule apparently differs a bit from the normal spec, and thus the gallium equivalent format leads to slightly wrong colors. Since some recent cards do not support it, do not support it either. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Use linear filtering for shadow mappingAxel Davy2016-02-041-2/+3
| | | | | | | | Some docs say linear filtering is always used when app does shadow mapping. Signed-off-by: Axel Davy <axel.davy@ens.fr> Reviewed-by: Patrick Rudolph <siro@das-labor.org>
* st/nine: Support D3DFMT_R8G8B8Patrick Rudolph2016-02-041-3/+3
| | | | | | | | | | | | | | | | Add support for D3DFMT_R8G8B8. It allows format conversion for surfaces of pool scratch. Usually gallium formats equivalents for d3d9 formats have their names reversed. The gallium format PIPE_FORMAT_R8G8B8_UNORM is the right equivalent here, and its name is likely wrong (reversed). Fixes a crash in TmNationsForever. Signed-off-by: Patrick Rudolph <siro@das-labor.org> Reviewed-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Use CSO cache for sampler viewsAxel Davy2015-08-211-2/+2
| | | | | | | | The CSO cache unbinds views that are not needed anymore, which we don't do. It checks for change before committing the views. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Remove NINED3DRS_ZBIASSCALEAxel Davy2015-08-211-1/+11
| | | | | | | | | It wasn't giving the expected result. This fixes some object being transparents in games like FEAR. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Rework blend statesAxel Davy2015-08-211-2/+2
| | | | | | Separate state preparation and state commit Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Rework rasterizer statesAxel Davy2015-08-211-4/+3
| | | | | | Separate state preparation and state commit Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Reorder DSA state settingsAxel Davy2015-08-211-2/+3
| | | | | | Separate state preparation and state commit Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Account POINTSIZE_MIN and POINTSIZE_MAX for point sizePatrick Rudolph2015-08-211-1/+7
| | | | | | | | | | When using D3DRS_POINTSIZE make sure the value is at least D3DRS_POINTSIZE_MIN but not greater than D3DRS_POINTSIZE_MAX. Fixes some Wine tests. Reviewed-by: Axel Davy <axel.davy@ens.fr> Signed-off-by: Patrick Rudolph <siro@das-labor.org>
* st/nine: Always set point_quad_rasterization to 1Axel Davy2015-08-211-1/+1
| | | | | | | Both Points and Point Sprites are rasterized like quads, according to d3d9 doc and gallium rasterizer doc. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* gallium: replace INLINE with inlineIlia Mirkin2015-07-211-1/+1
| | | | | | | | | | | | | | | | 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 <imirkin@alum.mit.edu> Acked-by: Marek Olšák <marek.olsak@amd.com>
* st/nine: Implement AMD alpha to coverageAxel Davy2015-02-061-1/+1
| | | | | | | | | This D3D hack is supposed to be supported by all AMD SM2+ cards. Apps use it without checking if they are on AMD. Reviewed-by: Tiziano Bacocco <tizbac2@gmail.com> Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Refactor format d3d9 to pipe conversionAxel Davy2015-02-061-1/+1
| | | | | | | | | | | Move the checks of whether the format is supported into a common place. The advantage is that allows to handle when a d3d9 format can be mapped to several formats, and that cards don't support all of them. Reviewed-by: Tiziano Bacocco <tizbac2@gmail.com> Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Refactor nine_d3d9_to_pipe_format_mapAxel Davy2015-02-061-79/+44
| | | | | | | | | | The order of the format is changed to have an increasing ordering of the d3d9 format values. Some missing formats are added and matched to PIPE_FORMAT_NONE Reviewed-by: Tiziano Bacocco <tizbac2@gmail.com> Signed-off-by: Axel Davy <axel.davy@ens.fr>
* nine: Add state tracker nine for Direct3D9 (v3)Joakim Sindholt2014-11-181-0/+410
Work of Joakim Sindholt (zhasha) and Christoph Bumiller (chrisbmr). DRI3 port done by Axel Davy (mannerov). v2: - nine_debug.c: klass extended from 32 chars to 96 (for sure) by glennk - Nine improvements by Axel Davy (which also fixed some wine tests) - by Emil Velikov: - convert to static/shared drivers - Sort and cleanup the includes - Use AM_CPPFLAGS for the defines - Add the linker garbage collector - Restrict the exported symbols (think llvm) v3: - small nine fixes - build system improvements by Emil Velikov v4: [Emil Velikov] - Do no link against libudev. No longer needed. Acked-by: Jose Fonseca <jfonseca@vmware.com> Reviewed-by: Marek Olšák <marek.olsak@amd.com> Reviewed-by: Axel Davy <axel.davy@ens.fr> Signed-off-by: David Heidelberg <david@ixit.cz>