Hello!
In my vertex shader I am using two tbuffers. The first tbuffer is an array of World transform matrices, used for normal transformations for lighting. The other tbuffer is an array of WorldViewProjection matrices, used for transforming vertex positions.
What I do now is to calculate both matrix arrays on the CPU and send them to the GPU. However, I figured that I could just generate the second tbuffer from first tbuffer on the GPU by multipling every element in the first tbuffer with a ViewProjection matrix that is located in a cbuffer.
What ways are there to implement "tbuffer2 = tbuffer1 * cbuffer.ViewProj;" on the GPU?
Cheers!