Gfx.waitForPresent taking a lot of CPU time in Unity? That means the CPU is waiting for the GPU - so ignore the CPU times and profile the GPU.
http://forum.unity3d.com/threads/gfx-waitforpresent.211166/
Thursday, 14 May 2015
Sunday, 10 May 2015
GLSL constant buffers - alignment problems
Uniform buffers in GLSL - arrays of mats seem to destroy the alignment of the values afterwards.
layout(std140) uniform ConstantB
{
uniform mat4 views[6];
uniform float texCoord; <-- this doesn't work.
uniform float gamma;
uniform float interp;
uniform float brightness;
}
layout(std140) uniform ConstantB
{
uniform mat4 views[6];
uniform float texCoord; <-- this doesn't work.
uniform float gamma;
uniform float interp;
uniform float brightness;
}
Subscribe to:
Posts (Atom)