[Freedreno] [PATCH 2/3] a3xx: make use of software clipping when hw can't handle it

2016-08-30 Thread Ilia Mirkin
The hw clipper only handles up to 6 UCPs. If there are more than 6 UCPs, or a clip vertex, or clip distances are in use, then we must use the fallback discard-based clipping from the frag shader. Signed-off-by: Ilia Mirkin Cc: mesa-sta...@lists.freedesktop.org ---

[Freedreno] [PATCH 3/3] a3xx: use window scissor to simulate viewport xy clip

2016-08-30 Thread Ilia Mirkin
Unfortunately a3xx does not have a separate disable for depth clipping, so when depth clamp is enabled, we disable the whole 3d clipper logic. This in turn also gets rid of the xy clip that it would normally do. When we detect this would happen, instead we integrate the viewport into the window