Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 39284b76 authored by Romain Guy's avatar Romain Guy
Browse files

Make gradients beautiful again

Bug #7239634

This change passes two matrices to the vertex shader instead of one.
We used to compute the final MVP matrix on the CPU to minimize the
number of operations in the vertex shaders. Shader compilers are
however smart enough to perform this optimization for us. Since we
need the MV matrix to properly compute gradients dithering, this
change splits the MVP matrix into two. This has the advantage of
removing one matrix multiplication per drawing operation on the
CPU.
The SGX 540 shader compiler produces the same number of instructions
in both cases. There is no penalty hit with having two matrices
instead of one. We also send so few vertices per frame that it
does not matter very much.

Change-Id: I17d47ac4772615418e0e1885b97493d31435a936
parent bd43152b
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment