summaryrefslogtreecommitdiffstats
path: root/src/gallium/state_trackers
Commit message (Collapse)AuthorAgeFilesLines
...
* st/nine: Fix the calculation of the number of vs inputsAxel Davy2016-10-101-1/+1
| | | | | | | | Fixes hangs on radeonsi, and assert on llvmpipe. Signed-off-by: Axel Davy <axel.davy@ens.fr> Cc: "12.0" <mesa-stable@lists.freedesktop.org>
* st/nine: Fix specular w coordinateAxel Davy2016-10-101-4/+2
| | | | | | | Found looking at Wine formulas. Fixes a few visual issues. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Disable parts of lighting calculation if no normal providedAxel Davy2016-10-101-26/+35
| | | | | | Behaviour found in Wine sources, and checked with some test apps. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Fix condition for specular lightningAxel Davy2016-10-101-12/+11
| | | | Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Do always accumulate diffuseAxel Davy2016-10-101-3/+2
| | | | | | | According to spec. Signed-off-by: Axel Davy <axel.davy@ens.fr> Reviewed-by: Patrick Rudolph <siro@das-labor.org>
* st/nine: Initialize ps ff registersAxel Davy2016-10-101-0/+5
| | | | | | | Found with wine tests for the rTmp register. Not sure for the other ones. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Do not pollute rTmp in ff psAxel Davy2016-10-101-2/+4
| | | | | Signed-off-by: Axel Davy <axel.davy@ens.fr> Reviewed-by: Patrick Rudolph <siro@das-labor.org>
* st/nine: Allocate temporaries on demand for ps ffAxel Davy2016-10-101-14/+10
| | | | | | | | | | Same change than for vs ff. This makes it easier to not introduce mistakes reusing temporaries whose result shouldn't be erased. Signed-off-by: Axel Davy <axel.davy@ens.fr> Reviewed-by: Patrick Rudolph <siro@das-labor.org>
* st/nine: Fix texbemAxel Davy2016-10-101-2/+2
| | | | | | | | | Error found with wine tests. nine_shader was expecting another order than the one device9 was using. Signed-off-by: Axel Davy <axel.davy@ens.fr> Reviewed-by: Patrick Rudolph <siro@das-labor.org>
* st/nine: Fix ff computation for inverseAxel Davy2016-10-102-23/+6
| | | | | | | | | Thanks to wine tests. Apparently 4x4 inverse is to be used, and if the inverse can't be calculated, the input matrix is to be used. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Used normed Vtx for reflectionvectorAxel Davy2016-10-101-2/+5
| | | | | | Fix deduced from the spec. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Implement SPHEREMAPAxel Davy2016-10-102-4/+30
| | | | | | Behaviour checked with a test app. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Enable passthrough only if positiont is usedAxel Davy2016-10-101-0/+2
| | | | | | | | | | Wine tests for the passthrough feature are for positiont. Nothing seems to indicate passthrough happens when positiont it not used. However having passthrough with positiont makes sense (to be used with ProcessVertices outputs). Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Fix wrong mask in ff vsAxel Davy2016-10-101-1/+1
| | | | | Signed-off-by: Axel Davy <axel.davy@ens.fr> Reviewed-by: Patrick Rudolph <siro@das-labor.org>
* st/nine: Fix tweening factor computationAxel Davy2016-10-101-2/+2
| | | | | | | The computation was reversed. Deduced by tests on windows. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Disable ff vertex blending if required inputs are missingAxel Davy2016-10-101-2/+12
| | | | | | This behaviour has been partially tested on windows. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Use materials if source is not given.Axel Davy2016-10-101-4/+5
| | | | | | Deduced by test on windows. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Fix ff SPECULARENABLEAxel Davy2016-10-101-10/+3
| | | | | | | | | | | | | | | We were (wrongly) adding specular to diffuse in vertex shaders when SPECULARENABLE was set. However the spec says specular has to be added after texture processing (which is in ps). Besides SPECULARENABLE is flagged as a pixel state. There was unused support for SPECULARENABLE in the ps ff code. Remove the vs code, and use the ps code. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Undefined specular should be full of zerosAxel Davy2016-10-101-6/+6
| | | | | Signed-off-by: Axel Davy <axel.davy@ens.fr> Reviewed-by: Patrick Rudolph <siro@das-labor.org>
* st/nine: Implement normal transformation with vertex blendingAxel Davy2016-10-101-5/+21
| | | | | | | The formula is different from the one of the spec, but otherwise nothing particular. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Increase MaxVertexBlendMatrixIndexAxel Davy2016-10-102-5/+5
| | | | | | Modern cards do advertise 8. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Compact ff vs constants a bitAxel Davy2016-10-101-9/+9
| | | | | | | | There are several holes. This patch reduces the holes a bit, which reduces the size of the constant buffer uploaded. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Fix vertex blending aVtx computationAxel Davy2016-10-101-17/+10
| | | | | | | There was an multiplication by the world matrix 0 which had nothing to do there. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Reorganize ff vtx processingAxel Davy2016-10-101-52/+72
| | | | | | | The new order simplified the code a bit for next patches. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Small simplification for position_t and fogAxel Davy2016-10-101-6/+3
| | | | | | position_t disables fog computation. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Cleaning code for vs temporariesAxel Davy2016-10-101-98/+135
| | | | | | | | | | | | | | | | | This has been a real mess up to now: the temporaries were allocated once, and shared after that between the different parts of the code. To help maintaining the code, the temporaries are now allocated and released on need. As surprising as it could be, this patch, which was supposed to introduce no behaviour change, actually solved a visual bug observed on a sample program. This was due to ureg_normalize3 polluting a temporary variable. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: No need for the local flag for temporaries in ffAxel Davy2016-10-101-2/+2
| | | | | Signed-off-by: Axel Davy <axel.davy@ens.fr> Reviewed-by: Patrick Rudolph <siro@das-labor.org>
* st/nine: Handle D3DRS_NORMALIZENORMALSAxel Davy2016-10-101-2/+5
| | | | | | | | When this state is set, the normals computed in the vs ff shader should be normalized. Signed-off-by: Axel Davy <axel.davy@ens.fr> Reviewed-by: Patrick Rudolph <siro@das-labor.org>
* st/nine: Initial ProcessVertices supportAxel Davy2016-10-1011-69/+735
| | | | | | | | For now only VS 3 support is implemented. This enables The Sims 2 to work. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Partial software vertex processing supportAxel Davy2016-10-108-60/+322
| | | | | | | | | | | | | | | | | | | | | | | | Software Vertex Processing allows: . Less limitations for shaders (more loops, etc) . Less limitations for ff (more enabled lights, 255 matrices for VertexBlend) In particular shaders can get more constants. This patch implements support for this (not using software rendering, but hardware rendering, as llvmpipe and dx10+ hw have the same limits...) This is considered a second class path. Even apps asking for "Mixed Vertex processing" (ie the ability to switch to swvp on demand) do not use the feature much. Some just initialize more constants than the normal limit at the start of the application, but never use more than the normal limit. When the apps do not need the software vertex processing features, they do not seem to turn it on. This means it is ok if that path is slow. Thus no care has been made to make the path optimized. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Rework vs int and bool constants bufferAxel Davy2016-10-104-24/+37
| | | | | | This will help to support swvp constants. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Change dirty tracking for vs int and bool constantsAxel Davy2016-10-104-22/+56
| | | | | | | This change makes easier to introduce tracking for swvp constants. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Drop unused constant upload pathAxel Davy2016-10-103-210/+4
| | | | | | | | | This path has been disabled for some time because of some bugs with it. It hasn't been updated to the new features, and is not faster. Signed-off-by: Axel Davy <axel.davy@ens.fr> Reviewed-by: Patrick Rudolph <siro@das-labor.org>
* st/nine: Add support for swvp constants in shadersAxel Davy2016-10-103-37/+125
| | | | | | | swvp has relaxed limits (more nested loops, etc). In particular it enables more constants. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Initial mixed vertex processing supportAxel Davy2016-10-102-5/+16
| | | | | | | | | | In mixed vertex processing, the user can enable or disable software vertex processing. It is on hardware by default. This feature is not a state, and thus the setting doesn't need to be recorded by stateblocks. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Implement SetNPatchModeAxel Davy2016-10-101-1/+1
| | | | Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Implement D3DUSAGE_SOFTWAREPROCESSINGAxel Davy2016-10-101-2/+3
| | | | | | | | Buffers with this flag must be usable with both software and hardware vertex processing. Use Staging for fast cpu access. Signed-off-by: Axel Davy <axel.davy@ens.fr> Reviewed-by: Patrick Rudolph <siro@das-labor.org>
* st/nine: Allocate more space for ATI1Patrick Rudolph2016-10-102-6/+17
| | | | | | | | | | | | | | ATIx are "unknown" formats that do not follow block format conventions. Tests showed that pitch*height bytes are allocated. apitrace used to depend on this behaviour. It used to copy more bytes than it has to for the ATI1 block format, but it didn't crash on Windows. Increase buffersize for ATI1 to fix this crash. The same issue was present in WINE but a patch has been sent by me. Signed-off-by: Patrick Rudolph <siro@das-labor.org> Reviewed-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Add missing breakPatrick Rudolph2016-10-101-0/+1
| | | | | | | Add missing break instruction. Signed-off-by: Patrick Rudolph <siro@das-labor.org> Reviewed-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Implement relative addressing for ps inputsAxel Davy2016-10-101-3/+27
| | | | | | | | | To implement the feature we copy the ps inputs to a temp array. This is not optimal for performance, but it is the simplest solution. This is a feature that is very very rarely used. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Wait for pending tasks to execute in swapchainAxel Davy2016-10-101-0/+4
| | | | | | Fixes crash after Reset() when using thread_submit=true Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Use fixed size arrays for swapchain buffersAxel Davy2016-10-102-40/+11
| | | | Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Fix buffer count check for Ex devicesPatrick Rudolph2016-10-101-5/+4
| | | | | 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-102-2/+2
| | | | | | d3d9 doesn't have seamless cubemap. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Fix some check flagsAxel Davy2016-10-101-11/+12
| | | | | | | Uses the new defines introduced in previous commit. See comment in the commit for more explanation. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Unify some check flagsAxel Davy2016-10-102-4/+12
| | | | | | The new defines will be reused in a later patch. Signed-off-by: Axel Davy <axel.davy@ens.fr>
* st/nine: Memset pipe_resource templatesAxel Davy2016-10-102-0/+8
| | | | | | | | | | | | Fixes regression introduced by ecd6fce2611e88ff8468a354cff8eda39f260a31 and is more future proof than just clearing the next field. Other nine usages did already zero out the templates. Signed-off-by: Axel Davy <axel.davy@ens.fr> Acked-by: Edward O'Callaghan <funfunctor@folklore1984.net>
* st/xvmc/tests: force enable assertionsEmil Velikov2016-10-061-0/+2
| | | | | | | | | | Similar to the other 'tests', enable assertions in xvmc_bench. This silences the GCC warnings about unused-variable(s), makes the program actually useful, as the XvMC API called. Atm the function calls are omitted, since they're called within the assert. Signed-off-by: Emil Velikov <emil.velikov@collabora.com>
* st/omx/dec/h265: add scaling list dataLeo Liu2016-10-041-5/+97
| | | | | | | | | Specified by subclause 7.3.4 v2: get the loop optimized Signed-off-by: Leo Liu <leo.liu@amd.com> Reviewed-by: Christian König <christian.koenig@amd.com>
* st/omx/dec/h265: fix the skip for before and after listLeo Liu2016-10-041-3/+4
| | | | | | | | | | For reference picture sets, there are cases that rps will not always be used. Once detect the unused flag from encoded bitstream, we should not add this rps to any list, otherwise pass the incorrect reference and skip the correct rps. Signed-off-by: Leo Liu <leo.liu@amd.com> Reviewed-by: Emil Velikov <emil.velikov@collabora.com>