summaryrefslogtreecommitdiffstats
path: root/doc/src/snippets/code/src_script_qscriptclass.cpp
diff options
context:
space:
mode:
authorTom Cooksey <thomas.cooksey@nokia.com>2010-01-20 09:18:32 (GMT)
committerJesper Thomschutz <jesper.thomschutz@nokia.com>2010-01-28 15:42:54 (GMT)
commit97b2f3e45c34cdbeed7c7fa4a2aa2b42dc7cfd44 (patch)
treec1da418b5616e2cb2b73246e4dc64619d702dea2 /doc/src/snippets/code/src_script_qscriptclass.cpp
parent3cb0f2fc95de3920a9223764790a1385e5b74fcb (diff)
downloadQt-97b2f3e45c34cdbeed7c7fa4a2aa2b42dc7cfd44.zip
Qt-97b2f3e45c34cdbeed7c7fa4a2aa2b42dc7cfd44.tar.gz
Qt-97b2f3e45c34cdbeed7c7fa4a2aa2b42dc7cfd44.tar.bz2
Use an attribute value for the PMV matrix rather than a uniform
This has several advantages: First, updating an attribute value seems to be cheaper than updating a uniform. Second, vertex atribute values are independent of shader program, which means they persist across changing of the shader program. This makes code simpler and reduces GL state changes. Note: Credit goes to Samuel for finding this little gem. :-) For the 25920 solid QGraphicsRectItem test case, this gives 10% improvement on desktop and 27% on the SGX. Reviewed-By: Kim
Diffstat (limited to 'doc/src/snippets/code/src_script_qscriptclass.cpp')
0 files changed, 0 insertions, 0 deletions