TextureCache: Implement layered framebuffer support.

Stereoscopic EFB2Tex is now supported.
GeometryShaderGen: Allow stereoscopy to be disabled.

Will facilitate future use of this generator for other purposes.
TextureCache: Check the number of layers before reusing a texture.
TextureCache: Set proper vertex limit in geometry shader.

Without instancing 6 vertices are output instead of 3.
ShaderGen: Add a stereoscopy flag in the UID data.
VertexShaderGen: Generalize GenerateVSOutputStruct().

By accepting the parent interface we can use this function in the function templates.