Fold layout transitions into subpass (Refs #155), refactoring of offscreen render pass

This commit is contained in:
saschawillems 2016-08-13 15:41:36 +02:00
parent 7918e0c435
commit cb5bd093ec
6 changed files with 188 additions and 331 deletions

View file

@ -10,7 +10,6 @@ layout (binding = 0) uniform UBO
{
mat4 projection;
mat4 model;
vec4 glowColor;
} ubo;
layout (location = 0) out vec3 outColor;
@ -22,8 +21,6 @@ out gl_PerVertex
void main()
{
{
outColor = inColor;
}
outColor = inColor;
gl_Position = ubo.projection * ubo.model * inPos;
}

View file

@ -7,8 +7,6 @@ layout (binding = 1) uniform sampler2D samplerColor;
layout (binding = 2) uniform UBO
{
int texWidth;
int texHeight;
float radialBlurScale;
float radialBlurStrength;
vec2 radialOrigin;
@ -20,7 +18,8 @@ layout (location = 0) out vec4 outFragColor;
void main()
{
vec2 radialSize = vec2(1.0 / ubo.texWidth, 1.0 / ubo.texHeight);
ivec2 texDim = textureSize(samplerColor, 0);
vec2 radialSize = vec2(1.0 / texDim.s, 1.0 / texDim.t);
vec2 UV = inUV;